JackDance / DocumentQA_RAG

RAG+ChatGPT+LangChain搭建本地知识库文档问答系统

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

DocumentQA_RAG

Environment Setup

Install Milvus

Please refer to the Docker method of installing Milvus online.

Download Repository

git clone https://github.com/JackDance/DocumentQA_RAG

Install Python Packages

conda create -n your_conda_envir_name python=3.10 -y
conda activate your_conda_envir_name
pip install requirments.txt

Modify Configuration

Open .envfile and modify the following values

OPENAI_API_KEY1="your openai api key"
EMB_OPENAI_API_BASE="your openai embedding api base"
CHAT_OPENAI_API_BASE="your chat openai api base"
MILVUS_HOST="milvus host ip"
MILVUS_PORT="milvus port, default is 19530"

Knowledge Building

cd DocumentQA_RAG
python knowledge_building.py --doc_folder "your local document folder path"

Knowledge Retrieval

cd DocumentQA_RAG
python knowledge_retrieval.py

Sample Result

sample_demo.mp4

About

RAG+ChatGPT+LangChain搭建本地知识库文档问答系统


Languages

Language:Python 100.0%