What happens
The code agent fails validation with output/code-result.json not found because it never writes the required structured output file. This was first observed on run 28621163275 — the first run after agents were registered from this repo (commit e0b4d16b on .fullsend).
Both validation iterations (1 of 2, 2 of 2) the agent completed its code task (exit 0) but never produced code-result.json. The agent made code changes and committed them but didn't write the structured output.
Root cause
The code agent's instructions are missing the structured output guidance that review and fix agents already have:
1. agents/code.md — no structured output section
The code agent definition has zero mentions of code-result.json, FULLSEND_OUTPUT_DIR, FULLSEND_OUTPUT_FILE, fullsend-check-output, or the output schema. It simply says: "Follow the code-implementation skill for the step-by-step procedure."
Compare to agents/fix.md which has a dedicated "Structured output" section with:
- "You MUST produce a JSON file..."
- "Without this file, the post-script cannot communicate your work back to the reviewer."
- Schema field documentation
fullsend-check-output validation instructions
2. skills/code-implementation/SKILL.md — output buried and no self-validation
The instruction to write code-result.json is buried in step 3 ("Discover repo conventions") among ~60 lines of unrelated instructions about build commands, linter config, and branch conventions. Problems:
- Not a dedicated step — lost in context
- No "MANDATORY" or "MUST" language
- No
fullsend-check-output validation (unlike review and fix skills)
- No reminder at step 10 (commit) to verify the output file exists
- No mention that the harness
validation_loop will reject the run without it
Agent comparison
| Agent |
Agent def has output section |
Skill has dedicated output step |
fullsend-check-output in skill |
Status |
| Review |
Yes (detailed) |
Yes (step 7) |
Yes |
Working |
| Fix |
Yes ("MUST") |
Yes (step 9, MANDATORY) |
Yes |
Working |
| Code |
No |
No (buried in step 3) |
No |
Broken |
Proposed fix
A. Add "Structured output" section to agents/code.md
Between "Failure handling" and "Detailed implementation procedure", add a section modeled on agents/fix.md:
## Structured output
You MUST produce a JSON file at `$FULLSEND_OUTPUT_DIR/$FULLSEND_OUTPUT_FILE`
(typically `code-result.json`) that documents the target branch for PR creation.
The post-script reads this file to create the PR against the correct branch.
Without this file, the harness validation loop will reject the run.
Write this file early — during step 3 of the skill, after determining the
target branch — so it is available even if the agent hits a timeout later.
Include the schema fields, an example, and fullsend-check-output instructions.
B. Add output verification step to skills/code-implementation/SKILL.md
- Add MANDATORY language around the existing output writing block in step 3
- Add
fullsend-check-output call after the write
- Add a new step 11 ("Verify structured output") as a final check before exit, with a recovery path if the file is missing
Context
What happens
The code agent fails validation with
output/code-result.json not foundbecause it never writes the required structured output file. This was first observed on run 28621163275 — the first run after agents were registered from this repo (commite0b4d16bon.fullsend).Both validation iterations (1 of 2, 2 of 2) the agent completed its code task (exit 0) but never produced
code-result.json. The agent made code changes and committed them but didn't write the structured output.Root cause
The code agent's instructions are missing the structured output guidance that review and fix agents already have:
1.
agents/code.md— no structured output sectionThe code agent definition has zero mentions of
code-result.json,FULLSEND_OUTPUT_DIR,FULLSEND_OUTPUT_FILE,fullsend-check-output, or the output schema. It simply says: "Follow thecode-implementationskill for the step-by-step procedure."Compare to
agents/fix.mdwhich has a dedicated "Structured output" section with:fullsend-check-outputvalidation instructions2.
skills/code-implementation/SKILL.md— output buried and no self-validationThe instruction to write
code-result.jsonis buried in step 3 ("Discover repo conventions") among ~60 lines of unrelated instructions about build commands, linter config, and branch conventions. Problems:fullsend-check-outputvalidation (unlike review and fix skills)validation_loopwill reject the run without itAgent comparison
fullsend-check-outputin skillProposed fix
A. Add "Structured output" section to
agents/code.mdBetween "Failure handling" and "Detailed implementation procedure", add a section modeled on
agents/fix.md:Include the schema fields, an example, and
fullsend-check-outputinstructions.B. Add output verification step to
skills/code-implementation/SKILL.mdfullsend-check-outputcall after the writeContext
harness/code.yamlhasvalidation_loop:withmax_iterations: 2— this was added during the agents extraction (PR feat: extract code, fix, review, retro, prioritize agents from fullsend #12) and didn't exist in the old scaffold'sharness/code.yaml. The validation correctly catches the missing file, but the agent doesn't know it needs to produce it.