Skip to content
CorbelBeta
D-07 · The mandate

[D-07]Layers

The mandate

An AI agent trades the owner's money. A contract holds the rules. The agent pays for trying to break them.

How it works#

  1. 01FundThe owner puts money in a mandate vault and writes the rules.
  2. 02BondThe agent posts a bond in USDG before it may trade.
  3. 03TradeEvery trade is checked by the contract, not by the agent.
  4. 04PayA broken rule costs the agent part of its bond. The owner gets it.

Five skills#

[M-00]THE MANDATE
#SkillRuleIn the demo
01ASSETSBoth sides of a trade must be on the owner's list.USDG, WETH, ETH and NVDA only
02SIZEEach trade stays under a cap per token.1,000 USDG or 0.5 WETH per trade
03BUDGETEach token has a daily spending cap, reset at 00:00 UTC.2,000 USDG or 1 WETH per day
04PRICEThe fill must stay close to the pool's own price.1% from the pool; pool fee 1% max; no unknown hooks
05WINDOWTrades happen only in the owner's hours and days.Weekdays only (UTC)

The eleven rules#

  1. 01Only listed assets, on both sides of the trade.
  2. 02No trade larger than the per-trade cap.
  3. 03No more than the daily budget per token.
  4. 04On V2, the minimum output is the pool's quote minus the allowed slippage.
  5. 05On v4, the contract sets the price limit itself. The agent can't loosen it.
  6. 06No pool with a fee above 1%, a dynamic fee, or a hook the owner didn't approve.
  7. 07Trades only inside the trading hours, and on weekdays if the owner says so.
  8. 08A cooldown between trades, if the owner sets one.
  9. 09No bond, no trade. Each violation takes 10% of the bond to the owner.
  10. 10The third violation freezes the agent and sends the rest of the bond to the owner.
  11. 11Output stays in the vault. Only the owner withdraws, and never the agent's bond.

Try to break it#

The site runs a real mandate contract inside a simulation of the live chain. Pick an attack and watch which rule stops it.

Open Break it