From 7bcffbaf07851ecb993f3e3556f0aca619c9385d Mon Sep 17 00:00:00 2001 From: Vladimir Blagojevic Date: Fri, 10 Jan 2025 10:04:26 +0100 Subject: [PATCH] PR feedback --- docs/pydoc/config/tools_api.yml | 2 +- haystack/tools/component_tool.py | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/docs/pydoc/config/tools_api.yml b/docs/pydoc/config/tools_api.yml index 35aa7aeff8..3d59dbdf49 100644 --- a/docs/pydoc/config/tools_api.yml +++ b/docs/pydoc/config/tools_api.yml @@ -2,7 +2,7 @@ loaders: - type: haystack_pydoc_tools.loaders.CustomPythonLoader search_path: [../../../haystack/tools] modules: - ["tool"] + ["tool", "component_tool"] ignore_when_discovered: ["__init__"] processors: - type: filter diff --git a/haystack/tools/component_tool.py b/haystack/tools/component_tool.py index 2c6d43b038..d3dbdb3014 100644 --- a/haystack/tools/component_tool.py +++ b/haystack/tools/component_tool.py @@ -37,7 +37,12 @@ class ComponentTool(Tool): Key features: - Automatic LLM tool calling schema generation from Component input sockets - Type conversion and validation for Component inputs - - Support for complex types (dataclasses, Pydantic models, lists) + - Support for complex types: + - dataclasses + - custom classes + - Lists of dataclasses or custom classes + - Basic types (str, int, float, bool, dict) + - Lists of basic types - Automatic name generation from Component class name - Description extraction from Component docstrings