Skip to main content
Glama

run_drc_script

Run a KLayout DRC deck in batch mode against the session layout for design rule checking. Returns run_id and marker counts per rule for marker extraction.

Instructions

Run a KLayout DRC deck in batch mode against the session layout.

The deck receives $input_path and $report_path variables and must write its report to $report_path. Returns a run_id and marker counts per rule; pass the run_id to extract_markers for marker locations. Requires the klayout executable (on PATH or via KLAYOUT_BIN).

Args: session_id: Session returned by open_layout. script_path: Absolute path to the DRC deck. script_type: Deck language. Only ruby is supported. params: Extra variables passed to the deck with -rd name=value.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsNo
session_idYes
script_pathYes
script_typeNoruby

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.3

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it documents the deck contract ($input_path/$report_path variables, must write to $report_path), a hard environment prerequisite (klayout executable on PATH or KLAYOUT_BIN), and the return payload (run_id + marker counts). It omits failure/timeout behavior and whether the run mutates session state.

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 with the core action, then the deck contract, then follow-up and prerequisites, with an Args list at the end. Efficient and well-organized, though the contract paragraph could be tightened slightly.

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?

Output schema exists, yet the description still usefully names run_id and marker counts, and it covers the environment prerequisite and downstream handoff. Complete enough to invoke correctly; only error-handling behavior is unaddressed.

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 coverage is 0%, so the description must compensate, and it does: session_id is tied to open_layout, script_path is specified as an absolute path, script_type is constrained to ruby only, and params is explained with the -rd name=value forwarding syntax. This is meaningful added meaning beyond the bare schema.

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+resource+mode: 'Run a KLayout DRC deck in batch mode against the session layout.' It is clearly distinguishable from siblings like extract_markers, which it explicitly names as a downstream step rather than a competing choice.

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?

Establishes context (batch DRC against an open session) and routes the agent to extract_markers via run_id for marker locations. It lacks explicit when-not guidance (e.g., when to prefer interactive/geometry queries over a full deck run), so it stops short of a 5.

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