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
Currently langchain only supports setting the responseMimeType to json but does not set the responseSchema to ensure that the JSON follows the given schema.
Motivation
Currently when using the built in .withStructuredOutput the model usually fails with complex schemas. With this feature the reliability would increase a lot.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Checked
Feature request
Gemini models support structured output JSON schemas:
https://cloud.google.com/vertex-ai/generative-ai/docs/multimodal/control-generated-output#generativeaionvertexai_gemini_controlled_generation_response_schema-drest
Currently langchain only supports setting the
responseMimeType
to json but does not set theresponseSchema
to ensure that the JSON follows the given schema.Motivation
Currently when using the built in
.withStructuredOutput
the model usually fails with complex schemas. With this feature the reliability would increase a lot.Proposal (If applicable)
No response
Beta Was this translation helpful? Give feedback.
All reactions