Skip to content

fix(decisions-log): enumerate decisions.yaml writes in every phase agent (closes #399)#400

Merged
jjackson merged 1 commit into
mainfrom
emdash/question-3o2eh
May 22, 2026
Merged

fix(decisions-log): enumerate decisions.yaml writes in every phase agent (closes #399)#400
jjackson merged 1 commit into
mainfrom
emdash/question-3o2eh

Conversation

@jjackson
Copy link
Copy Markdown
Owner

Summary

Closes #399.

Phase 2-9 agents were never writing rows to decisions.yaml because the procedural authority — the per-step Output: bullets in agents/<phase>.md — was silent on it, even though 8 downstream skills already carried well-formed Decisions Log catalogs in their SKILL.md. Phase 1 had the canonical pattern; PR #4 of the decisions-log series shipped the catalogs without the matching agent-file enumeration. Result on malaria-itn-app run 20260521-1400: 22+ completed steps across 6 phases produced zero decision rows.

What changed

  • Mirrored Phase 1's pattern across 8 downstream phase agent files. Each Step that maps to a Decisions-Log-carrying skill now enumerates the anchor row IDs to be appended (e.g., Appended verification-flags, payment-unit-shape, opportunity-end-date rows in decisions.yaml).
  • Updated agents/orchestrator-reference.md § Phase Write-Back Contract § Decisions log clause to explicitly name the per-step Output bullet as the load-bearing procedural authority. The ## Decisions Log section in the writing skill's SKILL.md is a teaching device; the agent file is what the dispatched subagent treats as its checklist. Future skills adding anchor rows must update both.

Out of scope (follow-ups)

Test plan

  • Next end-to-end /ace:run (any opp) produces non-zero decisions.yaml rows from Phase 3-10 skills.
  • decisions.gdoc rendered by decisions-render shows rows under all phases that ran, not just Phase 1.
  • No regression in Phase 1 (still produces ~25 rows).

🤖 Generated with Claude Code

…ent (closes #399)

Phase 2-9 agents never wrote decisions.yaml rows because the procedural
authority (per-step `Output:` bullets in `agents/<phase>.md`) was silent
on them, even though 8 downstream skills carried well-formed Decisions
Log catalogs in their SKILL.md. Phase 1 had the canonical pattern but
PR #4 of the decisions-log series shipped only the catalogs, not the
agent-file enumeration. Result: 22+ completed steps across 6 phases on
malaria-itn-app run 20260521-1400 produced zero decision rows.

Mirror Phase 1's pattern in every downstream phase. Each Step that maps
to a Decisions-Log-carrying skill now enumerates the anchor row IDs:

- commcare-setup Step 1 (pdd-to-deliver-app): deliver-unit-count,
  one-form-per-module-workaround, multimedia-coverage-strategy
- commcare-setup Step 2.6 (app-test-cases): test-scenario-count,
  test-archetype-coverage
- connect-setup Step 2 (connect-opp-setup): verification-flags,
  payment-unit-shape, opportunity-end-date
- ocs-setup Step 1 (ocs-agent-setup): system-prompt-baseline,
  rag-collection-scope, test-prompt-count
- synthetic-data-and-workflows Step 1 (synthetic-narrative-plan):
  persona-count, scenario-count, narrative-arc-shape
- solicitation-management Step 1 (solicitation-create):
  solicitation-type, response-deadline, response-template-choice
- execution-manager Step 3 (llo-launch): llo-capacity-actual,
  day-one-readiness, downstream-handoff-alignment, stop-loss-planning
- closeout Step 1 (opp-closeout): closeout-depth,
  learnings-summary-scope

orchestrator-reference.md § Phase Write-Back Contract § Decisions log
clause now explicitly names the per-step agent-file Output block as the
load-bearing procedural authority — the SKILL.md catalog is a teaching
device, not a checklist — so adding a new anchor-row skill in future
requires updating BOTH locations.

Out of scope (called out for follow-up):
- `app-test-cases/SKILL.md` records its rows with
  `phase: 6-qa-and-training` even though dispatch happens in Phase 3.
  Phase mismatch noted inline in commcare-setup.md.
- Suggested guardrail (downgrade phase verdict when a phase with an
  anchor catalog writes zero rows) — separate change; the per-step
  enumeration is the proximate fix.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@jjackson jjackson enabled auto-merge May 22, 2026 08:22
@jjackson jjackson merged commit 07ebdb0 into main May 22, 2026
2 checks passed
jjackson added a commit that referenced this pull request May 22, 2026
… 6-qa-and-training)

`app-test-cases/SKILL.md` recorded its decisions-log rows with
`phase: 6-qa-and-training` even though the skill is dispatched from
`agents/commcare-setup.md § Step 2.6` (Phase 3). The convention used by
every other writer skill is "the phase the skill is dispatched in," and
the artifact manifest already maps the producer's output to
`3-commcare/app-test-cases.yaml` (see `lib/artifact-manifest.ts:383`).
The `6-qa-and-training` tag was a mismatch — rows would group under
the wrong phase in the rendered decisions.gdoc and confuse the Phase
Write-Back Verifier's per-phase row-count checks (when those land).

No data migration needed — issue #399 surfaced that this skill had
written zero rows in practice (the bug it documented), so there's no
historical decisions.yaml content tagged with the old phase.

Flagged inline in commcare-setup.md by PR #400 as a follow-up.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.

decisions.yaml: Phase 2-9 agents never write rows (Phase Write-Back Contract documented but not procedurally enforced)

1 participant