| 1 | // ==================== Anthropic API Types ==================== |
| 2 | |
| 3 | export interface AnthropicRequest { |
| 4 | model: string; |
| 5 | messages: AnthropicMessage[]; |
| 6 | max_tokens: number; |
| 7 | stream?: boolean; |
| 8 | system?: string | AnthropicContentBlock[]; |
| 9 | tools?: AnthropicTool[]; |
| 10 | tool_choice?: AnthropicToolChoice; |
| 11 | temperature?: number; |
| 12 | top_p?: number; |
| 13 | stop_sequences?: string[]; |
| 14 | thinking?: { type: 'enabled' | 'disabled' | 'adaptive'; budget_tokens?: number }; |
| 15 | } |
| 16 | |
| 17 | /** tool_choice 控制模型是否必须调用工具 |
| 18 | * - auto: 模型自行决定(默认) |
nothing calls this directly
no outgoing calls
no test coverage detected