mirror of
https://github.com/jeffusion/gitea-ai-assistant.git
synced 2026-03-27 10:05:50 +00:00
新增REVIEW_ENGINE、向量记忆、Reflection/Debate等环境变量;添加@qdrant/js-client-rest和zod-to-json-schema依赖;添加test脚本 Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
54 lines
1.8 KiB
Plaintext
54 lines
1.8 KiB
Plaintext
# Gitea配置
|
||
GITEA_API_URL=http://localhost:3000/api/v1
|
||
GITEA_ACCESS_TOKEN=your_gitea_token
|
||
|
||
# OpenAI配置
|
||
OPENAI_BASE_URL=https://api.openai.com/v1
|
||
OPENAI_API_KEY=your_openai_key
|
||
OPENAI_MODEL=gpt-4o-mini
|
||
CUSTOM_SUMMARY_PROMPT=your_custom_prompt
|
||
CUSTOM_LINE_COMMENT_PROMPT=your_custom_prompt
|
||
|
||
# 飞书配置
|
||
FEISHU_WEBHOOK_URL=https://open.feishu.cn/open-apis/bot/v2/hook/your_webhook_token
|
||
FEISHU_WEBHOOK_SECRET=your_webhook_secret
|
||
|
||
# 应用配置
|
||
PORT=3000
|
||
# 建议使用以下命令生成一个安全的随机字符串作为webhook密钥:
|
||
# 在Linux/Mac终端: openssl rand -hex 32
|
||
# 或者在Node.js中: require('crypto').randomBytes(32).toString('hex')
|
||
WEBHOOK_SECRET=your_webhook_secret
|
||
|
||
# Agent审查配置(默认关闭,开启请设置为agent)
|
||
REVIEW_ENGINE=legacy
|
||
REVIEW_WORKDIR=/tmp/gitea-assistant
|
||
REVIEW_MODEL_PLANNER=gpt-4o-mini
|
||
REVIEW_MODEL_SPECIALIST=gpt-4o-mini
|
||
REVIEW_MODEL_JUDGE=gpt-4o-mini
|
||
REVIEW_MAX_PARALLEL_RUNS=2
|
||
REVIEW_MAX_FILES_PER_RUN=200
|
||
REVIEW_MAX_FILE_CONTENT_CHARS=40000
|
||
REVIEW_AUTO_PUBLISH_MIN_CONFIDENCE=0.8
|
||
REVIEW_ENABLE_HUMAN_GATE=true
|
||
REVIEW_ALLOWED_COMMANDS=git,rg,cat,sed,wc
|
||
REVIEW_COMMAND_TIMEOUT_MS=10000
|
||
|
||
# 向量记忆和学习系统配置(可选,第二阶段功能)
|
||
# Qdrant向量数据库URL(如果不配置则禁用记忆系统)
|
||
QDRANT_URL=http://localhost:6333
|
||
# 是否启用记忆系统(需要先配置QDRANT_URL)
|
||
ENABLE_MEMORY=false
|
||
# Few-shot学习示例数量(0-20)
|
||
FEW_SHOT_EXAMPLES_COUNT=10
|
||
|
||
# Reflection和Debate配置(可选,第三阶段功能)
|
||
# 是否启用Reflection自我批评机制(提升审查质量)
|
||
ENABLE_REFLECTION=false
|
||
# Reflection最大轮次(1-5)
|
||
MAX_REFLECTION_ROUNDS=2
|
||
# 是否启用Debate多代理辩论机制(提升高严重性问题准确性)
|
||
ENABLE_DEBATE=false
|
||
# Debate触发阈值(high=仅高严重性, medium=高和中等严重性)
|
||
DEBATE_THRESHOLD=high
|