MCPcopy Create free account
hub / github.com/Noumena-Network/code / hasToolResultContent

Function hasToolResultContent

src/utils/attachments.ts:2454–2456  ·  view source on GitHub ↗

* Check whether a user message's content contains tool_result blocks. * This is more reliable than checking `toolUseResult === undefined` because * sub-agent tool result messages explicitly set `toolUseResult` to `undefined` * when `preserveToolUseResults` is false (the default for Explore agents

(content: unknown)

Source from the content-addressed store, hash-verified

2452 * when `preserveToolUseResults` is false (the default for Explore agents).
2453 */
2454function hasToolResultContent(content: unknown): boolean {
2455 return Array.isArray(content) && content.some(isToolResultBlock)
2456}
2457
2458/**
2459 * Tools that succeeded (and never errored) since the previous real turn

Callers 2

Calls

no outgoing calls

Tested by

no test coverage detected