---
title: "next-steps"
url: "https://claudemods.dev/zh-cn/builds/next-steps-b0ae2b"
source: "https://github.com/anthropics/claude-plugins-community/tree/main/next-steps"
source_type: "official"
author: "泉水亮介 │ 大学でVibe Codingを教えてます。"
author_handle: "rsensui"
stars: 4879
category: "工作流与 CI"
categories: ["workflow"]
tags: ["hooks", "l3-capability", "mods", "official-community", "prompt-suggestions", "ui"]
permission_level: 3
scan_complete: true
install: "claude plugin marketplace add anthropics/claude-plugins-community\nclaude plugin install next-steps@claude-community"
added: "2026-10-05T00:53:36.043Z"
updated: "2026-11-12T07:56:31Z"
locale: "zh-cn"
content_locale: "zh-cn"
---

# next-steps

在每个转折之后，在输入上方建议最多三个下一个提示。按 1、2 或 3 将其中一个放在提示框中作为你可以编辑的草稿，按 0 关闭。

## Description

一个在官方 anthropics/claude-plugins-community 存储库中发布的函数钩子插件。在 `turn.complete` 上，它通过 `$.model.fork` 分叉会话以生成最多三个可能的下一个提示，受限于会话的可用技能和斜杠命令（通过 `$.command.list` 获取）。建议通过 `ui.render` 在 `AbovePrompt` 上在提示框上方呈现；按 1/2/3 将提示框填充为可编辑草稿（`$.prompt.fill`），按 0 关闭，顶部建议通过 `$.prompt.suggest` 显示为幽灵文本。建议在 `turn.start` 上清除，该插件绝不会自行提交提示。选项：`minAnswerChars`（默认值 80）和 `suggestSkills`（默认值 true）。扫描在 hooks/register.tsx 中标记了 L3 model-fork 调用。

## Install

```
claude plugin marketplace add anthropics/claude-plugins-community
claude plugin install next-steps@claude-community
```

## Original README

# next-steps

After each turn, suggests up to three next prompts above the input box.

```
next:
  1: run the tests you just wrote
  2: do the same for the settings page
  3: /code-review high
  0: dismiss
```

Press `1`, `2` or `3` from an empty prompt box (or click one) and that prompt is written into the box as a draft. Edit it, then press Enter yourself. `0` dismisses. The top suggestion also shows as the box's dim ghost text, so Tab takes it.

The plugin never submits a prompt on its own.

## How it works

It is a function-hooks plugin (`hooks/register.tsx`):

- `turn.complete`: forks the session with `$.model.fork` to ask for likely next prompts. The fork shares the session's prompt cache, so it costs about one short reply.
- `$.command.list`: the session's skills and slash commands (plugin, user and MCP ones with their descriptions) go into the fork's question, so a suggestion can be `/skill arguments`. A suggestion that names a command the session does not have is dropped.
- `ui.render` on `AbovePrompt`: draws the suggestions as buttons.
- A press calls `$.prompt.fill`; the top suggestion goes to `$.prompt.suggest`.
- `turn.start`: hides the suggestions.

Suggestions draw in the terminal. Other surfaces show nothing.

## Options

| Option | Default | What it does |
| --- | --- | --- |
| `minAnswerChars` | `80` | Skip suggestions after answers shorter than this |
| `suggestSkills` | `true` | Tell the suggester which skills and slash commands the session has |


Showcase: Claude Codeに「Mods」が入った。

Thariq（@trq212）が紹介していたので、公式ドキュメントと手元のCLIで全部裏を取った。
一部、ポストの説明より踏み込める。

元記事→ https://x.com/trq212/status/2105734197801562264

Modsは「中で動くフック」だ。ここが肝。

これまでのsettings hooksは外側でシェルコマンドを叩く仕組みだった。
Modsは、JS/TSで書いた関数がClaude Codeのプロセスの内側で呼ばれる。

だからできることが一段違う。
ツール呼び出しを握って止める、差し替える、ユーザーに聞き返す。スピナーの表示を書き換える。トランスクリプトの横に自分のペインを出す。

公式ドキュメントの例は12行で、ツール呼び出し数をスピナーの隣に出すだけのコードだった。
`on('http://tool.call', ...)` と `on('ui.render', { component: 'Spinner' }, ...)` の2本。短い。

Thariqが挙げていた「毎ターン分類器を回して記憶を書く」も実装できる。

ただ、彼は「エージェントを分岐させる（fork）」と書いていたので、APIを確認した。

実体は `$.model.fork({ prompt })`。
別エージェントを立ち上げるのではなく、**いま進行中の会話の上に1問だけ投げる**。同じモデル・同じシステムプロンプトなので、大半がプロンプトキャッシュから返る。

会話を混ぜたくなければ `$.model.complete`。こちらは履歴を持たない単発のプロンプト。
どちらも自分のプランかAPIキーを消費する。

で、驚いたのがこっち。

**`/diff` も、AGENTS.mdの読み込みも、実はModだった。**

公式の組み込み一覧にこう書いてある。
・`cc-plugin-diff` → `/diff` のペインを描いている
・`cc-plugin-agents-md` → AGENTS.mdをプロジェクト指示として読む
・`cc-plugin-telemetry` → 分析記録の送信

つまりAnthropic自身が、自社機能をこの拡張層の上に載せ替えている。
後付けのプラグイン機構じゃなくて、本体がもうそう動いてる。

`/plugin` の Installed タブに Built-in として並ぶ。無効化もできる。

危ないところも書いておく。ここは誇張じゃない。

Modsはサンドボックスされない。あなたの権限でそのまま動く。
ファイルの読み書き、プロセス起動、ネットワーク、環境変数のAPIキー、送ったプロンプト全部、そしてツール呼び出しの事前承認まで。

sandboxingを有効にしていても、Modが起動したプロセスはサンドボックスの外だ。

入れる前に中身を見る手がある。

```
claude plugin validate ./some-mod
```

出力の `hooks:` と `calls:` に、扱うイベントと要求する操作が出る。実行せずに読める。

手元で試すなら。

```
claude plugin marketplace add anthropics/claude-plugins-community
claude plugin install next-steps@claude-community
```

next-stepsの実際の挙動も確認した。「次に何をするか提案」より具体的で、**次のプロンプト候補を最大3つ、入力欄の上に出す。1/2/3で下書きに入り、0で消える**。

ひとつ注意。Modsはv2.1.287以降が必要。僕の手元は2.1.281で、そのままでは動かなかった。`claude --version` を先に見たほうがいい。

僕の考察。
ツール呼び出しの前後に自分のコードを差し込めるということは、「AIにどこまで任せるか」を各チームが自分で書けるということだ。危険なコマンドを止めるのも、承認を自動化するのも、同じ一行の裏表にある。

機能が増えた話に見えて、実は責任の置き場所が変わった。

@trq212 非エンジニア向け Claude Code / Vibe Coding 法人研修
https://vibe-coder-bootcamp.com
社群 next-steps mod：輸入欄上方最多 3 個下一步提示
