Skip to main content

QpiAI Quantum Agent Tools

An MCP (Model Context Protocol) server that exposes the QpiAI Quantum SDK as tools for AI agent interfaces (such as OpenCode, Claude Desktop, and Cursor).


Installation

You can install the package either globally (so the command is available anywhere) or inside a local virtual environment.

1. Global Installation (Recommended)

This registers the qpiai-quantum-mcp command globally on your system so you don't need to specify absolute virtual environment paths in your config.

  • Using standard pip:
    pip install qpiai-quantum-agent-tools
    
  • Using uv:
    uv tool install qpiai-quantum-agent-tools
    

2. Local Virtual Environment Installation

If you prefer installing it inside an isolated project virtual environment:

  • Using standard pip:
    pip install qpiai-quantum-agent-tools
    
  • Using uv (add the --compile-bytecode flag to compile files during installation and prevent first-run startup delay):
    uv pip install qpiai-quantum-agent-tools --compile-bytecode
    

Configuration & Usage

Authentication requires a QpiAI API key. You can run the MCP server in one of two modes:

1. stdio Mode

The server runs directly as a subprocess managed by your AI agent interface. Configure it by adding the server definition under the environment settings in the client's configuration file.

Finding Your Config File

  • OpenCode (opencode.jsonc):
    • Windows: C:\Users\<username>\.config\opencode\opencode.jsonc
    • Linux/macOS: ~/.config/opencode/opencode.jsonc
  • Claude Desktop (claude_desktop_config.json):
    • Windows: C:\Users\<username>\AppData\Roaming\Claude\claude_desktop_config.json
    • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Other applications (e.g., Cursor, Cline, Roo Code):
    • Please search online or consult the application's documentation to find the location of its MCP configuration file.

Configuration for Global Installation

If you installed the package globally, use the command name "qpiai-quantum-mcp" directly:

OpenCode (opencode.jsonc)
{
  "mcp": {
    "qpiai-quantum": {
      "type": "local",
      "command": ["qpiai-quantum-mcp"],
      "env": {
        "API_KEY": "your_qpiai_api_key_here"
      },
      "enabled": true
    }
  }
}
Claude Desktop / Cursor
{
  "mcpServers": {
    "qpiai-quantum": {
      "command": "qpiai-quantum-mcp",
      "env": {
        "API_KEY": "your_qpiai_api_key_here"
      }
    }
  }
}

Configuration for Local Virtual Environment

If you installed the package inside a local project virtual environment, specify the absolute path to the executable inside that environment:

OpenCode (opencode.jsonc)
{
  "mcp": {
    "qpiai-quantum": {
      "type": "local",
      "command": [
        "C:/path/to/your/venv/Scripts/qpiai-quantum-mcp.exe"
      ],
      "env": {
        "API_KEY": "your_qpiai_api_key_here"
      },
      "enabled": true
    }
  }
}

(On Linux/macOS, use the path "/path/to/your/venv/bin/qpiai-quantum-mcp")

Claude Desktop / Cursor
{
  "mcpServers": {
    "qpiai-quantum": {
      "command": "C:/path/to/your/venv/Scripts/qpiai-quantum-mcp.exe",
      "env": {
        "API_KEY": "your_qpiai_api_key_here"
      }
    }
  }
}

(On Linux/macOS, use the path "/path/to/your/venv/bin/qpiai-quantum-mcp")


2. HTTP Mode

For lower latency across multiple agent sessions, you can run the server as a persistent HTTP local server.

  1. Set the API Key in the terminal where you will start the server:

    • PowerShell: $env:API_KEY="your_qpiai_api_key_here"
    • Command Prompt: set API_KEY=your_qpiai_api_key_here
    • Linux/macOS: export API_KEY="your_qpiai_api_key_here"
    • Alternative: Create a .env file containing API_KEY=your_qpiai_api_key_here in the directory where you run the server.
  2. Start the HTTP Server: Run the following command in the terminal where the package was installed:

    qpiai-quantum-mcp --http
    

    By default, the server starts on http://127.0.0.1:8080/mcp.

    If the command is not recognized or not on your system PATH, you can run it via its absolute path or using Python:

    python -m qpiai_quantum_agent_tools.server --http
    

    Options:

    • --port PORT — Custom port (default: 8080)
    • --host HOST — Custom bind host (default: 127.0.0.1)
  3. Configure your client to connect to the URL:

    • OpenCode (opencode.jsonc):
      {
        "mcp": {
          "qpiai-quantum": {
            "type": "remote",
            "url": "http://127.0.0.1:8080/mcp",
            "enabled": true
          }
        }
      }
      
    • Claude Desktop / Cursor:
      {
        "mcpServers": {
          "qpiai-quantum": {
            "url": "http://127.0.0.1:8080/mcp"
          }
        }
      }
      

Tools

  • qpiai_health_check: Reports SDK import status, active transport (stdio/http), and whether an API key is configured.
  • qpiai_verify_api_key: Validates the configured key against QpiAI.
  • qpiai_get_user_details: Retrieves the name and email of the authenticated user.
  • qpiai_list_compute_resources: Lists available compute resources for the configured key.
  • qpiai_validate_qasm: Performs basic OpenQASM sanity checks.
  • qpiai_submit_qasm_job: Dry-runs by default; submits only when run=true.
  • qpiai_get_job_status: Fetches job status by ID.
  • qpiai_get_job_result: Fetches parsed job result data by ID.
  • qpiai_get_job_history: Retrieves recent job submission history with optional status and period filtering.
  • qpiai_simulate_local: Runs a local statevector simulator on custom circuit JSON.

Example Prompts

  • "Check whether QpiAI Quantum is configured."
  • "List my available QpiAI compute resources."
  • "Validate this Bell-state OpenQASM without submitting it."
  • "Dry-run a submission of this QASM to QpiAI-QSV-Simulator with 1024 shots."
  • "Submit this QASM with run=true after confirming the simulator and shot count."

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qpiai_quantum_agent_tools-0.1.1.tar.gz (69.9 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

qpiai_quantum_agent_tools-0.1.1-py3-none-any.whl (13.2 kB view details)

Uploaded Python 3

File details

Details for the file qpiai_quantum_agent_tools-0.1.1.tar.gz.

File metadata

  • Download URL: qpiai_quantum_agent_tools-0.1.1.tar.gz
  • Upload date:
  • Size: 69.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.5 {"installer":{"name":"uv","version":"0.10.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for qpiai_quantum_agent_tools-0.1.1.tar.gz
Algorithm Hash digest
SHA256 6236f33e344b7c8b691aff94cc790231ab56d7d7aae27bbb704d36d2ba6857de
MD5 126d6fb917bba81a381184bd9c453950
BLAKE2b-256 f8ed4d6448d03d2ba79d17c6e3456c0a089942486e03a3d85e7dd4e0dcf05aa6

See more details on using hashes here.

File details

Details for the file qpiai_quantum_agent_tools-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: qpiai_quantum_agent_tools-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 13.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.5 {"installer":{"name":"uv","version":"0.10.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for qpiai_quantum_agent_tools-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 65f0100a69ad7ba22dfc0b964dbd72220d9df5876bde10b46254a8cae42007ca
MD5 ca93cf707af77ebb5d258a0770f6b8d9
BLAKE2b-256 e69c5937e0b1b67770ac5963e5540f60ad4d4277a4f3a33add55b7f1b5dfcae0

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 files

0.1.0

2 files

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