Commit Graph

15 Commits

Author SHA1 Message Date
Brummel edbbb68f97 feat(agents): pin explicit reasoning effort on every agent and workflow call
Effort joins model as a mandatory pin: an omitted field inherits the
session effort, coupling every dispatch's thinking budget to whatever
the user happens to be chatting at (often xhigh) — the same
session-state coupling the model pin removes. The assignment follows
the model split:

- xhigh on every opus agent (judgement roles are the pipeline's
  quality floor and must not degrade with the session);
- high on every sonnet agent (tightly-scoped plan execution gains
  little from xhigh but pays its latency per dispatch, and these are
  the per-task in-loop roles — wall-clock is the efficiency metric;
  not lower than high, since re-loops cost more than saved thinking);
- medium inline in the workflow scripts for schema-bound
  extraction/verification stages that author no code (preflight,
  plan-extract, mini-verify, tree-check, finalize, build/suite
  verify).

Workflow agent() calls pass effort explicitly on every call — whether
frontmatter effort propagates through an agentType dispatch is
undocumented, so the scripts do not rely on it. Policy documented in
docs/agent-template.md § effort, mirroring § model.
2026-07-02 15:43:36 +02:00
Brummel 6bfec9655c feat(agents): pin explicit model on every agent and workflow call
Agents and workflows previously carried no model field, so every
dispatch inherited the session model — including fable, which is
banned for all plugin agents and workflows by owner decree. Every
dispatch now pins opus or sonnet explicitly.

- opus (low-volume judgment gates whose misses silently poison
  downstream work): architect, bencher, debugger, fieldtester,
  grounding-check, plan-recon, quality-reviewer, spec-skeptic,
  tdd-author
- sonnet (mechanical scope, in-loop or fanned out): docwriter,
  glossary-extractor, implementer, spec-reviewer, synthetic-user,
  tester
- workflows: all 13 agent() call sites pin a model — sonnet
  everywhere except the quality-reviewer gate in implement-loop,
  the loop's last correctness check (spec-reviewer only gates
  task-text correspondence; real-bug finding is the documented
  opus strength)
- docs/agent-template.md: model is now a mandatory frontmatter
  field, with the assignment rule and the fable ban recorded
2026-07-02 12:14:36 +02:00
Brummel ea54be6535 refactor(pipeline): ignore specs/plans via project-local docs/.gitignore
Replace the global ~/.config/git/ignore mechanism with a committed,
per-project docs/.gitignore whose entries `specs/` and `plans/` are
relative to docs/. The ignore now travels with each repo instead of
living in the user's global excludes.

specify (Step 3) and planner (intro) create docs/.gitignore on demand
if a project has not set it up yet, so a spec/plan can never become
committable. conventions.md § File layout is the single source; the
onboarding fragment tells a new project to set it up.

The global ~/.config/git/ignore block is removed separately (it is
outside this repo).
2026-07-02 11:53:59 +02:00
Brummel 08bc2aa027 refactor(pipeline): specs/plans are gitignored working files, never committed
Per-cycle specs and plans stop being git-tracked commit-then-git-rm
artefacts and become git-ignored working files: created on disk for the
active cycle, read across sessions from the working tree, and shell-rm'd
at cycle close by audit. Nothing is committed, so there is no
git-history copy — the durable record of a cycle's intent is the design
ledger only, and no durable artefact (code, test, doc, ledger) may cite
a spec/plan by number or path.

- conventions/pipeline/design/README: invert the git-tracked -> git-rm
  -> git-history-recovery model to gitignored -> shell-rm -> ledger-only.
- naming: drop the NNNN file counter; files are slug.md (fieldtest specs
  keep a fieldtest- prefix as the cycle-close discriminator).
- cycle number: separated from the (now-gone) file number, sourced from
  the feat(NNNN)/audit(NNNN) commit subjects, which cycle commits carry.
- specify/planner/fieldtest/fieldtester: no commit step; fieldtest splits
  fixtures (committed as code) from its spec (gitignored), with the
  cross-cycle rule that a fieldtest- spec belongs to the next cycle.
- boss: auto-sign auditability moves from the (boss-signed) commit
  subject to the run's reference issue; rollback reverts only code.
- audit: new Step 5 shell-rm's the cycle spec+plan after the architect
  reads them, sparing fieldtest- specs.

Companion machine config (outside this repo): the global git excludes
(~/.config/git/ignore) gains docs/specs/ and docs/plans/ so the ignore
applies to every project at once.
2026-07-02 11:35:06 +02:00
Brummel 012e70b058 docs: make specs/plans git-tracked and transient — retired via git rm at cycle close
docs/specs and docs/plans hold only the active cycle's artefacts: a spec/plan is committed while its cycle is live and git-rm'd in the cycle-close commit (after audit drift-clean), so HEAD shows only in-flight work while git history keeps the full text. No issue-posting, no gitignore branch — git history + the design ledger are the durable record.

Rewrites conventions.md § Lifecycle as the single source of truth; pipeline.md, design.md, README.md, specify, planner, glossary, brainstorm, issue, and the CLAUDE.md fragment follow it. Naming stays NNNN-slug.md (a within-cycle handle; recycling on an emptied directory is fine).
2026-06-18 11:59:45 +02:00
Brummel 82cd9eafb2 refactor: drop cross-project spec-validation parser machinery
The fence-label -> parser fact, the specify/grounding-check/planner
parse gates, the parse-trace attestation, and all their cross-references
served a single real user (ailang). Convention over configuration: the
generic machinery is removed plugin-wide; the one consumer carries an
equivalent project-local directive in its own CLAUDE.md.

Archive under docs/plans and docs/specs left intact as time documents.
2026-06-15 10:13:13 +02:00
Brummel 26e9630496 refactor: drop dev-cycle-profile.yml for conventions + CLAUDE.md facts
The profile was never parsed — it was prose the skill bodies told the model to read, so most slots were dead, constant across every project, or fiction (the whole pipeline block, including the "tdd is opt-in" claim, was enforced by nothing).

Split it in two: constants become fixed conventions named directly by the skills (new docs/conventions.md), and the few genuinely per-project facts move to each project's CLAUDE.md under '## Skills plugin: project facts'. tdd/fieldtest/docwriter are now always available; the only behavioural toggle left is spec auto-sign.

Delete docs/profile-schema.md and templates/project-profile.yml; add docs/conventions.md and a project-facts section to templates/CLAUDE.md.fragment; rewrite all SKILL/agent prose and the pipeline/design/migration/README/INSTALL docs accordingly.
2026-06-13 16:30:02 +02:00
Brummel f7758818ab audit(specify): close cycle — repair planner, grounding-check, schema drift
Architect drift review (cycle 9e8b9ec..HEAD) returned drift_found. Three
cycle-introduced items, all repaired here as tidy edits:

- planner/SKILL.md: the cycle never touched it (recon never scoped it,
  the feat commit body's "every pipeline rendering agrees" over-claimed).
  Its Handoff Contract still named `brainstorm → planner` and the bounce
  `planner → brainstorm`; the Input-source cross-ref and two
  rationalisation rows still pointed at brainstorm as the spec producer.
  All repointed to specify (specify produces and owns the spec; brainstorm
  is the optional discovery stage upstream of it). The skip rule now lists
  specify in the design path tdd bypasses.
- specify/agents/grounding-check.md: the agent move left one stale pair —
  "self-review (Step 7) and user-approval (Step 8)" were brainstorm's old
  numbers; in specify they are Step 4 and Step 6.
- profile-schema + template: the `optional: true` per-phase key I
  introduced in the plan was undocumented AND rested on a semantic error —
  `brainstorm: { gates: [specify] }` reads as "specify cannot start until
  brainstorm has run", which is false (specify enters directly from
  sources). Corrected to `brainstorm: {}` (an active phase with no hard
  gate of its own, like implement); specify keeps `gates: [planner]` as
  the one real hard gate. The optional key is gone; brainstorm's
  optionality lives in the skip rules and SKILL prose, where it belongs.

Why these escaped the cycle's own grep suite: the consistency greps used
`brainstorm *-> *planner`, which does not match the real renderings
`` `brainstorm` -> `planner` `` (backticks between the words). The same
filter-string blind spot recurred twice this session; the verification
greps here tolerate optional backticks.

Pre-existing debt (NOT cycle-introduced), filed as backlog Brummel/Skills
issue #5 rather than fixed here: docs/migration.md's layout tree and
README's migration-status both predate tdd/glossary/pseudo/issue/
postmortem and misdescribe the roster.

Verdict: cycle drift-clean after these repairs (carry-on). No regression
gate (prose repo, no scripts). Not a milestone close.
2026-06-04 23:25:03 +02:00
Brummel 137ec21e26 docs(tdd): wire sibling skills to the new entry path
The tdd skill referenced its neighbours (implement, brainstorm,
debug) but none referenced it back. Close the loop so the new
executable-spec-first entry path is reachable and consistent from
every skill that describes a relationship it now belongs to:

- implement: mini-mode trigger + dispatch example now cover a
  RED-first handoff from `debug` OR `tdd` (was debug-only); the
  orchestrator's task template and Phase-3 skip note generalised.
  This was real drift — mini-mode is no longer debug-exclusive.
- planner: skip rule gains the `tdd` case (it skips brainstorm
  AND planner — the RED executable-spec is the plan).
- brainstorm: `tdd` added to the permitted-skip list as the
  profile-gated alternative entry path, plus a cross-ref marking
  brainstorm as the bounce-back target when behaviour stops being
  test-specifiable.
- boss: pipeline diagram, Step-3 routing prose, and cross-refs.
  A test-specifiable feature issue is dispatched to `tdd`
  autonomously, the same way a bug issue goes to `debug`; this is
  NOT a new-cycle bounce-back (the test is the spec). The
  bounce-back fires only reactively, when tdd surfaces a genuine
  design fork.
- debug: reciprocal sibling note + cross-ref (new behaviour is
  tdd's job; debug is for regressions of existing behaviour).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-01 16:56:56 +02:00
Brummel fc0e1d0d46 skills: cut blabla and redundancy from skill prose
Per-skill prose tightening from the same audit swarm; each finding
passed an adversarial second reviewer. No behavioural change.

- audit: drop garbled "Conventions require deferred audits to
  compound" sentence (says the opposite of intent; the preceding
  line already closes the loophole).
- brainstorm: drop forward-pointing meta-comment about the
  Rationalisations table.
- debug: drop third restatement that debugger.md is the single
  source for the carrier/handoff fields.
- docwriter: drop motivational opener; Overview starts at the
  waste argument.
- fieldtest: fold the 2-4-examples rationale into the dispatch
  sentence instead of restating the count a fourth time.
- implement: drop "known platform constraint at the time" aside.
- planner: cut the verbose anti-drift paragraph (which restated
  the very table it claimed not to) down to a cross-reference.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-31 13:21:25 +02:00
Brummel 586298ff31 skills: resolve cross-skill drift in trivial carve-out and parse-gate
Two consistency fixes across the skill suite, both found by a
prose-audit agent swarm.

Trivial-mechanical-edit carve-out: brainstorm and planner each
invented their own bound (≤30 LOC, single file) that contradicts
the canonical definition in the project's CLAUDE.md (which allows
a rename across N files and sets no LOC ceiling) and disagreed
with implement. Both now reference that carve-out instead of
restating a divergent shape.

Parse-block gate: brainstorm Step 7 and planner Step 5 spelled out
the parser-invocation protocol near-verbatim. Both now defer to
docs/profile-schema.md, which owns the protocol, and keep only
their skill-specific parts (target artefacts, failure semantics,
where the parse-trace goes) — matching the single-sourcing the
carrier contracts already use.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-31 13:21:25 +02:00
Brummel 0b969838c0 refactor: single-source carrier/handoff contracts across skills
Apply the debug-skill pattern (commits 6410732..de42974) to the
remaining skills: the agent file is the single source for each
interface field's semantics; the SKILL.md copy is reduced to field
names plus a pointer, marking the agent's contract table
authoritative. Because SKILL.md loads into orchestrator context and
agents/*.md into the subagent's fresh system prompt with no
transclusion, duplicated field tables drift apart over time.

- brainstorm: carrier (spec_path/iteration_scope) -> grounding-check;
  the absolute-path requirement now lives only in the agent.
- planner: carrier (spec_path/iteration_scope/focus_hint) ->
  plan-recon, including the mandatory/optional markers and the
  BLOCKED-on-missing rule SKILL.md had omitted.
- fieldtest: carrier + produced fields -> fieldtester; the skill-level
  `status` roll-up (clean/friction_found/bugs_found/infra_blocked),
  which is not part of the agent's run-status protocol, stays defined
  in SKILL.md only.
- docwriter: carrier + produced fields -> docwriter agent.
- implement: carrier (iter_id scratch-dir/stats/not-a-branch
  semantics) -> implement-orchestrator; per-task sub-status vocabulary
  moved into the orchestrator-agent (it runs the loop in a fresh
  context and could not read SKILL.md at runtime, yet referenced "the
  sub-status table" by name); task_text_path single-sourced in
  implementer with spec-reviewer cross-referencing.

audit was already the reference implementation (pointers, no restated
contracts) and is unchanged.

closes #2

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-30 11:10:10 +02:00
Brummel e019d04f83 feat: plan-recon content-pin blast radius (issue #1 Fix 3)
plan-recon already had a Non-compile-checked sweep, but it was gated
behind signature/variant/removal scopes (omittable otherwise). The
raw-buf.2 failure was a module addition that shifted a workspace-listing
hash pinned in two test files — no signature change — so the sweep was
legitimately skipped and the twin pin was missed.

Adds "Content-pin-perturbing scopes" to Step 5: when the iteration
shifts a content-addressed/hashed/snapshot value a test pins, the
Non-compile-checked sweep is MANDATORY and must enumerate EVERY test
file that grep-matches the perturbed constant — not just the first.
Updates the omission clause accordingly, leans on the CLAUDE.md
lockstep-invariant pairs (no new profile slot), and adds a Common
Rationalisation plus two Red Flags. Embedded in the agent's own file
so the discipline does not depend on orchestrator memory.

refs #1

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-29 14:35:38 +02:00
Brummel 305d7973d4 feat: planner parse-the-bytes-you-inline gate (issue #1 Fix 4)
Adds self-review check #9 to planner Step 5, symmetric to Fix 1: when
the profile declares `spec_validation.parsers`, every verbatim code
body the plan inlines into a task step whose fence label has an entry
must parse clean against the live tool before hand-off. Non-zero exit
is a plan failure — the last defensive line before implementer
dispatch. Trace goes into the planner session.

Targets the surface-language snippets the plan lifts verbatim from the
spec (the compound-hallucination bytes); source-language test/impl
bodies are out of scope — the implement compile gate catches those.

Also adds a Common Rationalisation ("came straight from the spec") and
a Red Flag (configured parser, no trace in session).

refs #1

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-29 14:29:03 +02:00
Brummel 62060ba124 planner: skill + plan-recon agent migrated
Sixth skill via the boss pattern. planner is the spec→executable-
plan transformation; plan-recon is its read-only file-mapper.

Vocabulary substitutions:
- AILang → "this project"
- milestone → cycle
- Boss → orchestrator
- ailang-plan-recon → plan-recon
- "the architect's Lockstep invariants table" → "the project's
  CLAUDE.md lockstep-invariant pairs" (the lockstep pairs are
  project-specific; the plugin only carries the pattern that
  the orchestrator may declare them)

AILang-specific bits dropped or generalized:
- `docs/specs/<milestone>.md` / `docs/plans/NNNN-<iteration>.md`
  → `paths.spec_dir` / `paths.plan_dir`
- `cargo test --workspace -p <crate>` → "the project's test
  command from commands.test, scoped to this test" + generic
  template
- `cargo check`, `cargo expand` → "the project's type-checker
  / compiler" and "the project's macro-expansion tool" with
  Rust/TypeScript examples in parentheses
- Rust code-snippet template in Step 3 → language-neutral
  placeholder with `(exact source code here)` annotations
- Specific past-iter references (loop-recur.1, loop-recur.2,
  loop-recur.tidy, remove-mut-var-assign.1, form_a.md,
  iter-revert Concern 2, iter effect-doc-honesty Task 2, iter
  loop-recur.3 Concern) → generic "recurring defect family
  in this project's history" (the discipline survives; the
  AILang iter codes that wouldn't parse for a plugin reader
  go away)
- `error[E0061]` Rust-specific compiler error code → "hard
  compile error" (universal)

Universal substance preserved verbatim:
- Iron Law (3 lines)
- Six-step process (read spec → map structure → write tasks
  → header → self-review → hand off)
- Step 5 self-review checklist — all 8 calibrated checks
  (spec coverage, placeholder scan, type consistency, step
  granularity, no commit steps, pin/replacement substring
  contiguity, compile-gate vs deferred-caller ordering,
  verification-command filter strings must resolve)
- All 6 Common Rationalisations rows
- All 6 Red Flags bullets
- plan-recon's nine-step process incl. compile-driven
  enumeration (Step 5) and spec-named-path existence table
  (Step 6)
- plan-recon's output format including all five sections
  (Files, Compile-driven site set, Non-compile-checked
  sites, Spec-named-path existence table, Anchors not yet
  present)
- plan-recon's 8 Common Rationalisations rows and 9 Red
  Flags bullets

Calibrated discipline kept (per memory feedback_dont_strip_
repeated_discipline.md): the three plan-defect families flagged
by user memory (pin/replacement soft-wrap, compile-gate vs
deferred caller, verification filter must resolve) all stay
verbatim — they are project-history scaffolding, just
de-AILang'd in the references.
2026-05-28 16:05:38 +02:00