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

docs[patch]: Add wrapping library metadata to MongoDB docs example #4957

Merged

Conversation

baileympearson
Copy link
Contributor

This PR adds logic similar to the implementation in Python added in langchain-ai/langchain#13084.

In JS, users instantiate MongoClients and provide them to langchain instead of langchain instantiating the MongoClient for them. As such, there's no way for langchain to add client metadata like the Python implementation does. Additionally, there's no equivalent of importlib.metadata in Javascript that can return the version of a package. So we'd like to just add this to the documentation example, so that when users use the code provided in the docs, they include the metadata as well.

@dosubot dosubot bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Apr 2, 2024
Copy link

vercel bot commented Apr 2, 2024

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

Name Status Preview Comments Updated (UTC)
langchainjs-api-refs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 3, 2024 5:42am
langchainjs-docs ✅ Ready (Inspect) Visit Preview Apr 3, 2024 5:42am

@dosubot dosubot bot added the auto:documentation Changes to documentation and examples, like .md, .rst, .ipynb files. Changes to the docs/ folder label Apr 2, 2024
@@ -4,7 +4,7 @@ import { ChatOpenAI } from "@langchain/openai";
import { ConversationChain } from "langchain/chains";
Copy link

Choose a reason for hiding this comment

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

Hey there! I've flagged the recent change in mongodb.ts for your review as it explicitly accesses the MONGODB_ATLAS_URI environment variable. Please take a look and let me know if you need any further assistance with this.

@jacoblee93 jacoblee93 changed the title Add wrapping library metadata to MongoDB docs example docs[patch]: Add wrapping library metadata to MongoDB docs example Apr 3, 2024
@jacoblee93
Copy link
Collaborator

Thank you!

@jacoblee93 jacoblee93 added the lgtm PRs that are ready to be merged as-is label Apr 3, 2024
@jacoblee93 jacoblee93 merged commit 9a3087d into langchain-ai:main Apr 3, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto:documentation Changes to documentation and examples, like .md, .rst, .ipynb files. Changes to the docs/ folder lgtm PRs that are ready to be merged as-is size:XS This PR changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants