Skip to content

Commit 97ab44b

Browse files
committed
make AbstractBuiltinTool serializable
1 parent 57e568b commit 97ab44b

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

pydantic_ai_slim/pydantic_ai/builtin_tools.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
__all__ = ('AbstractBuiltinTool', 'WebSearchTool', 'UserLocation')
1010

1111

12+
@dataclass
1213
class AbstractBuiltinTool(ABC):
1314
"""A builtin tool that can be used by an agent.
1415

tests/models/test_model_request_parameters.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ def test_model_request_parameters_are_serializable():
77
params = ModelRequestParameters(function_tools=[], allow_text_output=False, output_tools=[])
88
assert TypeAdapter(ModelRequestParameters).dump_python(params) == {
99
'function_tools': [],
10+
'builtin_tools': [],
1011
'allow_text_output': False,
1112
'output_tools': [],
1213
}

0 commit comments

Comments
 (0)