Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

runq Python SDK

In-task SDK for the runq GPU scheduler.

Install

From the repo root:

pip install -e ./sdk/python

Optional extras:

pip install -e "./sdk/python[wandb]"   # optional W&B dependency
pip install -e "./sdk/python[dev]"     # for pytest

Quick start

import runq

ctx = runq.context()
lr = ctx.params.get("lr", 1e-3)          # ablation values from the sweep

with runq.log_group("train"):
    runq.report({"loss": loss}, step=step)   # → train/loss in metrics.jsonl
runq.record({"acc": acc}, seed=ctx.seed, split="val")  # axis-keyed result row

Checkpoints go under ctx.checkpoint_dir (<task_dir>/checkpoints, stable across retries, so a resume.extra_args restart can find them). runq does not manage checkpoint lifecycle or early stopping — those belong to your training script.

Three modes

Detected automatically at runq.context():

  • daemon — running under a runq daemon (RUNQ_TASK_ID + RUNQ_SOCKET_PATH set)
  • no_daemon — running on HPC compute node (RUNQ_TASK_ID set, no socket / RUNQ_NO_DAEMON=1)
  • manual — running outside runq (no RUNQ_TASK_ID); useful for local debugging

ctx.mode exposes which mode is active.

Output and W&B directories (RC3)

ctx.output_dir defaults to <task_dir>/outputs; ctx.checkpoint_dir defaults to <task_dir>/checkpoints. ctx.wandb_like_cfg["dir"] uses WANDB_DIR, whose default is the task directory. W&B manages the wandb child itself. Explicit project/job environment overrides are resolved before submission and preserved by the SDK.

import wandb
run = wandb.init(**ctx.wandb_like_cfg)
ctx.link_wandb(run)  # global rank 0; ignores missing offline/disabled URLs

The SDK still works without W&B installed. Retries keep outputs and offline files; online resume="allow" and offline wandb sync have different semantics. See the directory contract for artifact staging/cache/download paths and explicit clean behavior.

Metadata

Release files for runq-sdk 0.6.0rc4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for runq-sdk 0.6.0rc4
File Size Uploaded
runq_sdk-0.6.0rc4.tar.gz 30.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for runq-sdk 0.6.0rc4
File Interpreter ABI Platform
runq_sdk-0.6.0rc4-py3-none-any.whl Python 3 none any Details

Total release size: 53.0 kB

Release files / runq_sdk-0.6.0rc4.tar.gz

Download URL runq_sdk-0.6.0rc4.tar.gz
Size 30.0 kB
Tags Source
SHA-256 checksum
How to use checksums
60682e6a8479baf97bb7ff4e033777329a3a107182ffcc4b007a165a8bc33498
BLAKE2b-256 checksum
How to use checksums
456ec732770b6aa25ae64c78ec8285ad1040910f5634c5dc5e51fe7190bc7084
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 Oct 15, 2026.

Transparency log

Release files / runq_sdk-0.6.0rc4-py3-none-any.whl

Download URL runq_sdk-0.6.0rc4-py3-none-any.whl
Size 23.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1c8a0ac9bd708cde8de8a3ccaf473bcd98ffd11765648736698e49505863fec8
BLAKE2b-256 checksum
How to use checksums
1d207d9f99cab9a90acaf11597932a06425bbb0f7973512c467768f638ba5bf2
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 Oct 15, 2026.

Transparency log
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page