一键导入
agent-goal
// Write `/goal` prompts for long-running agent work in Codex or Claude Code. Use for slash goal, agent goal, durable objective, autonomous coding run.
// Write `/goal` prompts for long-running agent work in Codex or Claude Code. Use for slash goal, agent goal, durable objective, autonomous coding run.
Svelte 5 component patterns for `.svelte` files: runes, snippets, keyed lifecycles, `{#await}`, TanStack Query, SvelteMap, shadcn-svelte, and workspace observers. Use when editing Svelte components or Svelte state modules.
How a workspace-backed app under `apps/*` is composed: the isomorphic doc factory (`create<App>`), the environment factories (`open<App>Browser` / `open<App>Extension` / tauri), the `#platform/*` build-time platform DI for multi-platform (Tauri) apps, the `session` singleton, daemon/script placement under per-project `workspaces/<app>/`, and the file layout itself. Use when creating a new app, naming or placing the iso/browser/extension factory, wiring `#platform/*` subpath imports for a Tauri seam, choosing between auth-gated (Shape A) vs module-singleton (Shape B), placing the session singleton, or registering daemon/script bindings.
Epicenter auth packages: `@epicenter/auth` and the Svelte wrapper at `@epicenter/svelte/auth`, OAuth sessions, identity state, auth-owned fetch/WebSocket, and workspace lifecycle binding. Use when editing Epicenter auth clients, session state, hosted sign-in, or auth/workspace integration.
Better Auth security hardening: rate limits, secrets, CSRF, trusted origins, cookies, sessions, OAuth tokens, and audit logging. Use when reviewing auth security, brute-force protection, token handling, or deployment safety.
Tauri commands, permissions, capabilities, security config, path handling, cross-platform file ops, and native filesystem APIs. Use when mentioning Tauri, desktop apps, Rust commands, invoke, capabilities, permissions, ResourceId, file paths, or platform differences.
Run a continuous collapse-and-simplify pass that surgically removes indirection failing to earn its boundary. Use when the user says 'collapse pass', 'simplify pass', 'reduce indirection', 'shrink the surface', 'find what to delete', when asking to audit a package for dead abstractions, or when the goal is a sequence of small refactor commits that delete more than they add. Pairs with code-audit (smell catalog), refactoring (per-change mechanics), one-sentence-test (cohesion gate), cohesive-clean-breaks (deep redesigns), approachability-audit (first-read sanity), and post-implementation-review (second-read after each commit).
| name | agent-goal |
| description | Write `/goal` prompts for long-running agent work in Codex or Claude Code. Use for slash goal, agent goal, durable objective, autonomous coding run. |
Write one /goal line that a coding agent can keep pursuing across turns until it can prove the work is done.
The best goal is both a directive and a completion condition:
/goal [do the work] until [observable condition is true].
Treat the goal as a contract. It should tell the agent what to do, what evidence proves it, and where to start.
The highest-signal goal answers three questions:
What should change?
How will the agent prove it changed?
Where should the agent start?
Use this structure unless the user needs a different format:
/goal Complete [single objective] in [lane]. First read [required context]. Work in checkpoints. After each checkpoint, surface evidence from [validation]. Continue until [verifiable end state].
Include only execution-critical details:
/goal when the user asks for the goal text.bun test packages/workspace exits 0" over "tests pass"; prefer "all checked items in PLAN.md are complete" over "finish the plan."/goal./goal for vague wishes, unrelated chores, open-ended research, or work where the agent cannot produce evidence.Think in this order:
Outcome
What must be true?
Evidence
What command, artifact, or visible behavior proves it?
Lane
What is the intended work area?
Method
What should the agent read first, and how should it checkpoint?
Start
Where should the agent begin?
Then compress that into one goal.
Codex:
Claude Code:
/goal sets a session-scoped completion condition.Shared rule: the goal should not rely on hidden state. Tell the agent to run checks and surface evidence in the transcript.
Before finalizing the goal, imagine a checker can see only the transcript, not the filesystem.
Good evidence:
`bun test packages/auth` exited 0.
All checklist items in `specs/auth.md` are checked.
The final screenshot shows the empty state and no overlap at 390px and 1440px.
`git diff --name-only` only lists files under `apps/api`.
Weak evidence:
The implementation looks complete.
The agent believes the migration is done.
Most tests should pass.
The UI seems better.
If the evidence is weak, rewrite the goal until completion can be judged from command output, visible artifact checks, or an explicit final status.
Plan execution:
/goal Implement `specs/[file].md` in checkpoints until every checklist item is complete, the review section is filled in, and `[final validation command]` exits 0. First read the spec and the files it names. After each checkpoint, update the checklist and surface the validation result. Continue unless the spec conflicts with current code or needs a product decision.
Failing tests:
/goal Fix the failing tests in `[lane]` until `[test command]` exits 0 and no unrelated speculative changes are present. First run the command and inspect the failures. Work from the owning boundary outward. After each fix, rerun the targeted test and report the result. Ask before deleting tests or weakening assertions.
Migration:
/goal Migrate `[old path or system]` to `[new path or system]` until all callers use the new path, parity checks pass, and `[final validation command]` exits 0. First read `[migration plan or docs]` and identify callers. Work in checkpoints with validation after each checkpoint. Ask before changing unrelated public APIs, or if compatibility, data migration, or rollback policy is ambiguous.
Prototype:
/goal Build a polished first version of `[app or feature]` inside `[lane]` until the primary flow works end to end, the app builds and runs, and `[visual or command validation]` confirms the expected behavior. First read `[plan or reference]`. Work in checkpoints and surface screenshots or command output as evidence. Ask if the data model or user flow is unclear.
Backlog or issue queue:
/goal Work through `[queue or label]` until every item is closed or has a documented reason it needs user input. First list the queue and choose the item with the clearest owner and validation path. For each item, make the correction at its owning boundary, run `[validation]`, and report the result before moving on. Stop when the queue is empty.
Eval or prompt loop:
/goal Improve `[prompt or system]` until `[eval command]` reaches `[target score]` or no further targeted improvement is justified. First run the eval and inspect failures. Make direct design corrections, rerun the eval after each change, and report score changes. Ask if improvement requires product or policy guidance.
Weak:
/goal Make the app better and fix bugs.
Strong:
/goal Fix the checkout regressions tracked in `issues/checkout.md` until every listed reproduction passes, `bun test apps/storefront` exits 0, and the final status names any intentionally deferred issues. Work only in `apps/storefront` and shared checkout packages. Ask before changing payment provider contracts or deleting tests.
Weak:
/goal Finish the migration.
Strong:
/goal Complete `specs/20260514T120000 auth-migration.md` until every checklist item is checked, all auth callers compile against the new service, `bun test packages/auth apps/api` exits 0, and `git diff` shows no unrelated speculative edits. Update the spec after each checkpoint. Ask if the old API has undocumented behavior that needs a compatibility decision.
Before handing back a goal, verify:
/goal.