-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
42 lines (35 loc) · 1.76 KB
/
Copy path.env.example
File metadata and controls
42 lines (35 loc) · 1.76 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
# ========== 环境变量配置 ==========
# 复制此文件为 .env 后填入实际值
# ─── LLM 配置 ──────────────────────────────────────────────
# 方式一:使用 Ollama 本地模型(推荐,无需 API Key)
USE_OLLAMA=true
OLLAMA_BASE_URL=http://localhost:11434
OLLAMA_MODEL=qwen2.5:7b
OLLAMA_EMBED_MODEL=nomic-embed-text
# 方式二:使用 OpenAI API(生产环境推荐,取消注释并填入 Key)
# USE_OLLAMA=false
# OPENAI_API_KEY=sk-your-api-key-here
# OPENAI_MODEL=gpt-4o-mini
# OPENAI_EMBED_MODEL=text-embedding-3-small
# ─── Milvus 向量数据库配置 ─────────────────────────────────
# Milvus Lite 模式(本地文件存储,无需 Docker)
MILVUS_COLLECTION_SCHEMA=saas_bi_schema
MILVUS_COLLECTION_METRICS=saas_bi_metrics
MILVUS_COLLECTION_EXAMPLES=saas_bi_sql_examples
MILVUS_DATA_DIR=./data/milvus
# ─── 业务数据库配置(PostgreSQL) ───────────────────────────
DB_HOST=localhost
DB_PORT=5432
DB_NAME=saas_bi
DB_USER=postgres
DB_PASSWORD=postgres
# ─── FastAPI 服务配置 ──────────────────────────────────────
API_HOST=0.0.0.0
API_PORT=8000
DEBUG=true
# ─── RAG 检索配置 ──────────────────────────────────────────
TOP_K_SCHEMA=10
TOP_K_METRICS=5
TOP_K_EXAMPLES=5
# ─── SQL 生成配置 ──────────────────────────────────────────
MAX_SQL_RETRIES=3