8000 Toolsets by DouweM · Pull Request #2024 · pydantic/pydantic-ai · GitHub
[go: up one dir, main page]

Skip to content

Toolsets #2024

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 162 commits into from
Jul 16, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
162 commits
Select commit Hold shift + click to select a range
e290951
WIP: Output modes
DouweM Jun 3, 2025
2056539
WIP: More output modes
DouweM Jun 3, 2025
bceba19
Merge remote-tracking branch 'origin/main' into output-modes
DouweM Jun 3, 2025
0cb25c4
Fix tests
DouweM Jun 3, 2025
933b74e
Remove syntax invalid before Python 3.12
DouweM Jun 3, 2025
7974df0
Fix tests
DouweM Jun 3, 2025
9cc19e2
Add TextOutput marker
DouweM Jun 9, 2025
bc6bb65
Merge remote-tracking branch 'origin/main' into output-modes
DouweM Jun 9, 2025
0e356a3
Add VCR recording of new test
DouweM Jun 9, 2025
81312dc
Implement additional output modes in GeminiModel and GoogleModel
DouweM Jun 10, 2025
52ef4d5
Fix prompted_json on OpenAIResponses
DouweM Jun 10, 2025
fe05956
Test output modes on Gemini and Anthropic
DouweM Jun 10, 2025
94421f3
Add VCR recordings of Gemini output mode tests
DouweM Jun 10, 2025
1902d00
Remove some old TODO comments
DouweM Jun 10, 2025
1f53c9b
Add missing VCR recording of Gemini output mode test
DouweM Jun 10, 2025
a4c2877
Add more missing VCR recordings
DouweM Jun 10, 2025
56e58f9
Fix OpenAI tools
DouweM Jun 10, 2025
a5234e1
Improve test coverage
DouweM Jun 10, 2025
40def08
Update unsupported output mode error message
DouweM Jun 10, 2025
837d305
Improve test coverage
DouweM Jun 10, 2025
3598bef
Merge branch 'main' into output-modes
DouweM Jun 10, 2025
5f71ba8
Test streaming with structured text output
DouweM Jun 10, 2025
cfc2749
Make TextOutputFunction Python 3.9 compatible
DouweM Jun 10, 2025
a137641
Properly merge JSON schemas accounting for defs
DouweM Jun 11, 2025
f495d46
Refactor output schemas and modes: more 'isinstance(output_schema, ..…
DouweM Jun 12, 2025
449ed0d
Merge branch 'main' into output-modes
DouweM Jun 12, 2025
e70d249
Clean up some variable names
DouweM Jun 12, 2025
4592b0b
Improve test coverage
DouweM Jun 12, 2025
db1c628
Merge branch 'main' into output-modes
DouweM Jun 13, 2025
f57d078
Combine JsonSchemaOutput and PromptedJsonOutput into StructuredTextOu…
DouweM Jun 13, 2025
5112455
Add missing cassettes
DouweM Jun 13, 2025
416cc7d
Can't use dataclass kw_only on 3.9
DouweM Jun 13, 2025
4b0e5cf
Improve test coverage
DouweM Jun 13, 2025
094920f
Improve test coverage
DouweM Jun 13, 2025
9f61706
Improve test coverage
DouweM Jun 13, 2025
9f51387
Remove unnecessary coverage ignores
DouweM Jun 13, 2025
9a1e628
Remove unnecessary coverage ignore
DouweM Jun 13, 2025
2b5fa81
Add docs
DouweM Jun 13, 2025
6c4662b
Fix docs refs
DouweM Jun 13, 2025
3ed3431
Fix nested list in docs
DouweM Jun 13, 2025
3d77818
Merge branch 'main' into output-modes
DouweM Jun 17, 2025
a86d7d4
Split StructuredTextOutput into ModelStructuredOutput and PromptedStr…
DouweM Jun 17, 2025
ce985a0
Merge branch 'main' into output-modes
DouweM Jun 17, 2025
71d1655
Fix WrapperModel.profile
DouweM Jun 17, 2025
8c04144
Update output modes docs
DouweM Jun 17, 2025
d78b5f7
Add examples to output mode marker docstrings
DouweM Jun 17, 2025
70d1197
Fix mypy type inference
DouweM Jun 17, 2025
2eb7fd1
Improve test coverage
DouweM Jun 17, 2025
25ccb54
Merge branch 'main' into output-modes
DouweM Jun 17, 2025
9e00c32
Import cast and RunContext in _function_schema
DouweM Jun 17, 2025
7de3c0d
Move RunContext and AgentDepsT into their own module to solve circula…
DouweM Jun 17, 2025
4029fac
Make _run_context module private, RunContext can be accessed through …
DouweM Jun 17, 2025
98bccf2
Merge branch 'main' into output-modes
DouweM Jun 19, 2025
8041cf3
Fix thinking part related tests
DouweM Jun 19, 2025
9bfed04
Implement Toolset
DouweM Jun 20, 2025
0f8da74
Make MCPServer a Toolset
DouweM Jun 20, 2025
8a29836
--no-edit
DouweM Jun 21, 2025
3d2012c
Add MappedToolset
DouweM Jun 21, 2025
901267d
Import Never from typing_extensions instead of typing
DouweM Jun 21, 2025
b9258d7
from __future__ import annotations
DouweM Jun 21, 2025
27ccbd1
Update client.md
DouweM Jun 21, 2025
3031e55
Pass only RunToolset to agent graph
DouweM Jun 21, 2025
ebd0b57
Make WrapperToolset abstract
DouweM Jun 21, 2025
867bf68
Introduce ToolDefinition.kind == 'pending'
DouweM Jun 21, 2025
c1115ae
Rename pending tools to deferred tools
DouweM Jun 21, 2025
6abd603
Merge branch 'main' into toolsets
DouweM Jun 24, 2025
a2f69df
Fix retries
DouweM Jun 24, 2025
0e0bf35
Remove duplicate cassettes
DouweM Jun 24, 2025
735df29
Merge branch 'main' into toolsets
DouweM Jun 26, 2025
8745a7a
Pass just one toolset into the run
DouweM Jun 26, 2025
05aa972
WIP
DouweM Jun 26, 2025
ad6e826
Fix streaming tool calls
DouweM Jun 27, 2025
84cd954
Stop double counting retries and reset on success
DouweM Jun 27, 2025
74a56ae
Fix retry error wrapping
DouweM Jun 27, 2025
0360e77
Make DeferredToolCalls work with streaming
DouweM Jun 30, 2025
6607b00
Merge branch 'main' into toolsets
DouweM Jun 30, 2025
8a3febb
Let toolsets be overridden in run/iter/run_stream/run_sync
DouweM Jun 30, 2025
2e200ac
Add DeferredToolset
DouweM Jun 30, 2025
1cb7f32
Add LangChainToolset
DouweM Jun 30, 2025
a6eba43
Add Agent.prepare_output_tools
DouweM Jun 30, 2025
0c96126
Require WrapperToolset subclasses to implement their own prepare_for_run
DouweM Jul 1, 2025
2348f45
Require DeferredToolCalls to be used with other output type
DouweM Jul 1, 2025
9dc684e
Merge branch 'main' into toolsets
DouweM Jul 1, 2025
f3124c0
Lots of cleanup
DouweM Jul 1, 2025
f660cc1
Some more tweaks
DouweM Jul 2, 2025
64dacbb
Merge branch 'main' into toolsets
DouweM Jul 2, 2025
5ca305e
Fix docs example
DouweM Jul 2, 2025
c5ef5f6
Address some feedback
DouweM Jul 2, 2025
badbe23
Merge branch 'main' into toolsets
DouweM Jul 2, 2025
acddb8d
Add sampling_model to Agent __init__, iter, run (etc), and override, …
DouweM Jul 2, 2025
89fc266
Turn RunContext.retries from a defaultdict into a dict again as the 0…
DouweM Jul 2, 2025
7e3331b
Remove unnecessary if TYPE_CHECKING
DouweM Jul 2, 2025
ebf6f40
Remove Agent sampling_model field (and method argument) in favor of A…
DouweM Jul 3, 2025
f7db040
Allow OutputSpec to be nested
DouweM Jul 3, 2025
fe07149
Document Agent.__aenter__
DouweM Jul 3, 2025
a0f4678
Import Self from typing_extensions instead of typing
DouweM Jul 3, 2025
db82d00
Actually use Agent.prepare_output_tools
DouweM Jul 4, 2025
dea8050
Update test to account for fact that text output with early end_strat…
DouweM Jul 4, 2025
131a325
Improve test coverage
DouweM Jul 4, 2025
8203732
Merge branch 'main' into toolsets
DouweM Jul 4, 2025
778962c
Make Agent MCP-related tests only run when mcp can be imported
DouweM Jul 4, 2025
e6575a9
Add tests
DouweM Jul 4, 2025
9f9ee55
AbstractToolset.call_tool now takes a ToolCallPart
DouweM Jul 4, 2025
a3c9a59
Fix MCP process_tool_call example
DouweM Jul 4, 2025
6eae653
Fix test coverage
DouweM Jul 4, 2025
2b3a9e5
Merge branch 'main' into toolsets
DouweM Jul 4, 2025
b2aa894
Improve coverage
DouweM Jul 4, 2025
ecf6f75
Merge branch 'main' into toolsets
DouweM Jul 8, 2025
1c2d221
Address feedback
DouweM Jul 8, 2025
ca4915b
Make test_docs_examples an async test so Python 3.9 lets us instantia…
DouweM Jul 8, 2025
972e4a7
Merge branch 'main' into toolsets
DouweM Jul 8, 2025
93bb682
Fix test snapshots
DouweM Jul 8, 2025
8a986be
Revert "Make test_docs_examples an async test so Python 3.9 lets us i…
DouweM Jul 8, 2025
9c399c7
Make asyncio.Lock work in Python 3.9 when there is no event loop yet
DouweM Jul 8, 2025
a4f8c48
Address feedback, fix docs test
DouweM Jul 8, 2025
3e1847f
Give the A2A task some more time to complete
DouweM Jul 8, 2025
4daa152
Branch is OK to not be covered
DouweM Jul 8, 2025
c5c6f00
agent.iter(toolsets=...) is now additional, while new agent.override(…
DouweM Jul 9, 2025
f9ba559
Respect overridden toolsets in Agent.__aenter__ and Agent.set_mcp_sam…
DouweM Jul 9, 2025
b165503
Fix tool conflict error message
DouweM Jul 9, 2025
4baa710
Rename FunctionToolset.register_{tool,function} to add_{tool,function}
DouweM Jul 9, 2025
39e0353
Branch is OK to not be covered
DouweM Jul 9, 2025
18fcdf7
Add test to ensure tools can be added during a run
DouweM Jul 9, 2025
af6ce7d
Make CallableToolset public as we're going to want to let people defi…
DouweM Jul 9, 2025
93e6691
Make it easier to override tool call behavior by subclassing WrapperT…
DouweM Jul 10, 2025
3a4c4c8
Start writing docs
DouweM Jul 10, 2025
87aaa6c
Make WrapperToolset easier to subclass with new _rewrap_for_run method
DouweM Jul 10, 2025
8b81e65
Add classes I forget to add and push
DouweM Jul 10, 2025
e72548e
Make all public toolsets importable from pydantic_ai.toolsets
DouweM Jul 10, 2025
b8c93f1
Add ACIToolset
DouweM Jul 10, 2025
f87319c
Document LangChainToolset and ACIToolset
DouweM Jul 10, 2025
8136441
Merge branch 'main' into toolsets
DouweM Jul 10, 2025
239fc3d
Toolset._call_tool is always async
DouweM Jul 10, 2025
febbd08
A WrapperToolset subclass with no additional fields does not need to …
DouweM Jul 10, 2025
cfa9ccc
Add some more docs
DouweM Jul 10, 2025
50a72a0
Merge branch 'main' into toolsets
DouweM Jul 10, 2025
0151e20
Mostly finish docs
DouweM Jul 11, 2025
d27b4ec
Fix FunctionToolset.max_retries
DouweM Jul 11, 2025
692898e
Fix docs example output
DouweM Jul 11, 2025
06838e2
Make AbstractToolset overridable methods public
DouweM Jul 15, 2025
215eaae
Merge branch 'main' into toolsets
DouweM Jul 15, 2025
8018600
Merge remote-tracking branch 'origin/toolsets' into toolsets
Do 8000 uweM Jul 15, 2025
b2637f8
WIP
DouweM Jul 15, 2025
a25df7f
WIP
DouweM Jul 15, 2025
13d9c03
Remove AbstractToolset.for_run_step
DouweM Jul 15, 2025
ac5f77d
Rename AbstractToolset.accept to apply
DouweM Jul 15, 2025
0c8b25a
Fix toolsets docs
DouweM Jul 15, 2025
6046a1c
Fix example for 3.9
DouweM Jul 15, 2025
70d24da
Update docs
DouweM Jul 15, 2025
a4dedb3
Improve coverage
DouweM Jul 15, 2025
f48bd73
Improve docstrings
DouweM Jul 15, 2025
a4e0c04
Improve docstrings
DouweM Jul 16, 2025
fef897d
Fix docs link
DouweM Jul 16, 2025
9d3d240
Fix docs links
DouweM Jul 16, 2025
f3d1ae0
Add filtered, prefixed, prepared, renamed and wrap convenience method…
DouweM Jul 16, 2025
f756132
Merge branch 'main' into toolsets
DouweM Jul 16, 2025
57b0720
Move tool call tracing to ToolManager
DouweM Jul 16, 2025
e2e0f58
Merge branch 'main' into toolsets
DouweM Jul 16, 2025
7830c73
Fix huggingface_hub.AsyncInferenceClient link in docs
DouweM Jul 16, 2025
c9c8873
Add huggingface doc to nav
DouweM Jul 16, 2025
7e4629e
Fix coverage
DouweM Jul 16, 2025
28c753d
Fix coverage
DouweM Jul 16, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Rename pending tools to deferred tools
  • Loading branch information
DouweM committed Jun 21, 2025
commit c1115aece71a36f9c51f24e7f8a086c75d5d7630
22 changes: 11 additions & 11 deletions pydantic_ai_slim/pydantic_ai/_agent_graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
from pydantic_graph.nodes import End, NodeRunEndT

from . import _output, _system_prompt, exceptions, messages as _messages, models, result, usage as _usage
from .output import OutputDataT, OutputSpec, PendingToolCalls
from .output import DeferredToolCalls, OutputDataT, OutputSpec
from .settings import ModelSettings, merge_model_settings
from .tools import RunContext, ToolDefinition, ToolKind

Expand Down Expand Up @@ -549,8 +549,8 @@ async def _handle_tool_calls( # noqa: C901
):
yield event

pending_calls: list[_messages.ToolCallPart] = []
for call in tool_calls_by_kind['pending']:
deferred_calls: list[_messages.ToolCallPart] = []
for call in tool_calls_by_kind['deferred']:
if final_result:
parts.append(
_messages.ToolReturnPart(
Expand All @@ -561,19 +561,19 @@ async def _handle_tool_calls( # noqa: C901
)
else:
yield _messages.FunctionToolCallEvent(call)
pending_calls.append(call)
deferred_calls.append(call)

if pending_calls:
if not ctx.deps.output_schema.pending_tool_calls:
if deferred_calls:
if not ctx.deps.output_schema.deferred_tool_calls:
raise exceptions.UserError(
'There are pending tool calls but PendingToolCalls is not among output types.'
'There are pending tool calls but DeferredToolCalls is not among output types.'
)

pending_tool_names = [call.tool_name for call in pending_calls]
pending_tool_defs = {
tool_def.name: tool_def for tool_def in toolset.tool_defs if tool_def.name in pending_tool_names
deferred_tool_names = [call.tool_name for call in deferred_calls]
deferred_tool_defs = {
tool_def.name: tool_def for tool_def in toolset.tool_defs if tool_def.name in deferred_tool_names
}
output_data = cast(NodeRunEndT, PendingToolCalls(pending_calls, pending_tool_defs))
output_data = cast(NodeRunEndT, DeferredToolCalls(deferred_calls, deferred_tool_defs))
final_result = result.FinalResult(output_data)

if final_result:
Expand Down
40 changes: 21 additions & 19 deletions pydantic_ai_slim/pydantic_ai/_output.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
from ._run_context import AgentDepsT, RunContext
from .exceptions import ModelRetry, UserError
from .output import (
DeferredToolCalls,
ModelStructuredOutput,
OutputDataT,
OutputMode,
OutputSpec,
OutputTypeOrFunction,
PendingToolCalls,
PromptedStructuredOutput,
StructuredOutputMode,
TextOutput,
Expand Down Expand Up @@ -129,7 +129,7 @@ async def validate(

@dataclass
class BaseOutputSchema(ABC, Generic[OutputDataT]):
pending_tool_calls: bool
deferred_tool_calls: bool

@abstractmethod
def with_default_mode(self, mode: StructuredOutputMode) -> OutputSchema[OutputDataT]:
Expand Down Expand Up @@ -182,8 +182,8 @@ def build( # noqa: C901
"""Build an OutputSchema dataclass from an output type."""
raw_outputs = _flatten_output_spec(output_spec)

outputs = [output for output in raw_outputs if output is not PendingToolCalls]
pending_tool_calls = len(outputs) < len(raw_outputs)
outputs = [output for output in raw_outputs if output is not DeferredToolCalls]
deferred_tool_calls = len(outputs) < len(raw_outputs)
if output := next((output for output in outputs if isinstance(output, ModelStructuredOutput)), None):
if len(outputs) > 1:
raise UserError('ModelStructuredOutput cannot be mixed with other output types.')
Expand All @@ -194,7 +194,7 @@ def build( # noqa: C901
name=output.name,
description=output.description,
),
pending_tool_calls=pending_tool_calls,
deferred_tool_calls=deferred_tool_calls,
)
elif output := next((output for output in outputs if isinstance(output, PromptedStructuredOutput)), None):
if len(outputs) > 1:
Expand All @@ -207,7 +207,7 @@ def build( # noqa: C901
description=output.description,
),
template=output.template,
pending_tool_calls=pending_tool_calls,
deferred_tool_calls=deferred_tool_calls,
)

text_outputs: Sequence[type[str] | TextOutput[OutputDataT]] = []
Expand Down Expand Up @@ -240,20 +240,20 @@ def build( # noqa: C901
text_output_schema = PlainTextOutputProcessor(text_output.output_function)

if len(tools) == 0:
return PlainTextOutputSchema(processor=text_output_schema, pending_tool_calls=pending_tool_calls)
return PlainTextOutputSchema(processor=text_output_schema, deferred_tool_calls=deferred_tool_calls)
else:
return ToolOrTextOutputSchema(
processor=text_output_schema, tools=tools, pending_tool_calls=pending_tool_calls
processor=text_output_schema, tools=tools, deferred_tool_calls=deferred_tool_calls
)

if len(tool_outputs) > 0:
return ToolOutputSchema(tools=tools, pending_tool_calls=pending_tool_calls)
return ToolOutputSchema(tools=tools, deferred_tool_calls=deferred_tool_calls)

if len(other_outputs) > 0:
schema = OutputSchemaWithoutMode(
processor=cls._build_processor(other_outputs, name=name, description=description, strict=strict),
tools=tools,
pending_tool_calls=pending_tool_calls,
deferred_tool_calls=deferred_tool_calls,
)
if default_mode:
schema = schema.with_default_mode(default_mode)
Expand Down Expand Up @@ -343,19 +343,21 @@ def __init__(
self,
processor: ObjectOutputProcessor[OutputDataT] | UnionOutputProcessor[OutputDataT],
tools: dict[str, OutputTool[OutputDataT]],
pending_tool_calls: bool,
deferred_tool_calls: bool,
):
super().__init__(pending_tool_calls)
super().__init__(deferred_tool_calls)
self.processor = processor
self._tools = tools

def with_default_mode(self, mode: StructuredOutputMode) -> OutputSchema[OutputDataT]:
if mode == 'model_structured':
return ModelStructuredOutputSchema(processor=self.processor, pending_tool_calls=self.pending_tool_calls)
return ModelStructuredOutputSchema(processor=self.processor, deferred_tool_calls=self.deferred_tool_calls)
elif mode == 'prompted_structured':
return PromptedStructuredOutputSchema(processor=self.processor, pending_tool_calls=self.pending_tool_calls)
return PromptedStructuredOutputSchema(
processor=self.processor, deferred_tool_calls=self.deferred_tool_calls
)
elif mode == 'tool':
return ToolOutputSchema(tools=self.tools, pending_tool_calls=self.pending_tool_calls)
return ToolOutputSchema(tools=self.tools, deferred_tool_calls=self.deferred_tool_calls)
else:
assert_never(mode)

Expand Down Expand Up @@ -517,8 +519,8 @@ async def process(
class ToolOutputSchema(OutputSchema[OutputDataT]):
_tools: dict[str, OutputTool[OutputDataT]] = field(default_factory=dict)

def __init__(self, tools: dict[str, OutputTool[OutputDataT]], pending_tool_calls: bool):
super().__init__(pending_tool_calls)
def __init__(self, tools: dict[str, OutputTool[OutputDataT]], deferred_tool_calls: bool):
super().__init__(deferred_tool_calls)
self._tools = tools

@property
Expand Down Expand Up @@ -561,9 +563,9 @@ def __init__(
self,
processor: PlainTextOutputProcessor[OutputDataT] | None,
tools: dict[str, OutputTool[OutputDataT]],
pending_tool_calls: bool,
deferred_tool_calls: bool,
):
super().__init__(tools=tools, pending_tool_calls=pending_tool_calls)
super().__init__(tools=tools, deferred_tool_calls=deferred_tool_calls)
self.processor = processor

@property
Expand Down
2 changes: 1 addition & 1 deletion pydantic_ai_slim/pydantic_ai/output.py
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ def split_into_words(text: str) -> list[str]:


@dataclass
class PendingToolCalls:
class DeferredToolCalls:
"""Output type for calls to tools defined as pending."""

tool_calls: list[ToolCallPart]
Expand Down
2 changes: 1 addition & 1 deletion pydantic_ai_slim/pydantic_ai/tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ async def prepare_tool_def(self, ctx: RunContext[AgentDepsT]) -> ToolDefinition
With PEP-728 this should be a TypedDict with `type: Literal['object']`, and `extra_parts=Any`
"""

ToolKind: TypeAlias = Literal['function', 'output', 'pending']
ToolKind: TypeAlias = Literal['function', 'output', 'deferred']
"""Kind of tool."""


Expand Down
12 changes: 6 additions & 6 deletions tests/test_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
from pydantic_ai.messages import ModelMessage, ModelRequest, ModelResponse, TextPart, ToolCallPart, ToolReturnPart
from pydantic_ai.models.function import AgentInfo, FunctionModel
from pydantic_ai.models.test import TestModel
from pydantic_ai.output import PendingToolCalls, ToolOutput
from pydantic_ai.output import DeferredToolCalls, ToolOutput
from pydantic_ai.tools import ToolDefinition

from .conftest import IsStr
Expand Down Expand Up @@ -1180,19 +1180,19 @@ def infinite_retry_tool(ctx: RunContext[None]) -> int:
assert call_retries == [0, 1, 2, 3, 4, 5]


def test_pending_tool():
agent = Agent(TestModel(), output_type=[str, PendingToolCalls])
def test_deferred_tool():
agent = Agent(TestModel(), output_type=[str, DeferredToolCalls])

async def prepare_tool(ctx: RunContext[None], tool_def: ToolDefinition) -> ToolDefinition:
return replace(tool_def, kind='pending')
return replace(tool_def, kind='deferred')

@agent.tool_plain(prepare=prepare_tool)
def my_tool(x: int) -> int:
return x + 1

result = agent.run_sync('Hello')
assert result.output == snapshot(
PendingToolCalls(
DeferredToolCalls(
tool_calls=[ToolCallPart(tool_name='my_tool', args={'x': 0}, tool_call_id=IsStr())],
tool_defs={
'my_tool': ToolDefinition(
Expand All @@ -1204,7 +1204,7 @@ def my_tool(x: int) -> int:
'required': ['x'],
'type': 'object',
},
kind='pending',
kind='deferred',
)
},
)
Expand Down
Loading
0