nodus-compute
The Python SDK for Nodus: run functions, sandboxes, jobs and workspaces on the cheapest capacity that finishes them on time, with checkpoints, recovery and exact prepaid billing.
pip install nodus-compute
nodus login
import nodus
app = nodus.App("hello")
@app.function(gpu="H100", timeout="1h", max_cost=5)
def square(x: int) -> int:
return x * x
@app.local_entrypoint()
def main():
print(square.remote(7)) # one call; blocks and returns 49
print(list(square.map(range(10)))) # fan out; results stream back in order
nodus run app.py # ephemeral: the App is deleted when main() returns
nodus deploy app.py # persistent: call it later with nodus.Function.from_name("hello", "square")
Every blocking call also has an .aio form for asyncio code: await square.remote.aio(7).
For organizations enabled for the Spot pilot, nodus.Client().spot.request("h200x8", max_price=12) waits for a
dedicated interruptible node and returns its Nodus SSH command. Use client.spot.release(node["id"]) when finished.
The Spot guide covers stable request keys, polling and billing.
- Guides: https://nodus-compute.ai/docs/guides/python/
- Coming from Modal: https://nodus-compute.ai/docs/getting-started/modal-users/
- Examples:
examples/python/
Layout
| Path | What |
|---|---|
src/nodus/api/ |
Layer 1: the generic resource client (nodus.api.get, list, watch, apply, …) |
src/nodus/api/models/ |
Generated pydantic models (make gen; never edit) |
src/nodus/errors/ |
One exception per error-registry code, plus the SDK's outcome errors |
src/nodus/*.py |
Layer 2: App, Function, Image, Volume, Secret, Sandbox, Job, Workspace, llm |
src/nodus/runtime.py, log.py, checkpoint.py, cluster.py |
In-container helpers; no-ops outside Nodus |
src/nodus/_runtime/ |
The in-container worker runtimes (Functions, durable steps, agents) |
Development
make -C sdk/python lint # ruff lint and format check, mypy strict on nodus.api
make -C sdk/python gen # regenerate nodus.api.models from api/openapi
make -C sdk/python docs # griffe dump for the reference pages
The SDK has no tests of its own: the compose journeys exercise it end to end. Published SDK wheels are universal
and pin the separate nodus-compute-cli native dependency, so pip install nodus-compute still provides nodus.
SDK-only upgrades reuse the native package. Release tooling adds the exact dependency and console entry point;
development builds remain SDK-only. The native wheels are built with
NODUS_CLI_BIN=<binary> NODUS_WHEEL_PLATFORM=<tag> make -C sdk/python wheel-cli.
Optional engine observations
A supported serving collector can call nodus.runtime.report_engine_timing(observation)
once during a Function invocation. Supply the closed
nodus.serving-engine-timing/1 object with invoked_ns, first_output_ns (integer or
null), final_output_ns and exhausted_ns from one monotonic clock, after application
output validation. The worker converts them to invocation-relative offsets and attaches
them only to the winning successful completion when the API advertises support. The
console Function Calls details shows those application-reported observations separately
from server elapsed time. Older servers and calls without a report preserve their old
completion shape. Reporting cannot establish network delivery, quality or GPU drain.
Outside a supported worker call the helper is a no-op.
Supporting protected native rerank runtimes optionally report a same-owner monotonic clock after complete score validation. The Function's Calls tab groups loaded successful observations by worker epoch and owner, showing foreground claim-to-score p95 and background query completions. This is worker observation, not client latency or a complete workload census. Older SDKs/servers leave the optional clock absent; ordinary results and per-call engine timing remain available. The runtime still requires its independent installed-image and physical qualification before operator deployment.
Metadata
Release files for nodus-compute 1.0.97
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nodus_compute-1.0.97-py3-none-any.whl | Python 3 | none | any | Details for nodus_compute-1.0.97-py3-none-any.whl |
Release files / nodus_compute-1.0.97-py3-none-any.whl
| Download URL | nodus_compute-1.0.97-py3-none-any.whl |
|---|---|
| Size | 264.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a89e1d44f5e42481280074853011131c6d06d939807f4a7116ce131749bd3756
|
|
BLAKE2b-256 checksum How to use checksums |
f00d6d92f0f52a2f24278e76ae7f2bee02c86ea4ec79d16451cd596a6860cb18
|
| 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 Nov 26, 2026.
Transparency logSecurity for nodus-compute 1.0.97
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.
Full provenance
1 file in this release has been uploaded with provenance metadata.
Attestation for nodus_compute-1.0.97-py3-none-any.whl
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 Nov 26, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.