When to use it
You're launching an autonomous agent (Claude Code, the Cursor agent, an agent with MCP tools) that decides its own steps. Your role: the person setting the task. The result: a brief that tells the agent the goal, what to use, what NOT to do and when to stop — instead of an endless loop or a march in the wrong direction.
The prompt (copy and paste)
You are an autonomous agent. Achieve the GOAL below using the tools available.
GOAL (an outcome, not a process): "<FILL IN: what has to exist when you're done>".
TOOLS: <LIST: web search / code execution / files / DB (read-only) / specific MCPs> — and what each is for.
CONTEXT AND INPUTS: <links, file paths, project constraints>.
Working rules:
1. First write a short plan (3-6 steps) and show it, then act.
2. For facts and current data you MUST use tools, not memory. Never fabricate tool results.
3. GUARDRAILS: <NOT ALLOWED: changing or deleting data, spending money, writing outside these paths, anything irreversible without confirmation>.
4. If the task is ambiguous, make a reasonable assumption, RECORD it and carry on; stop and ask only at a genuine fork in the road.
5. Budget: no more than <N> steps/tool calls; if you run out, report what's blocking you.
DONE (how we'll know it's finished): <acceptance criteria — what to check>.
At the end, give a report: what you did, what you assumed, what didn't work.
Why it works: an agent needs a goal, guardrails and a done-criterion more than a step-by-step script — give it heuristics, not a rigid recipe; and keep the tool set narrow, or the agent won't know which one to call.
Filled-in example
Goal: "produce a comparison of 5 competitors as a table in competitors.md". Tools: web search (facts), files (write to ./research only). Guardrails: don't touch code outside ./research, don't publish. DONE: a table with price/features/audience columns plus source links.
How the AI should proceed: shows the plan (find the list → gather data on each → merge into a table → verify links), searches the web for each entry, records the assumption "using public pricing as of June 2026", writes the file into ./research, and lists in the report what it couldn't find.
Variations
- Read-only recon. "Just gather and analyse, change NOTHING; propose a plan of changes for review" — for risky environments.
- A narrow tool set. Give the agent 1-2 tools for a specific workflow rather than "everything" — accuracy goes up.
- With a self-check. Add a step: "before reporting, reread DONE and verify each criterion yourself".
Pro tips
- Phrase the GOAL as an outcome ("the table is built and verified"), not a process ("google it and write something") — that gives the agent a criterion for stopping.
- A narrow tool set beats a wide one: if even a human couldn't say which tool fits a situation, the agent certainly will get it wrong. Don't wrap everything in sight.
- Always set guardrails and a step budget: an autonomous agent with no "don'ts" and no iteration ceiling risks irreversible actions and infinite loops. Require confirmation before anything irreversible.