Files
HuiBrain/.env.example
EduBrain Dev 4c6a20e5fc chore: 项目更名为 HuiBrain
全局替换 EduBrain -> HuiBrain, edu-brain -> huibrain, edu_brain -> hui_brain, EDUBRAIN -> HUIBRAIN
涉及文件:README.md, pyproject.toml, docker-compose.yml, .env, .env.example,
app/config.py, app/main.py, app/wework_bot.py, app/__init__.py, app/mcp/server.py,
static/index.html, docs/IMAGE_API_GUIDE.md
2026-04-14 15:03:43 +08:00

81 lines
2.5 KiB
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# ============================================================
# HuiBrain - 中文直播教育知识库系统 环境变量配置
# ============================================================
# 复制此文件为 .env 并根据实际情况修改配置值
# cp .env.example .env
# ============================================================
# ── 数据库 ──
DATABASE_URL=postgresql+asyncpg://postgres:postgres@db:5432/hui_brain
POSTGRES_PASSWORD=postgres
# ── 嵌入模型配置 ──
# 可选值: openai / zhipu / local_bge / dashscope / minimax
# openai 模式也兼容硅基流动等第三方 OpenAI 兼容接口
EMBEDDING_PROVIDER=minimax
EMBEDDING_MODEL=MiniMax-Text-Embedding
EMBEDDING_DIMENSIONS=1024
# ── OpenAI 配置(也兼容硅基流动等第三方接口) ──
OPENAI_API_KEY=sk-your-openai-api-key
OPENAI_BASE_URL=https://api.openai.com/v1
# ── 智谱 AI 配置 ──
ZHIPU_API_KEY=your-zhipu-api-key
# ── 阿里云 DashScope 配置 ──
DASHSCOPE_API_KEY=your-dashscope-api-key
# ── 本地 BGE 模型路径(为空则自动从 HuggingFace 下载) ──
LOCAL_BGE_MODEL_PATH=
# ── OCR 配置 ──
# 可选值: paddleocr / aliyun / tencent / deepseek / auto
# auto 模式: 本地 PaddleOCR 优先,失败后 fallback 到 DeepSeek / 云端 OCR
OCR_PROVIDER=deepseek
OCR_CONCURRENCY=1
# ── 阿里云 OCR 配置 ──
ALIYUN_OCR_ACCESS_KEY=your-aliyun-access-key
ALIYUN_OCR_SECRET=your-aliyun-secret
# ── 腾讯云 OCR 配置 ──
TENCENT_OCR_SECRET_ID=your-tencent-secret-id
TENCENT_OCR_SECRET_KEY=your-tencent-secret-key
# ── MiniMax 配置 ──
MINIMAX_API_KEY=your-minimax-api-key
MINIMAX_BASE_URL=https://api.minimaxi.com/v1
MINIMAX_EMBEDDING_MODEL=MiniMax-Text-Embedding
MINIMAX_CHAT_MODEL=MiniMax-M2
# ── DeepSeek 配置 ──
DEEPSEEK_API_KEY=your-deepseek-api-key
DEEPSEEK_BASE_URL=https://api.deepseek.com
DEEPSEEK_OCR_MODEL=deepseek-chat
# ── LLM 配置(用于查询扩展、实体检测等) ──
# 可选值: minimax / deepseek / openai
LLM_PROVIDER=minimax
# ── 数据目录 ──
DATA_DIR=/app/data
# ── 文本分块参数 ──
CHUNK_SIZE=300
CHUNK_OVERLAP=50
# ── CORS 配置(多个来源用逗号分隔) ──
CORS_ORIGINS=["*"]
# ── Docker 端口映射 ──
APP_PORT=8000
DB_PORT=5432
# ── 企业微信智能机器人WebSocket 长连接) ──
# 后端启动时会自动检测配置并拉起机器人(后台线程)
WEWORK_BOT_ENABLED=false
WEWORK_BOT_ID=your-bot-id
WEWORK_BOT_SECRET=your-bot-secret
HUIBRAIN_BASE_URL=http://localhost:8765