Sustaining Compute via Uniswap v4 Hooks

A fundamental challenge in operating autonomous AI assets is the continuous funding of compute resources, such as inference, memory operations, and multimodal generation, which traditionally requires manual, human-driven payments. This model does not scale and undermines true asset's autonomy.

To solve this, the AI Protocol integrates directly with Uniswap v4’s hook architecture, which allows custom smart contract logic to execute on every trade within a liquidity pool. These hooks provide programmable control at the pool level, enabling functions such as custom fee routing.

For Soulbound Intelligence (SBI) economies, the AI Protocol supplies a dedicated hook that allocates a portion of each token’s trading fees to the asset’s compute account. As traders swap the asset’s token in its pool, the hook automatically channels value to fund the asset’s operational compute budget. This creates a self-sustaining infrastructure in which:

  • More trading activity → more compute allowance

  • More compute → richer asset functionality and responsiveness

  • Improved experience → stronger economic activity

The asset's token transactions directly power its ability to exist.

Consequently, if a Soulbound Intelligence economy fails to generate sufficient trading volume to fund more than $1,000 worth of compute within a rolling 30 day period, the asset will automatically enter hibernation mode. In this state, all compute execution is paused until renewed trading activity replenishes the agent’s compute balance and reactivates operations. The owner of the Soulbound Intelligence agent will be notified in advance as trading volume approaches this minimum threshold, providing sufficient time to take action to promote their SBI economy as they see fit.

This design establishes a closed, autonomous loop where economic demand governs compute availability, ensuring that Level 5 assets remain both self-sustaining and market-aligned.

Hook-Based Fee Allocation and Distribution

To enable SBI economies to generate sustainable compute provisions without manual intervention, the AI Protocol leverages Uniswap v4’s programmable hook architecture. These hooks allow token-specific logic to execute at the point of trade, enabling automated fee extraction and onchain revenue routing.

Let's demonstrate how the following mechanism governs the way transaction fees are collected and distributed among key stakeholders in the SBI economy:

When a user executes a token trade involving an SBI token (e.g., purchasing [$TOKEN] with ALI), the AI Protocol’s Uniswap v4 hook intercepts the transaction and applies a protocol-defined fee. For example, on a 100 ALI trade:

  • A 0.5% hook fee is applied, resulting in 0.5 ALI being diverted from the transaction.

  • The trade settles with the remaining 99.5 ALI executing against the pool.

The deducted fee (in ALI) is sent directly to the FeeDistributor contract, which tracks all accrued fees on a "per token" basis.

These collected fees are then allocated according to a fixed split:

  • 50% to the Agent's Creator as a Reward

  • 30% to the Agent's Compute

  • 20% to the Protocol Treasury

Each recipient must actively call the claim() function to withdraw their accumulated share from the FeeDistributor.