Claude Sonnet 5 开发者说明

Simon Willison··作者 Simon Willison

关键信息

Sonnet 5 不再支持 temperature、top_p 和 top_k 采样参数,并且拥有 100 万 token 的上下文窗口和 128,000 个最大输出 token。Anthropic 表示它保留了与 Sonnet 4.6 相同的工具和平台特性,默认开启 adaptive thinking,除非显式禁用;但它采用了新的分词器,同样的文本大约会产生比 Sonnet 4.6 多 30% 的 token,这对很多输入来说等于实际成本上升。

资讯摘要

Simon Willison 指出,Claude Sonnet 5 是当天上午发布的,而他通常会先看 Anthropic 的“what’s new”开发者文档,因为这类文档往往比官方发布公告更有可操作性。Anthropic 将 Sonnet 5 描述为在性能上接近 Opus 4.8,但价格更低。Willison 还提到系统卡,并认为其中解释了该模型为何能够发布而没有被美国政府阻止。系统卡中写道,Sonnet 5 在 cyber 任务上的能力明显弱于 Mythos 5,因此其安全护栏与 Opus 4.7 和 Opus 4.8 类似。API 说明里有一个重要的破坏性变化:temperature、top_p 和 top_k 不再受支持。

Sonnet 5 的上下文窗口达到 100 万 token,最大输出为 128,000 token,并且支持与 Sonnet 4.6 相同的一组工具和平台特性。adaptive thinking 默认开启,除非通过 thinking 设置显式关闭。定价名义上与 Sonnet 4.6 相同,并且在 8 月 31 日前有临时折扣,但新的分词器意味着同样的文本会比 Sonnet 4.6 多产生约 30% 的 token。Willison 使用自己的 token 计数器测试了英文、西班牙文、简体中文和 Python 代码,结果显示不同内容的涨幅差异很大,其中中文几乎不变,而英文类文本的实际成本上升更明显。

Claude Sonnet 5 开发者说明

资讯正文

<strong><a href="https://platform.claude.com/docs/en/about-claude/models/whats-new-sonnet-5">Claude Sonnet 5 有哪些新变化</a></strong>

Claude Sonnet 5 今天早上发布了。我总是会直接去看“what's new”开发者文档,因为它们往往比官方公告帖提供更可执行的信息。

Anthropic 对 Sonnet 5 的说法是:“它的性能接近 Opus 4.8,但价格更低。”这份 <a href="https://www-cdn.anthropic.com/9e6a1044980d8c4ed85669faf9c2a8342e2e9f1e/Claude%20Sonnet%205%20System%20Card.pdf">system card</a> 有助于解释他们为何能够发布这个模型而没有被美国政府拦下:

“Sonnet 5 在网络安全任务上的能力明显弱于 Mythos 5:因此,它的安全防护措施与我们应用于 Opus 4.7 和 Opus 4.8 的措施类似(这些模型的能力强于 Sonnet 5,但远弱于 Mythos 5)。"

从“what's new” API 变更里值得注意的有:

- 采样参数 <code>temperature</code>、<code>top_p</code>、<code>top_k</code> 不再受支持。

- 它拥有 100 万 token 的上下文窗口,以及 128,000 个最大输出 token。

- 它具备“与 Claude Sonnet 4.6 相同的一组工具和平台功能”。

- 自适应思考默认开启,除非你指定 <code>"thinking": {type: "disabled"}</code>。

- 定价与 Sonnet 4.6 相同:输入 $3/百万 token,输出 $15/百万 token;但在 8 月 31 日之前有 $2/$10 的优惠价格。不过……

- 该模型采用了新的 tokenizer,按照官方说法,“相同的输入文本产生的 token 数量大约比 Claude Sonnet 4.6 多 30%。”——实际上等于价格上涨了 30%。

我用自己的 <a href="https://tools.simonwillison.net/claude-token-counter">Claude Token Counter</a> 工具试用了这个新 tokenizer。以下是我对几份较大文档的测试结果:

文档 | Sonnet 4.6 | Opus 4.7 | Sonnet 5

<a href="https://github.com/simonw/udhr-markdown/blob/main/declarations/eng.md">世界人权宣言(英文)</a> | <b>2,356</b> | <b>3,347</b><br />1.42x | <b>3,341</b><br />1.42x

<a href="https://github.com/simonw/udhr-markdown/blob/main/declarations/spa.md">世界人权宣言(西班牙语)</a> | <b>3,572</b> | <b>4,753</b><br />1.33x | <b>4,747</b><br />1.33x

<a href="https://github.com/simonw/udhr-markdown/blob/main/declarations/cmn_hans.md">世界人权宣言(中文,简体普通话)</a> | <b>3,334</b> | <b>3,366</b><br />1.01x | <b>3,360</b><br />1.01x

<a href="https://github.com/simonw/sqlite-utils/blob/79117b9d110d72f46dab5fe2cda412ff4789ab55/sqlite_utils/db.py">sqlite_utils/db.py</a>(4,279 行 Python 代码) | <b>44,014</b> | <b>56,118</b><br />1.28x | <b>56,113</b><br />1.27x

这是那只鹈鹕。没什么好大惊小怪的。Sonnet 5 觉得它看起来像一只鹅。

通过 Hacker News

标签:ai、generative-ai、llms、anthropic、claude、llm-pricing、pelican-riding-a-bicycle、llm-release

来源与参考

  1. 原始链接
  2. What’s new in Claude Sonnet 5
  3. Anthropic's new Claude Sonnet 5 closes the gap to the pricier Opus model series
  4. Anthropic launches Claude Sonnet 5 as a cheaper way to run agents | TechCrunch

收录于 2026-07-01