mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2025-12-19 14:41:24 +08:00
chore: improve comments
This commit is contained in:
parent
e89af9042c
commit
5304b585b9
@ -145,13 +145,13 @@ function convertAnthropicToolResultToAiSdk(
|
||||
|
||||
/**
|
||||
* JSON Schema type for tool input schemas
|
||||
* Uses the standard JSONSchema7 type from the json-schema package (via @ai-sdk/provider)
|
||||
*/
|
||||
export type JsonSchemaLike = JSONSchema7
|
||||
|
||||
/**
|
||||
* Convert JSON Schema to Zod schema
|
||||
* This avoids non-standard fields like input_examples that Anthropic doesn't support
|
||||
* TODO: Anthropic/beta support input_examples
|
||||
*/
|
||||
export function jsonSchemaToZod(schema: JsonSchemaLike): z.ZodTypeAny {
|
||||
const schemaType = schema.type
|
||||
|
||||
Loading…
Reference in New Issue
Block a user