parseToolCall static method
Parse tool call from LLM output.
Useful for manual parsing without automatic execution.
Implementation
static ToolCall? parseToolCall(String llmOutput) {
final result = DartBridgeToolCalling.shared.parseToolCall(llmOutput);
if (!result.hasToolCall || result.toolName == null) {
return null;
}
return ToolCall(
toolName: result.toolName!,
arguments: result.arguments != null
? dynamicMapToToolValueMap(result.arguments!)
: {},
callId: result.callId.toString(),
);
}