vella-sdk
Python SDK for deterministic pre-execution adjudication and signed proof-bundle generation.
Install
pip install vella-sdk
From source (development)
python3 -m venv .venv
. .venv/bin/activate
python -m pip install --upgrade pip
pip install -e ".[dev]"
pytest
ruff check .
mypy --strict vella/
Basic usage
from vella import govern
result = govern(
intent="EXECUTE_CHANGE",
evidence_mask=1,
)
print(result["decision"]) # ALLOWED | DENIED
print(result["reason_code"]) # reason code string
With proof bundle
from vella import govern
signing_key = open("./proof-signing.pem", "r", encoding="utf-8").read()
result = govern(
intent="EXECUTE_CHANGE",
evidence_mask=1,
proof_signing_key=signing_key,
)
print(result["proof_bundle"]["kind"]) # vella_proof_bundle_v1
Custom policy evaluators
Applications that need an application-supplied policy can create an isolated evaluator through the public package API:
from vella import create_evaluator
policy = {
"policyVersion": "generation-v1",
"defaultScope": "generation",
"evidenceBits": {"AUTHN": 1},
"scopes": {
"generation": {
"allowUnknownIntents": False,
"defaultRequiredMask": 1,
"intents": {"GENERATION_CONTEXT": 1},
}
},
}
evaluator = create_evaluator(policy)
result = evaluator.evaluate(
{
"intent_id": "GENERATION_CONTEXT",
"evidence_mask": 1,
"authority_scope_id": "generation",
"policy_version": "generation-v1",
}
)
print(result["decision"]) # ALLOWED | DENIED
print(result["reason_code"]) # reason code string
The policy uses the same policyVersion, defaultScope, evidenceBits, and scopes shape as DEFAULT_POLICY. Each scope declares allowUnknownIntents, defaultRequiredMask, and an intents mapping from normalized intent names to required evidence masks.
create_evaluator(...) returns a policy-bound evaluator whose evaluate(...) method returns decision and reason_code. Missing inputs, unknown intents or scopes, insufficient evidence, policy-version mismatches, and unexpected evaluator errors all return DENIED.
Use govern(...) for the built-in default policy and the high-level response fields latency_us, proof_bundle, and proof_error. Custom evaluators perform deterministic policy adjudication only; they do not sign or persist proof bundles.
When to use this SDK
This SDK runs VELLA in-process inside your Python application. It is the right choice for agent tool-call hooks, CI/CD gating, edge compute, research notebooks, batch processing, and any context where microsecond-latency adjudication is needed without a separate service.
For enterprise service mesh, polyglot environments (Go, Java, .NET), Kubernetes admission control, or multi-tenant deployments, a different VELLA component (the runtime service or sidecar adapter) is the better fit. See the full deployment scope in the repository root.
API
govern(intent, evidence_mask, authority_scope=None, policy_version=None, proof_signing_key=None)- Returns a dict with
decision,reason_code,latency_us, and optionalproof_bundle/proof_error
- Returns a dict with
create_evaluator(policy=None)- Returns a policy-bound evaluator with
evaluate(input_dict), which returnsdecisionandreason_code
- Returns a policy-bound evaluator with
Reference docs
See the root repository docs for full protocol details:
spec/icd.mdspec/schemas/proof.jsonverify/
Metadata
Release files for vella-sdk 1.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| vella_sdk-1.0.3.tar.gz | 10.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| vella_sdk-1.0.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 18.0 kB
Release files / vella_sdk-1.0.3.tar.gz
| Download URL | vella_sdk-1.0.3.tar.gz |
|---|---|
| Size | 10.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
93056f5752b80f708860ed52c00f80d69a59431e57bf789237c324a5220eba05
|
|
BLAKE2b-256 checksum How to use checksums |
1b42bc4ccaf6942c1e817d0b844edab22422a596cfbafc90d68b208d85303378
|
| 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 Sep 1, 2026.
Transparency logRelease files / vella_sdk-1.0.3-py3-none-any.whl
| Download URL | vella_sdk-1.0.3-py3-none-any.whl |
|---|---|
| Size | 8.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c1b20eb38214283be8e2c4b6081fdb8c519dbf640ca3467db1fde2cc0834d6f2
|
|
BLAKE2b-256 checksum How to use checksums |
536de7536c6a4bd8fa77bcb146ff983dcfca3b2fd605a186d6a81bdcccd44840
|
| 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 Sep 1, 2026.
Transparency log