Urgent.News

What's breaking now, across hundreds of outlets.

Tech

Your Agent Isn't Bad at Tools. Your Tool Descriptions Are.

Your Agent Isn't Bad at Tools. Your Tool Descriptions Are. Every vendor demo shows an agent gliding through tool calls like it was born to it. Then you ship one, and it calls the wrong endpoint, invents an argument your schema never asked for, and retries the same broken call until your budget screams. The model isn't the problem. The contract you handed it is. Reliable tool selection isn't a…

Your agent may be skilled, but the issue lies in the quality of your tool descriptions. It is not the model's fault when it calls the wrong endpoint, generates unnecessary arguments, or retries a broken call repeatedly. The problem stems from the contract you provide to the model.

Reliable tool selection is not achieved through a more intelligent model; it requires better description, a more precise schema, and a validation gate. Most teams overlook these factors and then blame the LLM for the failure.

The description serves as the documentation for the model, which only receives a name, a paragraph of text, and a JSON schema. This limited documentation often leads to inaccurate routing between similar tools. Anthropic emphasizes the importance of providing detailed descriptions, stating that it is the most critical factor in tool performance.

When tools overlap, and the model cannot determine which one to use, it is left to guess, often resulting in incorrect predictions in a production environment. A loose schema invites the model to generate incorrect arguments, while a tight schema prevents a wide range of faulty calls from being executed.

Structured Outputs in OpenAI ensure that arguments match your schema, but shape alone is not correctness. Even if the call is perfectly structured, selecting the wrong tool will still result in an error. Therefore, validation must occur in your own code before executing the call.

Validation acts as the gate between the model's output and your systems. If the tool name is unknown, a required argument is missing, or the wrong type is provided, the call should be rejected safely, providing no side effects and returning a specific error indicating what failed, which field was involved, and what constitutes a valid call.

Every call, even those that fail, should receive a result, including the specific error details. Swallowing errors leads to agents confidently reporting refunds they never issued. With up to 512 tools declared in a single request, 512 tools should be a ceiling, not a target. A dozen well-described tools with distinct purposes will be selected far more reliably than a hundred overlapping ones.

As the catalogue grows, narrow the set offered on each turn to what that step can plausibly require, or implement a router in front of it.

In conclusion, an agent that "usually works" is not suitable for user interaction. The difference between a demo and a deployable tool loop lies in the often overlooked but essential plumbing: providing accurate descriptions, constraining with schemas, validating before execution, returning honest errors to the model, and enforcing a stop condition to prevent loops. Implement these practices, and the model will perform brilliantly. Neglect them, and no amount of prompt engineering can save you.

Rewritten by urgent.news; may contain errors — check the original.

Source: dev.to

Read the original at dev.to →

More from Dev.to on urgent.news

Get the news by email. Yesterday's most-covered stories, every morning.

See today's edition · More options

More in Tech

How to migrate from nextjs-mf to the Next.js App Router

If @module-federation/nextjs-mf is the reason your app is still on the Pages Router, you can move the federation integration first and move routes afterward.

  • Isolate UI components and move to remote build servers
  • Create Vite remote project with exposed UI components
  • Replace old import paths with createRemoteComponent wrapper

What is Next Federation, and when is it worth using?

I built Next Federation for Next.js teams that want to deploy part of a page on its own schedule. A Next.js app hosts the page. A separately deployed app provides a piece of UI.

  • Next Federation allows separate UI deployments in Next.js apps.
  • Supports both App Router and Pages Router with Turbopack or webpack.
  • Simplifies integration, but adds runtime composition complexity.

Windows certificate inventory with PowerShell: RSA and ECC

Start with one service. Its Windows certificate store can contain an expired certificate, the replacement waiting for a maintenance window, and a certificate issued for an entirely different…

  • PowerShell can inventory Windows certificates in personal store
  • Certificates have RSA or ECC public key algorithms
  • Verify TLS termination point and fingerprint comparison for secure connections

More from Saturday, 5 December 2026 →