MCPcopy Index your code
hub / github.com/simstudioai/sim / partitionToolBatch

Function partitionToolBatch

apps/sim/lib/copilot/tool-executor/router.ts:50–63  ·  view source on GitHub ↗
(toolCalls: ToolCallDescriptor[])

Source from the content-addressed store, hash-verified

48}
49
50export function partitionToolBatch(toolCalls: ToolCallDescriptor[]): PartitionedBatch {
51 const result: PartitionedBatch = { sim: [], go: [], subagent: [], client: [], unknown: [] }
52
53 for (const tc of toolCalls) {
54 const route = routeToolCall(tc.toolId)
55 if (!route) {
56 result.unknown.push(tc)
57 continue
58 }
59 result[route.route].push(tc)
60 }
61
62 return result
63}

Callers

nothing calls this directly

Calls 2

routeToolCallFunction · 0.85
pushMethod · 0.45

Tested by

no test coverage detected