Bonding curves in DeFi, explained

Bonding curves in DeFi, explained
Share
Facebook
Twitter
Pinterest
WhatsApp
Telegram

Article Contents

In This Article

Understanding bonding curves in DeFi

Bonding curves in decentralized finance (DeFi) leverage smart contracts and mathematical formulas to dynamically adjust a token’s price based on its supply. 

Bonding curves are smart contracts that algorithmically determine a token’s price based on its circulating supply. As more tokens are purchased, the price adjusts upward, and as tokens are sold or removed from circulation, the price adjusts downward.

This automated pricing mechanism ensures liquidity for new tokens without the need for traditional order books or external liquidity providers. It does so by embedding the liquidity directly into the token’s smart contract.

Specifically, bonding curves leverage the economic principles of supply and demand. When demand for a token rises, reflected by increased purchases, the smart contract raises the price accordingly. And when selling activity indicates falling demand, the smart contract lowers the price.

This dynamic adjustment happens algorithmically based on a predefined curve that models the relationship between price and quantity supplied. So, bonding curves allow for automated, decentralized liquidity that reacts to real-time market conditions.

Price determination in bonding curves

Bonding curves in DeFi adjust token prices with supply, supporting various economic strategies and market dynamics.

Mathematical modeling enables projects to customize bonding curve tokenomics by defining unique curves that determine how a token’s price changes based on its supply. There’s theoretically no limit to the types of curves, but the most common ones come in several forms:

Linear curves

A linear bonding curve is a simple mathematical model where the price of a token increases in direct proportion to the number of tokens sold. In this model, each additional token minted or sold increases the price by a fixed, predetermined amount.

Below is a simple graphical representation of a linear curve, where the X-axis (horizontal) represents the supply of tokens and the Y-axis (vertical) shows the price of each token at that supply level.

A linear bonding curve

Exponential curves

Exponential curves make the token’s price depend exponentially on the supply. This means if the supply doubles, the price more than doubles. Even adding a few more tokens can lead to big price jumps. This makes the token get more expensive much faster.

These curves reward early buyers the most. When demand goes up later, the first users will likely sell their tokens at much higher prices. So, exponential curves work well for projects that want to encourage early participation. The first users take the most risk but can profit the most if the project succeeds.

An exponential bonding curve

Logarithmic curves

Logarithmic curves make the token price rise rapidly at first as more tokens are added. But then the price increases slow down as the supply keeps expanding. So, the price spikes in the beginning but levels off over time. This benefits early investors the most since their tokens gain value quickly up front. The potential for fast early profits can attract the first buyers to provide liquidity.

A logarithmic curve

In DeFi, besides the linear, exponential and logarithmic models, diverse bonding curve types are possible. For example, there are S-Curves for phased growth and stabilization, Step Curves for milestone-based price increases, and Inverse Curves to reduce prices as supply grows, each tailored for specific bonding curve economic outcomes and project goals.

Bonding curve applications in crypto

Bonding curves provide automated token liquidity and dynamic pricing to facilitate projects, trading, stablecoins, communities and governance.

Bonding curves serve as a foundational mechanism for automated liquidity bootstrapping in initial decentralized exchange offerings (IDOs), enabling projects to launch new tokens with dynamically adjusted liquidity pool reserves. This model departs from traditional order books, ensuring a continuous and algorithmic adjustment to liquidity based on real-time demand​​. The flexibility of dynamic pricing in blockchain, which is enabled by bonding curves, creates new possibilities for token distribution and trading.

Platforms like Uniswap and Curve utilize bonding curves for autonomous market making, enhancing liquidity and enabling more efficient trading for a wide range of tokens, especially those that might otherwise suffer from low liquidity​​.

Bonding curves are pivotal in stablecoin protocols for building currency reserves and maintaining pegs through algorithmic supply adjustments, ensuring the stability of these digital currencies in a fully decentralized manner. However, this approach carries risks, as algorithmic stablecoins rely entirely on bonding curves and programmed supply changes to maintain their peg.

For example, the algorithmic stablecoin TerraUSD (UST) lost its 1:1 dollar peg in May 2022 after a dramatic bank run drained its reserves. This shows there are still stability challenges with decentralized algorithmic stablecoins compared to asset-backed models.

When demand falls rapidly, algorithmic stablecoins can fail to adjust supply quickly enough to uphold their peg. So, while bonding curves allow for decentralized stability mechanisms, they have not yet proven fully resilient to bank runs compared to collateralized alternatives.

Bonding curves facilitate continuous token models in DeFi that allow for automated liquidity bootstrapping, autonomous market making and dynamic pricing adjusted to real-time demand.

They are instrumental in decentralized autonomous organization (DAO) governance, enabling the purchase of voting tokens through bonding curves, which aligns investment with governance participation and ensures that pricing reflects the level of commitment to the DAO​​.

Decentralized exchanges (DEXs) and bonding curves

Bonding curves enable customized, automated decentralized liquidity and pricing for varied decentralized exchanges (DEXs).

Uniswap

Uniswap uses a constant product formula, a specific type of bonding curve, for its automated market maker (AMM) protocol. This formula ensures liquidity by maintaining a constant product between the quantities of the two assets in any given liquidity pool. For example, if the pool contains Ether (ETH) and another token, the product of their quantities remains constant, dictating the price based on supply and demand dynamics. This approach provides continuous liquidity and price discovery without using traditional order books.

Curve Finance

Curve Finance in DeFi focuses on stablecoins and employs a specialized bonding curve optimized for assets supposed to have equal value. Its bonding curve is designed to reduce slippage and maintain stable prices for closely pegged assets, such as different stablecoins pegged to the United States dollar. The curve is flatter for pairs of assets with similar values, which minimizes the impact of trades on price changes, making it efficient for swapping between stablecoins.

Balancer

Balancer uses a generalized version of the constant product formula, allowing custom liquidity pools with up to eight assets in any weighted proportion. This flexibility lets users create their own self-balancing portfolios and liquidity pools with a custom bonding curve defining the relationship between the pool’s asset prices and quantities. Balancer’s approach extends the utility of bonding curves beyond two-asset pools, accommodating a broader range of trading strategies and portfolio management practices.

Challenges associated with implementing bonding curves

Bonding curves face modeling, security and legal challenges that require extensive testing, auditing and compliance analysis to properly design, deploy and regulate automated token pricing systems.

Designing appropriate curve shapes that align incentives and encourage desired market behavior requires extensive modeling and testing. For example, too steep or shallow curves may enable price manipulation

The security of smart contracts executing bonding curves must be audited to safeguard against exploits that could compromise price integrity. Also, smart contracts need to be optimized to minimize the gas costs of automated trades. 

Ensuring the security of smart contracts governing bonding curves is critical, as flaws could enable arbitrage or manipulation. Formal verification, bug bounties and audits help mitigate this risk. Ongoing research is focused on enabling dynamic curves that can be adjusted algorithmically in response to market conditions.

The regulatory treatment of bonding curves is still an open question. Most jurisdictions have not provided clear guidance on whether AMMs, like bonding curves, constitute regulated trading venues or securities issuances.

Projects must carefully analyze the rights conferred by tokens sold through bonding curves on a jurisdiction-by-jurisdiction basis. Local regulations related to crypto assets and securities differ across regions.

For example, if tokens entitle holders to profits, governance rights, etc., they may be considered securities in some jurisdictions, requiring compliance with relevant securities regulations.

However, other jurisdictions may be more flexible in classifying utility tokens, even those with ancillary profit or governance rights. So, projects should review regulations in their target markets.

Many projects adopt a utility token model, where tokens solely provide access to a project’s products or services with no profit rights or governance abilities for holders. This restricted token design avoids meeting the legal definitions of a security in many cases.

However, Know Your Customer (KYC) and Anti-Money Laundering (AML) regulations may still apply even to pure utility tokens. These regulations require verifying user identities and sources of funds.

Projects must seek legal advice to navigate this complex landscape. The regulatory treatment of crypto tokens continues to evolve across jurisdictions. Ongoing legal developments may provide clearer frameworks for designing compliant token implementations and bonding curve systems.