ARC privacy framework: PQ-encrypted, attested, validator-anchored data layer for any application.
Project description
arc-avs-sdk
Python SDK for the ARC Privacy AVS — a Sepolia-anchored validator network
that proves applications process user data without retention. Same wire format
as @arc-avs/sdk on npm; envelopes round-trip byte-exact between TS and Python.
pip install arc-avs-sdk
# adapters & router are optional extras
pip install "arc-avs-sdk[postgres,neo4j,chain]"
Quick start
import asyncio
from arc_avs_sdk import arc, init
from arc_avs_sdk.adapter.memory import MemoryAdapter
schema = arc.schema(
app_id = "your-app.com",
compliance = ["GDPR", "CCPA"],
classes = {
"User": arc.identity({
"profile": arc.encrypted.struct({
"name": arc.encrypted.string(),
"email": arc.encrypted.email(),
}),
"events": arc.collection(
item_kind="event",
query="indexed",
index_fields=["kind"],
retention="permanent",
),
}),
},
)
async def main() -> None:
runtime = await init(schema, adapter=MemoryAdapter())
user, _ = await runtime.create_user("User", {"name": "Alice", "email": "a@b.c"})
ref, proof = await runtime.put_record(
user, "User", "event", {"kind": "login"}, index_fields={"kind": "login"}
)
print(proof.input_hash)
asyncio.run(main())
What's shipped
- Crypto layer — ML-KEM-768, ML-DSA-65, AES-256-GCM, secp256k1 ECDSA, keccak256
- Schema DSL — domain-agnostic, byte-canonical, on-chain hash matches the TS canonicalization
- Runtime —
create_user,put_record,read,list,process,purge_user,export_user - Adapters —
memory,postgres,mongo,redis,neo4j(graph-RAG / agent memory) - Processors —
openai,anthropic,mistral,kimi,nous - Validator router —
web3.pybased EIP-712 attestation submission
Compatibility
The Python CipherEnvelope serializes to the same byte layout as the TypeScript
SDK. A round-trip test in tests/test_envelope_compat.py proves that an
envelope sealed in TS opens in Python and vice-versa.
| Property | TS | Python |
|---|---|---|
| Schema canonical hash | keccak256(canonicalize_schema(s)) | keccak256(canonicalize_schema(s)) |
bind_aad(app_id, class, seq) |
byte-identical | byte-identical |
bind_digest(...) |
byte-identical | byte-identical |
proof_bind_digest(...) |
byte-identical | byte-identical |
This matters because the on-chain inputHash recorded by PrivacyTaskManager
must agree across language stacks.
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 arc_avs_sdk-1.0.0a1.tar.gz.
File metadata
- Download URL: arc_avs_sdk-1.0.0a1.tar.gz
- Upload date:
- Size: 32.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
438396c2e2c9f55ceb7900d69e0c2b2305567ee5ef8390b7aa3a15e97a2719dc
|
|
| MD5 |
bc490c7ca407a3bc0280e1c5cbfed365
|
|
| BLAKE2b-256 |
bda7c2294f3ead8336ecee1f62b96147e4c8c835fd3d5076322ec9d1c151caaf
|
File details
Details for the file arc_avs_sdk-1.0.0a1-py3-none-any.whl.
File metadata
- Download URL: arc_avs_sdk-1.0.0a1-py3-none-any.whl
- Upload date:
- Size: 43.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d0e61e08724df8af872ed60407fd56baf596d8e14e8fdb64dbb5f3dc21ff1175
|
|
| MD5 |
42a27979f7d1ba5920e60364c9c037c9
|
|
| BLAKE2b-256 |
4e7779186a514abc5f7c258f761e9ced5020af3f7cc1fdf0a47a4c7697c48fd7
|