-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Expand file tree
/
Copy path.env.example
More file actions
101 lines (83 loc) · 4.14 KB
/
Copy path.env.example
File metadata and controls
101 lines (83 loc) · 4.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# localGPT environment configuration
#
# Copy to .env and edit. Every variable below is read by code; the value shown
# after "default:" is what the code uses when the variable is unset.
#
# cp .env.example .env
#
# For Docker use docker.env instead (it is passed with --env-file and also
# supplies build-time values for the frontend).
# ---------------------------------------------------------------------------
# Services
# ---------------------------------------------------------------------------
# Ollama server. Read by backend/ollama_client.py and rag_system/main.py.
# In Docker this becomes http://host.docker.internal:11434.
# default: http://localhost:11434
OLLAMA_HOST=http://localhost:11434
# Base URL of the RAG API. backend/server.py builds /chat and /index from it.
# In Docker compose this is http://rag-api:8001.
# default: http://localhost:8001
RAG_API_URL=http://localhost:8001
# Browser-facing URLs, read by the Next.js frontend (src/lib/api.ts).
# NEXT_PUBLIC_* values are inlined at build time, so change them before `npm run build`.
# default: http://localhost:8000
NEXT_PUBLIC_API_URL=http://localhost:8000
# default: http://localhost:8001
NEXT_PUBLIC_RAG_API_URL=http://localhost:8001
# ---------------------------------------------------------------------------
# Storage
# ---------------------------------------------------------------------------
# SQLite database holding sessions, messages and index metadata.
# Set this to a shared path so the backend and the RAG API use one file.
# default: backend/chat_data.db (local) or /app/backend/chat_data.db (Docker)
# DB_PATH=backend/chat_data.db
# LanceDB vector store. Defaults to the `storage.lancedb_uri` of the active
# pipeline config in rag_system/main.py.
# default: ./lancedb
# LANCEDB_PATH=./lancedb
# ---------------------------------------------------------------------------
# Models
# ---------------------------------------------------------------------------
# Answer generation (Ollama). Options: qwen3.6:27b (high-end, ~17GB), qwen3.5:4b (light).
# default: qwen3.5:9b
GENERATION_MODEL=qwen3.5:9b
# Routing, triage, query decomposition, contextual enrichment and verification
# (Ollama). Light option: qwen3.5:2b.
# default: qwen3.5:4b
ENRICHMENT_MODEL=qwen3.5:4b
# Embeddings (HuggingFace). The default is MIT-licensed, 1.2GB, 1024-dim, and
# measured best on our gold set (eval/DECISIONS.md).
# Option: Qwen/Qwen3-Embedding-4B for multilingual / long-context corpora.
# Changing this requires re-indexing every existing index - the stored vectors
# belong to the old model's vector space. localGPT records the embedding model
# on each table and refuses to query it with a different one.
# default: microsoft/harrier-oss-v1-0.6b
EMBEDDING_MODEL=microsoft/harrier-oss-v1-0.6b
# Reranker (HuggingFace). Only loaded when reranking is switched on - the
# default profile ships with it OFF, because the first stage above already
# outranks the cheap cross-encoder (eval/DECISIONS.md). When you do switch it
# on (UI "AI reranker" toggle, or reranker.enabled in the profile) this is the
# model that gets loaded, lazily.
# Options: BAAI/bge-reranker-v2-m3 (low latency, only pays off with a weaker
# embedder), answerdotai/answerai-colbert-small-v1, Qwen/Qwen3-Reranker-0.6B.
# default: Qwen/Qwen3-Reranker-4B
RERANKER_MODEL=Qwen/Qwen3-Reranker-4B
# ---------------------------------------------------------------------------
# Optional tuning
# ---------------------------------------------------------------------------
# Seconds the backend waits for a RAG API chat response.
# default: 600
# RAG_API_TIMEOUT=600
# Seconds the backend waits for a RAG API indexing run.
# default: 3600
# RAG_API_INDEX_TIMEOUT=3600
# LLM backend selector for rag_system (`ollama` or `watsonx`).
# WatsonX additionally needs the WATSONX_* variables - see env.example.watsonx.
# default: ollama
# LLM_BACKEND=ollama
# HuggingFace token, only needed for gated model downloads.
# HF_TOKEN=
# Ollama divides its context window (and any per-request num_ctx) across its
# parallel slots — with 2 slots a 32k request is served as a 16k window and
# oversized prompts are silently front-truncated. For single-user localGPT:
# OLLAMA_NUM_PARALLEL=1