Skip to main content
Glama

list_cells

Retrieve cells in a KLayout layout hierarchy by depth, sorted by name, with bounding boxes, top-cell status, child instance counts, and shape counts.

Instructions

List cells in the layout hierarchy, sorted by name.

Each entry has the cell bounding box in microns, whether it is a top cell, its direct child instance count, and its direct shape count.

Args: session_id: Session returned by open_layout. max_depth: Only include cells within this many levels of a top cell (0 = top cells only, 1 = top cells and their direct children). Omit to list every cell.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
max_depthNo
session_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.3

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It discloses ordering (sorted by name), the per-entry payload, and the depth-scoping rule, but says nothing about result size limits, pagination, or performance on large layouts, which are the real risks for a hierarchy listing.

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-loads purpose and sort order, then the return payload, then Args, which is a sensible ordering. The return-field sentence overlaps with the existing output schema, but it is brief and not padded.

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?

Both parameters are documented and an output schema already covers return values, so the agent has what it needs to call this correctly. The only gap is the absence of any session/permission or scale caveats that a no-annotation read tool might benefit from.

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 define both parameters, and it does: session_id is tied to `open_layout`, and max_depth is explained with concrete edge semantics ('0 = top cells only, 1 = top cells and their direct children') plus the omit-to-list-all default. That is genuine added meaning.

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 ('List cells in the layout hierarchy') plus the sort order, which is materially more informative than the bare name. It does not name or distinguish itself from siblings like describe_cell or query_region, but the purpose itself is unambiguous.

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?

Usage is implied rather than stated: an agent infers this is the enumeration step after `open_layout`, which the session_id arg indirectly confirms. There is no explicit when-to-use, when-not-to-use, or comparison against describe_cell/query_region, so guidance remains minimal.

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