Skip to content

Commit

Permalink
docs: add graphrag to readme (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
sykp241095 authored May 27, 2024
1 parent 7b87871 commit e3bd91c
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 29 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -242,5 +242,8 @@ There are some examples to show how to use the tidb-vector-python to interact wi
- [OpenAI Embedding](./examples/openai_embedding/README.md): use the OpenAI embedding model to generate vectors for text data, store them in TiDB Vector, and search for similar text.
- [Image Search](./examples/image_search/README.md): use the OpenAI CLIP model to generate vectors for image and text, store them in TiDB Vector, and search for similar images.
- [LlamaIndex RAG with UI](./examples/llamaindex-tidb-vector-with-ui/README.md): use the LlamaIndex to build an [RAG(Retrieval-Augmented Generation)](https://docs.llamaindex.ai/en/latest/getting_started/concepts/) application.
- [Chat with URL](./llamaindex-tidb-vector/README.md): use LlamaIndex to build an [RAG(Retrieval-Augmented Generation)](https://docs.llamaindex.ai/en/latest/getting_started/concepts/) application that can chat with a URL.
- [GraphRAG](./examples/graphrag-demo/README.md): 20 lines code of using TiDB Serverless to build a Knowledge Graph based RAG application.
- [GraphRAG Step by Step Tutorial](./examples/graphrag-step-by-step-tutorial/README.md): Step by step tutorial to build a Knowledge Graph based RAG application with Colab notebook.

for more examples, see the [examples](./examples) directory.
2 changes: 2 additions & 0 deletions examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ Please make sure you have created a TiDB Serverless cluster with vector support
- [Image Search](./image_search/README.md): use the OpenAI CLIP model to generate vectors for image and text.
- [LlamaIndex RAG with UI](./llamaindex-tidb-vector-with-ui/README.md): use the LlamaIndex to build an [RAG(Retrieval-Augmented Generation)](https://docs.llamaindex.ai/en/latest/getting_started/concepts/) application.
- [Chat with URL](./llamaindex-tidb-vector/README.md): use LlamaIndex to build an [RAG(Retrieval-Augmented Generation)](https://docs.llamaindex.ai/en/latest/getting_started/concepts/) application that can chat with a URL.
- [GraphRAG](./examples/graphrag-demo/README.md): 20 lines code of using TiDB Serverless to build a Knowledge Graph based RAG application.
- [GraphRAG Step by Step Tutorial](./examples/graphrag-step-by-step-tutorials/README.md): Step by step tutorial to build a Knowledge Graph based RAG application with Colab notebook.

## Real World Applications

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# LlamaIndex RAG Example
# GraphRAG Demo

This example demonstrates how to use the DSPy and TiDB Serverless to build a simple GraphRAG application. It crawled an example webpage and index the content to TiDB Serverless with Graph, then use the Graph and Vector to search the content and generate the answer with OpenAI.

Expand All @@ -21,7 +21,7 @@ git clone https://github.com/pingcap/tidb-vector-python.git
### Create a virtual environment

```bash
cd tidb-vector-python/examples/graphrag-helloworld
cd tidb-vector-python/examples/graphrag-demo
python3 -m venv .venv
source .venv/bin/activate
```
Expand All @@ -48,7 +48,7 @@ Get the `OPENAI_API_KEY` from [OpenAI](https://platform.openai.com/docs/quicksta


```text
$ python3 simple-retrieve.py
$ python3 graphrag-demo.py
Input your TIDB connection string:
Input your OpenAI API Key:
Enter your question:
Expand Down
File renamed without changes.
File renamed without changes.
26 changes: 0 additions & 26 deletions examples/graphrag-helloworld/simple-retrieve.py

This file was deleted.

0 comments on commit e3bd91c

Please sign in to comment.