/agent-traffic-control:multi-phase-skill-disk-reading-strategyfrom agent-traffic-control
Fix silent subagent failures in late phases of multi-phase Claude Code skills. Use when: (1) a skill has 10+ phases and the last phase's subagent silently fails to launch, (2) Phase N produces output that Phase N+1 needs but the orchestrator's context is near capacity, (3) the orchestrator injects large data payloads (500+ lines) into subagent prompts and the subagent produces degraded or empty output, (4) a skill's final output step works in short reviews but fails in long ones. The fix: have late-pipeline subagents read already-written files from disk instead of receiving data via orchestrator context injection.
Ships in agent-traffic-control. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description, though model invocation is off: only you can start it.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Sister skill:
multi-agent-skill-silent-phase-compressioncovers the output-direction symmetric problem (subagent outputs flooding back into orchestrator → silent compression of mandatory phases). Same fix family (file-based state passing), opposite direction. If a multi-agent skill is failing, read both — the bug is usually one or the other (sometimes both).
In Claude Code skills with many phases (10+), late-pipeline subagents silently fail to execute when the orchestrator's context window is near capacity. The orchestrator tries to inject large amounts of structured data (earlier phase outputs) into the subagent's prompt, but context exhaustion causes the launch to either fail silently or produce a degraded prompt that the subagent can't follow properly.
Symptoms:
If Phase N-1 and Phase N currently run in parallel, make them sequential. Phase N runs AFTER N-1 so that N-1's output file exists on disk.
Latency impact is usually negligible — orchestrator-assembled phases (no subagent) complete in seconds.
Instead of:
# BAD: Orchestrator injects 700+ lines into subagent prompt
Agent({
prompt: "Generate the report. Here is all the data:\n{massive_data_blob}"
})
Do:
# GOOD: Orchestrator tells subagent which files to read (~10 lines)
Agent({
prompt: "Generate the report by reading these files:
1. {absolute_path}/phase_1_output.md — structured data
2. {absolute_path}/phase_2_output.md — detailed narratives
3. {absolute_path}/references/spec.md — rendering spec
Follow the spec exactly. Write the complete output file."
})
The subagent has NO knowledge of:
The orchestrator MUST substitute all paths to absolute paths before including them in the subagent prompt.
Before reporting completion, verify all expected output files exist:
ls -la output_file_1.md output_file_2.md output_file_3.html
If the late-phase file is missing:
Document in the skill: if the user asks to regenerate the missing output, launch the SAME subagent with the SAME disk-reading prompt. Do NOT generate a generic version from the orchestrator's memory — it won't follow the spec.
After applying this pattern:
Before (agent-review-panel v2.16.3):
After (agent-review-panel v2.16.4):
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub wan-huiyan/agent-traffic-control --plugin agent-traffic-control118 skills in this plugin
/agent-refusal-with-evidence-beats-literal-complianceA dispatched agent that does exactly what you asked can ship a defect you would
have stopped yourself, because it can see something at the worksite that you
could not see when you wrote the brief. Use when: (1) you are writing a brief
that prescribes a specific fix, threshold, wording or value rather than the
outcome you want; (2) an agent reports that it did not do what you asked and
you are deciding whether that is insubordination or judgement; (3) an agent
asserts "this is fine" or "not needed" with no measurement behind it; (4) you
are reviewing overnight output and want to know which decisions were checked
and which were assumed. Two halves, and both are needed: give the agent
explicit permission to satisfy the INTENT of an instruction while refusing its
letter, and REQUIRE the evidence with the refusal — what it built or measured,
what that showed, what it did instead. Evidence is the whole difference between
a refusal you can bank and one you have to re-litigate. Four agents correctly
declined an instruction in a single run; one built the suggested fix, measured
that it turned a silent safe refusal into a permanently red pipeline, and
reverted it unpushed.
/auto-merge-rearms-while-agent-live-kill-then-disarm-verify