Skip to content

Polyglot gate fidelity + feature-cycle signals#246

Merged
qwerfunch merged 4 commits into
developfrom
feature/multilang-gate-and-cycle-signals
Jul 21, 2026
Merged

Polyglot gate fidelity + feature-cycle signals#246
qwerfunch merged 4 commits into
developfrom
feature/multilang-gate-and-cycle-signals

Conversation

@qwerfunch

Copy link
Copy Markdown
Owner

2026-07-21 · feature/multilang-gate-and-cycle-signals → develop

The gate now reads and reports non-JavaScript projects honestly, and it nudges when the spec-first feature cycle isn't being driven.

Heads-up: the new cycle signals are all advisory — informational, they never change a gate's exit status on their own. The polyglot changes affect how existing findings are reported (more granular lint, deduped test runs), not what passes. Rebased onto the latest develop so it ships alongside the 0.9.1 adoption-capabilities fix (#245); derived files were reconciled against the merged tree and the strict pre-push gate is green across 2602 tests.

Added — feature-cycle signals

Nudge when sustained source edits are bound to no feature. Once edits to files no feature tracks pass a small threshold, the post-edit card surfaces one advisory to start a feature — so the spec-first cycle gets triggered instead of silently skipped. Debounced, once-per-window, never blocks.
clad check flags unenforced projects. When features aren't done yet but neither a git hook nor CI wires the gate, the check prints one advisory — with how to wire enforcement. Informational only; it never changes the exit status.
Cold-start signal. When a project has code but no feature specs, the cycle simply hasn't started — the gate now says so plainly instead of looking clean.
Onboarding hands off to authoring the first feature spec, not straight to code, and writing code ahead of its spec is caught both at that handoff and at the resting state.

Changed — polyglot gate fidelity

Check-only formatters now list every dirty file, not just the first. dart format (and peers like dotnet format) print one changed-file line each; those aren't ESLint-shaped, so the lint stage used to collapse them to a single pathless finding — fix one, re-run, the next appears. Each dirty file now surfaces as its own finding with its path, plus a one-line fix: hint.
Python projects run the suite once per gate, not twice. The unit and coverage stages each spawned the whole pytest suite (pytest, then coverage run -m pytest) — roughly doubling gate time. The unit stage now runs the coverage-instrumented suite once and shares it, the same dedup vitest already had. The zero-executed-tests guard still applies on the shared run, so the dedup can't turn a vacuous run green.
The header-comment convention check understands more languages# comments and Python docstrings (""", '''), not only // / /*.

Fixed

Soft-shell jargon leaks closed and plain-language enforcement tightened — user-facing output stays in plain words rather than leaking internal cladding terms.

🤖 Generated with Claude Code

qwerfunch and others added 4 commits July 21, 2026 11:44
Land the in-flight pytest/convention-drift work and add three
feature-cycle signals, each authored spec-first (shard → sync →
implement → tests → clad done, strict gate GREEN).

- pytest test-run dedup (F-49f6f2d2): on pytest projects the unit and
  coverage stages now share ONE coverage-instrumented run instead of
  spawning the whole suite twice; the zero-executed-tests guard learned
  pytest's `collected 0 items` and applies on the shared run, so the
  dedup can never pass a vacuous run.
- lint multi-finding + fix hint (F-4643d99d): check-only formatters
  (dart/dotnet) now list EVERY dirty file with its path, plus a one-line
  `fix: run` hint — not just the first line collapsed to one finding.
- unbound-edit nudge (F-f9891175): a non-blocking, debounced,
  once-per-window post-edit card when source edits keep resolving to no
  feature, so the spec-first cycle gets triggered instead of skipped.
- enforcement advisory (F-f4e184f7): `clad check` flags a project that
  has undone features but neither a git hook nor CI enforcing the gate.
  Informational only; never changes the exit status.
- convention-drift: recognise `#` comments and Python docstrings.

Rebuilt bundle + plugin mirrors; READMEs + CHANGELOG updated. Strict
pre-push gate GREEN — 2586 tests, 41 detectors, 258 features (255 done).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…ment

The plain-language audit found the Soft Shell discipline (plain, host-
relayable user output; internal terms only in the Iron Core) is real and
tested, but the two enforcing tests had blind spots — they scanned only
DETECTOR_PLAIN `action` (not `lead`) and banned MCP names + "shard" but
not raw detector-name / stage-id leads. Several leaks slipped through.

Closed (user-facing only; code comments, field names, and the structured
Tier-A provenance banner stay Iron Core by design):
- softShell.ts: INVENTORY_DRIFT lead said "shard files" → "spec files".
- clad.ts: the `clad check` footer said "spec shards" / "the offending
  detector"; the `clad sync` note leaked a raw `stage_2.4`.
- done.ts: the git-op and no-feature refusals said "shard".
- hook.ts: the SessionStart stop-block line led with a raw detector name
  (AC_DRIFT) — now rendered via plainLead.
- init.ts: the scenarios README prose named `clad_create_feature`.

Tightened so it can't recur:
- plain-render.test.ts now scans each `lead` for "shard" and MCP names.
- human-first-cards.test.ts asserts the seeded stop-block detector is
  rendered as its plain lead, never the raw id.

Per-language: the behavior-triggered signals (unbound nudge, enforcement
advisory) fire from one English source regardless of the user's language
(proven with a Korean-titled spec + Korean-named path; slugs stay ASCII
machine ids by schema, human titles/paths are any language). Three host-
relay checks (ko/ja/zh) confirmed the emitted English relays cleanly with
no jargon leak.

New feature F-ebbb20af, authored spec-first; strict pre-push gate GREEN —
2593 tests, 41 detectors, 259 features (256 done). AB report metrics
refreshed for the shorter scenarios README.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…state

A real dogfood exposed the failure the unbound-edit nudge only partially
covers: after onboarding, a host read "ordinary development can begin" as
"write code now" and scaffolded a whole project with features: [] — the
feature cycle never started, and cladding stayed silent (the nudge is
reactive and source-edit-triggered; the enforcement advisory needs an
undone feature; no detector flags a young project's unbound code). The fix
layers the signal across every moment the cycle can be skipped, with the
gate as the only hard backstop.

- Onboarding handoff (F-195cb59e): the init host instruction and the CLI
  clarify completion now steer to authoring the first feature's spec — its
  acceptance criteria and the files it will cover — BEFORE writing code,
  instead of a bare "ordinary development can begin". Names WHAT the spec
  contains, in plain language, across all four host mirrors.
- Cold-start / resting state (F-be5306eb): a graduated featureCycleAdvisory
  — the cold-start signal ("source code but no feature specs — the cycle
  hasn't started") when un-started, else the enforcement advisory — surfaced
  at the SessionStart card (every session) and the clad check footer. Source
  presence is detected with the scan walker (vendor dirs ignored, early
  exit). Non-blocking; never changes the exit status.

Layers: ① handoff steer · ② the existing unbound-edit nudge (in-flight) ·
③ SessionStart + clad check cold-start signal · hard backstop = the gate
(UNMAPPED_ARTIFACT once ≥8 features, clad done honesty). Re-verified live:
a features:[] + code project now surfaces the cold-start signal via both
clad check and the SessionStart card; the handoff steer reached every host.

Both features authored spec-first; strict pre-push gate GREEN — 2602 tests,
41 detectors, 261 features (258 done).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Rebasing this branch onto develop — which now carries the 0.9.1
adoption-capabilities fix (#245) — left the harness-written files holding
their pre-rebase versions. Re-derived them against the merged tree:
rebuilt the dist bundle, re-synced the spec inventory, regenerated the
case-existing-adoption A/B report (capabilities-body byte-count shift), and
re-stamped the attestation. Strict pre-push gate GREEN across 2602 tests.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@qwerfunch
qwerfunch merged commit 1abb54f into develop Jul 21, 2026
1 check passed
@qwerfunch qwerfunch mentioned this pull request Jul 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant