一键导入
goal-compose
Compose a paste-ready condition for Claude Code's built-in /goal command — turn a rough intent into a measurable, self-verifying, self-terminating goal
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Compose a paste-ready condition for Claude Code's built-in /goal command — turn a rough intent into a measurable, self-verifying, self-terminating goal
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
You may have peer Claude sessions cooperating with you, and a human whose terminal is recorded — claude-pod lets you read what they're doing
Portfolio archaeology: scan ALL local branches for forgotten/neglected work and rank by 'could Claude do something useful on this right now?'
Analyze current work context and recommend top priorities
Resume a (often neglected) branch/worktree: where we left off, and what has to be true before the user can engage autopilot and walk away for minutes or hours
Bootstrap Claude Code plumbing in a repo (settings, tmp dir, gitignore)
| name | goal-compose |
| description | Compose a paste-ready condition for Claude Code's built-in /goal command — turn a rough intent into a measurable, self-verifying, self-terminating goal |
| allowed-tools | Bash, Read, Grep, Glob |
Turn the user's rough intent into a polished condition for Claude Code's
built-in /goal command, and hand them a ready-to-paste /goal … line.
/goal is a built-in Claude Code command (v2.1.139+). It is not this skill,
and Claude cannot trigger it — the user pastes /goal <condition>, and Claude
Code then keeps taking turns on its own until the condition is met:
/goal alone shows status; /goal clear cancels.This skill's only output is a /goal <condition> line for the user to paste.
Do not try to start the goal loop yourself — you can't.
Because the evaluator is blind to everything but the transcript, build the condition from four parts:
npm test exits 0, git status clean, ls dist/app.js succeeds).Optional but often valuable: constraints that must hold ("without modifying any other test file", "don't touch the public API").
Keep it well under the 4,000-character cap. A good condition is a few tight sentences, not an essay. If a draft balloons toward the limit, that's the signal the goal is doing too much — split it into chained goals (see anti-patterns).
Often the intent is already captured — a spec.md, a design doc, or a plan
Claude wrote earlier this session. Use it as the source of the finish line:
Reference the file by path in the condition (…per plan.md) so the working
Claude re-grounds itself each turn. How much you spell out depends on the plan:
npm test green and the
migration script exists, per plan.md" is.Either way, keep the surface-the-proof instruction: the evaluator can't open the plan, so it judges from the proof Claude pastes, not from the file.
A phased plan is not one goal. Each phase is its own finish line, so it
gets its own /goal, composed with all four parts and run in sequence: paste
phase 1, let it clear, paste phase 2. Cramming a multi-phase plan into one
condition breaks "one measurable end state" and bloats the cap.
Get the intent. Use the user's args as the rough goal. If they invoked this with nothing, or with something too vague to make measurable, ask 1–3 sharp questions — focus on: what's the finish line, how would you check it by hand, and what must NOT change.
Check for a plan or spec. If the user linked a .md, or a plan/spec is
already in the conversation, treat it as the source of the finish line(s) —
see "When a plan or spec is in play". Note whether it's phased.
Find the real check. Don't guess the verification command — look. Inspect the repo for how things are actually verified here:
package.json, Makefile, *.bats,
pyproject.toml, CI config)Prefer a command with an unambiguous exit code or a greppable summary line.
Respect repo conventions found in CLAUDE.md (e.g. tests that must run with
the sandbox disabled).
Recommend a model. The goal loop runs on whatever model is active when the user pastes the condition — pick the right tier:
xhigh effort on Opus 4.8When unsure, lean toward Opus 4.8 for goal loops — it's optimized for
long-horizon agentic execution. Include a one-line rationale and remind the
user to switch before pasting: /model <model-id>.
Draft the condition(s) from the four parts above — one goal, or one goal per phase for a phased plan. Keep each tight and imperative. Bake in "show the output" explicitly.
Present it in the output format below.
## Paste this
/goal <the composed condition>
## Why it's shaped this way
- End state: <…>
- Check: <command/observation>
- Proof surfaced: <what Claude will paste each turn>
- Stop clause: <turn cap / give-up>
- Constraints: <or "none">
- Model: <recommended model + one-line rationale> — switch with `/model <model-id>` before pasting
Keep the explanation to a few lines. The paste line is the product.
For a phased plan, present an ordered sequence instead — one /goal block
per phase, with a note to run them one at a time (paste the next only after the
previous clears).
Rough intent → composed /goal:
"get the auth tests passing"
→ /goal All tests under test/auth pass. After each change run \npm test -- test/auth` and paste the summary line (pass/fail counts) into your reply. Don't modify tests outside test/auth. If still failing after 15 turns, stop and summarize the remaining failures.`
"finish the changelog for this week"
→ /goal CHANGELOG.md has an entry for every PR merged in the last 7 days. Each turn, list the merged PRs you found (\gh pr list --state merged --search "merged:>="`) and which are still missing from CHANGELOG.md, then add them. Done when that missing list is empty — show the empty list. Stop after 10 turns if blocked.`
"make the bats suite green" (repo-aware: honors CLAUDE.md)
→ /goal \bats hooks/use-dedicated-tools.bats` exits 0 with zero failures. Run it each turn with the sandbox disabled (per CLAUDE.md) and paste the final tally. Don't weaken assertions to pass. If not green after 12 turns, stop and report what's failing.`
phased plan in plan.md → one goal per phase, run in order:
/goal Complete the Phase 1 Goal in plan.md and paste the verification output it specifies each turn. Stop after 15 turns if blocked./goal Phase 2 done per plan.md: the CLI wires the parser in and \npm test` is fully green. Paste the summary each turn. Don't touch the parser module. Stop after 15 turns if blocked.`
(…paste each only after the previous clears.)