Configuration
Environment variables
Variables read by TraDoc and deployment recommendations.
| Variable | Default | Purpose |
|---|---|---|
ENV | production | Environment name. |
DATA_DIR | ./data | Root for SQLite, projects, glossaries, outputs and credentials. |
ALLOWED_ORIGINS | empty | Additional allowed origins, comma-separated. |
ALLOWED_LLM_HOSTS | empty | Explicitly allowed LLM hosts. |
TRUSTED_LAN_PROXY | false | Allows the local LAN proxy; managed automatically by main.py dev. |
LLM_ENDPOINT | http://localhost:1234/v1 | Initial provider URL. |
LLM_API_KEY | lm-studio | Initial key or placeholder for a local service. |
LLM_MODEL | qwen3.5-instruct | Initial model. |
API_TYPE | openai | Initial provider adapter. |
CONCURRENCY | 1 | Simultaneous requests, maximum 32. |
CHUNK_TOKEN_SIZE | 1000 | Target segment size, from 200 to 10000. |
MAX_RETRIES | 3 | Attempts, from 1 to 10. |
REQUEST_TIMEOUT | 180.0 | Provider timeout in seconds. |
TEMPERATURE | 0.15 | Model temperature, from 0 to 2. |
MAX_UPLOAD_BYTES | 209715200 | Maximum import size, 200 MiB by default. |
MAX_ARCHIVE_ENTRIES | 20000 | Maximum number of archive entries. |
MAX_ARCHIVE_UNCOMPRESSED_BYTES | 1073741824 | Maximum uncompressed size, 1 GiB by default. |
ENABLE_PROOFREADING | false | Enables conditional proofreading features. |
DEFAULT_SOURCE_LANG | en | Initial source language. |
DEFAULT_TARGET_LANG | fr | Initial target language. |
Rules
- For source installs or explicit overrides, create
.envfrom.env.example, replace the placeholders, and never commit it. - An older
APP_SECRETvalue in.envis ignored and can be deleted. - A Docker environment variable overrides the value read from
.envby the application. - If you share a diagnostic, back up or redact configuration separately from keys and documents.