Merge pull request #1914 from danielaskdd/feat-tiktoken-cache

feat: add tiktoken cache directory support for offline deployment
This commit is contained in:
Daniel.y 2025-08-05 14:25:10 +08:00 committed by GitHub
commit c7d17f13c1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 7 additions and 0 deletions

1
.gitignore vendored
View File

@ -50,6 +50,7 @@ rag_storage/
examples/input/
examples/output/
output*/
data/
# Miscellaneous
.DS_Store

View File

@ -12,10 +12,13 @@ services:
volumes:
- ./data/rag_storage:/app/data/rag_storage
- ./data/inputs:/app/data/inputs
- ./data/tiktoken:/app/data/tiktoken
- ./config.ini:/app/config.ini
- ./.env:/app/.env
env_file:
- .env
environment:
- TIKTOKEN_CACHE_DIR=/app/data/tiktoken
restart: unless-stopped
extra_hosts:
- "host.docker.internal:host-gateway"

View File

@ -20,6 +20,9 @@ WEBUI_DESCRIPTION="Simple and Fast Graph Based RAG System"
# INPUT_DIR=<absolute_path_for_doc_input_dir>
# WORKING_DIR=<absolute_path_for_working_dir>
### Tiktoken cache directory (Store cached files in this folder for offline deployment)
# TIKTOKEN_CACHE_DIR=./temp/tiktoken
### Ollama Emulating Model and Tag
# OLLAMA_EMULATING_MODEL_NAME=lightrag
OLLAMA_EMULATING_MODEL_TAG=latest