class ToolResult:
Special result type for tools that can return images along with text.
This class is used by ChatAgent to detect when a tool returns visual content that should be included in the conversation context.
def __init__(self, text: str, images: Optional[List[str]] = None):
Initialize a tool result.
Parameters:
def __str__(self):
Return the text representation of the result.
def __repr__(self):
Return a detailed representation of the result.