Repository navigation
Conversation
在每次调用的累加状态中缓存备用 ID,使参数分片、执行结果和最终历史保持关联。保留模型原始 ID 与现有分片路由,补充回归测试和双语文档。 Refs agentscope-ai#4162
Preview approval requiredThis pull request comes from a fork, so Mintlify won't build a preview until someone with write access approves commit |
juruoO-o
approved these changes
Nov 19, 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.
AgentScope-Java Version
2.1.0-SNAPSHOT,基线为官方main的a4306d63d8ac737b535657f56a0ad5496503d4d8。Description
Fixes #4162.
当自定义模型分片返回一次没有原始 ID 的工具调用时,累加器在构建流式快照和最终消息时会分别按时间戳补 ID。工具只执行一次,但消费端无法用同一个
toolCallId拼接参数并关联执行结果。本 PR 在单次工具调用的累加状态中生成并复用一个备用 ID。备用 ID 保留
tool_call_前缀并使用 UUID,避免不同累加状态恰好在同一毫秒生成相同的 ID。模型提供的原始 ID 保持不变。不改分片路由、工具调度、权限或事件字段;不扩展到原始 ID 迟到的语义。验证
mvn -B -T1C -pl agentscope-core -am test:3452 项,0 failures、0 errors、11 skipped。实际在本机使用 Maven Central 临时 settings 与离线缓存;Spotless 通过。未运行全仓测试或 Windows。npm run broken-links未发现坏链。Mintlify 完整构建校验被本地预览缓存的文件权限阻止,待 CI 验证。相关 PR
#4163 也处理 #4162 的同一根因。本 PR 额外验证不同调用与重置之间不复用备用 ID,并补充双语事件文档。两份修复不需要同时合并,请维护者选择合适的实现。
Checklist
mvn spotless:apply.mvn test) — 已验证 Core,未运行全仓。