recursive-subagent-action

A command for recording work delegated to another coding agent during a software run. It saves details such as the agent, task phase, purpose, files, and result.

In plain words
What is it for?
Use it to log delegated implementation or code-review actions and connect them to the run's evidence files.
Why use it?
It gives the main controller a traceable record of what a subagent did and which files or review artifacts it produced.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/try-works/recursive-mode/recursive-subagent-action
Clone the repo
git clone --depth 1 https://github.com/try-works/recursive-mode
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,010 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.01010
Opus 5 $0.00000 $0.00505
Sonnet 5 $0.00000 $0.00202
Haiku 4.5 $0.00000 $0.00101

Measured 2d ago against content hash c2714e9ca437, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

recursive-subagent-action scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

docs/templates/commands/recursive-subagent-action.md · 35 lines

How it starts

The opening of the file, as written. The whole thing — 35 lines — stays where its author put it; the contents beside it link to each section on GitHub.

recursive-subagent-action (prompt template)

Paste this into chat if your agent does not support custom slash commands.

Usage Pattern

Record a subagent action for run <run-id> phase <phase> so the controller can verify it against real files and recursive artifacts.
python "<SKILL_DIR>/scripts/recursive-subagent-action.py" --repo-root . --run-id "<run-id>" --subagent-id reviewer-01 --phase "03.5 Code Review" --purpose "Delegated code review" --execution-mode review --artifact-path "/.recursive/run/<run-id>/03-implementation-summary.md" --review-bundle "/.recursive/run/<run-id>/evidence/review-bundles/code-review.md" --router-used "recursive-router" --routed-role "code-reviewer" --routed-cli "codex" --routed-model "gpt-5.4" --routing-config-path ".recursive/config/recursive-router.json" --routing-discovery-path ".recursive/config/recursive-router-discovered.json" --prompt-bundle-path ".recursive/run/<run-id>/router-prompts/code-reviewer-bundle.md" --invocation-exit-code "0" --output-capture-path ".recursive/run/<run-id>/evidence/router/code-reviewer-output.md" --action-taken "Reviewed the implementation summary, review bundle, and changed files for requirement and diff alignment." --reviewed-file "src/app.py" --artifact-read "/.recursive/run/<run-id>/02-to-be-plan.md" --artifact-read "/.recursive/run/<run-id>/03-implementation-summary.md" --evidence-used "/.recursive/run/<run-id>/evidence/router/code-reviewer-output.md" --evidence-used "/.recursive/run/<run-id>/evidence/logs/green/final.log" --finding "No blocking issues remained after verifying the repaired diff." --verification-path "src/app.py" --verification-path "/.recursive/run/<run-id>/evidence/review-bundles/code-review.md" --verification-item "Inspect these paths first during controller acceptance."

pwsh -NoProfile -File "<SKILL_DIR>/scripts/recursive-subagent-action.ps1" -RepoRoot . -RunId "<run-id>" -SubagentId reviewer-01 -Phase "03.5 Code Review" -Purpose "Delegated code review" -ExecutionMode review -ArtifactPath "/.recursive/run/<run-id>/03-implementation-summary.md" -ReviewBundle "/.recursive/run/<run-id>/evidence/review-bundles/code-review.md" -RouterUsed "recursive-router" -RoutedRole "code-reviewer" -RoutedCli "codex" -RoutedModel "gpt-5.4" -RoutingConfigPath ".recursive/config/recursive-router.json" -RoutingDiscoveryPath ".recursive/config/recursive-router-discovered.json" -PromptBundlePath ".recursive/run/<run-id>/router-prompts/code-reviewer-bundle.md" -InvocationExitCode "0" -OutputCapturePath ".recursive/run/<run-id>/evidence/router/code-reviewer-output.md" -ActionTaken "Reviewed the implementation summary, review bundle, and changed files for requirement and diff alignment." -ReviewedFile "src/app.py" -ArtifactRead "/.recursive/run/<run-id>/02-to-be-plan.md","/.recursive/run/<run-id>/03-implementation-summary.md" -EvidenceUsed "/.recursive/run/<run-id>/evidence/router/code-reviewer-output.md","/.recursive/run/<run-id>/evidence/logs/green/final.log" -Finding "No blocking issues remained after verifying the repaired diff." -VerificationPath "src/app.py","/.recursive/run/<run-id>/evidence/review-bundles/code-review.md" -VerificationItem "Inspect these paths first during controller acceptance."

Read the full file on GitHub · 35 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 35 lines · 0 tokens per session scan A c2714e9ca437

Subscribe to this mod's changes

recursive-subagent-action is a command published in the GitHub repository try-works/recursive-mode (129 stars, last pushed 1mo ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,010 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.