Skip to content

lakonema2000/msc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MSC Revenue Tracking — Sky Prime Agents

Monthly Settlement Cycle (MSC) analysis for prime agents in the Sky ecosystem (formerly MakerDAO). Each prime agent mints USDS debt via the allocator framework and deploys it into yield-generating venues.

Architecture

MSC diagram

The Allocation Module is a closed system — the Vat mints debt for each agent's ilk. The MSC process settles gains between the Prime Agent (SubProxy) and Sky (Surplus Buffer).

Agents

Agent Ilk Allocation venue Status Details
OBEX ALLOCATOR-OBEX-A Maple syrupUSDC Active (Nov 2025) agents/obex/
Skybase TBD TBD Pending agents/skybase/
Grove TBD TBD Pending agents/grove/
Spark TBD TBD Pending agents/spark/
Prysm TBD TBD Pending agents/prysm/
Keel TBD TBD Pending agents/keel/

Shared contracts

Contract Address Role
Vat 0x35D1b3F3D7966A1DFe207aa4514C12a259A0492B Source of truth for debt (frob / ilk art)
USDS 0xdC035D45d973E3EC169d2276DDab16f1e407384F Stablecoin (debt denomination)
sUSDS 0xa3931d71877C0E7a3148CB7Eb4463524FEc27fbD Savings token
USDC 0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48 Common intermediate token

Rates (all agents)

Rate Value Description
SSR (Sky Savings Rate) Variable Base rate, set via SP-BEAM governance
Borrow rate SSR + 0.30% APY Cost of minting USDS debt
Agent rate (USDS) SSR + 0.20% APY Earned on idle USDS in subproxy
Agent rate (sUSDS) 0.20% APY Earned on sUSDS in subproxy (flat, not SSR-based)

All rates are APY with per-second compounding. See RULES.md for the full SSR history and calculation methodology.

Shared queries (parameterized)

All agent-specific queries are parameterized — pass different addresses/ilk to run for any agent. Default parameters are set to OBEX.

Query ID Local file Parameters
SSR history 6953056 queries/shared/6953056_ssr_history.sql (none)
Daily debt increases 6954382 queries/shared/6954382_daily_debt_increases.sql ilk_bytes32, start_date
Daily utilized USDS 6954386 queries/shared/6954386_daily_utilized_usds.sql ilk_bytes32, subproxy_address, alm_proxy_address, start_date
Monthly sky revenue 6954384 queries/shared/6954384_monthly_interest.sql ilk_bytes32, subproxy_address, alm_proxy_address, start_date, calendar_start_date
Monthly PnL 6954380 queries/shared/6954380_monthly_pnl.sql + venue_token_address
Subproxy USDS balance 6954383 queries/shared/6954383_subproxy_usds_balance.sql subproxy_address, start_date, calendar_start_date

Interest calculation

The APY already accounts for compounding. For any debt D over d days:

Interest = D * [(1 + APY)^(d / 365) - 1]

Daily interest is computed as:

daily_interest = D * [(1 + APY)^(1/365) - 1]

Dividing APY by 12 (APR approach) is incorrect — it overstates monthly cost by ignoring that compounding is already embedded in the APY.

PnL framework (common to all agents)

Prime agent revenue:

  • Mark-to-market change in allocation position value minus cost basis (e.g., Maple syrupUSDC yield for OBEX)

Agent rate:

  • USDS in subproxy: balance × (SSR + 0.20%) APY
  • sUSDS in subproxy: balance × 0.20% APY (flat, not SSR-based)

Sky revenue:

  • Utilized USDS × (SSR + 0.30%) APY
  • Utilized USDS = total frob debt - subproxy USDS - subproxy sUSDS - ALM proxy USDS

Monthly PnL = prime agent revenue + agent rate - sky revenue

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors