-
Notifications
You must be signed in to change notification settings - Fork 173
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
currently it's not possible to set "strict: true" for tool definitions. in the python versoin it can be set, it's even true by default.
see also open ai function-calling: https://platform.openai.com/docs/guides/function-calling#defining-functions
and the helper method to get from zod jsons to strict schemas:
https://github.com/openai/openai-node/blob/7a97bfcf1ea071bc605c654161cc0e4867d22960/src/lib/transform.ts#L38
(ensureStrictJsonSchema helper)
what is missing:
- make the strict prop configurable (and set it to true by default?)
- wrap the toJsonschema in the ensurestrict json schema function .. see: https://github.com/openai/openai-node/pull/1666/files#diff-3a1140710d3b12cdf0bbe73ea5c769ef4d3452a10bcb4d46bc696401ea22e2bbR33
Relevant log output
No response
Describe your environment
Minimal reproducible example
No response
Additional information
No response
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working