Nomos Python SDK — capability layer for AI agents (scoped, time-bound, revocable, delegable permissions for MCP / LangGraph / CrewAI / AutoGen)
Project description
auto-nomos-sdk (Python)
Python SDK for Nomos — multi-agent orchestration security.
Mirrors the TS SDK so LangGraph / CrewAI / AutoGen orchestrators get the same chain-aware authorize / proxy story.
Install
pip install auto-nomos-sdk
You also need the nomos-ucan CLI on PATH for UCAN minting:
npm install -g @auto-nomos/ucan-cli
Use — root agent
from nomos import AuthGuard
guard = AuthGuard(api_key="nomos_<id>_<secret>", pdp_url="https://pdp.example.com")
decision = guard.authorize(
ucan="<jwt>",
command="github:repo:read",
resource={"repo": "org/test-repo"},
)
if decision.allow:
...
Use — fork a child agent (LangGraph / CrewAI / AutoGen)
import subprocess, os, json
from nomos import fork_child, read_parent_chain_from_env
# Inside the parent agent (already authorized once and got a child UCAN
# minted via nomos-ucan or via the control-plane mint endpoint):
chain, env = fork_child(
parent_chain=read_parent_chain_from_env().chain,
child_ucan_jwt=child_jwt,
parent_receipt_id=last_receipt_id,
swarm_id=swarm_id,
)
subprocess.Popen(["python", "child_agent.py"], env={**os.environ, **env})
The child process's AuthGuard() automatically picks up
NOMOS_PARENT_UCAN_CHAIN and includes the full root → leaf chain on
every authorize / proxy call.
Env vars (orchestrator-agnostic wire format)
| Var | Purpose |
|---|---|
NOMOS_PARENT_UCAN_CHAIN |
JSON UCAN array (root-first). |
NOMOS_PARENT_UCAN_CHAIN_FILE |
Fallback file path when env exceeds OS limits. |
NOMOS_PARENT_RECEIPT_ID |
Causation back-link to parent's last receipt. |
NOMOS_SWARM_ID |
Explicit swarm id; PDP otherwise derives. |
NOMOS_MAX_CHAIN_DEPTH |
Override depth cap; default 8. |
NOMOS_UCAN_BIN |
Path to nomos-ucan binary; default nomos-ucan on PATH. |
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
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 nomos_sdk-0.1.1.tar.gz.
File metadata
- Download URL: nomos_sdk-0.1.1.tar.gz
- Upload date:
- Size: 10.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d66e16eabe42c4d25ca7fd6a8ff135e4ccd8b46d51b0c55f9ed43431ee4534a8
|
|
| MD5 |
e873ba8e6749da58fea94264cc2ea1f4
|
|
| BLAKE2b-256 |
bc1f1461e300374075ae0ae2f53ea4a1e2c3b04cb1c55380829d60b0708db336
|
Provenance
The following attestation bundles were made for nomos_sdk-0.1.1.tar.gz:
Publisher:
release-sdk.yml on auto-nomos/python-packages
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
nomos_sdk-0.1.1.tar.gz -
Subject digest:
d66e16eabe42c4d25ca7fd6a8ff135e4ccd8b46d51b0c55f9ed43431ee4534a8 - Sigstore transparency entry: 1624520747
- Sigstore integration time:
-
Permalink:
auto-nomos/python-packages@bfbaaa35361bbc31ef9593097e5d1f42cbcaab7b -
Branch / Tag:
refs/tags/sdk-v0.1.1 - Owner: https://github.com/auto-nomos
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-sdk.yml@bfbaaa35361bbc31ef9593097e5d1f42cbcaab7b -
Trigger Event:
push
-
Statement type:
File details
Details for the file nomos_sdk-0.1.1-py3-none-any.whl.
File metadata
- Download URL: nomos_sdk-0.1.1-py3-none-any.whl
- Upload date:
- Size: 8.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7649ee731e25d9df43b51b9b36c2aec6ee6242b86941db211aed1ed00f2e4fa2
|
|
| MD5 |
caba2e89286d45b50fd3262cc70c9f4d
|
|
| BLAKE2b-256 |
027c14ba8899892afcab453a3b017110410784140f3f62f9d51929e5ae569745
|
Provenance
The following attestation bundles were made for nomos_sdk-0.1.1-py3-none-any.whl:
Publisher:
release-sdk.yml on auto-nomos/python-packages
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
nomos_sdk-0.1.1-py3-none-any.whl -
Subject digest:
7649ee731e25d9df43b51b9b36c2aec6ee6242b86941db211aed1ed00f2e4fa2 - Sigstore transparency entry: 1624520754
- Sigstore integration time:
-
Permalink:
auto-nomos/python-packages@bfbaaa35361bbc31ef9593097e5d1f42cbcaab7b -
Branch / Tag:
refs/tags/sdk-v0.1.1 - Owner: https://github.com/auto-nomos
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-sdk.yml@bfbaaa35361bbc31ef9593097e5d1f42cbcaab7b -
Trigger Event:
push
-
Statement type: