From e041b3d7b3657d78fb211b4d90ce3c8dc5317259 Mon Sep 17 00:00:00 2001 From: Gus Date: Wed, 4 Sep 2024 16:50:59 +0800 Subject: [PATCH] docs: add naive rag --- ROADMAP.md | 2 +- readme.md | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/ROADMAP.md b/ROADMAP.md index 17c6b58..cd46b02 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -1,7 +1,7 @@ ## Next Version TODO - [ ] Add `eval` method for `GraphRAG`, add at least one benchmark dataset -- [ ] Add `before_query`, `before_insert` to separate component loadings. +- [x] Add naive RAG pipeline ## Interesting directions diff --git a/readme.md b/readme.md index 5d37626..cdc38a6 100644 --- a/readme.md +++ b/readme.md @@ -103,6 +103,23 @@ with open("./book.txt") as f: +
+ Naive RAG + +`nano-graphrag` supports naive RAG insert and query as well: + +```python +graph_func = GraphRAG(working_dir="./dickens", enable_naive_rag=True) +... +# Query +print(rag.query( + "What are the top themes in this story?", + param=QueryParam(mode="naive") +) +``` +
+ + ### Async For each method `NAME(...)` , there is a corresponding async method `aNAME(...)`