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

Function shouldSkipToolCallEvent

apps/sim/lib/copilot/request/sse-utils.ts:56–65  ·  view source on GitHub ↗
(event: StreamEvent)

Source from the content-addressed store, hash-verified

54}
55
56export function shouldSkipToolCallEvent(event: StreamEvent): boolean {
57 if (!isToolCallStreamEvent(event)) return false
58 if (isPathlessVfsGeneratingEvent(event)) return true
59 if (event.payload.status === TOOL_CALL_STATUS.generating) return false
60 const toolCallId = getToolCallIdFromCallEvent(event)
61 if (event.payload.partial === true) return false
62 if (wasToolResultSeen(toolCallId) || wasToolCallSeen(toolCallId)) return true
63 markToolCallSeen(toolCallId)
64 return false
65}
66
67function isPathlessVfsGeneratingEvent(event: ToolCallStreamEvent): boolean {
68 if (event.payload.status !== TOOL_CALL_STATUS.generating) return false

Callers 2

sse-utils.test.tsFile · 0.90
runStreamLoopFunction · 0.90

Calls 6

isToolCallStreamEventFunction · 0.90
wasToolResultSeenFunction · 0.85
wasToolCallSeenFunction · 0.85
markToolCallSeenFunction · 0.85

Tested by

no test coverage detected