prompt
Write a clean prompt, ready to paste, for a Claude Code session, a subagent, a system prompt or another model - goal and why, the session's context, limits, done-when, output. Use when the user asks to write, clean up or improve a prompt, or to turn a request into one.
- License 许可
- MIT
- 最近更新
- 2026-11-15
- Stars
- ★ 3
- Forks
- 3
01 前言 Front Matter
- name
- prompt
- description
- Write a clean prompt, ready to paste, for a Claude Code session, a subagent, a system prompt or another model - goal and why, the session's context, limits, done-when, output. Use when the user asks to write, clean up or improve a prompt, or to turn a request into one.
- argument-hint
- [what the prompt must get done]
03 SKILL.md 正文
What the prompt must get done: $ARGUMENTS; without it, what the user just asked for. Talk to
the user in their language; write the prompt in the language of the model's work (English by
default, the user's language when the output is for people who read it, e.g. a French site's copy).
-
Who reads it: a Claude Code session (here or in another repo), a subagent, a system prompt (API, an app), another model or tool. Guess it from the request; ask one short question only when the answer changes the prompt and nothing gives it.
-
Gather before writing: the facts this session already holds go into the prompt (paths, ticket IDs, commands, the decision taken and the options turned down, what was tried and failed): the reader starts cold. Read a file rather than guess it; never invent a fact. A secret or real personal data never goes in.
-
Write it, plain and direct, as a brief to a smart colleague who knows nothing of this conversation:
- Goal first, in one or two sentences, with why it matters: the reason lets the model make the right call in cases the prompt didn't foresee.
- Context: only what changes the work (where it lives, what exists, the constraints of the project or the user's way of working); no history for its own sake.
- What to do, as steps when the order matters; say what to do rather than what to avoid, and say whether to act or only to propose.
- Constraints and limits: scope (what not to touch), decisions to bring back to the user, actions that need their yes.
- Done when: the check that proves the work is finished (a test, a command, an output).
- Output: the expected form (a file, a diff, a report of N lines, JSON with these keys); an example when the form is unusual.
- Long material (a log, a document, data) goes in XML tags (
<log>…</log>), before the question about it. No shouting (CAPITALS, "CRITICAL"), no padding, no role play unless it sets real expertise; as short as the task allows, as long as it needs.
-
Sessions on backlog tickets skip steps 2 and 3: the ticket is the brief. Run
ion repo session <repo>#T-NN [<repo>#T-NN…]in the tickets' repo and give the line it prints, in a singlebashblock. It opens in the repo's main tree, names the session after the tickets, takes the effort and branch from the ticket's**Session**field (elselowfor XS or S,mediumfor M or L), and sends the session through/repo:worktree,/repo:backlog start, a failing test for a bug, and/repo:merge. A ticket that lacks the brief gets it written in the backlog first, never in the prompt.- Effort:
lowby default,mediumfor a large or loosely bounded ticket;highonly for money, concurrency or production data, said in one line above the command (--effortoverrides, the ticket's field keeps the choice). - Several sessions at once: group the tickets so that no two sessions edit the same files;
a ticket that needs another's merge waits for the next wave, said in one line. Each line
gets
--note "Leave <files> alone (<repo>#T-NN, another session).": what only holds now goes in a note, never in the ticket. - Above each line, one line: its tickets, its effort and why.
- Effort:
-
Give it ready to use, then one or two lines: the choices made (reader, language, what was left out). For any other Claude Code session:
- Write the prompt with the Write tool to
/tmp/<repo>-<subject>-prompt.md, overwritten at each new version: a multi-line command pasted from the terminal comes back indented, and a heredoc then never closes. - Show the prompt in a code block, so the user can read it, then the one line to paste in a
single
bashblock, which opens the session in the right folder:cd ~/code/<path>/<repo> && claude --model claude-opus-5-5 --effort low --name "<subject>" "$(cat /tmp/<repo>-<subject>-prompt.md)" - Always
--model claude-opus-5-5, an effort chosen as above (lowby default) and a--namethat says the subject, written out. When the work needs a branch, the prompt's first step is/repo:worktree <type>/<subject>, the branch named by [BRANCHES]. Every other command that opens a session for the user (the debrief's Blocked part) is written the same way.
Otherwise the prompt alone in a single code block, and where it goes (the
Agenttool, a system prompt, another model). Don't run it unless the user asks. - Write the prompt with the Write tool to
04 同仓库更多 Skills
worktree
Create a work branch in a ready-to-use git worktree. The normal way to start a branch, so as not to cross another session in the main tree.
update
Update ion-repo - the ion-repo tool of the machine and its plugins, then the open repo (ion repo update, on a branch merged right away into develop). Use when the user asks to update ion-repo, or accepts the update offered at session start.
token
Set up a service's credentials (PyPI, Stripe, an API, a host…) in a `.<service>/` folder at the repo root (`token`, chmod 600, and `config` on its scope), with one command that pastes the token unseen. Use when a task needs an API key or a token, or when the user wants to give one.
statusline
Change the look of the status line - its style, its colors, among them the chat's (the person's and Claude's) - each shown before it is chosen. Use when the user wants another status line, other colors for it, or from `/repo:look`.
skill
Write or sharpen a skill of an Ion tool's plugin - intent, SKILL.md in the right craft's plugin, one trigger case, docs; tested with `claude plugin eval` only on request. Use when the user wants a new skill, to fix one, or to check one fires and does its job.
review
暂无简介