clear_dynamic_hints

View as MarkdownOpen in Claude

Remove all dynamically added speech recognition hints. This clears every hint that was previously added via add_dynamic_hints(). Static hints defined on the agent at configuration time are not affected.

Parameters

None.

Returns

FunctionResult — self, for chaining.

Example

1from signalwire import AgentBase
2from signalwire import FunctionResult
3
4agent = AgentBase(name="my-agent", route="/agent")
5agent.set_prompt_text("You are a helpful assistant.")
6
7@agent.tool(name="reset_context", description="Reset speech recognition context")
8def reset_context(args, raw_data):
9 return (
10 FunctionResult("Context reset.")
11 .clear_dynamic_hints()
12 )
13
14agent.serve()