Glean 拾遗
日刊 /2026-07-27 / Ultrareview:Claude Code 远程多 Agent 深度代码审查

Ultrareview:Claude Code 远程多 Agent 深度代码审查

原文 code.claude.com 收录 2026-07-27 06:00 阅读 9 min
AI 解读

Ultrareview 是 Claude Code 提供的一项深度代码审查功能,启动一组远程 reviewer agent 在沙箱中并行审查当前分支或 Pull Request。与本地审查相比,Ultrareview 的每个发现都会独立复现验证,因此更聚焦真实缺陷而非风格建议;覆盖范围更广,能发现本地审查遗漏的问题;且完全在远端运行,不占用终端资源。文章详细介绍了使用方法:通过 /code-review ultra 命令启动,支持指定 base 分支、PR 编号、自然语言描述上下文;提供非交互式子命令 claude ultrareview 用于 CI 集成。定价方面,Pro/Max 用户有 3 次免费额度,之后每轮审查约 $5-$25 按量计费,审查时长约 5-10 分钟。限制包括 diff 大小上限(默认 500 文件/8000 行)、部分平台不可用等。适用于合并前需要更深入检测的场景。

原文 9 分钟
原文 code.claude.com ↗
§ 1

Ultrareview is a deep code review that runs on Claude Code on the web infrastructure. When you run /code-review ultra, Claude Code launches a fleet of reviewer agents in a remote sandbox to find bugs in your branch or pull request. Compared to a local /code-review or /review, ultrareview offers:

Higher signal: every reported finding is independently reproduced and verified, so the results focus on real bugs rather than style suggestions

Broader coverage: a larger fleet of reviewer agents explores the change in parallel, which surfaces issues that a local review can miss

No local resource use: the review runs entirely in a remote sandbox, so your terminal stays free for other work while it runs

Ultrareview 是一种深度代码审查,运行在 Claude Code on the web 基础设施上。当你运行 /code-review ultra 时,Claude Code 会在远程沙箱中启动一组审查代理,以发现你的分支或拉取请求中的错误。 与本地 /code-review 或 /review 相比,ultrareview 提供以下优势:

更高信号:每个报告的发现都会被独立复现和验证,因此结果聚焦于真正的错误而非风格建议

更广覆盖:更大的审查代理阵列并行探索变更,从而发现本地审查可能遗漏的问题

无本地资源占用:审查完全在远程沙箱中运行,因此你的终端可以腾出来处理其他工作

§ 2

Ultrareview requires authentication with a claude.ai account because it runs on Claude Code on the web infrastructure. If you are signed in with an API key only, run /login and authenticate with claude.ai first. Ultrareview is not available when using Claude Code with Amazon Bedrock, Google Cloud’s Agent Platform, or Microsoft Foundry, and it is not available to organizations that have enabled Zero Data Retention. When ultrareview is not available, /code-review ultra runs a local review in your session instead.

Ultrareview 需要使用 claude.ai 账户进行身份验证,因为它运行在 Claude Code on the web 基础设施上。如果你仅使用 API 密钥登录,请先运行 /login 并通过 claude.ai 进行身份验证。Ultrareview 在以下情况下不可用:使用 Amazon Bedrock、Google Cloud's Agent Platform 或 Microsoft Foundry 中的 Claude Code,以及已启用零数据保留的组织。当 ultrareview 不可用时,/code-review ultra 会在你的会话中运行本地审查。

§ 3

Run ultrareview from the CLI

Start a review from any git repository:

Without arguments, ultrareview reviews the diff between your current branch and the default branch, including uncommitted and staged changes. For a branch review, Claude Code bundles the repository state and uploads it to a remote sandbox; when you review a pull request, Claude Code uploads nothing from your machine. Before launching, Claude Code shows a confirmation dialog with the review scope, your remaining free runs, and the estimated cost; for a branch review, the scope includes the file and line count. After you confirm, the review continues in the background while you keep using your session. The command runs only when you invoke it with /code-review ultra; Claude doesn’t start an ultrareview on its own.

从 CLI 运行 ultrareview

从任意 git 仓库启动审查:

不带参数时,ultrareview 审查当前分支与默认分支之间的差异,包括未提交和暂存的更改。对于分支审查,Claude Code 会打包仓库状态并上传到远程沙箱;当你审查拉取请求时,Claude Code 不会从你的机器上传任何内容。 在启动前,Claude Code 会显示一个确认对话框,包含审查范围、剩余免费运行次数以及预估费用;对于分支审查,范围包括文件数和行数。确认后,审查会在后台继续运行,你可以继续使用会话。 该命令仅在调用 /code-review ultra 时运行;Claude 不会自行启动 ultrareview。

§ 4

Review against a different base

To compare against a base other than the default branch, pass the branch name. This example reviews your current branch against develop instead:

The base branch doesn’t need to exist in your local clone; Claude Code fetches it from origin. If the name has a typo, Claude Code suggests the closest branch name in the error.

针对不同基准进行审查

要与默认分支之外的基准进行比较,请传入分支名称。以下示例审查当前分支与 develop 分支的差异:

基准分支不需要存在于本地克隆中;Claude Code 会从 origin 获取。如果名称有拼写错误,Claude Code 会在错误信息中建议最接近的分支名称。

§ 5

Review a pull request

To review a GitHub pull request instead of a local branch, pass the PR number:

The command also accepts #1234, PR 1234, and pasted PR URLs; a pasted URL must point to the repository in your current directory. In PR mode, the remote sandbox clones the pull request directly from the host rather than bundling your local working tree. PR mode works with repositories on github.com and on GitHub Enterprise Server instances that an Owner has connected to Claude Code.

审查拉取请求

要审查 GitHub 拉取请求而非本地分支,请传入 PR 编号:

该命令也接受 #1234、PR 1234 以及粘贴的 PR URL;粘贴的 URL 必须指向当前目录中的仓库。 在 PR 模式下,远程沙箱直接从主机克隆拉取请求,而不是打包你的本地工作树。PR 模式适用于 github.com 上的仓库,以及所有者已连接至 Claude Code 的 GitHub Enterprise Server 实例。

§ 6

Pass a request in plain words

On Claude Code v2.1.218 or later, you can also describe what you’re working on in plain words:

The review still covers your current branch, the same scope as running with no argument. Claude keeps your text as a note, shown in the launch dialog, and relates the findings to it when they arrive. Claude Code treats your text as a note only when it has more than one word and isn’t a branch name or PR reference. It reads a single word as a branch name or PR reference, so a mistyped branch name gets the closest-branch error from Review against a different base instead of launching with a note. If your text combines a PR reference with other words, such as check PR 123 again, Claude Code doesn’t launch either; it asks you to rerun with the PR number alone to review that PR, or without the reference to review your current branch.

用自然语言传递请求

在 Claude Code v2.1.218 或更高版本中,你还可以用自然语言描述你正在处理的内容:

审查仍覆盖你的当前分支,与不带参数运行时的范围相同。Claude 会将你的文本作为备注保留,并在启动对话框中显示,当发现结果返回时将其关联起来。 只有当文本超过一个单词且不是分支名称或 PR 引用时,Claude Code 才会将其视为备注。如果只有一个词,则会被当作分支名称或 PR 引用,因此拼写错误的分支名称会触发“针对不同基准进行审查”中的最近分支错误,而不是以备注方式启动。如果你的文本将 PR 引用与其他词语组合在一起,例如 check PR 123 again,Claude Code 不会启动任何操作;它会要求你单独使用 PR 编号重新运行以审查该 PR,或者不使用引用来审查当前分支。

§ 7

Diff limits and fallbacks

Ultrareview checks the diff before any review work runs and tells you when it can’t review it as-is:

Diff too large: a branch review can include up to 500 changed files and 8,000 changed lines by default. The exact values can change, and the refusal names the ones in effect, the size of your diff, and the files with the most changed lines. Claude Code refuses a too-large pull request the same way, naming its file and line counts but not the per-file breakdown

Nothing to review: when the diff against the base is empty, Claude Code says so and suggests staging or committing local edits, or passing a different base

No merge base: when your branch shares no history with the base branch, Claude Code offers to review every tracked file in the repository instead; the fallback requires a full clone and applies the same size limits

Diff 限制与回退

Ultrareview 在任何审查工作运行之前检查 diff,并在无法原样审查时通知你:

Diff 过大:分支审查默认最多可包含 500 个更改文件和 8,000 行更改。具体数值可能会变化,拒绝信息会注明当前生效的数值、你的 diff 大小以及更改行数最多的文件。Claude Code 同样会拒绝过大的拉取请求,并注明其文件和行数,但不提供每个文件的细分。

无内容可审查:当与基准的 diff 为空时,Claude Code 会提示并建议暂存或提交本地修改,或传入不同的基准。

无合并基准:当你的分支与基准分支没有共同历史时,Claude Code 会转而审查仓库中所有被跟踪的文件;此回退需要完整克隆,并应用相同的规模限制。

§ 8

Pricing and free runs

Ultrareview is a premium feature that bills against usage credits rather than your plan’s included usage.

Free runs: the three Pro and Max runs are a one-time allotment per account and don’t refresh.

Cost per review: after you use the free runs, or after the free-run period ends, typically $5 to $25 in usage credits depending on the size of the change, matching the estimate the launch dialog shows before each run.

When a run counts: once the cloud session starts. A review you stop early or that fails to complete still uses a free run; a paid review bills only for the portion that ran.

Because ultrareview always bills as usage credits outside the free runs, your account or organization must have usage credits turned on before you can launch a paid review. If usage credits aren’t turned on, Claude Code blocks the launch, and how you turn them on depends on your billing access:

If you can manage billing for your account, Claude Code links you to the billing settings where you can turn on usage credits.

On Team and Enterprise plans, members without billing access send a request from the CLI asking their admin to turn on usage credits.

You can also run /usage-credits to check or change your usage-credits setting. Claude Code asks you to confirm usage-credits billing once per conversation: when you start a new conversation, for example with /clear, Claude Code shows the confirmation again for the next paid review.

定价与免费运行

Ultrareview 是一项高级功能,按用量积分计费,而不是使用你套餐中的包含使用量。

免费运行:Pro 和 Max 用户的三个免费运行次数是每个账户的一次性配额,不会刷新。

每次审查费用:在使用免费运行次数后,或免费运行期结束后,通常需要 5 到 25 美元的用量积分,具体取决于更改的大小,与每次运行前启动对话框中显示的预估一致。

何时计入运行:一旦云端会话启动即开始计费。提前停止或未能完成的审查仍会消耗一次免费运行;付费审查仅按实际运行部分计费。

由于 ultrareview 在免费运行次数之外始终以用量积分计费,你的账户或组织必须先开启用量积分才能启动付费审查。如果未开启用量积分,Claude Code 会阻止启动,开启方式取决于你的计费权限:

如果你可以管理账户的计费,Claude Code 会提供链接让你进入计费设置并开启用量积分。

对于 Team 和 Enterprise 套餐,没有计费权限的成员可以通过 CLI 发送请求,请管理员开启用量积分。

你也可以运行 /usage-credits 来检查或更改你的用量积分设置。 Claude Code 每个对话只会要求你确认一次用量积分计费:当你开始新对话时(例如通过 /clear),Claude Code 会在下一次付费审查时再次显示确认。

§ 9

Track a running review

A review typically takes 5 to 10 minutes. The review runs as a background task, so you can keep working in your session, start other commands, or close the terminal entirely. Use /tasks to see running and completed reviews, open the detail view for a review, or stop a review that is in progress. Stopping a review archives the cloud session, and partial findings are not returned. When the review finishes, the verified findings appear as a notification in your session. Each finding includes the file location and an explanation of the issue so you can ask Claude to fix it directly.

跟踪正在运行的审查

一次审查通常需要 5 到 10 分钟。审查作为后台任务运行,因此你可以继续在会话中工作、启动其他命令,甚至完全关闭终端。 使用 /tasks 可以查看正在运行和已完成的审查、打开审查的详细视图,或停止正在进行的审查。停止审查会归档云端会话,并且不会返回部分结果。审查完成后,经过验证的发现结果会以通知形式出现在你的会话中。每个发现结果都包含文件位置和问题说明,因此你可以直接要求 Claude 修复它。

§ 10

Run ultrareview non-interactively

Use the claude ultrareview subcommand to start an ultrareview from CI or a script without an interactive session. The subcommand launches the same review as /code-review ultra, blocks until the remote review finishes, prints the findings to stdout, and exits with code 0 on success or 1 on failure.

Without arguments, the subcommand reviews the diff between your current branch and the default branch, with the same whole-repository fallback as /code-review ultra when no merge base exists. Pass a PR number to review a pull request, or a base branch to review against it; base-branch handling matches the interactive command. You consent to the whole-repository fallback and to the billing and terms prompt when you run the subcommand, so the run starts without waiting for input. On Claude Code v2.1.218 or later, you can also start the cloud review by running /code-review ultra in a non-interactive session, for example claude -p '/code-review ultra'. Claude Code launches the review and prints a tracking link without waiting for the findings, unlike claude ultrareview, which blocks until they arrive. When the review would bill usage credits, Claude Code stops before launching and points you to claude ultrareview, because the billing confirmation needs an interactive session. Before v2.1.218, /code-review ultra in a non-interactive session ran a local review. Progress messages and the live session URL go to stderr so stdout stays parseable. Use these flags to control the output and timeout:

Running claude ultrareview requires the same authentication and usage credit configuration as /code-review ultra. The subcommand exits with code 0 when the review completes with or without findings, code 1 when the review fails to launch, the cloud session errors, or the timeout elapses, and code 130 when interrupted with Ctrl-C. The remote review keeps running if you interrupt the subcommand; follow the session URL printed to stderr to watch it in the browser. For automatic reviews on GitHub pull requests, Code Review integrates with your repository directly and posts findings as inline PR comments without a CLI step.

非交互式运行 ultrareview

使用 claude ultrareview 子命令从 CI 或脚本中启动 ultrareview,无需交互式会话。该子命令启动与 /code-review ultra 相同的审查,阻塞直到远程审查完成,将结果打印到 stdout,成功时退出码为 0,失败时退出码为 1。

不带参数时,该子命令审查当前分支与默认分支之间的差异,并在没有合并基准时使用与 /code-review ultra 相同的全仓库回退。传入 PR 编号可审查拉取请求,传入基准分支可针对其审查;基准分支的处理方式与交互式命令一致。 运行该子命令即表示同意全仓库回退以及计费和条款提示,因此运行不会等待输入。 在 Claude Code v2.1.218 或更高版本中,你还可以在非交互式会话中运行 /code-review ultra 来启动云端审查,例如 claude -p '/code-review ultra'。与等待结果的 claude ultrareview 不同,Claude Code 会启动审查并打印跟踪链接,而不等待结果。当审查需要用量积分计费时,Claude Code 会在启动前停止并提示你使用 claude ultrareview,因为计费确认需要交互式会话。在 v2.1.218 之前,非交互式会话中的 /code-review ultra 会运行本地审查。 进度消息和实时会话 URL 发送到 stderr,以便 stdout 保持可解析。使用以下标志控制输出和超时:

运行 claude ultrareview 需要与 /code-review ultra 相同的身份验证和用量积分配置。该子命令在审查完成(无论是否发现结果)时退出码为 0;在审查启动失败、云端会话出错或超时时退出码为 1;在通过 Ctrl-C 中断时退出码为 130。如果你中断该子命令,远程审查会继续运行;可以跟随打印到 stderr 的会话 URL 在浏览器中查看。 对于 GitHub 拉取请求的自动审查,Code Review 直接与你的仓库集成,并将结果以内联 PR 评论形式发布,无需 CLI 步骤。

§ 11

How ultrareview compares to /code-review and /review

All three commands review code, but they target different stages of your workflow.

Use /code-review for fast feedback as you work. Use /review <pr> to look over a pull request the same way you would before approving it. Use /code-review ultra before merging a substantial change when you want a deeper pass that catches issues a local review might miss.

Ultrareview 与 /code-review 和 /review 的比较

这三种命令都会审查代码,但它们针对的是工作流程的不同阶段。

在你工作时使用 /code-review 获得快速反馈。使用 /review <pr> 以批准前的方式查看拉取请求。在合并重大更改前,如果你希望进行更深入的审查以捕获本地审查可能遗漏的问题,请使用 /code-review ultra。

§ 12

Claude Code on the web: learn how cloud sessions and cloud sandboxes work

Plan complex changes with ultraplan: the planning counterpart to ultrareview for upfront design work

Manage costs effectively: track usage and set spending limits

Claude Code on the web:了解云端会话和云端沙箱的工作方式

使用 ultraplan 规划复杂变更:ultrareview 的规划对应功能,用于前期设计工作

有效管理成本:跟踪使用情况并设置支出限制

打开原文 ↗