Skip to main content
Glama
lazyverilog

LazyVerilog MCP

Official
by lazyverilog

code_actions

Discover available SystemVerilog RTL edits at a specific file and line, optionally targeting a symbol, to identify the appropriate fix or generation step before applying it.

Instructions

List RTL code actions available at line of file: AutoInst (on an instantiation line), AutoArg (module header), AutoFunc, AutoFF (always_ff), AutoWire, add default case, ... Pass symbol to place the cursor on it (e.g. the module name of an instance). Run one with apply_code_action.

Input Schema

NameRequiredDescriptionDefault
fileYesSystemVerilog file path, absolute or relative to the workspace root
lineYes1-based line number
symbolNoSymbol text as written on that line

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.2

TDQS

A4/5.0
Behavior3/5

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

With no annotations, the description must carry the full behavioral burden; it does convey the key trait that this only lists actions while apply_code_action performs them. However it says nothing about side effects, failure modes, or whether the listing depends on index/LSP readiness, and the trailing "..." leaves the action set open-ended.

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?

One dense, front-loaded sentence pair with the core operation first, examples second, and the hand-off to the sibling last. The informal "..." after the action list is the only loose element.

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?

No output schema exists, yet the description never states what a listed action looks like or how an action is identified when passed to apply_code_action (by name? index?), which is exactly the hand-off the agent needs. It is otherwise adequate for a three-parameter read tool.

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 100%, so the baseline is 3, and the description adds genuine meaning on top: it tells the agent which line kinds yield which action (instantiation line, module header, always_ff) and that `symbol` disambiguates by placing the cursor, with an example (module name of an instance).

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 ("List RTL code actions") scoped to a line in a file, and its examples (AutoInst, AutoArg, AutoFF) make the resource concrete. It is unambiguously the read/query counterpart to apply_code_action, so an agent can tell it apart from every sibling.

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?

Explicitly routes the follow-up step ("Run one with apply_code_action") and hints at positioning with "Pass `symbol` to place the cursor on it." It gives clear context for use but no exclusions or preconditions (e.g., what happens if no actions exist at that line).

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