Blocking Messages before Tool Calls
# support
a
Quick question, where do i put this in the JSON for a transient agent? Blocking Messages before Tool Calls: You can now configure your tool calls to wait until a message is fully spoken before starting with ToolMessageStart.blocking=true seems cool? Does this mean that it wont call the tool until the agent has fully spoken? I notice that it can interrupt itself when calling a tool in the middle of it speaking, does this fix that issue? Thanks!
k
Yes, setting blocking: true in a ToolMessageStart message means the tool won't execute until the agent has finished speaking that message completely. This helps prevent the agent from interrupting itself mid-speech when making tool calls. Here's how to configure it in your JSON for a transient agent:
Copy code
{
  "tools": [
    {
      "type": "function", // or any other tool type
      "messages": [
        {
          "type": "request-start",
          "content": "Let me check that for you...",
          "blocking": true
        }
      ]
      // ... other tool configuration
    }
  ]
}
when blocking is true, the tool call will wait for the onComplete callback after the message is spoken before proceeding.
a
AWESOME thanks @Shubham Bajaj this is awesome