基础设施 4.0 · 优秀 2026-11-02 · 文章

Make long-running agents faster with message threads

Anthropic 推出 Messages API Message Threads 公测:长会话 agent 首轮传全文,之后只传新消息加前次 response id,Claude 每轮仍读全史,token 用量与账单不变。50 万–100 万 token 请求中位 TTFT 约 −35%,请求体中位 800KB→1.8KB;Claude Code 多数用户默认开启。线程存加密内存不落盘,闲置 5 分钟过期、最长保留 1 小时;不自动做 prompt cache,二者是两套时钟;无 list/read/delete API,不适用 ZDR/HIPAA。

打开原文回到归档

Make long-running agents faster with message threads

  • ID: 62ae9381
  • 原文链接: https://claude.com/resources/articles/message-threads
  • 作者: Anthropic
  • 日期: 2026-11-02
  • 分类: infra
  • 来源类型: article
  • 标签: message-threads, prompt-caching, ttft, context-management, api, anthropic
  • 质量评分: 4/5
  • 抓取时间: 2026-11-04T23:44:52+08:00

中文导读

Anthropic 为 Messages API 推出 Message Threads 公测(beta header message-threads-2026-08-12):长会话 agent 首轮传全文,之后每轮只传新消息加前次 response id,Claude 每轮仍读全部历史,token 用量与账单科目不变。官方数字:50 万–100 万 token 请求的中位 TTFT 约 −35%,请求体中位从约 800KB 降到 1.8KB;Claude Code 对多数用户默认开启。线程存于加密内存不落盘,闲置 5 分钟过期、最长保留 1 小时;线程不自动做 prompt cache,二者是「传全文」与「缓存复用」两套时钟;无 list/read/delete 线程 API,不适用 ZDR/HIPAA。可用平台含原生 API、AWS、Microsoft Foundry、GCP Anthropic managed,标准费率与限额。

为什么值得关注

Threads 把长 agent 的重复上下文传输挪到服务端,TTFT −35% 是官方实测口径;但它与 prompt cache 是两套时钟,过期重放仍是应用自己的活

关键信息

  • 公测 2026-11-02:首请求传全文,后续只传新消息 + 前次 response id;Claude 每轮仍读全史 → token 用量与价目不变
  • 官方数字:500k–1M token 请求中位 TTFT 约 −35%;请求体中位约 800KB → 1.8KB;Claude Code 多数用户默认开启
  • 线程存加密内存不落盘;闲置 5 分钟过期、最长保留 1 小时;不自动做 prompt cache(两套时钟)
  • 无 list/read/delete 线程 API;不适用 ZDR/HIPAA;需 beta header message-threads-2026-08-12
  • 平台:原生 API、AWS、Microsoft Foundry、GCP Anthropic managed;标准费率与限额

English Summary

Anthropic's Messages API Message Threads entered public beta (2026-11-02): long-running agents send the full conversation once, then only new messages plus the previous response id, while Claude still reads the full thread each turn - token usage and billing unchanged. Anthropic reports median TTFT down about 35% for 500k-1M token requests and median request bodies shrinking from ~800KB to ~1.8KB; Claude Code enables it by default for most users. Threads live in encrypted memory (not disk), expire 5 minutes after the last request, are kept at most 1 hour, do not automatically create prompt-cache entries (two separate clocks), lack list/read/delete APIs, and are not offered under ZDR or HIPAA terms. Available on the native API, AWS, Microsoft Foundry and GCP Anthropic managed at standard rates.

原文

Message threads public beta on Claude Platform (2026-11-02).

Agents no longer resend full history each turn. First request full conversation; later turns new messages + previous response id. Threads in encrypted memory, not disk. Expire 5 minutes after last request. Claude still reads full conversation each turn → token usage unchanged. Claude Code default on for most users: 500k–1M token requests median TTFT about −35%. Best for long coding agents, computer use (screenshots stay on thread), doc/image-heavy workflows. Available native platform, AWS, Microsoft Foundry, GCP Anthropic managed. Standard rates and rate limits.

Docs: https://platform.claude.com/docs/en/build-with-claude/message-threads

Obsidian Notes

  • DeepResearch/2026-11-04-morning-Claude-Message-Threads-双时钟-研究材料/references/01-claude-message-threads-article.md(要点级抓取)+ 03-prompt-caching-notes.md
  • 数字与边界经 调研/2026-11-04-调研-Claude-Message-Threads-双时钟.md 核对表逐条核对(官方公告 + platform docs + changelog)