mirror of
https://github.com/block/goose.git
synced 2026-07-09 16:09:22 +00:00
fix(acp): include structuredContent from MCP tool response (#10128)
This commit is contained in:
parent
402ff562b3
commit
de331d78ef
1 changed files with 7 additions and 1 deletions
|
|
@ -184,11 +184,17 @@ function toolResultValue(
|
|||
update: ToolCallUpdate,
|
||||
mcpAppMeta: DesktopMcpAppMeta | undefined
|
||||
): ToolResultValue {
|
||||
return {
|
||||
const toolResult: ToolResultValue = {
|
||||
content: toolResultContent(update),
|
||||
isError: false,
|
||||
...(mcpAppMeta ? { _meta: mcpAppMeta } : {}),
|
||||
};
|
||||
|
||||
if (update.rawOutput !== undefined) {
|
||||
toolResult.structuredContent = update.rawOutput;
|
||||
}
|
||||
|
||||
return toolResult;
|
||||
}
|
||||
|
||||
function toolResultContent(update: ToolCallUpdate): GooseContentBlock[] {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue