Skip to content

Commit 5ea0b6b

Browse files
fix yapf formatting
Signed-off-by: vedika-saravanan <vsaravanan@nvidia.com>
1 parent 153a589 commit 5ea0b6b

14 files changed

Lines changed: 78 additions & 50 deletions

File tree

.agents/skills/_shared/scripts/pick_workflow.py

Lines changed: 50 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -77,13 +77,16 @@
7777
"required_features": ["core"],
7878
},
7979
"debug-import": {
80-
"skill": "cuda-qx-build",
81-
"reference": ".agents/skills/cuda-qx-build/references/install-triage.md",
80+
"skill":
81+
"cuda-qx-build",
82+
"reference":
83+
".agents/skills/cuda-qx-build/references/install-triage.md",
8284
"commands": [
8385
"bash scripts/doctor.sh",
8486
"pip list | grep -E 'cuda-quantum|cudaq-(qec|solvers)|cuquantum|tensorrt|torch'",
8587
],
86-
"verify": "python3 -c 'import cudaq, cudaq_qec, cudaq_solvers'",
88+
"verify":
89+
"python3 -c 'import cudaq, cudaq_qec, cudaq_solvers'",
8790
"required_features": [],
8891
},
8992

@@ -100,67 +103,85 @@
100103
"required_features": ["core"],
101104
},
102105
"qec-custom": {
103-
"skill": "cuda-qx-qec-extending",
104-
"reference": ".agents/skills/cuda-qx-qec-extending/references/code-python.md",
106+
"skill":
107+
"cuda-qx-qec-extending",
108+
"reference":
109+
".agents/skills/cuda-qx-qec-extending/references/code-python.md",
105110
"commands": [
106111
"ls libs/qec/include/cudaq/qec/codes/",
107112
"ls libs/qec/python/cudaq_qec/plugins/decoders/",
108113
],
109-
"verify": "python3 -c 'import cudaq_qec as qec; "
110-
"print(qec.get_code(\"my_code\").get_stabilizers())'",
114+
"verify":
115+
"python3 -c 'import cudaq_qec as qec; "
116+
"print(qec.get_code(\"my_code\").get_stabilizers())'",
111117
"required_features": ["core"],
112118
},
113119
"qec-realtime": {
114-
"skill": "cuda-qx-qec-realtime",
115-
"reference": ".agents/skills/cuda-qx-qec-realtime/references/in-kernel.md",
120+
"skill":
121+
"cuda-qx-qec-realtime",
122+
"reference":
123+
".agents/skills/cuda-qx-qec-realtime/references/in-kernel.md",
116124
"commands": [
117125
"echo 'Phase 1: build DEM; Phase 2: write config.yaml; "
118126
"Phase 3: configure_decoders_from_file BEFORE cudaq.run; "
119127
"Phase 4: in-kernel reset/enqueue/get_corrections; finalize at end'",
120128
],
121-
"verify": "CUDAQ_QEC_DEBUG_DECODER=1 python3 your_script.py "
122-
"2>&1 | grep 'Initializing realtime decoding library'",
129+
"verify":
130+
"CUDAQ_QEC_DEBUG_DECODER=1 python3 your_script.py "
131+
"2>&1 | grep 'Initializing realtime decoding library'",
123132
"required_features": ["core"],
124133
},
125134
"qec-ai-decoder": {
126-
"skill": "cuda-qx-qec-ai-decoders",
127-
"reference": ".agents/skills/cuda-qx-qec-ai-decoders/references/training.md",
135+
"skill":
136+
"cuda-qx-qec-ai-decoders",
137+
"reference":
138+
".agents/skills/cuda-qx-qec-ai-decoders/references/training.md",
128139
"commands": [
129140
"python3 -c \"import torch, tensorrt; print(torch.__version__, tensorrt.__version__)\"",
130141
],
131-
"verify": "trt_decoder loaded; test-set LER matches PyTorch within sampling noise",
142+
"verify":
143+
"trt_decoder loaded; test-set LER matches PyTorch within sampling noise",
132144
"required_features": ["core", "qec-trt-decoder"],
133145
},
134146
"qec-debug": {
135-
"skill": "cuda-qx-qec-decode",
136-
"reference": ".agents/skills/cuda-qx-qec-decode/references/decode-triage.md",
147+
"skill":
148+
"cuda-qx-qec-decode",
149+
"reference":
150+
".agents/skills/cuda-qx-qec-decode/references/decode-triage.md",
137151
"commands": [
138152
"echo '90% of \"LER looks wrong\" cases are: "
139153
"(1) didnt slice X-stab half, (2) decoded against code.get_parity instead of dem.detector_error_matrix, "
140154
"(3) different noise object passed to sample vs DEM helper'",
141155
],
142-
"verify": "python3 your_script.py # at p=0, LER should be 0",
156+
"verify":
157+
"python3 your_script.py # at p=0, LER should be 0",
143158
"required_features": ["core"],
144159
},
145160

146161
# Solvers family intents (each dispatches to its own skill)
147162
"vqe": {
148-
"skill": "cuda-qx-solvers-algorithms",
149-
"reference": ".agents/skills/cuda-qx-solvers-algorithms/references/vqe.md",
163+
"skill":
164+
"cuda-qx-solvers-algorithms",
165+
"reference":
166+
".agents/skills/cuda-qx-solvers-algorithms/references/vqe.md",
150167
"commands": [
151168
"python3 -c \"import cudaq_solvers as solvers; print(solvers.vqe.__doc__)\"",
152169
],
153-
"verify": "energy < hf_energy after the run",
170+
"verify":
171+
"energy < hf_energy after the run",
154172
"required_features": ["core"],
155173
},
156174
"qaoa": {
157-
"skill": "cuda-qx-solvers-algorithms",
158-
"reference": ".agents/skills/cuda-qx-solvers-algorithms/references/qaoa.md",
175+
"skill":
176+
"cuda-qx-solvers-algorithms",
177+
"reference":
178+
".agents/skills/cuda-qx-solvers-algorithms/references/qaoa.md",
159179
"commands": [
160180
"python3 -c \"import cudaq_solvers as solvers; "
161181
"print('use cobyla; lbfgs needs gradients QAOA does not auto-wire')\"",
162182
],
163-
"verify": "QAOAResult unpack: optval, optp, config = result",
183+
"verify":
184+
"QAOAResult unpack: optval, optp, config = result",
164185
"required_features": ["core"],
165186
},
166187
"gqe": {
@@ -177,13 +198,16 @@
177198
"required_features": ["core", "solvers-gqe"],
178199
},
179200
"chemistry": {
180-
"skill": "cuda-qx-solvers-chemistry",
181-
"reference": ".agents/skills/cuda-qx-solvers-chemistry/references/molecule-building.md",
201+
"skill":
202+
"cuda-qx-solvers-chemistry",
203+
"reference":
204+
".agents/skills/cuda-qx-solvers-chemistry/references/molecule-building.md",
182205
"commands": [
183206
"export OMP_NUM_THREADS=1 # reproducible PySCF coefficients",
184207
"lsof -n -i :8000 || true # verify no stale cudaq-pyscf server",
185208
],
186-
"verify": "mol.energies['hf_energy'] is finite",
209+
"verify":
210+
"mol.energies['hf_energy'] is finite",
187211
"required_features": ["core"],
188212
},
189213
}

.agents/skills/cuda-qx-contributing/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ description: >-
99
"sign off", "DCO", "where do I put this code", "clang-format",
1010
"yapf format", "open an issue", or otherwise wants to push changes
1111
upstream.
12-
version: "0.1.2"
12+
version: "0.1.3"
1313
author: "CUDA-QX"
1414
license: "Apache License 2.0"
1515
compatibility: "Any platform (git, clang-format, yapf)"

.agents/skills/cuda-qx-qec-extending/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ description: >-
1111
delegate to cuda-qx-qec-realtime. For solvers extensions (operator
1212
pools, optimizers, state-prep), see the cuda-qx-solvers-algorithms package
1313
(`cuda-qx-solvers-extending` skill).
14-
version: "0.1.1"
14+
version: "0.1.2"
1515
author: "CUDA-QX"
1616
license: "LicenseRef-NVIDIA-Proprietary (libs/qec/LICENSE)"
1717
compatibility: "Python 3.11+, C++ 20, CMake 3.28+, Linux x86_64/aarch64"

.agents/skills/cuda-qx-qec-extending/references/code-cpp.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ The kernel type aliases are in `code.h`:
7979
`surface_code.cpp` is added; mimic exactly).
8080
2. Header lives under `libs/qec/include/cudaq/qec/codes/my_code.h`.
8181
3. If you want a Python binding, extend
82-
`libs/qec/python/bindings/py_codes.cpp` to expose your class.
82+
`libs/qec/python/bindings/py_code.cpp` to expose your class.
8383
4. Rebuild: `ninja install` inside the `build/` directory.
8484
5. Run the C++ test: `ctest -R my_code`.
8585

.agents/skills/cuda-qx-qec-extending/references/decoder-cpp.md

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -48,15 +48,18 @@ defined in `decoder.h`.
4848
4949
## Build glue
5050
51-
1. Create `libs/qec/lib/decoders/my_decoder/` with `my_decoder.cpp`,
52-
`my_decoder.h` (and a `CMakeLists.txt`).
53-
2. Add an `add_subdirectory(my_decoder)` to
54-
`libs/qec/lib/decoders/CMakeLists.txt`.
51+
1. Drop `my_decoder.cpp` (and any private headers) directly into
52+
`libs/qec/lib/decoders/` alongside the existing decoder sources
53+
(or add a subdir under `libs/qec/lib/decoders/plugins/` if you
54+
prefer the plugin layout — see `libs/qec/lib/decoders/plugins/example/`).
55+
2. Wire the source into `libs/qec/lib/CMakeLists.txt` next to the
56+
other built-in decoders.
5557
3. If your decoder needs an external dependency (e.g. LAPACK, CUDA),
56-
declare it in your subdirectory's CMakeLists.
57-
4. Add the public header to the install set in
58-
`libs/qec/include/cudaq/qec/decoders/CMakeLists.txt` if you want
59-
downstream users to `#include` it.
58+
declare it in `libs/qec/lib/CMakeLists.txt` next to your `add_library`.
59+
4. Place any public headers under `libs/qec/include/cudaq/qec/` and
60+
add them to that include directory's CMake install set (see
61+
`libs/qec/CMakeLists.txt`) if downstream users should `#include`
62+
them.
6063
5. Rebuild: `ninja install` in `build/`.
6164
6. Verify with `ctest -R my_decoder`.
6265

.agents/skills/cuda-qx-qec-extending/references/decoder-python.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,9 @@ effect.
6363

6464
For shipping with cudaq-qec: drop it under
6565
`libs/qec/python/cudaq_qec/plugins/decoders/` and follow the loader
66-
contract used by built-in plugins. The loader tests at
67-
`libs/qec/python/tests/test_plugin_loader.py` show what's expected.
66+
contract used by built-in plugins. The decoder tests at
67+
`libs/qec/python/tests/test_decoder.py` exercise the registration path
68+
and show what's expected.
6869

6970
## Plugin loader behavior
7071

.agents/skills/cuda-qx-qec-realtime/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ description: >-
1313
in-kernel decoding, autonomous_decoder, AIDecoderService,
1414
AIPreDecoderService, CUDA Graph QEC, Helios, Quantinuum, FPGA, ring
1515
buffer, decoder dispatch, RPC, or "low latency QEC".
16-
version: "0.1.1"
16+
version: "0.1.2"
1717
author: "CUDA-QX"
1818
license: "Apache License 2.0 (parts under LicenseRef-NVIDIA-Proprietary, see libs/qec/LICENSE)"
1919
compatibility: "Python 3.11+, C++ 20, Linux x86_64 with NVIDIA GPU"

.agents/skills/cuda-qx-qec-realtime/references/sliding-window.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,6 @@ sw = qec.get_decoder("sliding_window", H,
101101

102102
- Component docs: `docs/sphinx/components/qec/introduction.rst`
103103
"Sliding Window Decoder" section.
104-
- Source: `libs/qec/lib/decoders/sliding_window/`.
104+
- Source: `libs/qec/lib/decoders/sliding_window.cpp`, `libs/qec/lib/decoders/sliding_window.h`.
105105
- For real-time eligible incremental decoders, see
106106
`cuda-qx-qec-realtime/references/autonomous-decoder.md`.

.agents/skills/cuda-qx-quickstart/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,4 +175,4 @@ Do not duplicate workflow content here. This skill is a router.
175175
- `references/first-qec-example.md` — code-capacity walkthrough with
176176
output interpretation.
177177
- `references/first-solvers-example.md` — H2 VQE walkthrough.
178-
- `references/concepts.md` — one-page glossary.
178+
- `references/concepts.md` — one-page glossary.

.agents/skills/cuda-qx-solvers-algorithms/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ description: >-
1010
construction, PySCF, basis sets, active spaces, operator pools — use
1111
`cuda-qx-solvers-chemistry`); writing a new operator pool / optimizer
1212
(use `cuda-qx-solvers-extending`).
13-
version: "0.3.2"
13+
version: "0.3.3"
1414
author: "CUDA-QX"
1515
license: "Apache License 2.0"
1616
compatibility: "Python 3.11+, C++ 20, Linux x86_64/aarch64"

0 commit comments

Comments
 (0)