fromJson static method

AgentDescription fromJson(
  1. Map<String, dynamic> a
)

Implementation

static AgentDescription fromJson(Map<String, dynamic> a) {
  return AgentDescription(
    description: a["description"] ?? "",
    title: a["title"] ?? "",
    name: a["name"],
    inputSchema: a["input_schema"],
    outputSchema: a["output_schema"],
    supportsTools: a["supports_tools"] == true,
    labels: a["labels"]?.whereType<String>().toList(),
    annotations: (a["annotations"] as Map?)?.cast<String, dynamic>(),
  );
}