From 2d8dde3d3b08c0f745d8a849e5f7b207043a65e4 Mon Sep 17 00:00:00 2001 From: sykp241095 Date: Wed, 17 Apr 2024 11:54:30 +0800 Subject: [PATCH] chore: fix docs desc --- examples/README.md | 5 ++++- examples/llamaindex-tidb-vector/README.md | 6 +++--- .../{talk_to_url.py => chat_with_url.py} | 4 ++-- 3 files changed, 9 insertions(+), 6 deletions(-) rename examples/llamaindex-tidb-vector/{talk_to_url.py => chat_with_url.py} (97%) diff --git a/examples/README.md b/examples/README.md index 6fad95f..193b641 100644 --- a/examples/README.md +++ b/examples/README.md @@ -27,10 +27,13 @@ Please make sure you have created a TiDB Serverless cluster with vector support - [OpenAI Embedding](./openai_embedding/README.md): use the OpenAI embedding model to generate vectors for text data. - [Image Search](./image_search/README.md): use the OpenAI CLIP model to generate vectors for image and text. -- [LlamaIndex RAG](./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. +- [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. ## Real World Applications ### tidb.ai [tidb.ai](https://tidb.ai) is an amazing out-of-the-box RAG(Retrieval Augmented Generation) template project based on the TiDB Vector store, it contains ui and server logic, fork it on [github](https://github.com/pingcap/tidb.ai) and build your own application. + +![out-of-box-conversational-search](https://github.com/pingcap/tidb.ai/assets/1237528/0784e26e-8392-4bbe-bda1-6a680b12a805 "Image Title") \ No newline at end of file diff --git a/examples/llamaindex-tidb-vector/README.md b/examples/llamaindex-tidb-vector/README.md index fbfe09a..2fb3e65 100644 --- a/examples/llamaindex-tidb-vector/README.md +++ b/examples/llamaindex-tidb-vector/README.md @@ -46,15 +46,15 @@ export TIDB_PASSWORD="****" ### Run this example ```text -$ python talk_to_url.py --help -Usage: talk_to_url.py [OPTIONS] +$ python chat_with_url.py --help +Usage: chat_with_url.py [OPTIONS] Options: --url TEXT URL you want to talk to, default=https://docs.pingcap.com/tidb/stable/overview --help Show this message and exit. $ -$ python talk_to_url.py +$ python chat_with_url.py Enter your question: : tidb vs mysql TiDB is an open-source distributed SQL database that supports Hybrid Transactional and Analytical Processing (HTAP) workloads. It is MySQL compatible and features horizontal scalability, strong consistency, and high availability. TiDB is designed to provide users with a one-stop database solution that covers OLTP, OLAP, and HTAP services. It offers easy horizontal scaling, financial-grade high availability, real-time HTAP capabilities, cloud-native features, and compatibility with the MySQL protocol and ecosystem. Enter your question: : diff --git a/examples/llamaindex-tidb-vector/talk_to_url.py b/examples/llamaindex-tidb-vector/chat_with_url.py similarity index 97% rename from examples/llamaindex-tidb-vector/talk_to_url.py rename to examples/llamaindex-tidb-vector/chat_with_url.py index 38f995b..23509cb 100644 --- a/examples/llamaindex-tidb-vector/talk_to_url.py +++ b/examples/llamaindex-tidb-vector/chat_with_url.py @@ -39,7 +39,7 @@ def do_prepare_data(url): @click.command() @click.option('--url',default=_default_url, help=f'URL you want to talk to, default={_default_url}') -def talk_to(url): +def chat_with_url(url): do_prepare_data(url) while True: question = click.prompt("Enter your question: ") @@ -47,4 +47,4 @@ def talk_to(url): click.echo(response) if __name__ == '__main__': - talk_to() + chat_with_url()