Skip to content
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]: Upgrade prompts to optional imports #21078

Merged
merged 4 commits into from
Apr 30, 2024

Conversation

eyurtsev
Copy link
Collaborator

Upgrades prompts module to use optional imports.

This code was generated with a migration script, but had to be adjusted manually a bit.

Testing in preparation for applying this code modification across the rest of the modules in langchain package to reverse the dependency
between langchain community and langchain.

Copy link

vercel bot commented Apr 30, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
langchain ⬜️ Ignored (Inspect) Visit Preview Apr 30, 2024 2:36pm

@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. 🤖:improvement Medium size change to existing code to handle new use-cases labels Apr 30, 2024
@eyurtsev
Copy link
Collaborator Author

#21080

# Create a way to dynamically look up deprecated imports.
# Used to consolidate logic for raising deprecation warnings and
# handling optional imports.
MODULE_LOOKUP = {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ooc any reason not to make this private _MODULE_LOOKUP

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah no reason, just inertia -- we can follow up with another refactor to make this private

@dosubot dosubot bot added the lgtm PR looks good. Use to confirm that a PR is ready for merging. label Apr 30, 2024
@eyurtsev eyurtsev merged commit 8658d52 into master Apr 30, 2024
42 checks passed
@eyurtsev eyurtsev deleted the eugene/migrate_prompts branch April 30, 2024 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🤖:improvement Medium size change to existing code to handle new use-cases lgtm PR looks good. Use to confirm that a PR is ready for merging. size:M This PR changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants