Metadata-Version: 2.4
Name: agdr-aki
Version: 1.8.2
Requires-Dist: pydantic>=2.0
License-File: LICENSE-APACHE
License-File: LICENSE-CC0
Summary: Atomic Kernel Inference SDK for Phoenix v1.8 Ultra
Home-Page: https://accountability.ai
Author-email: Genesis Glass Foundation <founding@accountability.ai>
License: Apache-2.0 OR CC0-1.0
Requires-Python: >=3.10
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM

# AKI + AgDR

Atomic Kernel Inference seals decisions at the moment of inference.
Atomic Genesis Decision Record produces court-admissible proof.
Together they create a stakeholder shield for regulated AI.

## Why This Matters

AI decisions face regulatory scrutiny.
Boards need defensible evidence when algorithms impact people.
AKI and AgDR deliver cryptographic accountability that holds up in court.

## What Is AKI?

AKI is the inference engine.
It captures context, reasoning, and output at the exact moment a decision is made.
Every capture is sealed with Ed25519 signatures and BLAKE3 hashes.

## What Is AgDR?

AgDR is the decision record.
It produces a tamper-evident, timestamped artifact that regulators can verify.
Each record includes provenance, purpose, and cryptographic proof of integrity.

## The Stakeholder Shield

Court-admissible records protect decision-makers.
When AI systems face audit or litigation, AgDR provides the evidence trail.
Cryptographic sealing means no one can alter the record after the fact.

## Installation

### Python Users
pip install agdr-aki

### Rust Users
[dependencies]
agdr-aki = "1.8"

## Quick Start

### Python Example
from agdr_aki import AKIEngine, PPPTriplet, HumanDeltaChain

engine = AKIEngine(":memory:")
ppp = PPPTriplet("audit", "compliance", "regulatory_review")
hdc = HumanDeltaChain("decision_123", True, "approved")

record = engine.capture(
    ctx={"user": "reviewer"},
    prompt="Approve loan application?",
    reasoning_trace={"risk_score": 0.23, "policy_match": True},
    output="approved",
    ppp_triplet=ppp,
    human_delta_chain=hdc
)

print(f"Sealed: {record.hash}")
print(f"Public key: {engine.public_key_hex()}")

### Rust Example
use agdr_aki::{AKIEngine, monotonic_raw_nanos};

let mut engine = AKIEngine::new(":memory:".into());
let timestamp = monotonic_raw_nanos();
println!("Monotonic timestamp: {}", timestamp);

## Technical Details

### Cryptographic Guarantees
- Ed25519 digital signatures for authenticity
- BLAKE3 hashing for integrity
- Merkle root chaining for sequence verification
- CLOCK_MONOTONIC_RAW timestamps for tamper resistance

### Compliance Alignment
- PIPEDA: Audit trail for personal information handling
- EU AI Act: Documentation for high-risk AI systems
- Canada Evidence Act: Cryptographic proof admissible in court

### Performance

Rust core achieved a 0.62 µs latency floor in testing.
High-throughput systems scale linearly with core count.
Prebuilt wheels require Python 3.12+. Source builds support 3.9+.

## For Developers

### Build from Source
Requires Rust toolchain + Python 3.8+
git clone https://github.com/aiccountability-source/AgDR-Phoenix
cd AgDR-Phoenix
python -m maturin develop  # For Python testing
cargo build --release      # For Rust-only usage

### Feature Flags
- python (default): Enables PyO3 bindings
- Build without Python: cargo build --no-default-features

## License

Licensed under either of:
- Apache License, Version 2.0
- CC0 1.0 Universal

At your option. See LICENSE-APACHE and LICENSE-CC0 for details.

## About Genesis Glass Foundation

Genesis Glass Foundation is a federally incorporated Canadian not-for-profit.
We steward open standards for cryptographic accountability in AI systems.
Our work supports ethical governance through verifiable decision records.

accountability.ai
