ModelBoth floors, by the size of a position2% tax
0120M240M360M480M600M720M0246810TOKENS IN THE POSITIONBNBCURVE FLOORGRADUATION FLOORLARGEST LOAN = LOWER FLOOR / 1.25
Docs

How the vault works.

Mechanism rules are fixed in code. The drawing is the heart of it: a loan may be at most the lower floor divided by 1.25.

The vault

Each vault belongs to one Flap tax token and runs a BNB lending pool for long positions on that token only. Lenders deposit BNB for shares. A trader sends margin; the vault lends from the pool's idle BNB, buys the token on Flap's Portal with both, and holds the tokens for that position.

A long opens only if, at that moment, its tokens would still repay 1.25× the loan in the worst case, both on the curve and after graduation. Both bounds depend only on the position's own token count and on constants fixed at launch, so the vault needs no price oracle and liquidates nothing.

Chart of the Flap bonding curve: the price per token rises about thirteenfold as 800 million tokens leave the curve, and the BNB under the curve reaches about 16 BNB at graduation. (open large)
Flap's curve: about 16 BNB of buying takes it to graduation.

The two floors

For a position holding T tokens, the curve floor assumes every other holder sells first, so the position sells from the bottom of the curve. The graduation floor assumes every other outside token is sold into the freshly seeded PancakeSwap pool first.

curve floor Fc(T) = (1 − fs) · ( K / (A − T) − r ) graduation floor Fg(T) = W1 · a / (Tk1 + a) Tk1 = P0 + (D − T), W1 = W0 · P0 / Tk1, a = T · (1 − φ) open only if min(Fc(T), Fg(T)) ≥ 1.25 × loan

K = k·1e18 and A = 1e27 + h are the curve's constants, D is the graduation supply (800M tokens), W0 ≈ 16.00 BNB and P0 = 200M tokens seed the pool. fs and φ are the sell tax plus 1%. Every step rounds down.

Leverage limits

The highest leverage is where the lower floor meets 1.25× the loan. It falls as the curve fills, and on a young curve it rises with margin, up to the 2.0x cap. The map is the model at a 2% tax; the vault card simulates the exact figure from your wallet.

Heat map of the highest leverage by margin and curve reserve: bright where up to 2.0x fits, dark where only small leverage or none fits. (open large)

Lending and revenue

Deposits first pull in pending token tax, then buy shares at gross pool value: idle BNB plus open loans, including revenue still releasing. Withdrawals use net value, subtracting the unreleased amount. Leaving before the release that existed at deposit ends leaves your part of it behind, so you can receive less than you deposited. Half of the token's tax and the 1% open fee reach net value linearly over 3 days; arrivals merge at an amount-weighted end. Withdrawals are limited to idle BNB.

The other half of the tax goes to the developer wallet. While no shares are held outside that wallet, all tax goes there. At both edges of that period the remaining pool cash goes to the developer, and open loans become its pool shares. A later deposit cannot collect revenue from before it joined.

Diagram of the pool's value: idle BNB that lenders can withdraw, BNB lent to open positions, less revenue that is still being released. (open large)

Term and take-over

Loans run 30 days. After that anyone may pay a loan in full; the payer receives a share of the position's tokens that grows linearly from 0% at expiry to 100% 24 hours later, and the owner keeps the rest as an unlevered position. Nothing is sold. An owner avoids a take-over by closing before expiry.

Graduation

New longs open only while the token is on its bonding curve, and a buy that would graduate the token is refused. Positions opened before graduation stay open and close through the Portal's routing to the PancakeSwap pool.

Diagram of graduation: at about 16 BNB the curve's BNB and 200 million tokens seed a PancakeSwap pool; the graduation floor assumes every other token is sold into that pool first. (open large)

Fees

Open fee1% of the loan, rounded up, paid from margin to the pool
Token taxThe token's own buy and sell tax: half to the pool, half to the developer wallet (all of it while nobody lends)
Trading feeFlap's Portal fee on the curve, the DEX fee after graduation
InterestNone
Factory commissionNone
Diagram of where the money goes: half of the token's tax and the 1% open fee go to the lending pool and reach lenders over 3 days; the other half of the tax goes to the developer wallet, all of it while nobody lends; loans carry no interest. (open large)

Roles

Traders open and close their own single position. Lenders deposit and withdraw. Anyone may take over a loan past its term. The Flap Guardian can upgrade the vault's implementation through the factory.

The developer wallet (the factory's deployer) receives the other half of the tax. It can pause new positions (closing, lending and take-overs keep working) and recover tokens sent to the vault by mistake (the vault's token only above what positions hold); the Flap Guardian can make the same calls as a backup, with any payment going to the developer wallet. None of these calls can move lenders' deposits, lenders' revenue or positions.

Risks

  • The token can fall. A long loses its margin first; a close sells at whatever the market pays.
  • A loan left past day 30 can be taken over, and the taker's share grows by the hour.
  • Lenders can withdraw only idle BNB; lent BNB returns as positions close or are taken over.
  • Figures on this site's pages come from a model of the vault's rules; the vault card reads and simulates the live state before you sign.
  • Smart contracts and the chain they run on can fail in ways no rule here describes.

Contracts and constants

Leverage1.0x to 2.0x
Worst-case cover at open1.25× loan
Open fee1% of the loan
Smallest margin and deposit0.01 BNB
Tax split50% pool · 50% developer
Revenue release3 days per amount
Loan term30 days
Take-over window24 hours
Interestnone