Skip to main content

sv-nav

SystemVerilog navigation MCP service for AI agents.

Wraps slang-server LSP capabilities into an MCP (Model Context Protocol) service, providing semantic APIs — AI agents can query by signal name and hierarchy path instead of file URI + line/column, and get structured, deduplicated results without dealing with LSP protocol details.

Installation

pip install sv-nav-mcp

Requirements

Configuration

Add to your project's .claude/settings.json or global ~/.claude/settings.json:

{
  "mcpServers": {
    "sv-nav": {
      "command": "sv-nav-mcp"
    }
  }
}

With verbose logging (output to stderr):

{
  "mcpServers": {
    "sv-nav": {
      "command": "sv-nav-mcp",
      "args": ["--verbose"]
    }
  }
}

Tools

Lifecycle

Tool Description
sv_init Initialize with top_module and build_file (.f). Required first call.
sv_refresh Refresh file content after external changes. Optional file to refresh a single file.
sv_reinit Full server restart. Expensive, use sparingly.

Navigation

Tool Description
sv_search Search symbols by regex. Global or scoped to a module/hierarchy path.
sv_definition Get symbol definition with hover content. For modules/instances, also returns ports and params.
sv_refs Find all references to a symbol or module.
sv_hierarchy Browse instance hierarchy tree (Build mode).

Tracing

Tool Description
sv_cone Trace signal driver/load cone, automatically merging duplicate nodes (Build mode).

Diagnostics

Tool Description
sv_diagnostics Get compilation errors and warnings. Returns summary grouped by diagnostic code, supports filtering by code and severity.

sv_definition: Elaborated vs Declaration Data

The data level depends on the context parameter:

  • Hierarchy path context (e.g. "top.cpu"): Returns elaborated data — instance-specific parameter values, resolved types (e.g. logic[7:0] instead of logic[W-1:0]). elaborated=True.
  • Module name context (e.g. "cpu"): Returns declaration data — source-level defaults, no type/value enrichment. elaborated=False.
  • No context: Global module search, declaration data.

Build File Format (.f)

sv_init requires a build file listing source files:

// One source file path per line
// Lines starting with // are comments
// Environment variables ($VAR, ${VAR}) are expanded
// +incdir+ directives and lines with unresolvable vars are skipped
rtl/module_a.sv
rtl/module_b.sv
$SHARED_DIR/util.sv
  • Relative paths resolve from the .f file's directory
  • No dependency ordering required

Typical Workflow

  1. sv_init(top_module="ibex_core", build_file="rtl/ibex_core.f")
  2. sv_search to find symbols of interest
  3. sv_definition to get definition details and internal structure
  4. sv_refs to find all usages
  5. sv_cone to trace signal drivers/loads
  6. sv_diagnostics to check for errors

License

MIT

Metadata

Release files for sv-nav-mcp 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sv-nav-mcp 0.1.2
File Size Uploaded Provenance Actions
sv_nav_mcp-0.1.2.tar.gz 38.9 kB Without provenance Details for sv_nav_mcp-0.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for sv-nav-mcp 0.1.2
File Interpreter ABI Platform Actions
sv_nav_mcp-0.1.2-py3-none-any.whl Python 3 none any Details for sv_nav_mcp-0.1.2-py3-none-any.whl

Total release size: 74.6 kB

Release files / sv_nav_mcp-0.1.2.tar.gz

Download URL sv_nav_mcp-0.1.2.tar.gz
Size 38.9 kB
Tags Source
SHA-256 checksum
How to use checksums
abbd3e92f8dcd68e851dea2251afc6f6f1822b774815925f9d61f3b56d29a49e
BLAKE2b-256 checksum
How to use checksums
a1881a2e74096c8f4ac337663b022bb0e8cfece643da2b7f4bcd41092886075c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.15

Release files / sv_nav_mcp-0.1.2-py3-none-any.whl

Download URL sv_nav_mcp-0.1.2-py3-none-any.whl
Size 35.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
33fdf178dff300e907aa4a7a5251c41e8f958c00978a553f7b7200744ff5521b
BLAKE2b-256 checksum
How to use checksums
d406bff176112ddc6cdf6520a74498047f53d2d254ead9b683e7db5a2f63ef42
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.15

Security for sv-nav-mcp 0.1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page