TARE liquidations¶
API reference: AuctionHouse · TareEngine
ELI5: If your loan gets too risky, bots can pay off part of your debt and take your collateral — plus a small reward. If you're already underwater, a different path settles bad debt.
What you can do¶
| Function | When |
|---|---|
liquidate(collateral, user, debt_to_cover) |
HF < 1, position still solvent |
settle_bad_debt(user) |
Collateral value < debt |
retire_bad_debt(amount) |
Refill surplus to pay down ledger |
Flywheel fit¶
Liquidation bonuses and stability fees increase surplus → sTARE APY + Keep reinvestment. Does not route through Coil.
Contract walkthrough¶
Liquidate (tare_engine.vy):
assert HF(user) < MIN_HEALTH_FACTOR- Seize collateral worth
debt_to_cover+ 10% bonus - Burn
debt_to_coverTARE from liquidator - Assert HF strictly improved
Settle bad debt:
- Require insolvency (collateral USD < debt)
- Move collateral to
seized_collateral - Zero user debt
- Burn
min(debt, surplus)from buffer - Book remainder as
total_bad_debt
flowchart TD
A[HF drops below 1] --> B{Collateral covers debt+bonus?}
B -->|yes| L[liquidate]
B -->|no| S[settle_bad_debt]
S --> AH[AuctionHouse optional]
S --> BD[total_bad_debt ledger]
AuctionHouse — Dutch auction on seized collateral; proceeds to surplus.
Parameters¶
| Param | Value |
|---|---|
MIN_HEALTH_FACTOR |
1e18 |
LIQUIDATION_BONUS |
10% |
What can go wrong¶
User risks
- No warning UI on-chain — monitor HF off-chain.
- Deep insolvency cannot use
liquidate— must use bad-debt path. - Surplus exhaustion →
total_bad_debtrises (transparent on-chain).
See Liquidations (learn).
Source: TARE-Stablecoin/src/tare_engine.vy, auction_house.vy