Skip to main content
Glama
OriginQ

QPanda3 Runtime MCP Server

by OriginQ

add_zip_rule_tool

Creates one-to-one pairs between quantum circuits and observables by matching specified indices, similar to Python's zip function.

Instructions

Add zip (one-to-one) rule to CircuitObservableBinding.

This generates one-to-one pairs of circuits and observables. This is analogous to Python's zip function.

For example, if circuit_indices=[0,2] and observable_indices=[1,0], it generates combinations: (0,1), (2,0).

Args: binding_id: The ID returned by create_circuit_observable_binding_tool. circuit_indices: List of circuit indices (must match length of observable_indices). observable_indices: List of observable indices (must match length of circuit_indices).

Returns: Dictionary containing: - status: "success" or "error" - binding_id: The binding ID - combinations_added: Number of combinations added - message: Status description

Example: # Add specific circuit-observable pairs result = add_zip_rule_tool( binding_id="your_binding_id", circuit_indices=[0, 2], observable_indices=[1, 0] ) # This adds 2 combinations: (circuit_0, observable_1), (circuit_2, observable_0)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
binding_idYes
circuit_indicesYes
observable_indicesYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

With no annotations provided, the description carries full burden and does well by explaining what the tool does (generates one-to-one pairs), providing an example, and specifying the return structure. It doesn't mention permissions, rate limits, or error conditions, but covers core behavior adequately.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is efficiently structured with a clear purpose statement, analogy, parameter explanations, return values, and a practical example. Every sentence adds value without redundancy, and it's front-loaded with the core functionality.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (creating indexed pairings), 0% schema coverage, and no annotations, the description provides complete guidance: purpose, analogy, parameter semantics, return structure, and an example. The output schema is present, so return values don't need extra explanation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description fully compensates by explaining all three parameters: binding_id's source, circuit_indices and observable_indices as lists that must match in length, and their pairing behavior. The example further clarifies usage.

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?

The description clearly states the verb 'add' and resource 'zip (one-to-one) rule to CircuitObservableBinding', with a specific analogy to Python's zip function. It distinguishes from sibling tools like add_product_rule_tool by specifying it creates one-to-one pairs rather than Cartesian products.

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?

The description provides clear context by mentioning it's analogous to Python's zip function and giving a concrete example, which helps understand when to use it. However, it doesn't explicitly state when NOT to use it or compare alternatives like add_product_rule_tool beyond the analogy.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/OriginQ/qpanda3-runtime-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server