pump-bonding-curve

Installation
SKILL.md

Bonding Curve — Pricing, Quoting & AMM Mathematics

Implement and maintain the constant-product AMM bonding curve math that powers Pump token pricing — including buy/sell quoting, fee-aware calculations, market cap computation, reserve management, and edge-case handling for new, active, and migrated curves.

Context

Pump tokens are priced using a constant-product bonding curve ($x \times y = k$) where $x$ = virtual SOL reserves and $y$ = virtual token reserves. The bonding curve determines token prices during the pre-graduation phase. Once market cap reaches a threshold, the token "graduates" and migrates to a PumpAMM pool.

Key Files

  • src/bondingCurve.ts — all bonding curve math functions (buy/sell quoting, market cap)
  • src/fees.ts — fee computation (basis points, tiered fees, ceiling division)
  • src/state.tsBondingCurve, Global, FeeConfig, FeeTier interfaces

Constant-Product Formula

$$x \times y = k$$

Installs
2
GitHub Stars
86
First Seen
May 8, 2026
pump-bonding-curve — nirholas/pump-fun-sdk