Protocol
Parameters and invariants
Constants in SoftlineCredit
| MIN_SHARE_BPS / MAX_SHARE_BPS | 500 / 5000 |
|---|---|
| MIN_FEE_BPS / MAX_FEE_BPS | 200 / 3000 |
| PROTOCOL_CUT_BPS | 1000 (10% of the fee part of each repayment) |
| MIN_TARGET | 10 USDG |
| MIN_FUNDING / MAX_FUNDING | 1 day / 14 days |
| STAKE_DELAY | 2 days before a new staking address takes effect |
Accounting
owed = principal x (10000 + feeBps) / 10000, fixed at the draw.- On each repayment
r:cut = r x feeBps x 1000 / ((10000 + feeBps) x 10000)goes to stakers;r - cutis shared among lenders pro-rata to deposits through an accumulator. claimable(lender) = deposit x accPerUnit / 1e18 - claimed.
Invariants
- The USDG held by Softline is at least the deposits of lines in Funding or Cancelled, plus everything claimable, plus protocol fees not flushed, plus failed payouts waiting for their owner.
repaidnever exceedsowed; the line closes when they are equal.- An inbox only releases USDG to Softline, and only through
settle. - The owner can set the underwriter and propose a staking address. No owner function moves deposits, repayments or agent revenue.