Difference between revisions of "LLM: RAG-GPT"
Jump to navigation
Jump to search
Onnowpurbo (talk | contribs) |
Onnowpurbo (talk | contribs) |
||
Line 44: | Line 44: | ||
source myenv/bin/activate | source myenv/bin/activate | ||
pip install -r requirements.txt | pip install -r requirements.txt | ||
+ | |||
+ | '''ERROR:''' ERROR: Ignored the following versions that require a different python version: 2.0.1.1 Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8; 2.0.1.20230426 | ||
+ | Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8; | ||
+ | 2.0.1.20240426 Requires-Python | ||
+ | !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8; 2.0.1.20240427 | ||
+ | Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8; | ||
+ | 2.0.1.20240429 Requires-Python | ||
+ | !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=3.7; 2.1.0 Requires-Python | ||
+ | !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=3.7; 2.1.3 Requires-Python | ||
+ | !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8 | ||
+ | ERROR: Could not find a version that satisfies the requirement onnxruntime==1.16.3 (from versions: 1.17.0, | ||
+ | 1.17.1, 1.17.3, 1.18.0, 1.18.1) | ||
+ | ERROR: No matching distribution found for onnxruntime==1.16.3 | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
python3 create_sqlite_db.py | python3 create_sqlite_db.py | ||
Revision as of 13:37, 16 July 2024
Sumber: https://github.com/gpt-open/rag-gpt?tab=readme-ov-file#using-local-llms
Buat API di LLamaCloud, login mengggunakan email
https://cloud.llamaindex.ai/api-key
Sebagai user biasa, clone RAG-GPT
git clone https://github.com/open-kf/rag-gpt.git && cd rag-gpt cp env_of_ollama .env
Edit .env
LLM_NAME="Ollama" OLLAMA_MODEL_NAME="xxxx" OLLAMA_BASE_URL="http://127.0.0.1:11434" MIN_RELEVANCE_SCORE=0.4 BOT_TOPIC="xxxx" URL_PREFIX="http://127.0.0.1:7000/" USE_PREPROCESS_QUERY=1 USE_RERANKING=1 USE_DEBUG=0 USE_LLAMA_PARSE=0 LLAMA_CLOUD_API_KEY="xxxx"
menjadi misalnya
LLM_NAME="Ollama" OLLAMA_MODEL_NAME="llama3" OLLAMA_BASE_URL="http://127.0.0.1:11434" MIN_RELEVANCE_SCORE=0.4 BOT_TOPIC="OpenIM" URL_PREFIX="http://127.0.0.1:7000/" USE_PREPROCESS_QUERY=1 USE_RERANKING=1 USE_DEBUG=0 USE_LLAMA_PARSE=0 LLAMA_CLOUD_API_KEY="llx-HYs1KFrtKm5eeLAJeJW4goCnAaeKZeHd6RmjKSprrogxYdwP!"
Buat dari source
sudo apt install python3.12-venv python3 -m venv myenv source myenv/bin/activate pip install -r requirements.txt
ERROR: ERROR: Ignored the following versions that require a different python version: 2.0.1.1 Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8; 2.0.1.20230426
Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8; 2.0.1.20240426 Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8; 2.0.1.20240427 Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8; 2.0.1.20240429 Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=3.7; 2.1.0 Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=3.7; 2.1.3 Requires-Python !=2.7.*,!=3.0.*,!=3.1.*,!=3.12.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8 ERROR: Could not find a version that satisfies the requirement onnxruntime==1.16.3 (from versions: 1.17.0, 1.17.1, 1.17.3, 1.18.0, 1.18.1) ERROR: No matching distribution found for onnxruntime==1.16.3
python3 create_sqlite_db.py
sh start.sh
Browser
http://ipaddress:7000