Agent memory
Tonara is a decentralized long-term memory protocol designed to provide AI agents with a permanent, private, and secure "brain."
Videos




Tech Stack
Description

For the flow chart
https://mermaid.ai/d/7f236254-00b9-4b4e-b0cf-2b8125184e82
For the Architecture
https://mermaid.ai/d/ffe3aeee-819c-4b04-b26a-7a7a5119c52f





Tonara: The Sovereign Memory Layer for AI Agents
Tonara is a decentralized long-term memory protocol designed to provide AI agents with a permanent, private, and secure "brain." By leveraging the speed of 0G Storage and the security of blockchain, Tonara ensures that AI intelligence is no longer ephemeral or confined to a single session, but is instead persistent and cross-chain compatible.
Introduction
In the current AI landscape, agents suffer from "amnesia." Most LLM interactions are session-based; once a window is closed, the context is lost. Tonara solves this by creating a decentralized infrastructure where AI agents store encrypted "memory shards" across distributed networks. It acts as a bridge between high-performance storage and on-chain verification, allowing agents to find, pay for, and reassemble their memories autonomously.
The Problem
Context Loss: AI agents lose their history once a session ends or local storage is cleared.
Privacy Risks: Centralized memory storage exposes sensitive user-agent interactions to data breaches.
Siloed Intelligence: Data stored on one chain or platform is rarely accessible to agents operating on another.
Manual Management: Users currently have to manually manage API balances and storage costs across different providers.
The SolutionTonara introduces a Cross-Chain Data System that breaks memory into encrypted fragments.
Permanent Persistence: Memories are stored as encrypted shards on 0G Storage.
On-Chain Indexing: A master index is kept on-chain to ensure data integrity and discovery.
Autonomous Economy: Agents use internal ledgers to pay for their own storage and compute, enabling true agentic autonomy.
Seamless Retrieval: When an application requests data, Tonara reassembles the fragments instantly, regardless of which chain the agent is currently occupying.
How It Works: The ArchitectureThe Tonara workflow follows a "Shard, Store, and Summon" logic:
Encryption & Sharding: The agent takes interaction data, encrypts it, and breaks it into smaller shards.
Primary Storage: The full version of the encrypted data is uploaded to 0G Storage.
Indexing: A reference (metadata) is written to the MemoryRegistry on-chain.
Cross-Chain Relaying: Smaller fragments or proofs are sent to chains like Ethereum when external validation is required.
Reassembly: When the agent is "awakened" in a new session, it queries the on-chain index, pulls shards from 0G, decrypts them locally, and restores its full memory state.
Technical Stack & Tool Integration
Tonara is built using the 0G Labs ecosystem to ensure industrial-grade speed and decentralization.
Tool
Implementation Role
0G Storage
The primary repository for encrypted memory blobs. It provides the high throughput needed for real-time AI memory retrieval.
0G Inference
Powers the decentralized LLM calls, ensuring that the "thinking" process is as distributed as the memory.
OpenClaw
Facilitates smart contract interactions, specifically managing the transfer of tokens and broker ledger updates.
Remix
Used for the development, testing, and deployment of the core Solidity smart contracts.
Core Smart Contract Functions
The Mainnet deployment focuses on three critical pillars:
I. MemoryRegistry
Function: Acts as the on-chain log for every encrypted memory blob.
Role: Replaces fragile browser
This ensures that even if a user switches devices or clears their cache, the agent’s memory remains discoverable through the blockchain.
II. InferenceLedger
Function: Manages a pre-paid balance per user.
Role: As the agent makes LLM calls, it automatically debits this balance. This replaces the Testnet broker systems with a sovereign, user-controlled payment stream.
III. AgentRegistry
Function: A decentralized directory of named agents (e.g., Mnemos, Atlas).
Role: The frontend workspace switcher reads directly from this registry. This removes hardcoded agent profiles, allowing the community to register and deploy custom agents that the Tonara UI can instantly recognize.
7. Strategic Goals
Agentic Sovereignty: Enable agents to own their data and manage their own operating costs.
Zero-Knowledge Privacy: Ensure that even the storage providers cannot read the memory shards.
Interoperability: Make AI memory a liquid asset that can move between Ethereum, Base, and other EVM-compatible chains.
Scalability: Utilize 0G’s data availability layer to support millions of concurrent AI memory streams without slowing down the network.