Skip to main content
Glama

pcb_calc_polygon_area

Calculates the boundary area of each copper polygon on the active board in square mils and millimetres, optionally filtered by net or layer, to estimate copper coverage and plane area.

Instructions

Report the area of each copper polygon on the active board.

Returns each polygon's overall boundary area in square mils and square millimetres, optionally filtered by net and/or layer. Useful for estimating copper coverage / plane area.

Args: net: Only polygons on this net (optional). layer: Only polygons on this layer name (optional).

Returns: Dict with polygons (each: name, net, layer, area_sq_mils, area_sq_mm) and count.

Input Schema

NameRequiredDescriptionDefault
netNo
layerNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.1

TDQS

A3.6/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the disclosure burden; it makes clear this is a read-only reporting operation and clarifies that the area reported is the 'overall boundary area' (addressing hole handling). It says nothing about cost, board-state prerequisites, or behaviour when no polygons match.

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?

Front-loaded purpose sentence followed by units, filtering, and a use case; the Args block is tight. The Returns block restates information already carried by the output schema, which is mild redundancy.

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 two-param read-only calculation with an output schema, the description covers purpose, filtering, units, and the qualitative caveat about boundary area. Minor gaps remain around default empty-string behaviour and result ordering/failure modes.

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

Parameters4/5

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

Schema description coverage is 0%, so the description must compensate, and it does explain both parameters: net restricts to polygons on that net, layer restricts by layer name, both optional. It does not specify matching semantics (exact name vs substring) or that empty string means 'no filter'.

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

Purpose4/5

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

States a specific verb+resource: reports the area of each copper polygon on the active board, which is meaningfully distinct from listing polygons. It doesn't explicitly contrast with siblings like pcb_get_polygons or pcb_get_board_statistics, so an agent must infer which to pick.

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?

'Useful for estimating copper coverage / plane area' gives a use context, but there is no explicit when-to-use vs when-not guidance and no sibling is named. The 'optionally filtered by net and/or layer' phrasing implies the filtering workflow but leaves the choice of alternatives to inference.

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

Deploy Server

Other Tools