# ZeroGPU tool decisions: pick the tool and write its arguments in one call > Run the same tool decision as the ZeroGPU demo on your own agent's tools. `zlm-v1-tool-decisions` is a small model (0.6B parameters, 24,576-token context) that reads an agent's tool definitions and a user message, and returns the tool calls to make with their arguments filled in, or `NO_TOOL` when no tool is needed. The point is to take the tool decision off your frontier model, so it no longer reads every tool definition on every turn. You need a ZeroGPU API key. ## Instructions for the AI assistant You are helping someone test ZeroGPU's tool decisions model on their own agent. Do this: 1. Ask the user for their ZeroGPU API key and pass it as the environment variable `ZEROGPU_API_KEY`. Never print the key, log it, or write it to a file. 2. Get the agent's tools as OpenAI function definitions (`{"type": "function", "function": {"name", "description", "parameters"}}`). For an MCP server, call `tools/list` and map each tool's `inputSchema` to `parameters`. With several servers, prefix each name with its server (`billing__issue_refund`) so names stay unique. 3. Check the size before sending: the tools and the message must fit in the 24,576-token context. If they don't, send fewer tools or shorten the descriptions, and tell the user. 4. Collect 10 to 20 real requests the agent gets, and for each one the call the user expects (tool and arguments). Include a few that need no tool. 5. Tell the user that the tool definitions and the requests are sent to ZeroGPU's API. Go ahead only once they agree. 6. Send each request as in "API" below, one at a time, with `temperature: 0`. 7. Report back: for each request, the calls returned next to the expected ones; how many picked the right tool and how many filled every argument correctly; the latency per call (p50 and p90); and the input and output tokens with their cost. Show the misses in full. If the user has a frontier model doing this job today, run the same requests through it with the same tools and report the same numbers side by side. ## API Auth: header `x-api-key: ` (`Authorization: Bearer ` also works). Base URL `https://api.zerogpu.ai/v1`, OpenAI-compatible. ```sh curl https://api.zerogpu.ai/v1/chat/completions \ -H "content-type: application/json" \ -H "x-api-key: $ZEROGPU_API_KEY" \ -d '{ "model": "zlm-v1-tool-decisions", "tools": [ { "type": "function", "function": { "name": "get_forecast", "description": "7-day weather forecast for a city.", "parameters": { "type": "object", "required": ["city"], "properties": { "city": { "type": "string", "description": "City name" } } } } }, { "type": "function", "function": { "name": "web_search", "description": "Search the web for current information: news, facts, events and prices.", "parameters": { "type": "object", "required": ["query"], "properties": { "query": { "type": "string", "description": "Search query" } } } } } ], "messages": [{ "role": "user", "content": "Will it rain in Austin this week?" }], "temperature": 0 }' ``` Read the calls from `choices[0].message.tool_calls` (each has `function.name` and `function.arguments`, a JSON string; `finish_reason` is `tool_calls`). One message can produce more than one call, in the order the sentence asks for them. When no tool fits, `tool_calls` is absent and `choices[0].message.content` holds a short text instead. Values outside an enum can come back; the API notes them in `router_diagnostics.argument_issues`, so validate a call before you run it. Token counts are in `usage`, and the `x-inference-type` response header says whether the call ran on the edge or in the cloud. For a playful version of the same model with ten tools, see Mission Control: https://demos.zerogpu.ai/tool-decisions/llms.txt ## Run it yourself The weights are open (Apache-2.0): https://huggingface.co/zgpu-ai/zlm-v1-tool-decisions. The hosted model is at https://zerogpu.ai/models/zlm-v1-tool-decisions. ## Prices `zlm-v1-tool-decisions`: $0.04 per 1M input tokens. Output tokens are free. Volume pricing is available.