Anthropic
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:167
Extends
Section titled “Extends”Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new Anthropic(
init?):Anthropic
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:184
Parameters
Section titled “Parameters”Partial<Anthropic>
Returns
Section titled “Returns”Anthropic
Overrides
Section titled “Overrides”ToolCallLLM< AnthropicAdditionalChatOptions, AnthropicToolCallLLMMessageOptions >.constructor
Properties
Section titled “Properties”model:
"claude-3-7-sonnet-latest"|"claude-3-7-sonnet-20250219"|"claude-3-5-haiku-latest"|"claude-3-5-haiku-20241022"|"claude-sonnet-4-20250514"|"claude-sonnet-4-0"|"claude-4-sonnet-20250514"|"claude-3-5-sonnet-latest"|"claude-3-5-sonnet-20241022"|"claude-3-5-sonnet-20240620"|"claude-opus-4-0"|"claude-opus-4-20250514"|"claude-4-opus-20250514"|"claude-opus-4-1-20250805"|"claude-3-opus-latest"|"claude-3-opus-20240229"|"claude-3-haiku-20240307"|"claude-4-0-sonnet"|"claude-4-sonnet-20240514"|"claude-4-0-opus"|"claude-4-1-opus"|"claude-4-opus-20240514"|"claude-4-5-sonnet"|"claude-opus-4-1"|"claude-sonnet-4-5-20250929"|"claude-sonnet-4-5"|"claude-3-7-sonnet"|"claude-3-5-sonnet"|"claude-3-5-haiku"|"claude-3-opus"|"claude-3-sonnet"|"claude-3-sonnet-20240229"|"claude-3-haiku"|"claude-2.1"|"claude-2.0"|"claude-instant-1.2"|object&string
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:172
temperature
Section titled “temperature”temperature:
number
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:173
optionaltopP:number
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:174
maxTokens?
Section titled “maxTokens?”
optionalmaxTokens:number
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:175
additionalChatOptions?
Section titled “additionalChatOptions?”
optionaladditionalChatOptions:AnthropicAdditionalChatOptions
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:176
apiKey?
Section titled “apiKey?”
optionalapiKey:string
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:179
maxRetries
Section titled “maxRetries”maxRetries:
number
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:180
timeout?
Section titled “timeout?”
optionaltimeout:number
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:181
session
Section titled “session”session:
AnthropicSession
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:182
Accessors
Section titled “Accessors”supportToolCall
Section titled “supportToolCall”Get Signature
Section titled “Get Signature”get supportToolCall():
boolean
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:204
Returns
Section titled “Returns”boolean
Overrides
Section titled “Overrides”ToolCallLLM.supportToolCall
metadata
Section titled “metadata”Get Signature
Section titled “Get Signature”get metadata():
object
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:208
Returns
Section titled “Returns”object
model:
"claude-3-7-sonnet-latest"|"claude-3-7-sonnet-20250219"|"claude-3-5-haiku-latest"|"claude-3-5-haiku-20241022"|"claude-sonnet-4-20250514"|"claude-sonnet-4-0"|"claude-4-sonnet-20250514"|"claude-3-5-sonnet-latest"|"claude-3-5-sonnet-20241022"|"claude-3-5-sonnet-20240620"|"claude-opus-4-0"|"claude-opus-4-20250514"|"claude-4-opus-20250514"|"claude-opus-4-1-20250805"|"claude-3-opus-latest"|"claude-3-opus-20240229"|"claude-3-haiku-20240307"|"claude-4-0-sonnet"|"claude-4-sonnet-20240514"|"claude-4-0-opus"|"claude-4-1-opus"|"claude-4-opus-20240514"|"claude-4-5-sonnet"|"claude-opus-4-1"|"claude-sonnet-4-5-20250929"|"claude-sonnet-4-5"|"claude-3-7-sonnet"|"claude-3-5-sonnet"|"claude-3-5-haiku"|"claude-3-opus"|"claude-3-sonnet"|"claude-3-sonnet-20240229"|"claude-3-haiku"|"claude-2.1"|"claude-2.0"|"claude-instant-1.2"|object&string
temperature
Section titled “temperature”temperature:
number
topP:
number
maxTokens
Section titled “maxTokens”maxTokens:
undefined|number
contextWindow
Section titled “contextWindow”contextWindow:
number
tokenizer
Section titled “tokenizer”tokenizer:
undefined=undefined
structuredOutput
Section titled “structuredOutput”structuredOutput:
boolean=false
Overrides
Section titled “Overrides”ToolCallLLM.metadata
Methods
Section titled “Methods”getModelName()
Section titled “getModelName()”getModelName(
model):string
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:225
Parameters
Section titled “Parameters”string
Returns
Section titled “Returns”string
parseToolInput()
Section titled “parseToolInput()”parseToolInput(
input):any
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:232
Parameters
Section titled “Parameters”string | JSONObject
Returns
Section titled “Returns”any
formatMessages()
Section titled “formatMessages()”formatMessages(
messages):MessageParam[]
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:244
Parameters
Section titled “Parameters”messages
Section titled “messages”ChatMessage<AnthropicToolCallLLMMessageOptions>[]
Returns
Section titled “Returns”MessageParam[]
chat()
Section titled “chat()”Call Signature
Section titled “Call Signature”chat(
params):Promise<AsyncIterable<ChatResponseChunk<AnthropicToolCallLLMMessageOptions>,any,any>>
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:447
Parameters
Section titled “Parameters”params
Section titled “params”LLMChatParamsStreaming<AnthropicAdditionalChatOptions, AnthropicToolCallLLMMessageOptions>
Returns
Section titled “Returns”Promise<AsyncIterable<ChatResponseChunk<AnthropicToolCallLLMMessageOptions>, any, any>>
Overrides
Section titled “Overrides”ToolCallLLM.chat
Call Signature
Section titled “Call Signature”chat(
params):Promise<ChatResponse<AnthropicToolCallLLMMessageOptions>>
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:455
Parameters
Section titled “Parameters”params
Section titled “params”LLMChatParamsNonStreaming<AnthropicAdditionalChatOptions, AnthropicToolCallLLMMessageOptions>
Returns
Section titled “Returns”Promise<ChatResponse<AnthropicToolCallLLMMessageOptions>>
Overrides
Section titled “Overrides”ToolCallLLM.chat
streamChat()
Section titled “streamChat()”
protectedstreamChat(anthropic,params):AsyncIterable<ChatResponseChunk<AnthropicToolCallLLMMessageOptions>>
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:578
Parameters
Section titled “Parameters”anthropic
Section titled “anthropic”Anthropic
params
Section titled “params”MessageCreateParams
Returns
Section titled “Returns”AsyncIterable<ChatResponseChunk<AnthropicToolCallLLMMessageOptions>>
toTool()
Section titled “toTool()”
statictoTool(tool):Tool
Defined in: .build/typescript/packages/providers/anthropic/src/llm.ts:668
Parameters
Section titled “Parameters”BaseTool
Returns
Section titled “Returns”Tool