# πAutomated Market Taking

"Better Safe Than Sorry You Missed Out on Another Cycle" - Confucius

Automated Market Taking (Takers) is our brand-new Convex Primitive, and the big innovation of Itos. It let's users create customizable asymmetric payoffs which is what ultimately powers our liquidation-free leverage, our hedging, or security model, and more.

**Convexity** is a powerful concept used by professionals in every corner of the TradFi world. It** **is when a price rises faster in relation to another price or falls more slowly. In effect it offers safety and larger returns, and therefore, convexity comes at a higher cost. A classic example of convexity in TradFi is an option has capped downside and a highly leveraged upside. Takers can be utilized in a similar way but with much more flexibility and leverage!

## How It Works

Automated Market Taking can be thought of in the same way as Automated Market Making, but instead of making the market it chases the market. Just like AMMs, users deposit assets into a smart contract and the smart contract rebalances those assets back and forth according to a constant product formula, but unlike AMMs, instead of trading against the active swap, AMTs piggy-back off the active swap and make a matching trade. It's basically an automated momentum trading strategy.

So let's say a trade happens where someone sells 1 ETH for 3000 USDC. The AMM positions would be supplying the 3000 USDC and accepting the 1 ETH. The AMT positions however, are selling their own ETH to the AMM in return for USDC. How much they sell depends on the amount of Taking Liquidity at that price. That is the basic understanding, but honestly that's already enough. This simple mechanism allows for the safety and asymmetry we want.

We make it a little more advanced by adding leverage. Unlike AMM positions, the AMT position doesn't need to supply token balances upfront. This is because we know the strategy will always be profitable (sans fees) so we ask for the necessary token balances when the position is closed. However, since fees will accumulate we do ask for fee collateral upfront. Because the fee collateral is so much smaller than the value of the tokens automatically traded, Taker positions have inherently high leverage.

Within The 2sAMM, whenever a Taker is created, we reserve its equivalent amount of Making liquidity to automatically trade against whenever the price moves. In reality we just do the trade in math to safe on gas until we need to close the Taker position.

## The Asymmetric Payoff

By asymmetric we mean that there is a limited downside, but an unlimited upside. If you create a Taker position on BTC that starts at zero, the principal value of it cannot go below zero just because the price of BTC drops, but if BTC ever climbs up, you'll be able to capture all of that upside. The cost is a funding rate for this privileged position.

Compare this to perpetuals, where you pay a funding rate **and** your position's principal value can go below zero (and ultimately cause a liquidation). Automated Market Taking offers the same leverage as perps, but protects you against the downside. In return, Taking has a slightly more expensive funding rate than perps do.

This asymmetric payoff is similar to TradFi Options. Indeed, we can use Taking as a DeFi equivalent for options investing. Unlike options however, the Taker is not a contractual agreement, there are no future obligations, no expiries, and no direct counterparties. They can be opened and closed at will.

## Taker Details

### Parameters

Like an Automated Market Making position, Takers are also parameterized by a **price range** and a **liquidity** value. We often refer to the price range as the **strike range** to match options lingo. On one side of the strike range, the Taker appreciates in value as if its holding a certain amount of tokens as determined by the liquidity value, on the other side the Taker stays at a flat value of zero. Within the range is a smooth transition from one side to another.

When the token pair's price is within the strike range, the Taker does the opposite of a Maker. It pays the trading fees that a Maker would earn (and a bit more). This ensure LPers on Itos aren't missing out on any income compared to just a basic liquidity provision, and in fact they should earn more due to the extra payments from Takers.

The transition within the price range is curved so that the geometric mean ($\sqrt{AB}$) of the lower and upper price bounds is the average price at which the Taker effectively buys or sells the underlying token. This is the equivalent of an option's **strike price**. Let's say you size your liquidity such that the Taker is long 10 ETH past the strike range. If the price of ETH goes to 4000 USDC and your strike price was 3000 USDC, then you'd make 1000 * 10 USDC in total.

The width of your price range controls how quickly that transition happens and how expensive the funding rate is. A wider price range diversifies the funding APR across more ticks making the payment cost more stable.

Besides the in-range swap fees Takers pay, they must also always pay a small borrow rate for the Maker liquidity it utilizes, no matter where the price is. We source that borrow rate from common on-chain Money Markets.

### TakerCall & TakerPut

Itos has two types of Taker positions (which can be used in combination for even more flexibility, see Vol-Taking), the TakerCall and the TakerPut. They're named similarly to call and put options because the TakerCall profits from the upside potential of a token while the TakerPut profits from any downwards movement.

For a **TakerCall**, below the price range the position is worth exactly zero. It doesn't lose money nor is it profitable. Above the price range the position rises one to one with respect to the token pair's price.

If the price range is 1600 to 2500 and the size is 10 ETH, then below 1600 the position is always worth nothing, but if the price of ETH goes above 2500, then for ever dollar above, the position earns 10 dollars. The curved part in the middle averages out to the geometric mean of $\sqrt{1600 * 2500} = 2000$. This helps us find the value of the position overall. If the price of ETH is 3000, we just have to subtract our average strike from it, and multiply by our size to calculate our profit. In this case (3000 - 2000) * 10 = 10,000. When above the price range, the profit formula is simply $Size * (Price - Strike)$.

When we're within the range, the formula is more complex:$Size * \frac{\sqrt{PP_H}(1+P_L) - \sqrt{P_LP_H}(1+P)}{\sqrt{PP_H} - \sqrt{PP_L}}$.

**TakerPuts** are just like TakerCalls except the payout is for the other side. Below the range the position appreciates in value according to the size. Above the range the position is worth nothing. And in range we have the curve again.

Again there is the average strike which is the geometric mean of the price range bounds. The value of the position when below the range is $Size * (Strike - Price)$. In range the formula is $Size * \frac{\sqrt{P_H} + \frac{1}{\sqrt{P_H}} - \sqrt{P} - \frac{1}{\sqrt{P}}}{\sqrt{P_H} - \sqrt{P_L}}$.

### Deposit Size

Although Takers are leveraged, they still require a small deposit to open. If the Taker is already profitable, we say it is **"In The Money"**, and anyone opening a profitable taker must first pay that profit. Otherwise, they would be able to exploit the protocol by opening In The Money (ITM) Takers non-stop. Additionally, since Takers pay fees a user needs to deposit some fee collateral before opening. If the user is using the Itos portfolio system, then as long as their portfolio is worth more than the minimum collateral, they don't need to put down more collateral.

While the value of the position can't go below zero, the In-The-Moneyness can be lost due to the position depreciating.

Last updated