Commit 5166bea
authored
[INTPYTHON-501](https://jira.mongodb.org/browse/{INTPYTHON-501})
[INTPYTHON-784](https://jira.mongodb.org/browse/{INTPYTHON-784})
## Summary
<!-- What is this PR introducing? If context is already provided from
the JIRA ticket, still place it in the Pull Request as you should not
make the reviewer do digging for a basic summary. -->
This PR adds graphical visualization of our MongoDBGraphStore, used for
Knowledge Graphs and Graph RAG. It also adds an example notebook, and
improvements to the prompting.
## Changes in this PR
<!-- What changes did you make to the code? What new APIs (public or
private) were added, removed, or edited to generate the desired outcome
explained in the above summary? -->
* New methods `view` and `to_networkx` methods to MongoDBGraphStore.
* Our first example notebook in
langchain-mongodb/libs/langchain-mongodb/examples/GraphRAG.ipynb.
* Improvements to the prompt examples.
* A new optional dependency group "viz".
## Test Plan
<!-- How did you test the code? If you added unit tests, you can say
that. If you didn’t introduce unit tests, explain why. All code should
be tested in some way – so please list what your validation strategy
was. -->
Unit tests were added for the new methods. Typing tests were run. The
notebooks was demonstrated numerous times to the maintainers and
stakeholders.
## Checklist
<!-- Do not delete the items provided on this checklist -->
### Checklist for Author
- [x] Did you update the changelog (if necessary)?
- [x] Is the intention of the code captured in relevant tests?
- [ ] If there are new TODOs, has a related JIRA ticket been created?
- [x] Has a MongoDB Employee run [the patch build of this
PR](https://github.com/mongodb-labs/ai-ml-pipeline-testing?tab=readme-ov-file#running-a-patch-build-of-a-given-pr)?
### Checklist for Reviewer {@primary_reviewer}
- [ ] Does the title of the PR reference a JIRA Ticket?
- [ ] Do you fully understand the implementation? (Would you be
comfortable explaining how this code works to someone else?)
- [ ] Have you checked for spelling & grammar errors?
- [ ] Is all relevant documentation (README or docstring) updated?
## Focus Areas for Reviewer (optional)
<!-- List any complex portion of code you believe needs particular
scrutiny and explain why. -->
1 parent 052e078 commit 5166bea
File tree
13 files changed
+5321
-2758
lines changed- libs/langchain-mongodb
- examples
- data
- langchain_mongodb/graphrag
- tests/integration_tests
13 files changed
+5321
-2758
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
| |||
This file was deleted.
0 commit comments