Skip to content

How I measured tool calls: an invented company and 120 tasks

Eight working tools on a made-up wholesale company, 120 tasks with one checkable answer each, and seven tool interfaces, one change at a time. The setup, and why each piece is there.

3 min read

To measure how reliably small local models use tools, I first needed an answer key. A real API can't give one: checking means trusting the API, and the model may already know some facts. So I made everything up.

An invented company

The tools act on Quillfen Supply Co., a wholesale company that doesn't exist: 28 contacts, 12 products with stock at 4 warehouses, 60 orders in 5 states, 41 events on a two-week calendar, and a 7-day forecast for 6 invented cities. Today is fixed at Tuesday 2026-03-03 and stated in the system prompt.

Because it's invented, a fact can only come from a tool. Because every tool is a plain Python function with no network, clock or randomness, every task has one answer. Every booking or cancellation is recorded, so a call that changes something it shouldn't is caught.

Eight tools

find_contact, get_order, cancel_order, check_stock, list_events, create_event, convert_units and get_weather. An error has a code, a message and a fix, such as "Closest match in the directory: 'Ilse Corvane'." The tools are lenient in obvious ways (case, spaces, "30" for 30) and strict where a real service would be: order ids must look like ORD-1043, dates must be YYYY-MM-DD.

120 tasks in six kinds

  • 24 single calls.
  • 20 where the wording doesn't match the tool and an argument has to be worked out: "How warm will it get in Harrowfell this Friday?"
  • 20 two-step and 16 three-step chains, where one call's result is the next call's argument.
  • 20 that need no tool: arithmetic, an acronym, or something no tool covers, like booking a train.
  • 20 with an injected error. Some can be fixed (a misspelt name, a clashing booking, a timeout, a bad id format), and some can't (a shipped order, a date beyond the forecast).

They come from 30 seeded templates, and no number the answer needs appears in the request. Before the full run I committed 14 predictions to git.

Seven interfaces, one change each

The baseline follows the usual advice: 8 tools, a one-line description of when to use each, a typed schema with id and date formats, and errors that say how to recover. Each other condition takes one piece away: 3 tools, 20 tools (12 working distractors added), terse descriptions, vague near-duplicate names, free-string arguments, or bare error codes. The tool functions never change, only what the model is told.

Every model runs every task under every condition, so each comparison is paired by task.

Change in task success from each of six interface changes against the baseline, one panel per model, with 95% intervals and a grey band for the noise floor. Almost every point sits within 5 points of zero; three tools instead of eight helps qwen3 8B by about 8 points, and bare error codes cost Gemma 3 about 6.

Models and settings

qwen3 8B and Llama 3.1 8B use Ollama's native tool calling. Gemma 3 12B has no tool support in its Ollama template, so it gets the tools as JSON in the system prompt and replies with a JSON call. To check that the protocol alone doesn't explain the differences, qwen3 ran the baseline both ways and scored 59% and 60%. A 30B qwen3 model with thinking ran three conditions on the first 60 tasks. All 4-bit, temperature 0, seed 7, at most 8 model turns a task: 3,180 episodes in all.

Scored by code

An episode succeeds only if the final answer has every required fact, the state is exactly as required, every required call had the right arguments, and a no-tool task called no tool.

Two checks on the numbers. First, the identical baseline was sent again as separate calls. An effect counts only if its 95% interval (2,000 bootstrap resamples over tasks) excludes zero and it is bigger than that flip rate, which was 0 of 120 for each model. Second, reading failures after the run showed the checker missing some correct answers; I widened it and re-scored every episode, which an earlier post in this series covers. A hand-labelled sample of 80 episodes is drawn and still waiting for labels.

Limits

Small open models with one system prompt, measured as Ollama serves them. Real tool sets are larger and messier than a tidy invented company. Each condition changes one thing, so combinations aren't tested.

The full design is in the case study, and the code is on GitHub. The results regenerate from cached model calls.

All writing
  • LLMs
  • Agents
  • Evaluation
  • Measuring LLM Systems

Get in touch

Questions about my work, a role, or a project idea. Send a message here or email me directly.

Srikarmks@gmail.com