Quantum Challenge Grader
Grading client for the IBM Quantum Challenge grading service.
Run locally
Pre-requisites:
- IBM Quantum account
- Python (3.10 or later) environment with
- Classic Jupyter Notebook interface or JupyterLab
To install the grader locally:
-
In the Python environment, install the grading client:
pip install qc-grader -
Configure the
QC_API_KEYenvironment variablesFrom a terminal (before launching your JupyterLab environment), enter
export QC_API_KEY=your_ibmcloud_api_keywhere
your_ibmcloud_api_keyis your IBM Cloud API Key found in your Account page.Alternatively, if you prefer you can instead run the following at the top cell of a notebook cell (whenever you start/restart the kernel)
%set_env QC_API_KEY=your_ibmcloud_api_keyNote1: you can check if the environment variable has been set by running the following in a notebook cell:
import os print(os.getenv('QC_API_KEY'))
Note2: If you already installed qiskit-ibm-runtime and saved your token by using
QiskitRuntimeServiceby following this instruction once, you don't need to set-up the env variable. You can save your token by usingQiskitRuntimeServicelike below:from qiskit_ibm_runtime import QiskitRuntimeService QiskitRuntimeService.save_account( channel="ibm_quantum", token="<YOUR_TOKEN>", set_as_default=True, overwrite=True, )
Usage
-
Open an exercise notebook
- In IBM Quantum Lab, the notebooks can be found in the
quantum-challengefolder in the Lab files panel - For local install, download the notebooks (from IBM Quantum Lab or specific challenge repo) and import into local Jupyter environment
- In IBM Quantum Lab, the notebooks can be found in the
-
Run the notebook cells, answering the exercises and submitting solution for grading. For example
from qc_grader.challenges.challenge_2021 import grade_lab1_ex1 grade_lab1_ex1(qc_1)
from qc_grader.challenges.challenge_2021 import grade_lab1_ex2 grade_lab1_ex2(qc_2)
Metadata
Release files for qc-grader 2026.8.28
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| qc_grader-2026.8.28.tar.gz | 142.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| qc_grader-2026.8.28-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 200.5 kB
Release files / qc_grader-2026.8.28.tar.gz
| Download URL | qc_grader-2026.8.28.tar.gz |
|---|---|
| Size | 142.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1784b4a98350da6574ecbc540aeedcaccddeeef0b91c2ab290812d6804995156
|
|
BLAKE2b-256 checksum How to use checksums |
1a51d1fa172ab8ab57a18cb093fef6c7eb1bd30b748c360ff8e2c7b5357c1239
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.
Transparency logRelease files / qc_grader-2026.8.28-py3-none-any.whl
| Download URL | qc_grader-2026.8.28-py3-none-any.whl |
|---|---|
| Size | 58.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7517f80990bd182636fb962ffd4fa3e16d2658a75006538e1f8ab62768ec3b93
|
|
BLAKE2b-256 checksum How to use checksums |
1ed05fe19950e32b6895a5ebf726fa035aba951bbe4d11fdef3ca4939e17f8ce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.
Transparency log