Master Shepherd reveals some of the most hidden secrets of DeFi
“Hey! Gimme the keyboard back!”
Uh, sorry, the Marketing Manager was trying to take the keyboard away from me…
If you got to know me, by now you should know The Shepherd likes to tell it like it is, whatever it takes.
I have the ambition to make our community of Llama Lovers (but not only!) responsible and aware. We’re in the middle of an unprecedented bull market, and every day I see people entering this market without having the slightest preparation or awareness. Yesterday an acquaintance told me “I invested in Doge!” “Really, why?” “Dunno! I like the dog!”
[The Marketing Manager] “Hey but this is our trade secret! People don’t have to know exactly how these things work! You’re a fool!”.
And then they ask me why I want to remain anonymous. In the world I live in, those who say things as they are usually come to a bad end… just to say.
So, without further ado, let’s delve into some of the hidden secrets of DeFi, especially the so called “liquidity mining” or “yield farming”.
1. Multipliers
60x 24x 5x
What exactly do they mean?
Honestly? NOTHING.
“Hey, but you have them too!”
True, as you know, our current UI is a pancake fork (which is a SushiSwap fork, which is a Uniswap fork). When we re-design the site (which is coming soon, along with SPIT launch), we will probably take them off, even though they are actually harmless, once you understand what they mean.
The multiplier sole purpose is to give an indication of how large the minted token allocation is per block to a specific pool compared to the other pools.
The unit of measurement is “points”, nothing more. Each pool will therefore have a percentage of token/block allocation depending on the points assigned to it, compared to the total points of all the farms.
Here is the formula (we use $LAMA as an example):
In LlamaSwap we currently have 7 farms and 2 pools, for a total of 92 allocation points. The LAMA Pool (stake Lama, get Lama) has a multiplier of 10x. Using the formula above, we know that the pool weight is 10/92*100 = 10.86%, for a $Lama/block allocation of 0.0543
So in the end the multiplier is the pool allocation points, which in turn is converted to a percentage. But saying 3x or 60x for a pool sounds better than saying “5.43%” or “32.78%” allocation, doesn’t it?
And this takes us straight to:
2. APR
aka Annual Percentage Rate
“Why can’t you give higher interests?” or “But how do they manage to give such high interests?”
I don’t know how many times I’ve heard these questions.
First, let’s make a fundamental distinction. There are two macro categories of yield farm:
➀ Lend & borrow platforms: the funds deposited by investors are lent to other investors, perhaps allowing them to overexpose with leverage. The interests and commissions received are distributed to investors who have injected liquidity;
➁ Pure yield farming platforms: users stake their single tokens or their LP tokens and they farm a new token (the native token of the platform). This is how LlamaSwap works, by the way;
➁.➀ Not a category in itself, but a subcategory of the second, yield aggregators/optimizers that, in a way more or less transparent to users, use the deposited funds to put them in staking — via special smart contracts (typically called Strategy) — in other farms/platforms to maximize the yield obtained. The paid interest can be in native token only or a combination of native token + third-party farm token.
In the first case, it is evident that the interest yield is a direct consequence of the active investment policies of the funds by the platform (how much % of exposure it allows for loans, whether it grants leveraged loans, the interest charged on the loans, etc.). Among other things, this type of platform is, in my opinion, the riskiest, since it is subject to the liquidity risk and in case of very violent moves of the market they could also go “bankrupt” (ok, a rare case, but not impossible).
In the second case, the risks should be more contained. In fact, in addition to the possible impermanent loss of the LP token (I’ll write about impermanent loss in a future article), the greatest risk is that of vulnerabilities or bugs in the smart contract that handles the staking of your LP tokens.
“Ok Shep, I got it. But I still haven’t figured out exactly how APR is calculated”.
Let’s reveal once and for all the formula for calculating the APR:
given a pool P:
where Wp is the percentage weight of the pool (remember the multiplier? that one!)
LAMA per block = 0.5
Block per year = (60 seconds *60 minutes *24 hours *365 days) / 3 seconds= 10,512,000
* on the BSC 1 block is mined every 3 seconds
(LP TOTAL VALUE)p = the $ value of the LP tokens (or single tokens) staked into the pool
So, now it should be clear that the only variables we the devs can act on are: the weight assigned to the pool (the multiplier) and the emission rate. And that, above all, the APR values keep fluctuating, based on the LAMA price and based on the total liquidity of the pool, and therefore are purely indicative.
“Ok Shep, that’s starting to make sense… but why do they give X thousands of APRs and yours are ONLY at 2 or max 3 figures?”
Hey, are you a Llama or a mule?
Would you like to see APRs in the order of thousands% per year on LlamaSwap as well? It would be enough for us to increase the emission rate et voilà, here is the extremely high % per year served. If they are realistic expectations, well I leave it to you to say. Flooding a token with an unsustainable inflation rate most probably it’s not the smartest move, unless your interest (and I mean of those running the project) is short term only. Tokens will literally drop to zero value in about a week.
(Oh, and I won’t even mention the possibility of simply cheating, putting a K multiplier in the formula in the UI code, anyway no one could ever really — or take the time to — understand if it is correct or not, right?)
“And what about the APYs?”
Take the APRs, which we have already understood to be purely indicative estimates, and apply a compound effect on a daily basis times 365 days and you will get dizzyingly high %. Ok, let’s meet again in a year and then you’ll tell me how it really went.
This is the first in a series of articles I have decided to write about the world of DeFi. Because a good Shepherd cares about his Llamas and only well-informed Llamas will be able to survive in this ferocious jungle that is BSC.
“Hey, but Llamas don’t live in the jungle!” Oh well, you get the idea.
Thanks for reading and keep lloving us.
Join our cool Llamas community:
Telegram: https://t.me/llamaswap
Twitter: https://twitter.com/llama_swap
LlamaSwap: http://llamaswap.finance