138 lines
3.9 KiB
Plaintext
138 lines
3.9 KiB
Plaintext
### Server Configuration
|
|
HOST=0.0.0.0
|
|
PORT=9621
|
|
NAMESPACE_PREFIX=lightrag_1 # separating data from difference Lightrag instances
|
|
|
|
### Optional SSL Configuration
|
|
#SSL=true
|
|
#SSL_CERTFILE=/path/to/cert.pem
|
|
#SSL_KEYFILE=/path/to/key.pem
|
|
|
|
### Security (empty for no api-key is needed)
|
|
# LIGHTRAG_API_KEY=your-secure-api-key-here
|
|
|
|
### Directory Configuration
|
|
# WORKING_DIR=./rag_storage
|
|
# INPUT_DIR=./inputs
|
|
|
|
### Logging level
|
|
LOG_LEVEL=INFO
|
|
|
|
### Optional Timeout
|
|
TIMEOUT=300
|
|
|
|
# Ollama Emulating Model Tag
|
|
# OLLAMA_EMULATING_MODEL_TAG=latest
|
|
|
|
### RAG Configuration
|
|
MAX_ASYNC=4
|
|
MAX_TOKENS=32768
|
|
EMBEDDING_DIM=1024
|
|
MAX_EMBED_TOKENS=8192
|
|
#HISTORY_TURNS=3
|
|
#CHUNK_SIZE=1200
|
|
#CHUNK_OVERLAP_SIZE=100
|
|
#COSINE_THRESHOLD=0.2
|
|
#TOP_K=60
|
|
|
|
### LLM Configuration (Use valid host. For local services, you can use host.docker.internal)
|
|
### Ollama example
|
|
# LLM_BINDING=ollama
|
|
# LLM_BINDING_HOST=http://host.docker.internal:11434
|
|
# LLM_MODEL=mistral-nemo:latest
|
|
|
|
### OpenAI alike example
|
|
LLM_BINDING=openai
|
|
LLM_MODEL=deepseek-chat
|
|
LLM_BINDING_HOST=https://api.deepseek.com
|
|
LLM_BINDING_API_KEY=your_api_key
|
|
|
|
### for OpenAI LLM (LLM_BINDING_API_KEY take priority)
|
|
# OPENAI_API_KEY=your_api_key
|
|
|
|
### Lollms example
|
|
# LLM_BINDING=lollms
|
|
# LLM_BINDING_HOST=http://host.docker.internal:9600
|
|
# LLM_MODEL=mistral-nemo:latest
|
|
|
|
|
|
### Embedding Configuration (Use valid host. For local services, you can use host.docker.internal)
|
|
# Ollama example
|
|
EMBEDDING_BINDING=ollama
|
|
EMBEDDING_BINDING_HOST=http://host.docker.internal:11434
|
|
EMBEDDING_BINDING_API_KEY=
|
|
EMBEDDING_MODEL=bge-m3:latest
|
|
|
|
### Lollms example
|
|
# EMBEDDING_BINDING=lollms
|
|
# EMBEDDING_BINDING_HOST=http://host.docker.internal:9600
|
|
# EMBEDDING_MODEL=bge-m3:latest
|
|
|
|
### Optional for Azure (LLM_BINDING_HOST, LLM_BINDING_API_KEY take priority)
|
|
# AZURE_OPENAI_API_VERSION=2024-08-01-preview
|
|
# AZURE_OPENAI_DEPLOYMENT=gpt-4o
|
|
# AZURE_OPENAI_API_KEY=myapikey
|
|
# AZURE_OPENAI_ENDPOINT=https://myendpoint.openai.azure.com
|
|
|
|
# AZURE_EMBEDDING_DEPLOYMENT=text-embedding-3-large
|
|
# AZURE_EMBEDDING_API_VERSION=2023-05-15
|
|
|
|
### Data storage selection
|
|
LIGHTRAG_KV_STORAGE=RedisKVStorage
|
|
LIGHTRAG_VECTOR_STORAGE=QdrantVectorDBStorage
|
|
LIGHTRAG_GRAPH_STORAGE=Neo4JStorage
|
|
LIGHTRAG_DOC_STATUS_STORAGE=MongoDocStatusStorage
|
|
|
|
### Oracle Database Configuration
|
|
#ORACLE_DSN=localhost:1521/XEPDB1
|
|
#ORACLE_USER=your_username
|
|
#ORACLE_PASSWORD='your_password'
|
|
#ORACLE_CONFIG_DIR=/path/to/oracle/config
|
|
#ORACLE_WALLET_LOCATION=/path/to/wallet # optional
|
|
#ORACLE_WALLET_PASSWORD='your_password' # optional
|
|
#ORACLE_WORKSPACE=default # separating all data from difference Lightrag instances(deprecated, use NAMESPACE_PREFIX in future)
|
|
|
|
### TiDB Configuration
|
|
#TIDB_HOST=localhost
|
|
#TIDB_PORT=4000
|
|
#TIDB_USER=your_username
|
|
#TIDB_PASSWORD='your_password'
|
|
#TIDB_DATABASE=your_database
|
|
#TIDB_WORKSPACE=default # separating all data from difference Lightrag instances(deprecated, use NAMESPACE_PREFIX in future)
|
|
|
|
### PostgreSQL Configuration
|
|
# POSTGRES_HOST=postgres
|
|
# POSTGRES_PORT=5432
|
|
# POSTGRES_USER=postgres
|
|
# POSTGRES_PASSWORD='your_password'
|
|
# POSTGRES_DATABASE=lightrag
|
|
#POSTGRES_WORKSPACE=default # separating all data from difference Lightrag instances(deprecated, use NAMESPACE_PREFIX in future)
|
|
|
|
### Independent AGM Configuration(not for AMG embedded in PostreSQL)
|
|
#AGE_POSTGRES_DB=
|
|
#AGE_POSTGRES_USER=
|
|
#AGE_POSTGRES_PASSWORD=
|
|
#AGE_POSTGRES_HOST=
|
|
# AGE_POSTGRES_PORT=8529
|
|
|
|
# AGE Graph Name(apply to PostgreSQL and independent AGM)
|
|
# AGE_GRAPH_NAME=lightrag # deprecated, use NAME_SPACE_PREFIX instead
|
|
|
|
### Neo4j Configuration
|
|
NEO4J_URI=neo4j+s://neo4j
|
|
NEO4J_USERNAME=neo4j
|
|
NEO4J_PASSWORD='your_password'
|
|
NEO4J_DATABASE=neo4j # IMPORTANT: free version of neo4j does not support multiple databases, therefore we force it to neo4j
|
|
|
|
### MongoDB Configuration
|
|
MONGO_URI=mongodb://mongodb:root@mongodb:27017/
|
|
MONGO_DATABASE=lightrag
|
|
MONGODB_GRAPH=false # deprecated (keep for backward compatibility)
|
|
|
|
### Qdrant
|
|
QDRANT_URL=http://qdrant:16333
|
|
QDRANT_API_KEY=your-api-key # 可选
|
|
|
|
### Redis
|
|
REDIS_URI=redis://redis:6379
|