Skip to main content
Glama

benchmark_local

Read-onlyIdempotent

Benchmarks an ONNX model on the current machine with ONNX Runtime and checks FPS, P95 latency, model size, and provider constraints to produce a deployment PASS/FAIL result.

Instructions

Benchmark an ONNX model on the current machine with ONNX Runtime and optionally evaluate deployment constraints. Without provider, CUDA is tried when listed and CPU is used if it fails to load.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "model": "<model>"
    },
    "name": "benchmark_local"
  }
}

Input Schema

NameRequiredDescriptionDefault
runsNo
modelYesAbsolute path to the .onnx model file
minFpsNo
warmupNo
maxP95MsNo
providerNo
maxModelMbNo
inputShapesNoPer-input shape overrides for dynamic models, e.g. {"images": [1, 3, 640, 640]}
requireProviderNoGate check: fail unless this execution provider was actually used (e.g. CUDAExecutionProvider)
defaultDynamicDimNoValue substituted for dynamic dimensions without an explicit override (default 1)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.9/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Adds real behavior beyond the annotations: the provider fallback rule (CUDA tried when listed, CPU if it fails to load) is exactly the kind of non-obvious runtime trait an agent needs. It stops short of saying the tool actually executes inference and how long that takes, or how failures are surfaced.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences: purpose first, then the provider-fallback caveat. Nothing is repeated from the schema or annotations and no sentence is wasted.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 10-parameter tool with a nested object and no output schema, the description leaves the result shape entirely unknown (latencies? FPS? pass/fail against the gates?) and never explains how constraint failures are reported, which is the main ambiguity an agent faces here.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is only 40%, and the description clarifies only two things: what `provider` means under the hood, and that a group of numeric params are deployment gate checks. Six parameters, including requireProvider, defaultDynamicDim, and the constraint thresholds, get no added meaning over their bare schema types.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource (benchmark an ONNX model) plus the crucial scope qualifier 'on the current machine', which distinguishes it from the sibling benchmark_remote_ssh without needing the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The local-vs-remote split is implied by 'current machine', and 'optionally evaluate deployment constraints' hints at the gating use case, but there is no explicit statement of when to pass minFps/maxP95Ms/maxModelMb versus plain benchmarking, and no named alternative.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.