Smart Contracts

Architecture Diagram

Lending Pool Management

The Lending Pool Management smart contract is responsible for:

  1. Loan Origination: Handles loan requests, matches borrowers with lenders, and initiates loan disbursement.

  2. Interest Calculation: Implements the dynamic interest rate model based on pool utilization and risk factors.

  3. Repayment Processing: Manages loan repayments and distributes interest to lenders.

  4. Default Handling: Triggers liquidation processes when loans default.

Master Pool Management

The Master Pool Management smart contract oversees:

  1. Liquidity Aggregation: Collects funds from liquidity providers into a single pool.

  2. Fund Allocation: Distributes funds to various Lending Pools based on demand and risk parameters.

  3. Yield Distribution: Calculates and distributes yields to liquidity providers.

  4. Rebalancing: Periodically rebalances funds across Lending Pools for optimal utilization.

Collateral Escrow

The Collateral Escrow smart contract manages:

  1. Collateral Locking: Secures tokenized RWAs when a loan is originated.

  2. Collateral Release: Releases collateral upon full loan repayment.

  3. Liquidation Support: Facilitates the liquidation process when loans default.

  4. Collateral Valuation: Interfaces with oracles to maintain up-to-date collateral valuations.

Last updated