# CUDA-Q Docs [Health: Active]

**Category:** 💻 Developer Tools  
**Repository:** https://github.com/rogerawong/cudaq-docs-mcp  
**GitHub Stars:** 1  
**Views:** 0  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/cuda-q-docs

## Description
CUDA-Q docs, API reference, and runnable examples for AI agents, pinned to your installed version.

## Tools
Capabilities this server exposes over MCP:

- **search_docs** — Search the NVIDIA CUDA-Q documentation and return ranked excerpts.

    Use this before answering any CUDA-Q question from memory: the platform
    moves quickly and memorized APIs are often stale. Each result carries a
    breadcrumb, an excerpt, and the canonical doc URL to cite. A response may
    include see_also, a one-sentence pointer to a sibling tool that fits the
    question better.

    Args:
        query: Natural language or keywords, for example "run kernel on GPU
            state vector" or "quantinuum credentials".
        version: Docs version such as "0.15.0" or "latest". Defaults to the
            installed cudaq version.
        limit: Maximum number of results (default 5).
    
- **get_page** — Fetch one documentation page as clean markdown.

    Args:
        path: Page path as returned by search_docs, for example
            "using/quick_start" or "using/backends/sims/svsims".
        version: Docs version. Defaults to the installed cudaq version.
    
- **find_api** — Resolve a CUDA-Q API symbol to its canonical definition and doc URL.

    For the legal values of a target or its options (for example what
    set_target accepts), use list_targets instead.

    Args:
        name: Symbol name, full or partial: "sample", "cudaq.observe",
            "qvector", "set_target".
        language: "python" or "cpp" to filter; omit for both.
        version: Docs version. Defaults to the installed cudaq version.
    
- **search_examples** — Find complete, runnable CUDA-Q example programs.

    Sources are the example, snippet, and application files shipped in the
    CUDA-Q repository at the matching release. Prefer adapting these over
    writing kernels from memory.

    Args:
        query: What the example should show, for example "GHZ state",
            "VQE", or "noise model".
        language: "python" or "cpp" to filter; omit for both.
        version: Docs version. Defaults to the installed cudaq version.
        limit: Maximum number of examples (default 3).
    
- **list_targets** — List CUDA-Q execution targets (backends) with guidance on choosing.

    Covers simulators (CPU, GPU state vector, tensor network, noisy,
    dynamics), quantum hardware providers, and cloud aggregators, each with
    selection snippets and doc URLs. Call this when deciding where to run a
    kernel or when the user names a provider.

    Args:
        category: Optional filter: "simulator", "hardware", or "cloud".
    

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `uvx` (confidence: high):

```json
"mcpServers": {
  "cuda-q-docs": {
    "command": "uvx",
    "args": ["cudaq-docs-mcp"]
  }
}
```

## Documentation

## What CUDA-Q Docs MCP server does

CUDA-Q Docs MCP server exposes version-matched CUDA-Q reference material to MCP-compatible AI clients. It serves documentation pages, API symbols, runnable programs, and guidance for choosing among CUDA-Q execution targets. The project is a community implementation and is not affiliated with or endorsed by NVIDIA.

The available content follows the CUDA-Q version installed on the machine when possible. This helps avoid answers based on renamed APIs, removed targets, or installation instructions from another release.

## How it works

The server uses CUDA-Q’s published documentation assets rather than scraping pages with heuristics. A Sphinx inventory provides the page and API-symbol manifest, while markdown documentation mirrors supply page content. The server cleans those pages, preserves heading anchors, and reconstructs code blocks with language information.

Content is divided by heading and indexed in SQLite FTS5. Porter stemming and BM25 ranking support full-text searches without embeddings or API keys. Examples and application sources come from the GitHub release tag corresponding to the selected documentation version. Each version has its own SQLite database in the local cache.

Version selection follows a fixed order: an explicit tool argument, the installed `cudaq` package detected through distribution metadata, and then `latest`. The package is not imported for detection. If a requested version has no local index, the response identifies the gap and falls back to `latest`, including the command needed to build the missing index.

## Setup and configuration

Register the server with an MCP client using `uvx cudaq-docs-mcp`, or install it with pip and run `cudaq-docs-mcp`. The server communicates over stdio. Claude Code, Claude Desktop, Cursor, and VS Code are documented configuration options.

On first use, the client downloads a prebuilt index when one exists. Build an index manually for a selected release with:

```bash
uvx cudaq-docs-mcp build --version 0.14.0
```

The command without a subcommand starts the MCP service. `cudaq-docs-mcp build` builds an index for the installed CUDA-Q package, or for `latest` when no installed package is detected. `cudaq-docs-mcp info` reports the cache location, indexed versions, and detected CUDA-Q installation.

Set `CUDAQ_DOCS_MCP_AUTOBUILD=1` to build an index automatically on first use. Set `CUDAQ_DOCS_MCP_CACHE` to move the cache directory. No API keys are required.

## Tools and capabilities

CUDA-Q Docs MCP server provides these tools:

- `search_docs(query, version?, limit?)` returns ranked excerpts with breadcrumbs and canonical URLs.
- `get_page(path, version?)` returns one complete documentation page as markdown.
- `find_api(name, language?, version?)` resolves an exact Python or C++ symbol and returns its kind, URL, and an excerpt.
- `search_examples(query, language?, version?, limit?)` finds complete runnable programs from the matching CUDA-Q release.
- `list_targets(category?)` lists 24 execution targets, including simulators, hardware providers, and clouds, with selection guidance.

It also exposes `cudaq://versions` for installed and indexed versions, and `cudaq://llms.txt` for the served version’s CUDA-Q `llms.txt` content.

## Limitations and notes

Prebuilt indexes are available only for versions that have published assets. Other versions require a local build. The `latest` index is refreshed by a nightly workflow, so newly published content may not appear immediately.

The roadmap mentions pinned prebuilt indexes for more release versions, retrieval evaluations, and CUDA-QX documentation; these are not current capabilities. Served documentation originates from NVIDIA’s CUDA-Q repository, and the project’s license materials identify the documentation content separately from the server code.

_Full upstream README: https://allmcps.com/mcp/cuda-q-docs/readme_

