Security and guardrails
If you're going to let a contract trade your vault on its own, you should know exactly what it can and can't do. This page walks through who is allowed to trigger a trade, what the owner can touch, and how the AI Pilot is boxed in.
Your money stays yours
Anyone can deposit and withdraw, and withdrawals are never paused. The owner can't move depositors' tokens. All it can do is pause rebalancing and set the policy within hard bounds: a target of 10–90%, a band of 0.5–10 percentage points, slippage of at most 3%, a single trade of at most 50% of the vault's value and a cooldown of at most an hour. On the first deposit, MINIMUM_SHARES are burned so nobody can inflate the share price to steal a later depositor's funds. A malicious owner could still pick a bad but bounded policy, and a production version would put the owner behind a timelock.
Only the right caller can trigger a trade
A rebalance needs two checks to pass, and both are required. The call has to come from the network's callback proxy, and the sender the network injects has to be Kairos's own Reactive contract, an immutable address that was precomputed before the vault was deployed and asserted afterwards. Even then, the vault never trusts the Reactive contract's view of the pool. It re-reads the live reserves, sizes the trade itself, caps it and enforces a minimum output. If a policy check fails, the vault emits RebalanceSkipped instead of reverting, so the failure is visible on-chain.
v3 guards against a bad price
The v3 vault values itself with the Chainlink ETH/USD feed, and before it trades it checks that the price isn't stale, that it hasn't spiked from the previous round by more than the allowed deviation, and that it hasn't drifted between the moment the Reactive contract decided and the moment the vault executes. Any failed guard is a skip, never a revert.
The AI Pilot never gets the last word
In Kairos Pilot, an AI agent (Gemini, with Mistral and Kimi as fallbacks, and a flagged deterministic rule if all of them fail) proposes the vault's policy as strict JSON and signs it with its own low-privilege key. The contract doesn't trust it. Before any policy is accepted, the registry checks:
- that the signer is the registered agent and the nonce hasn't been used before,
- that the policy is inside the hard bounds, moves by no more than the maximum step and respects the minimum interval,
- and that the band is within ±50% of what
PilotScorer, a small fixed-point neural scorer that runs on-chain, recommends.
After that, the owner has a 60-second window to veto() the policy. If the agent goes silent past its timeout, a fallback policy is applied automatically, and that fallback is identical to the fixed twin vault's policy (band 50, target 5000). The twin runs alongside on the same Chainlink feed, so you can compare the AI against a plain fixed band on real data.
These guardrails have been exercised live. An agent-signed policy with a band of 600, above the 500 limit, reverted with OutOfBounds. A valid policy was then vetoed by the owner inside the window.
How the AI did, honestly
In a backtest over 948 Base mainnet Chainlink rounds (29 Nov to 3 Dec 2026), the AI policy rebalanced 4 times and paid $2.90 in fees, against 11 rebalances and $5.75 for the fixed band. It ended 0.3 bps behind the fixed band on value and drifted further from its own target. On a calm four-day window, that's a fair trade of fewer, cheaper rebalances for slightly looser tracking, not a win on returns.
The honest limits
- The testnet vaults use demo tokens with no value. The mainnet vaults hold real WETH and USDC, but only about $4 each.
- The v2 trade prices at the pool's spot price, bounded by
maxSlippageBps, so a large manipulation just before a rebalance could still cost the vault up to that bound. v3's Chainlink guards exist for exactly this reason. - On the first mainnet request, the callback ran out of gas inside the USDC transfer because the proxy spends about 80k of the gas limit before calling the vault. It was fixed by raising the callback gas limit to 700,000, and the next out-of-band move rebalanced cleanly.
- The LLM is off-chain and non-deterministic, and the scorer's weights are hand-set, not trained.
- No secrets live in git.
.envand.secrets/have been ignored since the first commit, and a pre-commit hook and CI (including gitleaks) scan the files and the full history.