anthropic/claude-opus-4.8
Anthropic 当前旗舰。复杂编码(Claude Code)、长文本分析、多步 Agent 一流,现已支持 100 万 token 上下文。原生 prompt cache 在重复上下文时显著降本。只看输出质量时的第一选择。
来源: launch_0023 · 核验于 2026-06-01
缓存读 $0.250/M · 缓存写 $3.13/M
把 ONEHOP_KEY 占位符替换为你的 API Key。 创建 →
from anthropic import Anthropic
client = Anthropic(
base_url="https://api.onehop.ai/anthropic",
api_key="<ONEHOP_KEY>",
)
message = client.messages.create(
model="anthropic/claude-opus-4.8",
max_tokens=1024,
messages=[{"role": "user", "content": "What is the meaning of life?"}],
)
print(message.content[0].text)