⚖️ Governance & Compliance

Erasure, sessions, and export — the compliance surface.

GDPR Art. 17 erasure — irreversible crypto-shred

client.erase_subject("alice", reason="gdpr-art17-request")
# {"subject": "alice", "shredded": True,
#  "rows_affected": 4, "vectors_removed": 1, "blobs_removed": 0,
#  "receipt": {"signed": "..."}}

Session management (draft → review → commit)

# Stage some writes, review them, then commit or discard.
client.session_diff("session-shadow-ledger")
# {"changes": [{"type": "Person", "id": "alice", "op": "upsert", ...}]}
 
client.session_commit("session-shadow-ledger")
# {"committed": True, "rows": 4, "commit_hash": "f3a2c8b1..."}
 
# Or throw them away:
client.session_discard("session-shadow-ledger")
# {"discarded": True}

Data export

client.export_data("Transaction", format="json")
# {"type": "Transaction", "format": "json",
#  "rows": [...], "exported_at": "2026-08-08T..."}
 
client.export_data("Person", format="csv")
Enrichment rules & ontology migration (the governance long tail)
# Register custom SmartIngest enrichment rules.
client.enrichment_rules({
    "rules": [{"name": "internal_acct", "pattern": r"ACME-\d{6}",
               "canonical_kind": "account_number"}],
})
 
# Governed SHACL ontology migration.
client.ontology_migrate({
    "types": [{"name": "SanctionsHit",
               "properties": {"name": {"type": "text"},
                              "list": {"type": "text"}}}],
})

Next: Branches & Namespaces — copy-on-write schema forks for "what-if" analysis and the schemaless namespace handle.