Commit Graph

15 Commits

Author SHA1 Message Date
b64dade9e9 修复循环推理bug 2026-05-05 00:54:04 +08:00
c9bf21be0e fix: 修复 RAG 无限循环问题和导入错误
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Has been cancelled
主要修复:
1. 修复 RAG 推理无限循环问题(大小写不匹配 + 缺少已检索结果检查)
2. 修复 intent_classifier.py 的绝对导入错误
3. 删除旧的 start.sh 脚本,添加新的启动脚本
4. 优化路由逻辑和状态管理
2026-05-04 18:59:15 +08:00
9841f47432 refactor: 重构RAG核心组件,简化代码结构和测试文件
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Failing after 6m53s
2026-05-04 17:58:10 +08:00
4209386c77 refactor: 统一导入方式,移除 sys.path 操作
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Failing after 6m22s
- 重构所有模块导入,移除 sys.path.insert
- 统一使用 from backend.xxx 的绝对导入方式
- rag_core 包内使用相对导入(from .xxx)
- 移动 visualize_graph.py 到 tools/ 目录
- 添加必要的 __init__.py 文件
- 清理废弃文档和脚本
2026-05-04 12:55:45 +08:00
82dde7113e 修改rag,实现混合检索
All checks were successful
构建并部署 AI Agent 服务 / deploy (push) Successful in 5m42s
2026-05-04 04:28:32 +08:00
a5fc9cd5d8 完整的混合路由优化系统
All checks were successful
构建并部署 AI Agent 服务 / deploy (push) Successful in 6m8s
1. 双模型服务 (llm + smallLLM)
   - 增加 get_small_llm_service() 函数
   - 支持智谱/DeepSeek 小模型作为轻量级选项

2. 前置混合路由
   - 规则快速分流(无 LLM,超快速)
   - 轻量级意图分类(smallLLM)
   - 快速路径:fast_chitchat, fast_rag, fast_tool

3. 自动升级机制
   - 快速路径失败 → 自动回到 React 循环
   - SSE 事件增强:intent_classified, path_decision, fast_path_*, escalation

4. 向后兼容
   - build_react_main_graph(use_hybrid_router=True/False)
   - 可选择启用或禁用混合路由

5. 更新 intent.py
   - 支持 use_small_llm 参数
   - 保留原有完整功能供 React 循环使用
2026-05-03 16:45:46 +08:00
2893accbc4 修复三个问题:1. 子图执行后的无限循环 2. llm_call没有输出 3. 思考打印两次
- 子图执行后直接进入finalize,避免回到react_reason循环
- llm_call节点检查是否已有final_result,避免重复调用LLM
- 直接在react_reason_node中通过adispatch_custom_event发送推理事件,避免通过state传递导致重复
2026-05-02 09:00:34 +08:00
2761eca100 feat: 完成联网搜索功能实现和依赖更新
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Has been cancelled
2026-05-01 00:13:19 +08:00
a362459d1f fix: 修复嵌入维度不匹配和Web搜索优化
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Failing after 6m13s
- 将默认嵌入模型从 embedding-3 (2048维) 改为 embedding-2 (1024维),解决Qdrant维度不匹配问题
- 优化web_search.py,增加详细日志输出和更好的错误处理
- 更新模拟搜索结果,增加提示信息
2026-04-30 22:15:09 +08:00
7a6869ad62 添加公共工具:联网搜索(DuckDuckGo)和可视化图表(Mermaid),更新 intent.py 支持 WEB_SEARCH 动作
All checks were successful
构建并部署 AI Agent 服务 / deploy (push) Successful in 6m10s
2026-04-29 23:29:10 +08:00
4fe6b68819 添加公共工具:联网搜索(DuckDuckGo)和可视化图表(Mermaid)
All checks were successful
构建并部署 AI Agent 服务 / deploy (push) Successful in 10m38s
2026-04-29 23:10:15 +08:00
930139e454 修复 app/core/__init__.py 的导入,从 intent_classifier.py 获取正确的类
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Has been cancelled
2026-04-29 19:12:27 +08:00
2f83aca2c0 修复 StateBase -> BaseState 的导入名称
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Has been cancelled
2026-04-29 19:10:24 +08:00
a1d51fb1ce 更新 app/core/__init__.py 导出所有核心模块
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Has been cancelled
2026-04-29 19:08:16 +08:00
ef5113bffb refactor: 重构目录结构 - 简化层级
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Has been cancelled
2026-04-29 12:52:41 +08:00