MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / settleSynthetic

Function settleSynthetic

packages/agent-core/src/loop/tool-call.ts:241–252  ·  view source on GitHub ↗
(
    args: unknown,
    result: ExecutableToolResult,
    displayFields?: ToolCallDisplayFields,
  )

Source from the content-addressed store, hash-verified

239 };
240
241 const settleSynthetic = async (
242 args: unknown,
243 result: ExecutableToolResult,
244 displayFields?: ToolCallDisplayFields,
245 ): Promise<PreparedToolCallTask> => {
246 const coerced = coerceToolResult(result, call.toolName);
247 await dispatchToolCall(step, call, args, displayFields);
248 return {
249 task: makeResolvedToolCallTask(makeToolResult(call, args, coerced)),
250 stopBatchAfterThis: toolResultStopsTurn(coerced),
251 };
252 };
253
254 if (call.kind === 'rejected') return settleError(call.args, call.output);
255

Callers 1

prepareToolCallFunction · 0.85

Calls 5

coerceToolResultFunction · 0.85
dispatchToolCallFunction · 0.85
makeResolvedToolCallTaskFunction · 0.85
makeToolResultFunction · 0.85
toolResultStopsTurnFunction · 0.85

Tested by

no test coverage detected