hackquest logo

Enclave - 0g sovreign key

AI agents with cryptographic sovereignty on the 0G Galileo

Videos

Tech Stack

Next
Solidity
Node
SnarkJS
0gSDk
Typescript

Description

Every AI agent managing crypto today stores its private key in a .env file on someone's laptop or centralized server. One compromised server equals a total loss of funds.

Our Solution (How It Works):

Sovereign Agent Keys fixes this by turning an off-chain AI into a cryptographically secure, on-chain autonomous entity. Our solution works through four core pillars:

1. Key Sharding: The agent's private key is split into 3 pieces via Shamir 2-of-3 secret sharing, meaning no single party can reconstruct it. Shard 1 is pinned to 0G Storage (Turbo Indexer). In production, shards 2 and 3 go to independent MPC nodes.

2. ZK-Enforced Rules: Every transaction must pass a Groth16 Zero-Knowledge proof on-chain before it can settle. The ZK prover (circom 2.0 + snarkjs) guarantees the AI's intent adheres to its constitution (spend limits, whitelisted addresses) without revealing underlying proprietary data.

3. Immutable Memory: Every decision the agent makes is permanently logged to 0G Data Availability (DA) for a full, verifiable audit trail. AI accountability at scale — with the throughput to handle high-frequency agent actions that Ethereum L2s cannot afford.

4. Sovereign Command Console: Users connect their wallet, spawn agents they own on-chain, and issue natural-language instructions via the Mission Control dashboard. Each instruction flows through ZK proof generation → 0G DA anchoring → on-chain settlement via AgentRegistry.executeTask().

Progress During Hackathon

During this hackathon, we built the pipeline to be ~90% operational with real execution on the Galileo Testnet. Specifically, we:

Migrated the full end-to-end ZK pipeline from SP1 to Snarkjs for native, compact on-chain verification.

Built a Persistent Agent Scanner that utilizes ethers.js event filtering to discover agents directly from the 0G Galileo blockchain.

Created a Premium Telemetry Dossier dashboard for tracking MPC shard status, ZK constitution rules, and real-time proving durations.

Team Leader
BBarnabas Oboh
Project Link
Deploy Ecosystem
0G-Galileo-Testnet0G-Galileo-Testnet
Sector
OtherAI