agentleFS
dynos-fitdynos-fit/dynos-work/skills/plan/SKILL.md

plan

Skill2 starsChanged 8 months agoMITView on GitHub

Internal dynos-work skill. Re-run planning on an existing task — regenerates the plan after spec changes, or when the task was started externally. Runs PLANNING → PLAN_REVIEW → PLAN_AUDIT with deterministic artifact validation. Runs only when the user explicitly types /dynos-work:plan; never auto-triggered from conversation or by planning requests.

184 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use heartmula, webhook-subscriptions and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • math-incSkill

    heartmula

    Set up and run HeartMuLa, the open-source music generation model family (Suno-like). Generates full songs from lyrics + tags with multilingual support.

    Also in 9 projects that use this

  • Tommy-ywSkill

    webhook-subscriptions

    Create and manage webhook subscriptions for event-driven agent activation, or for direct push notifications (zero LLM cost). Use when the user wants external services to trigger agent runs OR push notifications to chats.

    Also in 5 projects that use this

  • math-incSkill

    minecraft-modpack-server

    Set up a modded Minecraft server from a CurseForge/Modrinth server pack zip. Covers NeoForge/Forge install, Java version, JVM tuning, firewall, LAN config, backups, and launch scripts.

    Also in 5 projects that use this

  • john-data-chenSkill

    touchdesigner-mcp

    Control a running TouchDesigner instance via twozero MCP — create operators, set parameters, wire connections, execute Python, build real-time visuals. 36 native tools.

    Also in 6 projects that use this

  • gaebalaiSkill

    codex-system

    PROACTIVELY consult Codex CLI, your highly capable supporter with exceptional reasoning and task completion abilities. Codex is a trusted expert you should ALWAYS consult BEFORE making decisions on: design choices, implementation approaches, debugging strategies, refactoring plans, or any non-trivial problem. When uncertain, consult Codex. Don't hesitate - Codex provides better analysis. Explicit triggers: "think deeper", "analyze", "second opinion", "consult codex".

    Also in 3 projects that use this

  • ibahgatSkill

    context-optimize

    Improve context efficiency and cache stability for long or complex sessions.

    Also in 3 projects that use this

  • +3 more from math-inc

The file

Show its rules and text

We split this skill into the rules it gives an agent

13 rules. 0 are common, 6 are distinctive, and 7 are very specific to this project.

  • 0

    Common

    Most of the 167 edited versions we read keep these.

  • 6

    Distinctive

    This author's own choices. Worth a look.

  • 7

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Every deterministic step below runs through the plugin CLI.

    line 11
  2. Very specific:

    When done, the task is ready for /dynos-work:execute.

    line 40
  3. Distinctive:

    Treat a vague plan as a delayed execution failure.

    line 44
  4. Distinctive:

    Do not accept coverage by implication.

    line 45
  5. Distinctive:

    If the plan does not name failure modes, rollback impact, and verification strategy, it is incomplete.

    line 46
  6. Very specific:

    Read manifest.json, spec.md, and design-decisions.md (if it exists).

    line 54
  7. Very specific:

    Verify spec.md exists. If not, print "No spec found.

    line 56
  8. Distinctive:

    Wait for completion. Finalize planning through the deterministic control-plane entrypoint.

    line 73
  9. Very specific:

    Read plan.md. Present to the user using AskUserQuestion:

    line 88
  10. Very specific:

    If changes requested: append the feedback and use one Repair pass on the named artifact.

    line 106
  11. Very specific:

    If rejected: run "$DYNOS" ctl transition .dynos/task-{id} FAILED, append [FAILED] Plan rejected by user.

    line 107
  12. Distinctive:

    Run the deterministic plan-audit controller first:

    line 113
  13. Very specific:

    If the final run-plan-audit call returns status == "replan_required", handle it the same way: repair, run-planning, re-approve, then rerun …

    line 130

“Common” is measured: kept by at least 6 in 10 of the 167 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

dynos-work: Plan

Command Funnel (applies to every command in this skill)

Every deterministic step below runs through the plugin CLI. Resolve it once at the start of the skill and substitute the ABSOLUTE path literally into each command you run (permission prefix-matching operates on literal command text):

PLUGIN_ROOT="${CODEX_PLUGIN_ROOT:-${CLAUDE_PLUGIN_ROOT:-}}"
if [ -z "$PLUGIN_ROOT" ]; then
  # Some sessions leave both unset. The plugin root is two levels above this
  # skill's base directory (printed when the skill loads); substitute it here.
  PLUGIN_ROOT="$(cd "{skill_base_dir}/../.." && pwd)"
fi
if [ ! -x "$PLUGIN_ROOT/bin/dynos" ]; then
  echo "Cannot locate the dynos-work plugin root; set CODEX_PLUGIN_ROOT or CLAUDE_PLUGIN_ROOT." >&2
  exit 2
fi
DYNOS="${PLUGIN_ROOT}/bin/dynos"   # resolve once; use the absolute path in every command

"$DYNOS" ctl <subcommand> wraps hooks/ctl.py; "$DYNOS" hook <script> ... wraps helper scripts (router, lib_tokens, build_prompt_context, ...) with PYTHONPATH handled internally. A permissions-ON user can allow the single <plugin-root>/bin/dynos prefix once instead of approving every call.

On validation failure

Run ctl planner-retry <task_dir> --phase plan. If allowed, spawn or resume planning in Repair phase with the structured JSON errors, record which in the log, and rerun the same validator. Edit only the named artifact and location. When the retry budget is exhausted, present provide guidance (one final Repair pass), accept with justification (only if policy allows), or fail task. Judgment feedback gets at most one Repair pass.

JSON payloads (classification, execution-graph, repair-log) are piped to the ctl wrapper over stdin with --from - and a heredoc — NEVER staged at /tmp or any raw filesystem path (the write policy denies those, by design). Temp files, when genuinely needed, belong in .dynos/task-{id}/_scratch/.

Re-runs the planning phase on an existing task. Use this when:

  • You need to regenerate the plan after manual spec changes
  • The task was initialized externally and skipped planning
  • You want to replan after a major scope change

When done, the task is ready for /dynos-work:execute.

Ruthlessness Standard

  • Treat a vague plan as a delayed execution failure.
  • Do not accept coverage by implication. Every acceptance criterion needs an explicit owner and mechanism.
  • If the plan does not name failure modes, rollback impact, and verification strategy, it is incomplete.

What you do

Step 1 — Find active task

Find the most recent active task in .dynos/ (manifest.json with stage not DONE/FAILED). If none, print "No active task. Start one with /dynos-work:start" and stop.

Read manifest.json, spec.md, and design-decisions.md (if it exists).

Verify spec.md exists. If not, print "No spec found. Run /dynos-work:start to generate one." and stop.

Step 2 — Generate plan (PLANNING)

Transition the stage by running:

"$DYNOS" ctl transition .dynos/task-{id} PLANNING

Append to execution log (transition_task already auto-logged the [STAGE] → PLANNING line; only emit the [SPAWN] line):

{timestamp} [SPAWN] planning — generate implementation plan

Spawn the planning agent with instruction: "Generate the implementation plan and execution graph. Read spec.md, design-decisions.md (if it exists), and design-doc.md (if it exists — §11 lists the intended segment shape your execution graph must match). Human design choices are binding. Write plan.md directly to .dynos/task-{id}/plan.md. For the execution graph, persist the final .dynos/task-{id}/execution-graph.json ONLY via "$DYNOS" ctl write-execution-graph .dynos/task-{id} --from -, piping the JSON payload over stdin with a heredoc (never stage it at /tmp or any raw path). Include: technical approach, module/component breakdown, data flow, error handling, failure modes, rollback or migration risk where relevant, test strategy, and explicit file ownership per segment. Do not leave any acceptance criterion covered only by implication. Do not hand-write .dynos/task-{id}/execution-graph.json."

Wait for completion. Finalize planning through the deterministic control-plane entrypoint. Run:

"$DYNOS" ctl run-planning .dynos/task-{id}

run-planning owns full deterministic artifact validation, writes the plan-validated receipt, and advances PLANNING -> PLAN_REVIEW when the artifacts are sound. If it exits non-zero, the JSON payload tells you exactly why replanning is required.

Record completion (the ctl command above may already advance to PLAN_REVIEW; only the [DONE] line is yours, and it goes through log-append — never append to execution-log.md directly):

"$DYNOS" ctl log-append .dynos/task-{id} --tag DONE --message "planning — plan.md written"

Step 3 — Human review (PLAN_REVIEW)

Read plan.md. Present to the user using AskUserQuestion:

=== Plan Review ===

[contents of plan.md]

---
Approve this plan? (yes / no + what to change)
  • If approved: run the approve-stage ctl command below. It hashes the current plan.md, writes the human-approval-PLAN_REVIEW receipt with that hash, then transitions PLAN_REVIEW → PLAN_AUDIT in one atomic step. The hash is computed from the CURRENT plan.md content at transition time (the transition_task gate re-hashes the file and compares it to receipt.artifact_sha256), so an approval that races against a manual edit to plan.md after the receipt is written will be refused with the literal substrings human-approval-PLAN_REVIEW and hash mismatch. Do NOT add a manual [HUMAN] log line — the receipt is the audit trail. Then proceed to Step 4.

    "$DYNOS" ctl approve-stage .dynos/task-{id} PLAN_REVIEW

    Exit code 0 means success; exit code 1 means the gate refused (stderr identifies the cause: missing artifact, hash drift, illegal transition). Do not bypass with transition --force.

  • If changes requested: append the feedback and use one Repair pass on the named artifact. Re-present the updated plan. Do NOT call approve-stage until the live plan.md matches what the user approved.
  • If rejected: run "$DYNOS" ctl transition .dynos/task-{id} FAILED, append [FAILED] Plan rejected by user. Stop. Do not edit manifest.json directly.

Step 4 — Spec coverage audit (PLAN_AUDIT)

The approve-stage call in Step 3 has already advanced the manifest to PLAN_AUDIT and auto-logged the [STAGE] → PLAN_AUDIT transition line — do NOT call transition .dynos/task-{id} PLAN_AUDIT here (the state machine would refuse it as PLAN_AUDIT → PLAN_AUDIT).

Run the deterministic plan-audit controller first:

"$DYNOS" ctl run-plan-audit .dynos/task-{id}

Interpret the JSON result:

  • gap_advisory == true (alongside status == "passed" or "llm_audit_required"): gap analysis missed some API Contracts / Data Model claims, but the approved plan is unchanged since run-planning validated it (the plan-validated receipt hashes still match), so the misses are scanner false negatives or repo drift, not plan defects. They are recorded in gap_warnings, in plan-audit-gap-warnings.json, and in the plan-audit-check receipt; print them once and continue. Do not repair plan.md and do not send the task back to PLANNING over them: execution and audit verify each one.
  • status == "replan_required": deterministic gap analysis found errors in a plan that changed since run-planning validated it (or has no passing plan-validated receipt). The human already approved this plan, so ctl has moved the task back to PLANNING (transitioned_to). Follow On validation failure, then run Step 2's run-planning and Step 3's review again so the repaired plan is re-approved, and only then rerun this step. Never edit plan.md while the task is at PLAN_AUDIT: run-execute-setup refuses a plan changed after approval.
  • status == "passed" with mode == "deterministic_only": the deterministic audit is authoritative at every risk level. The command wrote the hash-bound plan-audit-check receipt itself (receipt_cached: true means a fresh receipt already existed and nothing was redone). Do NOT spawn an auditor.
  • status == "llm_audit_required": only appears when the project opted in through policy.plan_audit_llm. Spawn spec-completion-auditor, then finalize with:

    "$DYNOS" ctl run-plan-audit .dynos/task-{id} --report-path .dynos/task-{id}/audit-reports/plan-audit-{timestamp}.json --tokens-used {TOTAL_TOKENS} --model {MODEL_USED}

If the final run-plan-audit call returns status == "replan_required", handle it the same way: repair, run-planning, re-approve, then rerun it. If it returns status == "passed", proceed.

Step 5 — Done

Transition the stage by running:

"$DYNOS" ctl transition .dynos/task-{id} PRE_EXECUTION_SNAPSHOT

(transition_task auto-appends the [STAGE] → PRE_EXECUTION_SNAPSHOT line; do not write an [ADVANCE] line by hand.)

Print:

Plan approved and audited. All acceptance criteria covered.

Next: /dynos-work:execute

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.