Skip to main content
Glama

Remove redundant vias

prune_vias

Remove every via the board does not need: groups of vias come out, the zones are refilled and KiCad's unconnected count compared, and a via stays only if removing it disconnects something. nets limits the candidates (GND and the plane rails first: pours already join most of their pads). Runs for minutes on a large board; then fill_zones, run_drc.

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": {
      "design_id": "<design_id>"
    },
    "name": "prune_vias"
  }
}

Input Schema

NameRequiredDescriptionDefault
netsNo
wait_sNoSeconds to wait (default 55); a job still running comes back "running" for get_board_job.
workersNo
design_idYesThe design id returned by import_kicad_project or list_designs.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changed
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • removedInput schema / properties / design_id / pattern
      Removed value: -"^[A-Za-z0-9_-]{8,80}$"
    • removedInput schema / properties / nets / items / maxLength
      Removed value: -200
    • removedInput schema / properties / nets / items / minLength
      Removed value: -1
    • removedInput schema / properties / nets / maxItems
      Removed value: -50
    • changedInput schema / properties / wait_s / description
      Previous value: -"Seconds to wait for the job (default 55). A job still running comes back with status \"running\": follow it with get_board_job. A job is allowed the time its budget asks for (time_budget_s, total_budget_s, rounds), and survives a server restart (the op starts over from its snapshot; route_board's pipeline goes on from its last finished stage)."New value: +"Seconds to wait (default 55); a job still running comes back \"running\" for get_board_job."
  2. Changed1 schema field changed
    • changedInput schema / properties / wait_s / description
      Previous value: -"Seconds to wait for the job (default 55). A job still running comes back with status \"running\": follow it with get_board_job. A job is allowed the time its budget asks for (time_budget_s, total_budget_s, rounds), and survives a server restart (the op starts over from its snapshot)."New value: +"Seconds to wait for the job (default 55). A job still running comes back with status \"running\": follow it with get_board_job. A job is allowed the time its budget asks for (time_budget_s, total_budget_s, rounds), and survives a server restart (the op starts over from its snapshot; route_board's pipeline goes on from its last finished stage)."
  3. Changed1 schema field changed
    • changedInput schema / properties / wait_s / description
      Previous value: -"Seconds to wait for the job (default 55). A job still running comes back with status \"running\": follow it with get_board_job."New value: +"Seconds to wait for the job (default 55). A job still running comes back with status \"running\": follow it with get_board_job. A job is allowed the time its budget asks for (time_budget_s, total_budget_s, rounds), and survives a server restart (the op starts over from its snapshot)."
  4. First observed

TDQS

A4.3/5.0
Behavior5/5

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

Goes well beyond the annotations by disclosing the acceptance criterion ('a via stays only if removing it disconnects something'), the side effect that zones are refilled mid-run, and the cost profile ('runs for minutes on a large board'). This justifies a removal tool that carries destructiveHint=false: the description explains why the removal is safe rather than contradicting the flag.

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

Conciseness4/5

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

Tight and front-loaded: the core action leads, then the mechanism, then the parameter note, then runtime and follow-ups. The only compression cost is the dense clause 'groups of vias come out, the zones are refilled and KiCad's unconnected count compared', which is readable but packed.

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

Completeness4/5

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

For a long-running mutation with no output schema, it covers cost, side effects, and the required follow-up sequence. It does not say what result is returned (e.g., how many vias were kept or removed), leaving the agent to infer that from the tool response rather than the description.

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 50%: design_id and wait_s are documented in the schema, while nets and workers are not. The description supplies real meaning for nets (candidate limiting, GND/plane rails prioritization) but says nothing about workers or how net scoping interacts with the connectivity test. Roughly one undocumented parameter remains uncovered.

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 ('Remove every via the board does not need') plus the scope rule that defines 'needed'. The algorithm sentence makes it unmistakable versus siblings like polish_vias or cleanup_board, which are not described as connectivity-preserving via removal.

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

Usage Guidelines4/5

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

Gives concrete usage context: limit candidates with nets, start with GND and plane rails because pours already join those pads, and follow up with fill_zones then run_drc. It stops short of explicit exclusions (e.g., when to prefer polish_vias or cleanup_board instead), so it is clear guidance without a full decision rule.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources