mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-03-05 07:40:19 +01:00
🔢 feat: Add Support for Integer and Float JSON Schema Types (#9469)
* 🔧 fix: Extend JsonSchemaType to include 'integer' and 'float' types
* ci: tests for new integer/float types
This commit is contained in:
parent
cadfe14abe
commit
0ecafcd38e
3 changed files with 162 additions and 2 deletions
|
|
@ -350,7 +350,7 @@ export function convertJsonSchemaToZod(
|
|||
} else {
|
||||
zodSchema = z.string();
|
||||
}
|
||||
} else if (schema.type === 'number') {
|
||||
} else if (schema.type === 'number' || schema.type === 'integer' || schema.type === 'float') {
|
||||
zodSchema = z.number();
|
||||
} else if (schema.type === 'boolean') {
|
||||
zodSchema = z.boolean();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue