Aptos DeFi Ecosystem. Part 2. Liquidity Pools.

Educational Content: How to Earn on Your Assets Using Liquidity Pools in the APTOS Ecosystem?

desadm.apt
6 min readJun 1, 2024
It’s an Aptos thing

Theoretical Part. Introduction

A liquidity pool is a fund composed of two or more tokens locked in a smart contract, used for trading on decentralized exchanges (DEX). Liquidity pools provide liquidity for trading pairs, allowing users to make swaps without traditional intermediaries. Here’s how it works:

  1. Creating a Liquidity Pool. A liquidity pool is created by depositing two tokens in a specific proportion into a smart contract. For example, a pool might consist of APT and USDT tokens.
  2. Liquidity Providers. Users who add their tokens to the pool are called liquidity providers (LPs).
  3. Trading Mechanism. When a user wants to exchange one token for another, such as APT for USDT, they do this through the liquidity pool. The smart contract uses an automated market maker (AMM) algorithm to determine the exchange rate. The most common algorithm is the Constant Product Market Maker (formula: x * y = k), where x and y represent the amounts of tokens in the pool, and k is a constant.
  4. Transaction Fees. A fee is charged for each transaction in the liquidity pool, usually a percentage of the transaction amount. This fee is distributed among the liquidity providers proportionally to their share of the pool, allowing them to earn on their contributions.
  5. Rewards and Incentives. In addition to transaction fees, some DeFi protocols offer additional rewards in the form of native network tokens (APT), incentivizing users to add liquidity to the pool.

Theoretical Part. Risks and Mitigation Strategies

Impermanent loss is the temporary reduction in value that liquidity providers may experience due to fluctuations in the prices of tokens within the pool. When the price of one token changes significantly relative to the other, liquidity providers might end up with a lower value upon withdrawal compared to simply holding the tokens separately. Impermanent loss is more prevalent in pools where the assets do not have correlated prices. To reduce these risks, consider the following strategies:

  • Avoid New Tokens with Low Liquidity;
  • Provide Liquidity in Multi-Asset Pools;
  • Use Pools with Different Token Ratios Pools with token ratios different from the standard 50:50 can help mitigate risks;
  • Participate in Pools with Additional Rewards or Bonuses.

Impermanent losses are temporary and can be recovered if the token prices return to their original values. This differentiates them from permanent losses, which are realized when assets are sold.

Example of Impermanent Loss: Consider the APT/USDC pool, where token prices are not correlated, and the smart contract sets the token ratio to 50/50. Let’s deposit 10 APT tokens at a price of $10 and 100 USDC tokens at a price of $1 into the pool. The total deposit value is $200 ($100 in APT and $100 in USDC). When the price of APT increases by 40%, the token ratio in the APT/USDC pool changes from 10/100 to 8.45/118.32, and the pool’s asset value becomes $236.64. If you simply held your tokens in a wallet, their value would be $140 in APT and $100 in USDC, totaling $240 (excluding exchange fees that you may earn in the liquidity pool). The impermanent loss is $240 — $236.64 = $3.36 (-1.4%).

Now, assuming that the price of USDC could decrease by -20% and the APT token could increase by +40%, the token ratio in the liquidity pool would change from 10/100 to 7.56/132.29. The pool’s asset value would be $211.66. If you simply held your tokens in a wallet, their value would be $140 in APT and $80 in USDC, totaling $220. The impermanent loss would be $220 — $211.66 = $8.34 (-3.79%).

For those who want to calculate Impermanent Loss themselves, click on the link.

Risks of Smart Contracts. Liquidity pools operate based on smart contracts, which may contain vulnerabilities or errors. Exploitation or hacking of these vulnerabilities can lead to the loss of funds locked in the pool. To mitigate risks, analyze the audit report.

Oracle Risk. Token prices in the pool may depend on data provided by oracles. Incorrect or manipulated oracle data can lead to incorrect calculations and losses for liquidity providers. Before depositing liquidity, verify the list of oracles used by the protocol.

Liquidity Risk. If there are not enough tokens in the liquidity pool, it may be difficult to execute large trades without significant price changes (slippage). Monitor slippage carefully, in most protocols, its magnitude is indicated in the exchange window.

Counterparty Risk. In some cases, there may be issues with the reliability and integrity of participants providing liquidity or using the pool for trading.

Aptominglets. Aptos NFT.

How to earn from liquidity pools in the Aptos ecosystem?

Protocols with liquidity pools include:

Personally, I’ve focused on three protocols — Thala, Liquidswap, and Cellana.

Protocol Thala — I recommend using liquidity pools APT/thAPT (stable), zUSDC/zUSDT (stable), THL/MOD (Weighted 80/20).

The stable pools APT/thAPT and zUSDC/zUSDT offer approximately 20% APR. Among them, 15% is distributed in thAPT tokens, and 5% in esTHL tokens. To receive token emissions, you need to lock up a minimum of 2.5% of your position in veTHL tokens. The esTHL tokens obtained for providing liquidity must be sent to vesting for 90 days. If you want to exchange your esTHL tokens for THL tokens before 90 days, a penalty of 25% will be applied, which decreases over time.

The volatile pool THL/MOD (80/20) offers approximately 55% APR. Among them, 40% is distributed in thAPT tokens, and 15% in esTHL tokens. To receive token emissions, you DO NOT NEED TO LOCK any tokens. Despite the pool’s volatility, impermanent losses are very low due to the asset ratio inside the pool: 80% THL and 20% MOD. I’ll remind those who haven’t read my article on Asset Tokenization and Black Rock, MOD token is the stablecoin of the Thala protocol.

Protocol Liquidswap — I use it when I want to earn on pools with meme coins. The returns are significantly higher than average and occasionally exceed 250%+. Be cautious; meme coins have very high volatility. I recommend keeping liquidity in the pool for either a very short or extremely long period.

In the Liquidswap protocol, volatile pools are created with a fee of 0.3%, while stable pools have a default fee of 0.04%. Of these fees, 66.7% go to liquidity providers, and the remaining 33.3% are directed to the treasury contract created for each liquidity pool on the default DEX.

Liquidswap. DooDoo-Apt. Aptos

Protocol Cellana — I use it when the returns in the pools of the protocol significantly exceed those in Thala. An important feature is that you receive CELL tokens as a reward for providing liquidity. The protocol’s fully diluted valuation (FDV) is $30 million, with approximately 12% of tokens in circulation, and the majority are locked for two years. This could lead to significant price fluctuations.

P.S. I only use stable pools.

Cellana. Tokenomics.

In the next article, we will explore the topic of Staking and Liquid Staking, as well as ways to earn from them.

Follow: Author’s link | Aptos Hot News

Previous articles: Lending | RWA | NFT

--

--