# ---- DEVELOPMENT TEMPLATE ---- # Copy to .env. Values below are intentionally weak defaults for local Docker # Compose. NEVER use them in production — see .env.prod.example. # ==== PostgreSQL ==== POSTGRES_HOST=postgres POSTGRES_PORT=5432 POSTGRES_DB=legacyhub POSTGRES_USER=legacyhub POSTGRES_PASSWORD=legacyhub # ==== MinIO ==== MINIO_ENDPOINT=minio:9000 MINIO_ACCESS_KEY=legacyhub MINIO_SECRET_KEY=legacyhub-secret MINIO_BUCKET_ORIGINALS=teamhub-legacyhub-originals MINIO_BUCKET_DERIVED=teamhub-legacyhub-derived MINIO_BUCKET_QUARANTINE=teamhub-legacyhub-quarantine MINIO_BUCKET_TMP=teamhub-legacyhub-tmp MINIO_BUCKET_EXPORTS=teamhub-legacyhub-exports MINIO_SECURE=false MINIO_REGION=us-east-1 # ==== OpenSearch ==== OPENSEARCH_HOST=opensearch OPENSEARCH_PORT=9200 OPENSEARCH_USE_SSL=false OPENSEARCH_VERIFY_CERTS=false OPENSEARCH_USER= OPENSEARCH_PASSWORD= OPENSEARCH_INDEX_CHUNKS=legacy_chunks # ==== Qdrant ==== QDRANT_HOST=qdrant QDRANT_PORT=6333 QDRANT_API_KEY= QDRANT_COLLECTION_CHUNKS=legacy_chunks # ==== Redis ==== REDIS_URL=redis://redis:6379/0 # ==== OCR ==== OCR_LANGUAGES=rus+eng OCR_ENABLED=true DOCLING_OCR_ENABLED=false MAX_DOCUMENT_TIMEOUT_SECONDS=180 OCR_DESKEW=true OCR_CLEAN=true OCR_OPTIMIZE=1 # ==== Embeddings / Reranker ==== EMBEDDING_MODEL=BAAI/bge-m3 EMBEDDING_DIM=1024 EMBEDDING_DEVICE=cpu EMBEDDING_BATCH_SIZE=8 EMBEDDING_NORMALIZE=true RERANKER_MODEL=BAAI/bge-reranker-v2-m3 RERANKER_DEVICE=cpu RERANKER_ENABLED=true RERANKER_BATCH_SIZE=8 # ==== Chunking ==== CHUNK_TARGET_TOKENS=700 CHUNK_MIN_TOKENS=120 CHUNK_MAX_TOKENS=900 CHUNK_OVERLAP_TOKENS=100 # ==== Search ==== HYBRID_OPENSEARCH_TOP_K=50 HYBRID_QDRANT_TOP_K=50 HYBRID_RRF_K=60 RERANK_CANDIDATES=40 # ==== App ==== # dev | prod — non-dev makes empty secrets a hard startup error. APP_ENV=dev APP_LOG_LEVEL=INFO APP_HOST=0.0.0.0 # APP_PORT is the in-container uvicorn bind (do not change for federation). APP_PORT=8000 # API_HOST_PORT is the published host port (8000 collides with SalesHUB / old # dispatch dev; LegacyHUB uses 8050). API_HOST_PORT=8050 APP_INPUT_DIR=/data/input APP_WORK_DIR=/data/work APP_API_PREFIX=/api/v1 # Comma-separated list of allowed origins for the browser. Use specific origins # in production; * is accepted only for local development. CORS_ALLOWED_ORIGINS=http://localhost:5273,http://localhost:4173 # Optional shared-secret API key. When empty, the API is open (dev default). # When set, every request under APP_API_PREFIX except /health requires # X-API-Key: or Authorization: Bearer . API_KEY= # Service-to-service key required on the participant ingest endpoints # (/knowledge-ingest, /ingest/folder). Falls back to API_KEY when empty. INGEST_API_KEY= # Trusted-header identity enforcement (gateway/SSO). Leave false for direct # local dev; set true when running behind the TeamHUB gateway. AUTH_REQUIRE_IDENTITY=false AUTH_APP_CODE=legacyhub # Deprecated local folder ingest (use /knowledge-ingest instead). ENABLE_FOLDER_INGEST=false # ==== Dispatch (inter-module event bus, D4) ==== # Disabled for standalone dev. Behind the platform set the dispatch-api URL + # this module's participant X-API-Key. DISPATCH_ENABLED=false DISPATCH_API_URL= DISPATCH_API_KEY= DISPATCH_PARTICIPANT_CODE=legacyhub DISPATCH_TIMEOUT_SECONDS=5