anthropic
Package
Section titled “Package”@ai-sdk/anthropic
Factories
Section titled “Factories”AIProviders.anthropic
Capabilities
Section titled “Capabilities”- Language
- Files
- Skills
Anthropic mirrors upstream 4.0.49 across Messages, files, and skills: thinking, citations, cache control, hosted/provider-defined tools, streamed code-execution input subtypes, fallbacks: default beta routing, caller metadata replay for client/server tools and web-search results across generated and streamed responses, Claude Opus 5 and forward-compatible Claude capabilities, structured-output tool safeguards, reasoning-token usage details, and provider metadata. Advisor tools map per-inference maxTokens and replay stopReason; stream parsing rejects spliced message IDs while tolerating duplicate starts for the active message; code-execution transcripts retain their complete prompt-cache-compatible wire shape. Generic adaptive reasoning requests include display: summarized. Generated response blocks retain upstream order across reasoning, text, citations, sources, tool calls/results, and compaction; signed/redacted thinking and text citation metadata are preserved. Mid-conversation system-message toolChanges map to tool-addition/removal content blocks with automatic beta headers, while initial-system changes warn and are ignored; toolChanges-only empty text does not consume an invisible cache breakpoint. thinking: disabled is forwarded and incompatible xhigh/max effort is lowered with a warning. Files and skills clients add the required Anthropic beta headers. The language wrapper also implements durable Batch V4 start/status/result streaming with strict response validation, redirect-safe JSONL retrieval, per-item terminal failures, and programmatic deferred-result replay without leaking the internal discriminator. Current Batch parity forwards the full request setting/content surface, preserves native counts and raw status, isolates invalid or unknown result items, safely encodes returned skill identifiers, and warns because completion webhooks are unsupported. The 4.0.49 delta adds Fable 5.1 and Vertex Claude 4 recognition, mid-conversation clearAt and effort, updated adaptive display and binding-only thinking behavior, plus the context-management, structured-outputs, interleaved-thinking, and web-search beta headers. Streaming multipart file bodies remain JS-specific because the Swift file client accepts buffered Data.
Factory argument requirements are defined by the public Swift factory signatures. Use Public symbols when you need the exact initializer or factory declaration.
Return to the provider matrix.