StableSwap-NG: Overview
Contract Source & Deployment
Source code is available on GitHub. The following documentation covers source code up until commit number 5f582a6
.
All stableswap-ng deployments can be found in the "Deployment Addresses" section.
For an in-depth understanding of the StableSwap invariant design, please refer to the official StableSwap whitepaper.
The Stableswap-NG AMM infrastructure represents a technically enhanced iteration of the previous stableswap implementation. It comprises the following key components:
-
AMM Blueprint Contracts
Stableswap-NG has two main implementations:
-
Pool and Gauge Factory
The Pool Factory is used to permissionlessly deploy new plain and metapools, as well as liquidity gauges. It also acts as a registry for finding the deployed pools and querying information about them.
-
Math Contract
Contract which provides mathematical utilities for the AMM blueprint contracts.
-
Views Contract
Contract targeted at integrators. Contains view-only external methods for the AMMs.
-
Liquidity Gauge Blueprint Contract
A liquidity gauge blueprint implementation which deploys a liquidity gauge of a pool on Ethereum. Gauges on sidechains must be deployed via the
RootChainGaugeFactory
.LiquidityGauge.vy
soon -
Oracles
Exponential moving-average oracles for the
D
invariant and for the prices of coins within the AMM.