In the DeFi agent context, an AI agent in DeFi is software that reads onchain data, evaluates approved actions, and executes transactions within predefined policies. Zyfai applies that model to yield automation: its self-custodial yield agent uses a pre-deployed Smart Account, account abstraction, and scoped Session Keys to automate yield generation in DeFi.
Recently, Zyfai reduced onboarding journey from three signatures to one deposit signature. The result is a more practical starting point for DeFi automation: choose a strategy, approve the mandate, make one meaningful deposit, and let the yield agent operate only within the boundaries that have been defined.
Why AI agents in DeFi need self-custodial smart wallets
A DeFi yield agent monitors opportunities, evaluates liquidity and risk, and decides whether a rebalance meets the strategy's rules. It then needs a way to execute the approved transaction onchain.
That execution layer creates a trust question. If an agent receives an unrestricted private key or control of a shared vault, the user has little visibility into what it can do. If the agent can only recommend actions, the user still has to handle every transaction manually.
Zyfai's architecture takes a different path. The user has a personal Safe Smart Account, also described here as a self-custodial smart wallet. The Agent receives scoped permissions through Session Keys. The Target Registry and Security Proxy Gateway check the permitted contracts, functions, and calldata before execution.
This is the infrastructure problem behind the article: how can an AI agent automate DeFi yield while the user keeps ownership and defines the operating limits?
The old DeFi onboarding flow: three signatures before earning
The previous onboarding sequence asked the user to sign three times:
Deploy the Smart Account.
Approve Session Key.
Deposit funds.
The deposit is the meaningful action from a user's perspective. The first two signatures are necessary infrastructure, but they create friction before the user has seen any value from the product.
The problem becomes more significant when an account must be prepared across multiple chains. From a developer's perspective, asking every new user to complete several setup transactions is difficult to scale. From a user's perspective, a simple goal, putting capital to work, starts to feel like a technical installation process.
Zyfai's solution is to prepare that infrastructure before the user's first deposit.
The new flow: pre-deploy a smart wallet, then deposit once
With the new pre-deployed Smart Account flow, Zyfai prepares a ready-to-use account in advance. This setup includes:
Smart Account deployment
Module installation
Session Key configuration
Ownership handover logic
Preparation for supported chains
A ready-to-use Safe Smart Account with an authorized Agent is reserved for the user. The account remains empty until the first deposit triggers the handover:
Ownership moves from the pre-deployment service to the user.
The Agent's authorization remains in place.
The user's capital is deposited into the Smart Account and can begin working.
The system does the setup work before the user's first meaningful action. Instead of signing each piece of infrastructure separately, the user signs the deposit.
The flow uses a Base deposit in USDC. Paul selects an Agent strategy, opens the advanced configuration, chooses protocol and pool permissions, and deposits. Even after configuring his own strategy and deselecting some pools, he only needs to sign the deposit transaction.
This removes much of the operational friction from onboarding. Users who are familiar with AI agents but less familiar with DeFi can access onchain yield through a simpler, more guided experience.
Session keys for AI agents: a mandate, not a master key
Reducing signatures only makes sense if the permissions behind the Agent remain narrow and inspectable.
Zyfai uses Session Keys to let an Agent execute approved transactions on behalf of a user's Smart Account without requiring a new signature for every action. A Session Key does not provide unrestricted access to the account. It is a permission-scoped mandate.
At Zyfai, Session Keys are scoped to a Target Registry. The registry defines the contracts, functions, and parameters that the Agent is allowed to use:
The Agent can execute only transactions that match approved functions in the Target Registry.
Actions outside the registry are rejected at the contract level, regardless of what the Agent requests.
Adding approved pools or protocols to the registry does not require a new user signature.
Zyfai limits the Agent to approved protocols, pools, and actions. This lets it manage a user's strategy without requiring a new signature for every rebalance.
Account abstraction and smart wallet addresses across chains
The onboarding work also addresses a less visible problem: keeping the user's account identity consistent as Zyfai expands across chains.
The Smart Account address is deterministic because it is derived from a fixed owner and salt. This allows the same account address to be used across the networks supported by the deployment model.
The benefit is more than convenience. A consistent address makes it easier to:
Monitor DeFi positions across chains
Associate activity with the same user-owned smart wallet
Extend an Agent's operating environment without creating a new account identity for every network
Build integrations around a predictable Smart Account address
When the user makes the first deposit, ownership of the prepared Smart Account is transferred to them. The handover is recorded onchain:
An
AddedOwnerevent records the user's EOA as the new owner.A
RemovedOwnerevent records the removal of the pre-deployment service as owner.
After the first deposit, the user owns the Smart Account and the Agent can continue operating through its configured Session Key permissions.
DeFi yield automation: strategy and pool selection stay in the user's hands
One deposit signature does not mean one default for everyone. Users can choose:
The chain where the deposit will be made
The asset to deposit
The strategy, such as Conservative, Aggressive, or Yield Maxxing
Users can choose which protocols and pools the Agent is allowed to use, including Aave, Compound, Fluid, Morpho, and Spark.
The interface lets users save protocol and pool selections, clear all selections, and choose whether future protocols should be approved automatically. Each pool card includes details such as APY, TVL, capacity, liquidity, and risk.
If a pool's TVL is unstable, the interface shows ‘Rebalancing is temporarily restricted.’ The Agent does not move capital simply because a pool is available; it can exclude or block a pool until it meets the relevant conditions.
AI yield optimization and risk checks behind the interface
The user experience is intentionally simple, but the execution layer is not.
The Agent rebalances only after explicit rebalancing checks pass, including:
TVL and liquidity safety
Allocation size
APY thresholds
Slippage and break-even conditions
Utilization conditions
The dashboard surfaces these checks in Rebalancing Updates, including TVL Safety, Delta APY, APY Stability Analysis, Profit vs Cost Analysis, and Money Market conditions.
These checks matter because AI yield optimization is not just a search for the highest headline APY. A strategy must also consider liquidity, utilization, execution costs, stability, and whether a rebalance is worth performing at all.
The Agent's job is to monitor these conditions and move capital only when an approved opportunity meets the strategy's rules. The user chooses the mandate. The Agent handles repetitive monitoring and execution inside that mandate.
Account abstraction for DeFi agents: why the architecture scales
For users, the change removes unnecessary friction from the first interaction with Zyfai. They can connect a wallet, choose an asset and strategy, configure permitted protocols if needed, and deposit with just one signature.
For developers, the benefit is architectural. Smart Account deployment, module installation, Session Key setup, ownership transfer, and expansion to supported chains become account-abstraction operations handled by the product rather than a checklist imposed on every user.
ERC-4337 account abstraction separates the technical preparation of a Smart Account from the user's first capital action. Smart-contract accounts and sponsored setup operations make that separation possible. Our Safe7579 Smart Accounts, Session Keys, Security Proxy Gateway, and Agent Quickstart docs explain the main components of this stack.
That separation is what makes the experience easier to scale. The system can do serious infrastructure work in advance, while the user sees one understandable action: deposit.
Why pre-deployed smart wallets matter for DeFAI
DeFAI is an emerging shorthand for the intersection of DeFi and AI. The category includes agents, copilots, and automation systems that help users monitor, manage, and execute onchain financial activity.
Pre-deployed smart wallets address one of the category's practical problems: an AI agent needs a wallet and an execution policy before it can manage a DeFi position. Preparing that infrastructure in advance makes the first user interaction simpler without removing the policy layer.
The account is prepared before the user arrives. The Agent is authorized through a scoped Session Key. Approved targets are enforced through registries and contract-level validation. Ownership is transferred to the user at deposit and can be verified onchain. Strategy and protocol exposure remain configurable.
The result is a clear division of responsibility:
Zyfai prepares and sponsors the infrastructure.
The user owns the self-custodial smart wallet and sets the mandate.
The yield agent monitors and rebalances within those constraints.
The blockchain provides an observable record of the handover and execution.
That is what agentic DeFi should feel like: simple at the surface, even when the infrastructure underneath is doing serious work.
Frequently asked questions
What are AI agents in DeFi?
AI agents in DeFi are software systems that read onchain data, evaluate possible actions, and execute approved transactions under predefined policies. A yield agent applies that workflow to monitoring rates, liquidity, risk, and portfolio allocations.
What is a DeFi yield agent?
A DeFi yield agent monitors yield opportunities and can rebalance capital when an approved opportunity meets the strategy's rules. In Zyfai's model, the Agent operates through a user-owned Smart Account and scoped Session Key permissions.
How does DeFi automation work in Zyfai?
Zyfai prepares the Smart Account and Agent permissions, then monitors approved protocols and pools. The Agent evaluates conditions such as liquidity, TVL, APY stability, utilization, slippage, and break-even costs before executing a permitted rebalance.
How does Zyfai monitor risk?
Zyfai monitors each opportunity across several dimensions before allowing a rebalance. The Agent checks liquidity, TVL, APY stability, utilization, slippage, stablecoin peg, the estimated cost of moving capital, and even FUD on X. If a pool no longer meets the configured conditions, the Agent can leave the position in the smart wallet until the conditions improve. This keeps yield optimization focused on risk-adjusted outcomes rather than headline APY alone.
What is a self-custodial smart wallet?
A self-custodial smart wallet is a programmable smart-contract wallet owned by the user. It can support account abstraction, transaction batching, sponsored setup, and scoped permissions for automation.
What are Session Keys for AI agents?
Session Keys are permission-scoped keys that let an AI agent execute approved transactions for a Smart Account without asking the user to sign every action. In Zyfai, the Target Registry and contract-level validation limit the contracts, functions, and parameters the Agent can use.
What is a pre-deployed Smart Account?
A pre-deployed Smart Account is a smart-contract wallet whose deployment, modules, and permission setup can be prepared before the user's first deposit. The user receives the prepared infrastructure when making the deposit rather than signing each setup transaction separately.
Explore Zyfai
About Zyfai
Zyfai provides self-custodial access to rule-based DeFi strategies. Its Agents allocate capital across curated opportunities and rebalance under defined rules.
Returns are variable and DeFi risks remain. Your assets remain under your control through the supported self-custodial paths.
