You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to use LLMs to generate OpenAPI schemas, and running into some roadblocks trying to use instructor. It mainly boils down to the fact that zod + typescript types don't really work well when schemas are recursive (OpenAPI specs have lots of recursion). It also seems weird that I'm doing all this work to convert the OpenAPI schema to zod when they publish a JSON schema.
How would you go about doing this? I've peaked at how instructor-js works and I'm tempted to use some of the primitives in zod-stream there and kind of roll-my-own thing similar to instructor but based on json schema instead of zod. I'm hoping you have better ideas :)
Thanks for building instructor!
The text was updated successfully, but these errors were encountered:
I'm trying to use LLMs to generate OpenAPI schemas, and running into some roadblocks trying to use instructor. It mainly boils down to the fact that zod + typescript types don't really work well when schemas are recursive (OpenAPI specs have lots of recursion). It also seems weird that I'm doing all this work to convert the OpenAPI schema to zod when they publish a JSON schema.
How would you go about doing this? I've peaked at how instructor-js works and I'm tempted to use some of the primitives in
zod-stream
there and kind of roll-my-own thing similar to instructor but based on json schema instead of zod. I'm hoping you have better ideas :)Thanks for building instructor!
The text was updated successfully, but these errors were encountered: