Local, compiler-backed CUDA-Q optimization agent
Project description
QBridge-Agent
Install and run
pip install "qbridge[quantum]" qbridge-agent
qbridge-agent my_problem.py --workspace ./qbridge-output
my_problem.py must be a supported QBridge Python DSL optimization model, not
arbitrary Python. Add --no-solve to emit CUDA-Q without running it.
QBridge-Agent translates a constrained binary optimization request into the QBridge Python DSL, then delegates verified compilation and execution to the locally installed QBridge CUDA-Q compiler. It is deliberately not a general coding agent and has no cloud compile/solve dependency.
Layout
QBridge-Agent/
├── agent/
│ ├── planner/ # intent-to-DSL prompt policy
│ ├── tools/ # independent benchmark verification
│ ├── compiler_interface/ # DSL extraction, local compiler and CUDA-Q execution
├── examples/
├── evaluations/
│ ├── benchmark_tasks.json # frozen T1/T2 task set
│ ├── results/ # raw reproducible run artifacts
│ └── README.md
└── README.md
Evaluation results
Run this in the Ubuntu environment that has CUDA-Q installed:
OPENROUTER_API_KEY=... \
/home/dilip/qbridge-env/bin/python3 evaluations/run_benchmark.py \
--trials 3 --results evaluations/results/my_run
The runner forces cudaq.set_target("nvidia"), performs a CUDA-Q sample GPU
probe before work begins, stores the actual target description for each V2
result, and checks both systems with the same classical feasibility/objective
verifier. It never converts an execution error into a successful result.
OPENROUTER_API_KEY is required only for this external-model comparison; the
normal agent compile/solve path is local. The reproducible 20 July 2026 run
on the six frozen T1/T2 tasks (three trials each, NVIDIA cusvsim_fp32) found:
- QBridge-Agent: 16
VERIFIED, 1INCORRECT, 1UNVERIFIED. - Aider: 0
VERIFIED, 17UNVERIFIED, 1INVALID_METHOD.
These are strict verifier outcomes, not success-rate estimates. Raw artifacts
for that run are retained under evaluations/results/20260720_t1_t2_gpu_fixed
in a source checkout and excluded from package distributions.
From a source checkout:
pip install .
qbridge-agent my_problem.py --workspace ./qbridge-output
qbridge-agent invokes the local qbridge package to emit CUDA-Q, then uses
the configured local CUDA-Q target. No problem DSL is sent to a QBridge cloud
endpoint.
For maintainer release steps, see RELEASE.md.
Scope
Supported: small constrained binary optimization problems expressible in the current QBridge DSL. Unsupported quantum algorithms and arbitrary Python are errors, not guessed translations.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file qbridge_agent-0.2.0.tar.gz.
File metadata
- Download URL: qbridge_agent-0.2.0.tar.gz
- Upload date:
- Size: 15.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c889fc2fd023e9541e07b619683ed271ea4ccfa4258c126f2250f9e8e87f6c9f
|
|
| MD5 |
0eb625a49bd58bfc4b5b2bc2847eeec4
|
|
| BLAKE2b-256 |
52e04304774ecaeae8dd95e79a092638aae1d4f22e468d34f01326303d733fa7
|
Provenance
The following attestation bundles were made for qbridge_agent-0.2.0.tar.gz:
Publisher:
publish.yml on ProfessionalQwerty/qbridge-agent
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
qbridge_agent-0.2.0.tar.gz -
Subject digest:
c889fc2fd023e9541e07b619683ed271ea4ccfa4258c126f2250f9e8e87f6c9f - Sigstore transparency entry: 2206233376
- Sigstore integration time:
-
Permalink:
ProfessionalQwerty/qbridge-agent@fdb99279b59cbfa8c05fb5f557511ed4b0c5dc75 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/ProfessionalQwerty
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@fdb99279b59cbfa8c05fb5f557511ed4b0c5dc75 -
Trigger Event:
push
-
Statement type:
File details
Details for the file qbridge_agent-0.2.0-py3-none-any.whl.
File metadata
- Download URL: qbridge_agent-0.2.0-py3-none-any.whl
- Upload date:
- Size: 17.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
29678aac69b524b2d4091b582f62ce3962e8f14b412c53b2183164e2d71bcc2f
|
|
| MD5 |
07ac2be883bcbfa056d036a03ff494b6
|
|
| BLAKE2b-256 |
b88f85174b298a6576297b1eb7407076b2930a9a3092ab77ad0561db2e288d8d
|
Provenance
The following attestation bundles were made for qbridge_agent-0.2.0-py3-none-any.whl:
Publisher:
publish.yml on ProfessionalQwerty/qbridge-agent
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
qbridge_agent-0.2.0-py3-none-any.whl -
Subject digest:
29678aac69b524b2d4091b582f62ce3962e8f14b412c53b2183164e2d71bcc2f - Sigstore transparency entry: 2206233399
- Sigstore integration time:
-
Permalink:
ProfessionalQwerty/qbridge-agent@fdb99279b59cbfa8c05fb5f557511ed4b0c5dc75 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/ProfessionalQwerty
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@fdb99279b59cbfa8c05fb5f557511ed4b0c5dc75 -
Trigger Event:
push
-
Statement type: