diff --git a/examples/function-calling/function-calling-anthropic-async.py b/examples/function-calling/function-calling-anthropic-async.py index 979ebcd59..b727cbd13 100644 --- a/examples/function-calling/function-calling-anthropic-async.py +++ b/examples/function-calling/function-calling-anthropic-async.py @@ -77,6 +77,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): llm = AnthropicLLMService( api_key=os.getenv("ANTHROPIC_API_KEY"), + enable_async_tool_cancellation=True, settings=AnthropicLLMService.Settings( system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.", ), diff --git a/examples/function-calling/function-calling-google-async-stream.py b/examples/function-calling/function-calling-google-async-stream.py index 0a2a1e831..c8d0f87db 100644 --- a/examples/function-calling/function-calling-google-async-stream.py +++ b/examples/function-calling/function-calling-google-async-stream.py @@ -118,6 +118,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): llm = GoogleLLMService( api_key=os.getenv("GOOGLE_API_KEY"), + enable_async_tool_cancellation=True, settings=GoogleLLMService.Settings( system_instruction=( "You are a helpful assistant in a voice conversation. " diff --git a/examples/function-calling/function-calling-google-async.py b/examples/function-calling/function-calling-google-async.py index 1b717d4f1..6892d4abd 100644 --- a/examples/function-calling/function-calling-google-async.py +++ b/examples/function-calling/function-calling-google-async.py @@ -128,6 +128,7 @@ indicate you should use the get_image tool are: llm = GoogleLLMService( api_key=os.getenv("GOOGLE_API_KEY"), + enable_async_tool_cancellation=True, settings=GoogleLLMService.Settings( system_instruction=system_prompt, ), diff --git a/examples/function-calling/function-calling-openai-async-stream.py b/examples/function-calling/function-calling-openai-async-stream.py index 5b4412489..1a3a6317b 100644 --- a/examples/function-calling/function-calling-openai-async-stream.py +++ b/examples/function-calling/function-calling-openai-async-stream.py @@ -118,6 +118,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): llm = OpenAILLMService( api_key=os.getenv("OPENAI_API_KEY"), + enable_async_tool_cancellation=True, settings=OpenAILLMService.Settings( system_instruction=( "You are a helpful assistant in a voice conversation. " diff --git a/examples/function-calling/function-calling-openai-async.py b/examples/function-calling/function-calling-openai-async.py index b5c5b83ac..7a7bd5ddd 100644 --- a/examples/function-calling/function-calling-openai-async.py +++ b/examples/function-calling/function-calling-openai-async.py @@ -87,6 +87,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): llm = OpenAILLMService( api_key=os.getenv("OPENAI_API_KEY"), + enable_async_tool_cancellation=True, settings=OpenAILLMService.Settings( system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.", ), diff --git a/examples/function-calling/function-calling-openai-responses-async-stream.py b/examples/function-calling/function-calling-openai-responses-async-stream.py index 0862e4813..5bdde5cb3 100644 --- a/examples/function-calling/function-calling-openai-responses-async-stream.py +++ b/examples/function-calling/function-calling-openai-responses-async-stream.py @@ -118,6 +118,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): llm = OpenAIResponsesLLMService( api_key=os.getenv("OPENAI_API_KEY"), + enable_async_tool_cancellation=True, settings=OpenAIResponsesLLMService.Settings( system_instruction=( "You are a helpful assistant in a voice conversation. " diff --git a/examples/function-calling/function-calling-openai-responses-async.py b/examples/function-calling/function-calling-openai-responses-async.py index ba984bc04..16b21f212 100644 --- a/examples/function-calling/function-calling-openai-responses-async.py +++ b/examples/function-calling/function-calling-openai-responses-async.py @@ -77,6 +77,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): llm = OpenAIResponsesLLMService( api_key=os.getenv("OPENAI_API_KEY"), + enable_async_tool_cancellation=True, settings=OpenAIResponsesLLMService.Settings( system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.", ),