Protocol controllers mediate each action: AccountManager routes the call to a Registry-approved controller, which checks the target and tokens, executes from the margin account, and reports the change so recognized collateral stays correct.
Shared account risk
All positions in an account share its health factor and debt. One profitable Farm position does not isolate it from another position’s losses. External positions must be exited before their underlying can repay a loan.Execution boundaries
Each external action is its own transaction. A deposit and a single borrow can go out together (deposit_and_borrow), but borrow-then-farm, LP entries and unwinds take several steps. Earlier confirmed steps survive a later failure, so check the account before retrying.
A registered controller doesn’t guarantee that an external pool has liquidity; the transaction simulation is the final check.
See Farm, Leveraged Yield and Controllers.
