A reply that is nothing but a JSON tool call (optionally in a code fence),
e.g. {"tool": "read_file", "args": {"path": "a.txt"}}. The name may be under
name, tool, tool_name or function, and the input under arguments,
args, parameters or input; a JSON array holds several calls.
Not a default parser, because plain JSON is also a legitimate answer. Opt in
with knownToolsOnly: true so only calls to offered tools are converted:
textToolCalls(p, { parsers: [...defaultToolCallParsers, jsonToolCalls], knownToolsOnly: true }).
A reply that is nothing but a JSON tool call (optionally in a code fence), e.g.
{"tool": "read_file", "args": {"path": "a.txt"}}. The name may be undername,tool,tool_nameorfunction, and the input underarguments,args,parametersorinput; a JSON array holds several calls.Not a default parser, because plain JSON is also a legitimate answer. Opt in with
knownToolsOnly: trueso only calls to offered tools are converted:textToolCalls(p, { parsers: [...defaultToolCallParsers, jsonToolCalls], knownToolsOnly: true }).