Replies: 1 comment
-
cc @ccurme |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Checked
Feature request
the default implementation for
with_structured_output
raises a value error on anykwargs
https://github.com/langchain-ai/langchain/blob/master/libs/core/langchain_core/language_models/chat_models.py#L1174
https://github.com/langchain-ai/langchain/blob/master/libs/core/langchain_core/language_models/chat_models.py#L1283
the tests for json_mode pass
method=
as a kwargshttps://github.com/langchain-ai/langchain/blob/master/libs/standard-tests/langchain_tests/integration_tests/chat_models.py#L1487
the result is a ValueError, e.g.
ValueError: Received unsupported arguments {'method': 'json_mode'}
request: allow ChatModels derived from BaseChatModel to pass test_json_mode without having to override
with_structured_output
Motivation
i would like to implement a ChatModel derived from BaseChatModel and minimize maintenance by relying on default methods.
ChatModels that deviate from BaseChatModel's signature to support method param (incomplete list) -
Proposal (If applicable)
No response
Beta Was this translation helpful? Give feedback.
All reactions