NTILC: Neural Tool Invocation via Learned Compression
NTILC is a neural framework that replaces linear in-context tool registry lookups with learned latent retrieval and a signature-aware composite objective, achieving over 95% context token reduction and up to 74% lower latency while maintaining high selection accuracy for agentic tool-calling models.
Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer
Imagine you are a highly skilled personal assistant (the AI) who needs to get things done for you. To do this, you have a massive phone book (the Tool Registry) containing thousands of different services: weather reports, calculators, file editors, web searchers, and more.
The Old Way: The "Read-Everything" Approach
Currently, when you ask your assistant a question like, "What's the weather in Ann Arbor?", the assistant has to read the entire phone book out loud before it can answer.
- The Problem: If your phone book has 5,000 entries, that's a lot of reading! It takes a long time (latency), costs a lot of money (token usage), and the assistant gets confused by all the irrelevant information (like reading about "file editing" when you just want the weather).
- The Result: As the phone book grows, the assistant gets slower and makes more mistakes because it's overwhelmed by the noise.
The New Way: NTILC (The "Smart Index" Approach)
The paper introduces NTILC, a new system that changes how the assistant finds the right tool. Instead of reading the whole phone book, NTILC uses a smart, pre-made index (like a digital library catalog).
Here is how it works, step-by-step:
- The Request: You ask, "What's the weather?"
- The Translation: Instead of reading the whole book, the system instantly translates your question into a "secret code" (an embedding) that represents the intent of your request.
- The Match: It compares your secret code against a pre-computed list of secret codes for every tool in the registry. It finds the closest match (the weather tool) in a split second.
- The Action: The assistant only looks at the specific page for the weather tool to get the details it needs to give you an answer.
The Magic Trick: The assistant never has to read the 5,000-page phone book. It only reads the one page it needs. This cuts the "reading time" (context usage) by over 95% and makes the process much faster.
The Tricky Part: "Semantic Blur"
There is a specific problem the paper solves. Imagine two tools in your phone book:
- Tool A: "Get Weather" (requires a zip code).
- Tool B: "Get Weather" (requires latitude and longitude).
They sound exactly the same! If the assistant just looks at the names, it might pick the wrong one. If you give it a zip code, but it picks the tool that needs latitude/longitude, the tool will fail. The paper calls this "Semantic Blur"—when tools look the same but work differently.
The Solution: The "Functional Margin"
NTILC uses a special training method called Functional Margin Loss. Think of this as a strict teacher who doesn't just teach the assistant to recognize the name of the tool, but also to feel the shape of the tool.
- Even if two tools have the same name, if their "shapes" (the arguments they need) are different, the system pushes them far apart in its memory.
- This ensures that when you ask for "Weather with a zip code," the system knows exactly which of the two "Weather" tools to pick, avoiding the wrong one.
The Results
The paper tested this on several public datasets (like ToolBench and API-Bank) and found:
- Speed: It is up to 74% faster than the old method.
- Efficiency: It reduces the amount of "reading" the AI has to do by over 95%.
- Accuracy: It is just as accurate as the old method, even when the phone book gets huge (thousands of tools).
Summary
NTILC is like upgrading from a librarian who reads every single book in the library to find your answer, to a librarian who has a perfect, instant index. They know exactly which book you need without ever opening the others, saving time and preventing confusion, even when the library grows to millions of books.
Drowning in papers in your field?
Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.