优化MCP工具名称列表顺序问题

This commit is contained in:
DaGou12138
2026-01-23 14:03:00 +08:00
parent 3222d6175d
commit 3559a7018c
@@ -147,6 +147,7 @@ public class AgentMcpAccessPointServiceImpl implements AgentMcpAccessPointServic
List<String> result = toolsList.stream()
.map(tool -> (String) tool.get("name"))
.filter(name -> name != null)
.sorted()
.collect(Collectors.toList());
log.info("成功获取MCP工具列表,智能体ID: {}, 工具数量: {}", id, result.size());
return result;