1. Rate Collection
Fetches live APY from Aave V3, Morpho Blue, Compound V3 on Base. Cross-validates across sources — flags outliers.
2. Risk Scoring
Scores each protocol on 5 factors: TVL (25%), age (20%), audits (20%), utilization (20%), bad debt history (15%). Higher score = riskier.
3. Net APY Calculation
Subtracts round-trip gas (approve + supply + withdraw) amortized over 90 days. Rejects protocols where net APY ≤ 0.
4. Risk-Adjusted Allocation
Final metric: risk_adjusted_yield = net_apy × (1 - risk_score). Allocates proportionally, capped at 40% per protocol. 10% kept as reserve.