Case Study: Loyal
Case Studies

Case Study: Loyal

MagicBlock
MagicBlock
@ magicblock

When builders imagine AI agents that handle finances, automate transactions, and interact with protocols on your behalf, one question keeps getting in the way: what happens when every transfer your agent makes is visible to the entire chain?

Loyal is an open-source, decentralized AI protocol on Solana, building the missing execution layer for AI agents, private payment rails and onchain task execution, powered by MagicBlock's Private Ephemeral Rollups (PER).


The Problem: Every Agent Action Is Broadcast to the  World

The vision for onchain AI agents is compelling. Imagine an assistant that can process your transactions, pay your invoices, manage your assets, and interact with DeFi protocols without routing through a centralized server.

But there's a fundamental trade-off. On a blockchain, every transaction, every transfer, every interaction is readable by default. When an AI agent moves funds, settles an invoice, or rebalances a position on your behalf, anyone watching the chain can see exactly what it did, how much it moved, and who was on the other end. For any real financial use case, this is a dealbreaker. No business wants its vendor payments visible to competitors and no user wants their entire financial activity graph exposed because they let an agent automate a few tasks.

The hard part is not private inference, but making the agent's actions private: the transfers, the settlements, the onchain execution itself.

The Loyal team recognized this early. The bottleneck for production-grade AI agents on Solana wasn't better models. It was a performant privacy layer for what those agents actually do onchain.

"We built Loyal to solve the last-mile problem for AI agents. Not private thinking, but private doing. An agent that can reason privately but broadcasts every action it takes isn't useful for real financial workflows." - Rodion, Loyal Co-founder.

MagicBlock's PER infrastructure was purpose-built for exactly this kind of use case: sensitive onchain execution that needs to be fast, private, and Solana-native. For Loyal, it meant they could shield agent transactions and task execution inside private rollups, without bridges, and without giving up Solana composability.


Why Private Ephemeral Rollups Are the Right Fit for Agent Execution

MagicBlock's Private Ephemeral Rollup (PER) is a variant of the vanilla Ephemeral Rollup that runs inside a Trusted Execution Environment (TEE), specifically Intel's Trust Domain Extension (TDX) architecture. Think of it as a hardware-secured vault inside a CPU: even the machine operator cannot inspect the memory where computations happen.

For Loyal, this solved the core problem elegantly. Agent-initiated transfers, payment settlements, and sensitive transaction logic could now run inside a hardware-verified execution environment shielded from observers, but still anchored to Solana's base layer with full composability.

The integration is built on three core capabilities that made it the right choice:

Confidential State at the Account Level. MagicBlock's Permission Program allows Loyal to define fine-grained access rules per account. User data and transaction accounts are delegated to the TEE validator, meaning only permissioned parties, authenticated via an onchain access control program, can read or write to them. This approach avoids bridging and grants Solana programs an opt-in path to private execution.

Sub-50ms Execution for Real-Time Agent Operations. Privacy solutions built on zero-knowledge proofs, FHE or MPC often introduce significant latency, sometimes seconds per operation. For an AI agent executing time-sensitive financial operations, this is unusable. Loyal's Private Ephemeral Rollups execute at sub-50ms latency by running inside the secure enclave, settling the state-diff back to Solana L1. Users get Web2-level responsiveness with onchain guarantees.

Minimal Developer Overhead. One of the most important constraints for the Loyal team was avoiding a full rewrite. MagicBlock's integration requires only a few additions to an existing program: permission hooks via the Permission Program, delegation hooks to route accounts into the PER, and an authorization step where users sign a challenge to receive a session token. The core program logic stays unchanged.


What Loyal Is Building: The Roadmap to Autonomous Onchain Agents

Loyal's vision unfolds in stages, each one expanding the scope of what AI agents can execute privately on Solana.

Phase 1: Private Transactions and Payments. The initial focus is giving AI agents the ability to process financial transactions, invoices, and asset transfers without exposing balances, counterparties, or transaction amounts onchain. MagicBlock's PER ensures that even the validator running the computation cannot observe the agent's execution state.

Phase 2: Intelligent Automation. With private execution established, the protocol expands to automate more complex workflows: scheduling recurring payments, managing DeFi positions, interacting with protocols on behalf of users, all with the same privacy guarantees on every action.

Phase 3: Full-Stack Onchain Agent. The long-term target is an AI agent layer that can handle the full breadth of a user's financial and operational life onchain, from routine payments to complex multi-protocol strategies, with every execution step shielded by default.

"We're not building another chatbot. We're building the execution layer that lets AI agents operate onchain the way they'd need to for real users where every transfer and every action is private by default."


Recognized as One of Solana's 12 Privacy Trailblazers

In December 2025, Solana's official account published a thread spotlighting 12 privacy projects across six categories: encrypted computation, privacy infrastructure, payment wallets, private transactions, prediction markets, and smart protection. Loyal was included in the encrypted computation category — recognition that the team's approach to private onchain execution for AI agents had earned its place among the ecosystem's most credible builders. For Loyal, the recognition validated a thesis the team had held from the beginning: that the next wave of meaningful agent-driven applications on Solana would require private execution rails, not just faster inference or lower fees.


Lessons for Builders Tackling Private Onchain Execution

Loyal's journey offers a few practical insights for builders who want AI agents that can actually execute sensitive operations onchain:

Composability is non-negotiable for agent-driven apps. Users of Loyal's agents will expect them to interact with the full Solana ecosystem, from simple token transfers to complex DeFi interactions. Any privacy solution that requires bridging or forking away from the base layer would break the agent's utility. With MagicBlock, Loyal preserves composability without compromise.

The integration is simpler than it looks. A common fear among builders considering privacy infrastructure is that it requires a full architectural overhaul. In practice, adding MagicBlock's Private Ephemeral Rollups to a program is a matter of adding permission hooks, delegation logic, and an authorization flow for users. The program logic itself doesn't change.


What's Next for Loyal

The protocol is live on mainnet with private transfers. The roadmap toward autonomous, privacy-preserving AI agents on Solana — Loyal's stated goal for 2027 — is unfolding. First private transactions and payments. Then intelligent automation. Then the full agent execution layer.

If Loyal's early progress is any indication, the missing ingredient for production-grade AI agents on Solana wasn't better models or cheaper compute. It was the private execution rails that let agents act on behalf of users without broadcasting every move to the world.

Loyal is building that foundation.

Interested in building privacy-first applications on Solana with MagicBlock's Private Ephemeral Rollups? Explore the documentation and connect with the team on Discord.

Follow Loyal's progress at @loyal_hq on X.