feat: dual LLM mode (default via .env, custom per-request) for AI analysis

This commit is contained in:
hyh
2026-09-04 12:06:05 +08:00
parent 1a935cae6e
commit 4a4c6f2ec2
10 changed files with 154 additions and 63 deletions
+7 -4
View File
@@ -2,10 +2,13 @@ SECRET_KEY=change-me
DEBUG=true
ALLOWED_HOSTS=*
# LLM(OpenAI 兼容接口)
LLM_BASE_URL=https://api.openai.com/v1
LLM_API_KEY=sk-placeholder
LLM_MODEL=gpt-4o-mini
# LLM 模式: default = 用下面全局配置; custom = 每次请求在 body.llm 里自带 base_url/model/api_key
LLM_MODE=default
# default 模式的全局 LLM(OpenAI 兼容接口)
LLM_BASE_URL=http://100.69.1.2:8001/v1
LLM_API_KEY=
LLM_MODEL=qwen38
# 检测执行
MAX_UPLOAD_SIZE_MB=200