Get Started
AI Inference Architecture
Overview
LightChain AI is a decentralized EVM blockchain with Proof of Intelligence (PoI) that enables users to submit AI inference jobs executed by a network of independent, economically incentivized workers. The platform orchestrates job submission, worker assignment, inference execution, result delivery, verification, and payments, all with privacy by default.The system is built on Prysm (Consensus Layer) and Geth (Execution Layer), with AI inference orchestration handled through smart contracts and off-chain services.
Core Components
Blockchain Layer
- Consensus Layer (Prysm): Provides consensus and EIP-4844 blob storage for encrypted prompts and responses
- Execution Layer (Geth): Hosts smart contracts that enforce eligibility, manage payments, and handle dispute resolution
Smart Contracts
Off-Chain Services
How It Works
1. Session Creation
A user requests a session for a specific AI model onSessionManager. Eligible workers watch for requests and claim them on-chain; the contract runs a weighted random draw (sortition) and accepts a claim only from a worker the draw allows. The user's frontend then generates a random AES-256 session key, encrypts it for the claiming worker (and for the disputer as escrow), and submits it on-chain, which opens the session.
2. Job Submission
The user encrypts their prompt with the session key and submits it as an EIP-4844 blob transaction, then calls submitJob() with the inference fee. The contract escrows the fee and auto-assigns the job to the session's pinned worker — no per-job assignment is needed.3. Inference Execution
The worker retrieves the encrypted prompt blob from the chain, decrypts it with the session key, and runs inference via Ollama. The response is encrypted and delivered to the user in real-time via WebSocket, while the on-chain completion (response blob + completeJob) happens asynchronously.Privacy
All prompts and responses are encrypted before touching the chain. Encryption operates at the session level — a single symmetric key covers all messages within a session.- User prompts are encrypted client-side before submission as blobs
- Worker responses are encrypted with the same session key
- On-chain observers only see ciphertext in blobs
- The relay never sees plaintext — it only forwards encrypted data
Verification
The platform uses a layered approach to ensure workers are running the correct models and delivering quality results:- Canary / Random Audit Jobs: The disputer re-executes a sampled percentage of real jobs and uses semantic similarity to compare the disputer's response against the original worker's response. A low similarity score indicates the worker may have substituted a different model or degraded output, and flags the worker for further review.
- User-Initiated Disputes: Users who notice low-quality responses can file a dispute by posting a bond. The disputer re-executes the inference and compares results using semantic similarity. All dispute evidence is stored on-chain for public verifiability.
- Staking & Slashing: Workers must stake LCAI to participate. Timeouts, failed disputes, and repeated offenses result in progressive slashing and eventual suspension.
Data Storage (EIP-4844 Blobs)
Encrypted prompts and responses are stored as EIP-4844 blobs, providing cost-effective on-chain data availability with a separate fee market. Since LightChain is its own L1, blob demand will initially be low, keeping storage costs minimal.Worker Requirements
Workers must:- Stake LCAI tokens (amount varies per model)
- Run the Worker Sidecar software alongside Ollama with whitelisted models
- Register an encryption public key on-chain
- Maintain uptime and responsiveness to avoid slashing
Worker Assignment
Workers are assigned on-chain, with no service choosing between them. Every eligible worker sees a session request and may try to claim it.SessionManager seeds a draw from the hash of the block after the request, weights each worker by stake and reputation, and widens the set of workers allowed to claim block by block until one does. The contracts enforce eligibility — registration, stake, supported model, capacity and suspension — and every request and claim is an on-chain event. See Dispatcher-free Mode for how a worker runs in this mode.
A central dispatcher used to select the worker for each session. It no longer runs on testnet or mainnet; on mainnet it was switched off on 13 October 2026.
In the production system, worker discovery will move to a P2P network and the draw will be seeded by an on-chain VRF (Verifiable Random Function), making worker assignment fully tamper-proof.