Goal

From manusco/resonance · View interactive version

Goal is an AI agent skill from the GitHub repository manusco/resonance. The autonomous goal loop. Takes a goal and drives it to a verified finish by first confirming a goal contract, then decomposing it into slices, building, and verifying against grounded checks (real tests, validators, audit), bounded and never auto-shipping. Use when the user gives an outcome to reac

How to use this skill

Skill file

/resonance-ops-goal: carry a goal to a verified finish

Role: the conductor. Turns an outcome into a bounded, grounded, autonomous loop over the existing skills.

Invoked as: /goal "<outcome>" (to drive a goal to done).

Input: A goal or outcome, not a single step.

Output: The goal reached and verified by real checks, or a clear stop with the progress made and what blocked it.

Definition of Done: The approved goal contract is satisfied. The goal's checkable acceptance checks are met and proven by grounded verification (tests green, validators clean, audit APPROVE). Every slice's DoD is met. Nothing was shipped without explicit approval. Decisions and learnings were recorded.

You do not execute the surface wording of a messy request. Users often mix the outcome, a guessed tactic, constraints, and fears in one sentence. First write the goal contract. It separates what must be true from what was merely proposed. Then break the contract into slices and loop: build a slice, verify it against reality, decide, repeat, until the goal is proven done or the loop hits a real bound and stops. The line between this and a runaway agent is three things: the done-signal is always an executed check and never your own opinion, the loop is bounded by code, and one-way doors and the finish are gated by the human.

Independent Review Policy

Use independent review as a policy, not as a model ranking.

Independence means a different configured reviewer identity, not a role-played persona and not an unverified command alias. A second model is evidence to reconcile. It is never the done signal.

Do not recurse. Run at most one decision review per artifact hash and the final diff review before ship.

Prerequisites (fail fast)

Algorithm

Copy this checklist and tick items as you go.

  1. Draft the goal contract. Separate the request into: outcome; user directives and requested tactics, with provenance (settled, directive, or inferred); hard constraints; unresolved assumptions or contradictions; non-goals; material risks; acceptance checks; and any deferred metric with a due date. Do not fill empty boxes with invented certainty. Do not generate a downstream execution prompt. → verify: contract fields with content are explicit and requested tactics are not treated as approved implementation.
  2. Resolve only user-owned unknowns. Run /grill on the contract. Grill resolves decisions the repo cannot answer and runs a targeted risk pass only when the triggers are present. → verify: the contract is updated with resolved decisions and remaining risks.
  3. Decompose without reopening settled decisions. /plan consumes the confirmed contract and produces atomic slices, each with its own DoD. When /plan is invoked by /goal, suppress pass-by-pass approval and return the plan for one combined gate. → verify: an ordered slice list exists and preserves contract provenance.
  4. Approve once before code. Present the goal contract plus the plan and acceptance checks. Get approval before any code. This single approval is what keeps the loop honest. → verify: the user approved a contract and plan with checks that a machine can run.
  5. Start the bound. py .forge/skills/ops/goal/scripts/loop_state.py start "<goal>" --dod "<checkable DoD>" --contract goal_contract.json --plan-hash "<hash>". → verify: state initialized with the approved contract and plan hash. Missing plan hash blocks the loop.
  6. Loop over slices, autonomously and bounded. For each slice:

Run multiple slices without pausing. Pause only at the checkpoints below. → verify: each slice ends verified or the loop stopped on a bound.

  1. Final gate. When the goal DoD verifies, run /second-opinion --mode diff on the whole change. For a high-risk approved contract or plan, run /second-opinion --mode decision once on that artifact before the loop starts. → verify: independent review was run and reconciled, or the manual prompt was answered and reconciled.
  2. Propose ship, never auto-ship. Run loop_state.py achieve; it fails unless every acceptance criterion has accepted evidence. Present the result and evidence and ask for approval to /ship. Clear the loop (loop_state.py done) only after achievement. → verify: shipped only after explicit approval and completed history is retained.

Checkpoints (the more-autonomous cadence)

Proceed on your own within and across slices. Stop and check in only when it matters:

See checkpoint_protocol for how to present a checkpoint.

Recovery

Out of Scope

The guardrails (non-negotiable)

Reference Library

Operating Standard

Apply the Resonance operating standard from AGENTS.md (always loaded): the builder Voice and its banned-word list (no AI slop, no em dashes), Recommendation-First decisions (models recommend, the user decides), the Completion protocol (end with DONE / DONE_WITH_CONCERNS / BLOCKED / NEEDS_CONTEXT, backed by evidence, escalate after 3 failed tries), and the Ratchet (record durable learnings in the project memory; when .resonance/ledger/ exists it is the system of record for decisions, lessons, metrics, customers, and experiments, while 02_memory.md keeps [lib] notes and pointers).

Execution note: Use the host's native file, search, shell, browser, and delegation tools. Follow the procedure and verify material claims with evidence. Keep internal reasoning private and report decisions, actions, and results clearly.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.