Developers > Perpetual Yield Tranches > Architecture
The main contract used by users is called
IdleCDOwhich allows depositing the underlying and mint tranche tokens (ERC-20), either AA or BB, and redeeming principal and interest from it.
The IdleCDO contract pools users' funds together and uses
IIdleCDOStrategyas a proxy for interacting with an underlying DeFi protocol to deposit funds and collect interest and rewards.
Governance tokens collected as rewards are not redistributed to users directly in the IdleCDO contract but rather sold to the market (
harvestmethod) and the underlying reinvested in the downstream lending provider where possible.
Other tokens, if any (e.g. IDLE that won't be sold or tokens that have no liquid markets) will get redistributed to people who staked their tranches in a
LiquidityGaugecontract usually one for AA and sometimes one for BB (for more info on Gauges, see here).
These are the core contracts used: