Agent skill

Compose Next

by XiaomiMiMo in XiaomiMiMo/MiMo-Code

A skill your agent uses for multi-step feature work, bug fixes, or refactors where requirements need to settle, a feature document should carry design + tasks + delivery evidence, and the change…

MITAuto-check: warningsDevelopment

Install Compose Next

The automated check flagged lines worth reading first. See the safety section below.

skills CLI
$ npx skills add XiaomiMiMo/MiMo-Code --skill compose-next -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install XiaomiMiMo/MiMo-Code compose-next --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/XiaomiMiMo/MiMo-Code.git skills-src && mkdir -p .claude/skills && cp -r skills-src/packages/cli/src/skill/builtin/.bundle/compose-next .claude/skills/compose-next && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
compose-next
GitHub stars
14k
Token cost
~3.6k tokens
SKILL.md length
1,834 words
Files
1
Skills in repo
22
Repo updated
First seen
Licence
MIT

At a glance

A skill your agent uses for multi-step feature work, bug fixes, or refactors where requirements need to settle, a feature document should carry design + tasks + delivery evidence, and the change…

  • Works in 4 steps: Choose the option marked (Recommended)… → Otherwise choose the closest… → If the decision includes destructive or… → …
  • Multi-step feature work
  • SKILL.md covers Step 0 — Orient, Grill — resolve decisions, Workspace — worktree ownership and Spec — one document per feature, plus 5 more sections
  • Calls git, bun and uv

What it does

Compose Next is an agent skill from XiaomiMiMo/MiMo-Code. Use for multi-step feature work, bug fixes, or refactors where requirements need to settle, a feature document should carry design + tasks + delivery evidence, and the change deserves independent review before merge. Use it only when the user explicitly requests this workflow, whether with /compose-next, by name, or in any other clear natural language; do not infer the request from task complexity alone. Not for one-shot edits, single-file tweaks, or answering questions — those need no orchestration overhead.

Its SKILL.md is about 3.6k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Refactoring and Debugging. The repository describes itself as: MiMo Code: Where Models and Agents Co-Evolve. The licence is MIT.

When your agent uses it

  • Multi-step feature work
  • Refactors where requirements need to settle
  • A feature document should carry design + tasks + delivery evidence
  • The change deserves independent review before merge

Example prompts

  • “/compose-next”

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. Choose the option marked (Recommended) when repository evidence still supports it and it can run unattended.
  2. Otherwise choose the closest minimal-scope option supported by the evidence; prefer text-only, non-interactive work.
  3. If the decision includes destructive or irreversible work, choose a non-destructive path that preserves progress; never auto-approve the…
  4. State the option selected and the reason in the response.

What it can do on your machine

Read from SKILL.md and the folder at commit 6babeb0. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git
    • bun
    • uv
    • gh

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git, uv and gh, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Compose Next loads about 3.6k tokens when it runs. Until then it costs about 132 tokens; SKILL.md has 1,834 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~132
When it runs · the whole SKILL.md, loaded when a task matches
~3.6k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: warnings

The automated check found patterns that need a careful read before installing.

  • WarningTells the agent its actions are pre-authorized / not to stop for confirmationSKILL.md:41
    - Do not ask for permission to continue when no decision remains.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from XiaomiMiMo/MiMo-Code at commit 6babeb0, republished under its MIT licence (© XiaomiMiMo). 1,834 words, ~3,584 tokens.

Download SKILL.mdSave it as .claude/skills/compose-next/SKILL.md (or your agent's skills folder).
name
compose-next
description
Use for multi-step feature work, bug fixes, or refactors where requirements need to settle, a feature document should carry design + tasks + delivery evidence, and the change deserves independent review before merge. Use it only when the user explicitly requests this workflow, whether with `/compose-next`, by name, or in any other clear natural language; do not infer the request from task complexity alone. Not for one-shot edits, single-file tweaks, or answering questions — those need no orchestration overhead.

Compose Next

Compact end-to-end contract for grill → workspace → spec → implement → verify → review → finalize → finish. One skill load, no internal skill hand-offs.

When writing a checkpoint or compacting context, preserve this recovery instruction in the checkpoint or compacted summary: on resumption, if the Compose Next instructions are absent, reload the compose-next skill before continuing.

Enter this workflow only on an explicit user request. Any clear natural-language instruction to use this workflow counts just like /compose-next; the user does not need to know or name the skill. If the user has not clearly requested the workflow, do the work directly and run none of the phases below; do not infer consent merely because the task is large or resembles a Compose task.

Step 0 — Orient

Inspect the repository, its instructions (AGENTS.md, README, existing spec files), and recent changes before asking anything. Do not ask the user for facts the environment already answers.

Decide the shape of the work:

  • Fully constrained mechanical change with no durable design surface → skip Grill and Spec, go to Workspace then Implement.
  • Requirements or design ambiguous → Grill first.
  • Requirements clear, feature deserves a durable document → Workspace then Spec.

User gates and project overrides:

  • If the user explicitly requests without worktree or specifies a worktree or workspace path, use that workspace choice and skip the default worktree gate. Do not ask again for worktree consent.
  • If the user explicitly says without spec, "no spec needed", "this is a small fix", or gives an equivalent instruction, skip the durable feature document and its spec gate. Keep verification and review when the task still warrants them.
  • An explicit project instruction, AGENTS.md, or user-provided agent/worktree configuration may define a project-specific worktree path, branch convention, spec path, or spec format. Use that configuration instead of the defaults in this skill. Record the override in the feature document or final report when it changes the normal artifact location.

Every path passes through Workspace before Spec or Implement; no branch skips it.

Grill — resolve decisions

Resolve one decision axis at a time. A single decision may bundle multiple dependent fields in one structured question; unrelated decisions require separate turns.

Use the Question tool for every user decision:

  • Put known choices in options. Each option gets a concise label and a description explaining the consequence. List the recommendation first and mark its label (Recommended).
  • For consequential choices, include 2–3 viable alternatives.
  • When choices cannot be enumerated, still call Question with options: [] for free-text.
  • Do not ask for permission to continue when no decision remains.

Split requests spanning independent subsystems before refining each part. Do not begin implementation until requirements and scope are settled.

Never-Ask handling

If the Question tool is unavailable or returns [Never-Ask], resolve this one decision yourself and continue:

  1. Choose the option marked (Recommended) when repository evidence still supports it and it can run unattended.
  2. Otherwise choose the closest minimal-scope option supported by the evidence; prefer text-only, non-interactive work.
  3. If the decision includes destructive or irreversible work, choose a non-destructive path that preserves progress; never auto-approve the destructive option.
  4. State the option selected and the reason in the response.

Never-Ask applies to the current decision only. At every later decision point, call the Question tool again — Never-Ask does not disable future questions or pause the workflow.

Workspace — worktree ownership

Never begin implementation on main or master without explicit user consent. If the active workspace is already chosen, skip creation below and continue with toolchain setup.

  • Compare git rev-parse --git-dir with git rev-parse --git-common-dir. If they differ, use the current linked worktree; do not nest another. A non-empty git rev-parse --show-superproject-working-tree indicates a submodule, not a linked worktree.
  • Create a linked worktree at .worktrees/<slug> by default. Base the new branch on the latest mainline (e.g. origin/main). If the current checkout makes the base unclear (detached HEAD, an unrelated feature branch, unknown default branch), ask the user explicitly which base to use before creating the worktree. Run git check-ignore -q "$path"; if it is not ignored, write * to .worktrees/.gitignore. Then run git worktree add "$path" -b "$branch" <base>.
  • When targeting the worktree with a command, pass its absolute path as workdir; omitted workdir uses the current session directory.
  • Install dependencies per repository instructions. Prefer lockfile-frozen, hardlink-friendly modes (bun ci, uv sync --frozen) over commands that mutate the lockfile. Confirm the toolchain is usable before continuing.

Spec — one document per feature

Maintain one document per feature at docs/compose/spec/<feature-name>.md from the workspace root. Do not add a date to the filename. A user-specified location overrides this path. Edit an existing document in place; never create a separate plan or report. Do not write the feature document before Workspace owns the active workspace.

Template
markdown
---
feature: <feature-name>
status: designed | in-progress | delivered
updated: YYYY-MM-DD
branch: <branch-name>
commits: <short-base-sha>..<short-head-sha> # leave empty while in progress; fill at delivery
---

# <Feature Name>

## Report

## [S1] Problem
Describe the user-visible problem.

## [S2] Design
Record the chosen behavior and the contracts needed to implement it.

## [S3] Out of Scope
State explicit boundaries.

## Tasks
- [ ] T1: <work item> — acceptance: <observable result> (covers: S2)
- [ ] T2: <work item> — acceptance: <observable result> (covers: S2; depends: T1)
Design-time rules
  • Leave Report empty and set status: designed.
  • Keep [Sn] anchors stable when headings change; never renumber existing anchors.
  • Record settled decisions and precise contracts, not exploration history or file-level code dumps. Include architecture, interfaces, data flow, error behavior, and testing boundaries when they affect the change.
  • Make each task the smallest independently verifiable work item; give it an observable acceptance criterion. Add depends: only for real prerequisites; dependencies must be acyclic.
  • Add covers: for every task implementing a design section. Every design requirement must be covered by at least one task; every reference must resolve.
  • Remove placeholders such as TBD, "handle edge cases", and references to unspecified similar work.
  • Scale detail to the change; do not pad small designs.

Before implementation, fix ambiguous requirements, contradictions, unresolved references, and unverifiable acceptance criteria. If the user is available, request document approval with the Question tool; otherwise continue.

Amendments

Update only affected sections, bump updated:, preserve anchors, and keep only the tasks required by the amendment and their dependents. Do not regenerate the document or create duplicate tasks.

Implement

Use the feature document as the source of requirements, or the conversation for an undocumented mechanical change. When a feature document exists, set its status: in-progress on the first implementation commit. Execute tasks in dependency order. Track multi-step work with the Task tool.

For behavior changes with a cheap reproduction, write a failing test, confirm it fails for the intended reason, implement the smallest fix, and confirm it passes. A bug fix requires a regression test when one can be written. Skip test-first for generated code, configuration-only changes, throwaway prototypes, or explicit user direction.

Test public behavior. Do not duplicate production logic in expected values, add test-only production APIs, or assert only that mocks were called. Prefer real implementations over mocks.

For failures, reproduce before editing and identify the root cause from errors, diffs, recent commits, or boundary instrumentation. After two failed fixes, stop patching and re-derive the cause.

Show full SKILL.md (728 more words)Show less
Parallel work

Dispatch independent tasks in parallel when isolation prevents collisions; keep tightly coupled work together. Prefer giving parallel subagents disjoint file sets and keeping commits with the orchestrator. Give each subagent the workspace path, task, acceptance criteria, relevant spec sections, and required verification. Do not pass session history. Treat its report as a claim and inspect the resulting diff.

Continue through tasks without routine approval pauses. Stop only for an unresolved product decision, a blocker that cannot be worked around, a destructive action requiring consent, or completion.

Verify

Before any completion claim, run the repository's relevant tests, typecheck, build, or reproduction from the correct directory and read the output. Record each command and result. Mark known baseline failures as PRE-EXISTING with a short identifier. Do not substitute prior output or a subagent report for fresh evidence.

Verification and review are strictly sequential. Wait for all verification commands to exit before dispatching the reviewer. Never overlap review with a resource-heavy test or application process in the same environment.

Review

After implementation is verified and before finalizing the feature document, dispatch one fresh subagent to review the complete change.

Provide the reviewer:

  • the applicable spec sections and acceptance criteria;
  • the workspace path, base branch, base SHA, head SHA, and exact diff command or precomputed diff;
  • a compact verification summary: one line per command with PASS, FAIL, or PRE-EXISTING, plus test counts when available. Do not paste full command output unless a specific failure requires it.

If there is no feature document, take acceptance criteria from the conversation. If none are explicit, ask the user for them before dispatching the reviewer.

Do not provide an implementer-authored narrative. The reviewer may inspect the diff and run additional commands needed to validate its conclusions. It must not repeat a command already reported as passing, especially a heavy E2E suite, unless the result is stale, the code changed afterward, or concrete evidence makes the result suspect. Before any justified rerun, confirm no equivalent command is still running. Missing evidence should be reported or gathered with the cheapest non-duplicative command.

Use a reviewer model at least as capable as the strongest implementer it reviews.

Require separate conclusions for:

  • Spec compliance — every acceptance criterion is met and points to evidence in the diff or reviewer-observed command output.
  • Correctness — logic, boundaries, error handling, regressions, and tests are sound, including issues outside the written spec.
  • Codebase consistency — naming, structure, and local conventions match surrounding code.

Classify unmet or unverifiable acceptance criteria and correctness bugs as critical. Fix critical findings, re-verify, and re-review affected areas. Reject incorrect findings with technical evidence. If the fix-and-re-review loop stops converging — repeated findings on the same area, or fixes that introduce new criticals — stop looping and report the impasse with the remaining findings instead of forcing a pass.

For human review feedback, verify each item against the codebase, clarify ambiguous items before editing, and implement validated items one at a time with verification. Check actual usage before expanding an unused path, and surface conflicts with prior user decisions instead of silently complying.

For parallel task work, review integrated task diffs at useful boundaries only when delaying review would compound risk.

Finalize — commit the feature document

If a feature document exists, after review passes and before finishing the branch:

  1. Set status: delivered, bump updated:, and record the reviewed range as <short-base-sha>..<short-head-sha> using git rev-parse --short. The range excludes the final documentation commit below.
  2. Check off completed tasks; leave incomplete tasks unchecked and do not claim delivery if they block acceptance.
  3. Replace Report with:
markdown
## Report

**What was built** — 1-3 concise paragraphs describing the final behavior.

**Verification** — commands run and their observed results.

**Journey log** — at most 5 entries that help future work: dead ends, pivots, or transferable lessons. Preserve useful prior entries and append new ones.

Update a design section only when it contradicts the delivered behavior. Commit the finalized document on the feature branch before finishing. This documentation-only commit does not restart verification or review; CI re-running on it is expected.

Finish

Do not auto-finish. After Finalize, report branch, base, head SHA, workspace, feature-doc path when available, and suggest a closing action.

If the user asks to finish but the path is unclear, use the Question tool to settle:

  • closing action: local merge / open PR / push only / keep the branch;
  • which base branch to merge or target;
  • keep or remove the worktree.

Worktree pitfalls:

  • Local merge and gh pr merge run from the main repository checkout — the base branch cannot be checked out while another worktree holds it.
  • git worktree remove only on .worktrees/ or the path scoped by the prompt / AGENTS.md.

© XiaomiMiMo, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in packages/cli/src/skill/builtin/.bundle/compose-next of XiaomiMiMo/MiMo-Code.

Open the folder on GitHubat commit 6babeb0

Compare with similar skills

Compose Next next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Compose Next compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Compose Next this skillXiaomiMiMo/MiMo-Code14k—~3.6kAutomated safety check: WarnMIT
Code Review Graph Navigatorhandsontable/handsontable22k—~939Automated safety check: PassCustom licence
Andrej Karpathy Skillduolahypercho/andrej-karpathy-skills248—~793Automated safety check: PassMIT
Verdaccio Change Implementationverdaccio/verdaccio18k—~1.3kAutomated safety check: PassMIT
RoamCranot/roam-code517—~2.4kAutomated safety check: PassApache-2.0
Odoo Workflowunclecatvn/agent-skills143—~4.7kAutomated safety check: PassMIT

Similar skills

  • Code Review Graph Navigator

    handsontable/handsontable

    Queries a pre-built, Tree-sitter-based code graph of the whole monorepo instead of grepping call chains, for exploring, debugging, refactoring or reviewing code.

    22k GitHub stars~939 tokensUpdated today
    DevelopmentAuto-check passed
  • Andrej Karpathy Skill

    duolahypercho/andrej-karpathy-skills

    Apply Andrej Karpathy-inspired coding-agent guidelines in Codex.

    248 GitHub stars~793 tokensUpdated 4 mo ago
    DevelopmentAuto-check passed
  • A workflow for implementing a Verdaccio bug fix, feature or refactor: pick the release lines, check existing options, edit the owning layer, test and add a changeset.

    18k GitHub stars~1.3k tokensUpdated today
    DevelopmentAuto-check passed
  • Roam

    Cranot/roam-code

    Codebase comprehension via roam-code CLI. An agent skill from Cranot/roam-code.

    517 GitHub stars~2.4k tokensUpdated 3 days ago
    DevelopmentAuto-check passed
  • Odoo Workflow

    unclecatvn/agent-skills

    Mandatory pre-code gate and definition-of-done for ANY Odoo change (add field, override method, inherit view/xpath, OWL/JS patch, wizard, cron, controller, report, security, migration, bug fix…

    143 GitHub stars~4.7k tokensUpdated 13 days ago
    DevelopmentAuto-check passed
  • Synapse Usage

    S1LV4/th0th

    Use the th0th Synapse cognitive modulation layer to get focused, low-noise retrieval during multi-step coding tasks.

    136 GitHub stars~2.9k tokensUpdated 3 mo ago
    DevelopmentAuto-check passed

More from XiaomiMiMo/MiMo-Code

All 22 skills in this repo
  • Paper Research on arXiv

    XiaomiMiMo/MiMo-Code

    Searches arXiv, fetches metadata, generates BibTeX, downloads PDFs and finds citations and related papers using a bundled Python script.

    14k GitHub starsUsed in 1 repo~1.5k tokens
    Auto-check passed
  • Agent Skill Creator

    XiaomiMiMo/MiMo-Code

    Interactive guide for creating, reviewing and fixing agent skills (SKILL.md folders), covering structure, frontmatter rules, trigger phrases and validation before sharing.

    14k GitHub stars~1.9k tokensUpdated 4 days ago
    Auto-check passed
  • DOCX Toolkit

    XiaomiMiMo/MiMo-Code

    Produces, edits and reads Microsoft Word files through python-docx and lxml, with a decision table for picking the lightest workflow for a given task.

    14k GitHub stars~2.4k tokensUpdated 4 days ago
    Auto-check passed
  • Drive MiMo Code

    XiaomiMiMo/MiMo-Code

    Lets one MiMoCode process drive another, headless with JSON events or interactively through tmux, to test behavior and visual regressions with parseable evidence.

    14k GitHub stars~3.9k tokensUpdated 4 days ago
    Auto-check passed
  • PDF Toolkit

    XiaomiMiMo/MiMo-Code

    Reads, transforms, composes and fills PDFs with Python scripts for extraction, merging, watermarking, encryption, OCR and form filling.

    14k GitHub stars~1.7k tokensUpdated 4 days ago
    Auto-check passed
  • XLSX Spreadsheet Toolkit

    XiaomiMiMo/MiMo-Code

    Builds, edits, cleans, recalculates and reads Excel workbooks and CSV files with openpyxl and pandas, plus LibreOffice for recalculation and PDF export.

    14k GitHub stars~2.9k tokensUpdated 4 days ago
    Auto-check passed

Categories

Questions about Compose Next

What does Compose Next do?

A skill your agent uses for multi-step feature work, bug fixes, or refactors where requirements need to settle, a feature document should carry design + tasks + delivery evidence, and the change…. Compose Next is an agent skill from XiaomiMiMo/MiMo-Code. Use for multi-step feature work, bug fixes, or refactors where requirements need to settle, a feature document should carry design + tasks + delivery evidence, and the change deserves independent review before merge.

When should I use Compose Next?

Compose Next fits situations like: multi-step feature work; refactors where requirements need to settle; A feature document should carry design + tasks + delivery evidence; the change deserves independent review before merge.

How do I install Compose Next in Claude Code?

Run `npx skills add XiaomiMiMo/MiMo-Code --skill compose-next -a claude-code`. Or copy the skill folder (packages/cli/src/skill/builtin/.bundle/compose-next in XiaomiMiMo/MiMo-Code) into .claude/skills/compose-next in your project. Claude Code loads it when a task matches its description.

How do I install Compose Next in Codex?

Run `npx skills add XiaomiMiMo/MiMo-Code --skill compose-next -a codex`. Or copy the skill folder (packages/cli/src/skill/builtin/.bundle/compose-next in XiaomiMiMo/MiMo-Code) into .agents/skills/compose-next in your project. Codex loads it when a task matches its description.

Can I use Compose Next in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add XiaomiMiMo/MiMo-Code --skill compose-next -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/compose-next, .gemini/skills/compose-next, .github/skills/compose-next and .opencode/skills/compose-next in your project.

What does Compose Next need to run?

Going by SKILL.md and its folder, Compose Next needs the command-line tools its instructions call (git, bun, uv and gh).

Does Compose Next access the network?

SKILL.md contains no URLs. Its commands use git, uv and gh, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Compose Next safe to install?

Our automated static check of SKILL.md flagged 1 warning(s): tells the agent its actions are pre-authorized / not to stop for confirmation. Read the flagged lines before installing; the check is not a guarantee either way.

What licence does Compose Next use?

Compose Next is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Compose Next use?

About 3.6k tokens (SKILL.md is roughly 14k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Compose Next?

Skills that share tags, products or a category with Compose Next: Code Review Graph Navigator (handsontable/handsontable, 22k stars), Andrej Karpathy Skill (duolahypercho/andrej-karpathy-skills, 248 stars), Verdaccio Change Implementation (verdaccio/verdaccio, 18k stars) and Roam (Cranot/roam-code, 517 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Compose Next?

XiaomiMiMo (a GitHub organization) maintains it in XiaomiMiMo/MiMo-Code, which has 13,601 GitHub stars. The repository holds 22 skills in this directory. The repository was last updated on October 3, 2026.

Source: XiaomiMiMo/MiMo-Code on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.