QubeCore Client SDK
Project description
QubeCore-Client
Python client SDK for QubeCore — Quantum Computing Operating System.
Overview
QubeCore Client provides a Python-friendly interface for communicating with QubeCore Server over gRPC. QubeCli, QubeLab, and QubeGate all depend on this package.
Requirements
- Python 3.11+
- QubeCore Server
Installation
pip install qubecore-client
Quick Start
from qubecore_client import QubeClient
client = QubeClient(address="localhost:50051")
# Submit a job
job_id = client.submit_gate_job(
backend_name="backend1",
gate_circuits=[
"OPENQASM 2.0;\ninclude \"qelib1.inc\";\nqreg q[2];\ncreg c[2];\nh q[0];\ncx q[0],q[1];\nmeasure q -> c;"
],
shots=100,
)
print("job_id:", job_id)
# Check status
status = client.get_job_status(job_id)
print("status:", status["status"])
# Fetch result
result = client.get_job_result(job_id)
print("result:", result)
# Cancel job (only possible while status is PENDING)
message = client.cancel_job(job_id)
print("cancel:", message)
CLI
Server Configuration
qubecore config set host 192.168.1.100:50051
qubecore config get
Commands
# Submit a job
qubecore submit --backend backend1 --circuit "OPENQASM 2.0;..." --shots 100
# Check status
qubecore status --job-id <job_id>
# Fetch result
qubecore result --job-id <job_id>
# Cancel job
qubecore cancel --job-id <job_id>
One-time server override:
qubecore --host 10.0.0.1:50051 submit --backend backend1 --circuit "..." --shots 100
API
| Method | Description |
|---|---|
submit_gate_job() |
Submits a gate-circuit execution job and returns a job_id |
get_job_status() |
Retrieves the current job status |
get_job_result() |
Retrieves the job result |
cancel_job() |
Cancels a job (only possible while status is PENDING) |
submit_gate_job Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
backend_name |
str |
Yes | Backend name (backend1, backend2, kreo.sc-20) |
gate_circuits |
list[str] |
Yes | List of circuit strings (QASM2/QASM3/JSON) |
shots |
int |
Yes | Number of execution shots |
priority |
int |
No | Priority from 1 to 4 (default: 3 = NORMAL) |
optimization_level |
int |
No | Transpile optimization level from 0 to 3 (no default) |
Compatibility
| qubecore-client | qubecore |
|---|---|
| 1.x | 1.x |
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
qubecore_client-1.0.3.tar.gz
(42.2 kB
view details)
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 qubecore_client-1.0.3.tar.gz.
File metadata
- Download URL: qubecore_client-1.0.3.tar.gz
- Upload date:
- Size: 42.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6ae563e3e04ad4621d594878c9b82c1dbea3db134a0938edcb75b28a78aff7f5
|
|
| MD5 |
5dec5cb7ad72a909b9789303bb7725e8
|
|
| BLAKE2b-256 |
27ca3a0dde494c537b1b9b9446bb47af0a9a2cd63e877a003c3d09e2afee2e9c
|
File details
Details for the file qubecore_client-1.0.3-py3-none-any.whl.
File metadata
- Download URL: qubecore_client-1.0.3-py3-none-any.whl
- Upload date:
- Size: 11.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3b02d6dd7173145a1bf93018e7fbc00470dea739cec37ea442ffbf8584fc55e5
|
|
| MD5 |
2e7806a28c0f6c201258fb95de474dc8
|
|
| BLAKE2b-256 |
a013a63092a46f5f5929830afed5ea7f2a5b054e3aa509eb6e47c0f468754b33
|