OpenQuantum: Skill for Codex

.agents/skills/quantum-circuit-verification/SKILL.md

quantum-circuit-verification is a skill for Codex from xi-zhao/OpenQuantum. It costs 121 tokens per session (758 once invoked), scanned A, original, MIT.

A local checker for deciding whether two small OpenQASM 2 quantum circuits perform the same quantum transformation. OpenQASM 2 is a text format for describing quantum circuits.

In plain words
What is it for?
Use it to compare an original circuit with a translated or rewritten version, as long as both are bounded, measurement-free circuits within the stated limits.
Why use it?
It catches meaning-changing errors after circuit translation or optimisation, while keeping strict equivalence, phase-only equivalence, and uncertain results separate.

Skill for Codex

Written for Codex: agents/openai.yaml present. Also seen: installed under .agents/ (shared by several agents); $skill-name invocation.

This is xi-zhao/OpenQuantum's own configuration. It tells Codex how to work on OpenQuantum itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything OpenQuantum configures →

Reuse

Borrowing it

Nothing to install: this file belongs to xi-zhao/OpenQuantum. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/xi-zhao/OpenQuantum/main/.agents/skills/quantum-circuit-verification/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/xi-zhao/OpenQuantum

Made for: Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for quantum-circuit-verification

README.md
[![agentmods](https://agentmods.dev/badge/skills/xi-zhao/openquantum/quantum-circuit-verification.svg)](https://agentmods.dev/skills/xi-zhao/openquantum/quantum-circuit-verification)
Your own site
<a href="https://agentmods.dev/skills/xi-zhao/openquantum/quantum-circuit-verification"><img src="https://agentmods.dev/badge/skills/xi-zhao/openquantum/quantum-circuit-verification.svg" alt="Measured on agentmods" height="20"></a>
Per session 121 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 758 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00121 $0.00758
Opus 5 $0.00060 $0.00379
Sonnet 5 $0.00024 $0.00152
Haiku 4.5 $0.00012 $0.00076

Measured 3d ago against content hash 4a53df6ca677, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

quantum-circuit-verification scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (mcp/bridge.py, mcp/server.mjs, test/mcp.test.mjs), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/quantum-circuit-verification/SKILL.md · 45 lines

What it actually says

量子电路等价性验证

核心边界

核心对象是“一对待比较的有界 unitary OpenQASM 2 电路”。Qiskit 电路工作台负责加载、转换、门数与深度分析;本 Skill 使用 MQT QCEC 回答更窄但更关键的问题:两个电路是否实现等价的量子变换。

  • 每份 QASM 最多 64 KiB、最多 16 个量子位、最多 512 个语句。
  • 两份电路必须声明相同的总量子位数。
  • 只允许标准 qelib1.inc;不接受任意 include 路径。
  • 不接受 measureresetifcregopaque
  • 固定 10 秒 QCEC 超时,调用方不能扩大运行预算。

工作流

  1. 先确认比较目标:通常是原电路与转译/优化后的电路。
  2. 若输入是 OpenQASM 3 或 QPY,先用 $qiskit-circuit-workbench 做受控转换;不要自行猜测语义。
  3. 调用 verify_circuit_equivalence,传入两份 QASM 文本,不传文件路径。主动作加载固定环境并返回 packageVersion;首次调用可能下载依赖并写入工作区环境,无需单独检查运行时。
  4. 按以下语义解释 result.equivalence
    • equivalent:QCEC 给出等价结论;
    • equivalent_up_to_phase / equivalent_up_to_global_phase:只在用户目标允许相位等价时采用;
    • not_equivalent:本次比较不等价;
    • probably_equivalent / probably_not_equivalent / no_information:不确定,不能升级成确定结论。
  5. 同时报告实际包版本、输入 SHA-256、QCEC checker 记录、耗时和 provenance.complete=not_checked;环境不可用时报告工具错误,不编造结果。

必须保持的规则

  • “门数更少”不等于语义等价,必须看 QCEC observation。
  • provider 超时或 no_information 不算电路语义失败,只算验证未交付。
  • circuits.equivalent=fail 是科学 observation,不是 MCP 运行错误。
  • 相位等价必须原样报告,不能静默写成严格等价。
  • 没有 Result Package 和 Session Event Log 来源链时,输出只能是 observations_available

输出格式

  1. 两份输入摘要与 SHA-256;
  2. QCEC 的完整 criterion;
  3. checker 与耗时摘要;
  4. conclusive / equivalent / provenance 三类 observations;
  5. 适用范围和未验证项。
Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago Changed · -1 lines 4a53df6ca677
  2. 8d ago First seen · 46 lines · 121 tokens per session scan A 2db729b95dc9

Subscribe to this mod's changes

quantum-circuit-verification is a skill published in the GitHub repository xi-zhao/OpenQuantum (48 stars, last pushed yesterday), licensed MIT. It adds 121 tokens to every session and 758 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

discriminating-experiment-design

Recognize when a benchmark cannot discriminate between methods, construct experiment families that could, sweep structural knobs without sweeping the decision itself, and report a tie that survives as the headline result. Use when all methods score the same on your benchmark, when designing a new evaluation world or…

AURORA-NEURO/aurora-agent · 89 tokens

i4h-catheter-navigation-e2e

End-to-end smoke for catheter navigation covering setup, digital twin, DRR, and unit tests. Use when asked to run the full catheter workflow smoke or demo the v0.7 pipeline.

NVIDIA/skills · 49 tokens

i4h-catheter-navigation-render-drr

Render a single DRR fluoroscopy frame from a CT cache or synthetic phantom. Use when asked to render DRR, generate a fluoro image, or smoke-test the Slang renderer.

NVIDIA/skills · 48 tokens

nw-tlaplus-verification

TLA+ formal verification for design correctness and PBT pipeline integration.

nWave-ai/nWave · 20 tokens

academic-research

Search academic papers, scholarly articles, and research publications through SandBase. Use when asked for literature review, academic citations, scholarly research, paper discovery, or scientific evidence gathering.

sandbaseai/sandbase-skills · 39 tokens

test-first

A test-first development guide, where tests are written before the code they check. TDD, or test-driven development, means first writing a test that fails, then writing the simplest code that makes it pass.

pingfanfan/hello-dsh · 48 tokens