cyl-0411/cyl0411-skills/qsnare-closed-loop

Claude Code and agent skill by cyl-0411/cyl0411-skills

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Run Q-SNARE/Q-Whisperer evaluation through metrics, QEC simulation, PyMatching decoding, feedback, cleanup, and git handoff. Use for closed-loop LER validation or iteration acceptance.

Install

npx vskill@latest install cyl-0411/cyl0411-skills/qsnare-closed-loop

SKILL.md

The same SKILL.md was published earlier as cyl-0411/cyl0411-skills/qsnare-closed-loop.

Q-SNARE Closed Loop

Overview

Use the actual QEC decoding outcome as the primary success signal. Classification AP/F1 is useful for diagnosis, but a model is only effective when model-adjusted PyMatching improves logical error rate versus raw PyMatching.

Workflow

  1. Inspect the current state before running anything expensive:
  • git status --short
  • latest model/figures/experiment_comparison.csv
  • latest model/figures/<experiment>/baseline_comparison.json
  • latest model/figures/<experiment>/selective_operating_point*.json
  • latest simulation/results/**/feedback.json, summary.json, gated_validation_summary.csv, or gated_validation_summary.md
  1. Run commands from the Q-Whisperer repository root. Resolve <QSNARE_PYTHON>

once: prefer .venv/Scripts/python.exe on Windows or .venv/bin/python on POSIX, and require "<QSNARE_PYTHON>" -X utf8 -c "import torch, stim, pymatching" to pass. Do not fall back to an unrelated system Python. For the current accepted baseline, prefer the runtime-gated validation CLI:

powershell
"<QSNARE_PYTHON>" -X utf8 -m simulation.run_gated_policy_validation `
--policy-manifest simulation/policies/runtime_gated_v2.yaml `
--policy-mode gated `
--instances 2 `
--shots-per-instance 100 `
--device auto
  1. Scale accepted-policy validation only after the smoke test passes:
  • Single-seed 100k: add --seed 7101 --instances 100 --shots-per-instance 1000 --output-root simulation/results/gated_policy_validation_full.
  • The manifest defines scenarios x50, x100, x300, x1000, and x50-x1000; keep paired raw-versus-adjusted samples.
  • Use "<QSNARE_PYTHON>" -X utf8 -m simulation.run_closed_loop_workflow only for historical or experimental single-model scans.
  1. Treat the repository's simulation/ package as QEC-SIM unless the user provides an external simulator path. It uses Stim for detector sampling and PyMatching for decoding.

Success Criteria

  • Primary: LER(noisy_model_adjusted_pm) < LER(noisy_raw_pm).
  • Strong success: model-adjusted LER improves raw PM by at least 10% and the difference is larger than about two combined standard errors.
  • "Correctness improves" means logical success rate increases; report both success rate and LER, but make LER the decision metric.
  • If AP/F1 is high but QEC LER regresses, do not call the model good. Tune policy mapping, action threshold, and decoder hotspot multiplier first.

Resource Policy

  • Use GPU for training and model inference when CUDA is available.
  • Use CPU workers conservatively for data loading and simulation orchestration; do not saturate all cores by default.
  • Keep GPU memory headroom. If CUDA OOM occurs, reduce batch size and retry before changing model code.
  • For large QEC runs, increase instances and shots-per-instance gradually. Avoid holding all detector samples in memory.

Logs and Artifacts

  • Prefer structured small artifacts: feedback.json, feedback.md, summary.json, instances.csv.
  • Compress workflow logs to run.log.gz and delete raw run.log.
  • Keep only recent workflow run directories for the same experiment unless the user asks to preserve a run.
  • Do not delete historical training logs or checkpoints unless the user explicitly requests cleanup or passes a cleanup flag.

Git Handoff

  • Commit code changes after tests pass.
  • Push model-iteration results only when the closed-loop QEC result meets the strong success criterion.
  • Stage only files related to the current workflow; avoid mixing unrelated dirty worktree changes into the commit.

Security

  • Security scanPassed, 90 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
0

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/cyl-0411/cyl0411-skills/qsnare-closed-loop/badge)](https://verified-skill.com/skills/cyl-0411/cyl0411-skills/qsnare-closed-loop)

Something wrong with this skill or its page? Tell us.