-
Notifications
You must be signed in to change notification settings - Fork 16.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
langchain[patch]: update agent and chains modules root_validators #23256
langchain[patch]: update agent and chains modules root_validators #23256
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 1 Ignored Deployment
|
@eyurtsev Please review, thx! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @wenmengzhou thanks for the contribution!
Could you review the semantics of pre=True
. When pre=True
, the code cannot assume that any keys exist in values
even ones that have default values. I pointed two places that will crash with a KeyError.
…g/langchain into fix_agent_root_validator
Hi @eyurtsev, thx for pointing out this issue, I will fix it! |
@eyurtsev please review again, thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wenngong I'm going to push a few changes to this PR right now.
Thanks for the work! If you're doing more changes, could you keep a PR to no more than ~5 root validators. It'll help to get the PR reviewed and merged quickly!
libs/langchain/langchain/chains/combine_documents/map_rerank.py
Outdated
Show resolved
Hide resolved
libs/langchain/langchain/chains/combine_documents/map_reduce.py
Outdated
Show resolved
Hide resolved
libs/langchain/langchain/chains/combine_documents/map_reduce.py
Outdated
Show resolved
Hide resolved
libs/langchain/langchain/chains/combine_documents/map_reduce.py
Outdated
Show resolved
Hide resolved
libs/langchain/langchain/chains/combine_documents/map_reduce.py
Outdated
Show resolved
Hide resolved
libs/langchain/langchain/chains/combine_documents/map_rerank.py
Outdated
Show resolved
Hide resolved
@eyurtsev Thanks! I will follow your suggestion. |
…g/langchain into fix_agent_root_validator
Head branch was pushed to by a user without write access
…ain into fix_agent_root_validator
@ccurme we can merge this pr now, Thx! |
Description: update agent and chains modules Pydantic root_validators.
Issue: the issue #22819