feat(rag state):RAG isolation and structure - #51
Merged
Conversation
RUSS0718
approved these changes
Aug 16, 2026
RUSS0718
approved these changes
Aug 16, 2026
RUSS0718
approved these changes
Aug 16, 2026
RUSS0718
approved these changes
Aug 16, 2026
RUSS0718
approved these changes
Aug 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
背景
当前 RAG 子图直接复用父图 State,RAG route、ToolMessage 和解析中间结果可能进入父图;Planner、ToolNode 和 Parser 的异常处理也没有统一经过同一个最终收口节点。
变更内容
RagSubgraphState,隔离 RAG 私有状态。knowledge_base_result。config和runtime.context。rag_question_planner -> rag_tool_node -> rag_result_parser -> rag_finalizeunavailable、protocol_error和available状态。success=False的 RAG 工具结果仍然进入 Parser。rag_finalize。JobExecutionRevoked和asyncio.CancelledError不被重试或降级。rag_finalize投影,避免重复事件。验证
compileall:通过git diff --check:通过langchain_core和mysql依赖风险与后续
Docker 环境恢复后,需要补跑完整的
unit-test服务,并进一步执行真实模型、MCP、知识库和 worker/checkpoint 集成验证。