-
-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Closed as not planned
Labels
Description
The Feature
Currently ChatLiteLLMRouter does not support json_schema method which is the gold standard for Structured Output using OpenAI.
Langchain's ChatOpenAI supports chat.with_structured_output(pydantic_model, method="json_schema")
but if chat is ChatLiteLLMRouter the following error is received:
langchain_core/language_models/chat_models.py", line 1303, in with_structured_output
raise ValueError(msg)
ValueError: Received unsupported arguments {'method': 'json_schema'}
Motivation, pitch
Langchain is a standard in the industry and supporting this functionality will not just improve user's reliability since Structured Output using json_mode, as opposed to json_schema, is frequently faulty and causes issues in production.
Are you a ML Ops Team?
No
Twitter / LinkedIn details
No response