Turn an approved spec, agent-ready ticket, tracker frontier, or partially implemented ticket into a verifiable execution goal without re-interviewing the user. Use after to-tickets or triage, before starting a fresh implementation session; use --all only for an explicitly requested cross-ticket goal.
npx skills add https://github.com/tt-a1i/matt-skills-with-to-goal --skill to-goal
Compile existing planning and repository evidence into an execution goal. Do not implement, mutate the tracker, create a branch, or modify files.
Read ../goal-crafter/SKILL.md only for compiled-handoff mode, Phase 2 harness formats, Phase 3's four self-checks, and Special Rules (never re-interview; one verifiable condition per checkbox). Skip Phase 1 and Examples. This skill owns context gathering, frontier selection, readiness checks, and execution handoff. Do not reopen decisions already made by to-spec, to-tickets, or triage.
Resolve one of:
.scratch/<feature>/spec.md and one file per ticket under .scratch/<feature>/issues/<NN>-<slug>.md);--all <parent>: generate one dependency-ordered cross-ticket goal.Always read ticket comments. For a tracker parent, use native sub-issue and dependency relationships when available; otherwise use explicit blocker text. Do not infer that a ticket is ready merely from its label.
If no argument yields several frontier tickets, list them and ask the user to choose one. Do not silently combine them. If a requested ticket is blocked, report its blockers and do not generate an implementation goal.
For a spec with no tickets, generate a goal directly only when the entire work fits one fresh context window. If it is multi-session work, route it through to-tickets instead of bypassing the context boundary.
Before drafting:
Keep this work read-only. Do not create status artifacts merely to build the goal.
Default to exactly one frontier ticket. The generated goal must fit one fresh context window and must not attract work from downstream blocked tickets.
For --all:
--all as the normal Matt workflow.Classify the implementation session by required capability, not by a hard-coded model name. The recommendation must remain portable across Claude Code, Codex, Pi, and other coding agents.
Choose exactly one capability tier:
Choose exactly one reasoning intensity:
Recommend the lowest tier and intensity that can reliably complete the ticket. Include one short evidence-based reason. Do not recommend a stronger tier merely because the ticket is large; prefer splitting work when it cannot fit one fresh context window.
Only name a concrete model when the target harness and its available model choices are known from current context. When naming one, present it as an optional mapping after the portable recommendation, not as the recommendation itself. Never assume a fixed set such as Luna, Terra, or Sol.
This list is for this compiler; do not put it in the paste block.
Required propositions — tick every item before drafting. If any of these is unchecked, stop and do not invent a goal.
<readiness-checklist>
goal-crafter Phase 3: no "looks good").</readiness-checklist>
Conditional prohibitions — satisfied by default on the single-ticket path. Do not tick them; an unchecked item here is not a stop.
--all: skip. If it is --all: the user asked for it explicitly, and the goal is labeled cross-context.to-tickets.Required fields must be filled. Conditional fields appear only when they apply. Use the harness envelope from goal-crafter Phase 2. When the harness is not explicit, infer it from the invocation context; if that is impossible, emit this generic block so it can be pasted into a fresh coding-agent session. Current state, Execution order, and the prefilled constraints stay required even when the harness names fewer sections.
Unless the source context explicitly overrides a default constraint, keep that line verbatim. When it does override, rewrite that line and name the source.
If current implementation is partial, put verified finished work in Current state and every remaining gap in Completion criteria. Never hide a known gap or tell the next agent to redo verified work.
Inherit every ticket criterion without changing product decisions. Do not relist evidenced-complete work as to-do.
<!-- compiler: only when tests were skipped, add these two Completion criteria lines (do not include them by default; they are not an execution to-do):
-->
<goal-template>
<one ticket-scoped outcome>
<shortest dependency-respecting path through the selected ticket>
<command>Reason:
</goal-template>
Output only:
<session-recommendation>
</session-recommendation>
Recommend a fresh session that directly executes the goal after to-tickets or triage. The ticket, spec, branch, and recorded fixed point carry the context; do not send the fresh session back through an interview or create a handoff document unless essential context exists only in the conversation and was never published.
For --all, explicitly label the goal as cross-context and recommend a persistent goal loop. For a single frontier ticket, recommend a normal fresh implementation or goal-loop session. If the harness automatically invokes /implement, the goal remains the execution contract and /implement must not re-interview or restate it. Keep the recommendation portable: for example, say Advanced + High for an authorization migration with concurrency invariants, not use Model X unless Model X is known to be available.
Take tt-a1i/to-goal from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.