· 项目推荐 · 35 min read
Float Capital
FLOAT CAPITAL(白皮书)
FLOAT CAPITAL (Alpha Whitepaper)
Perpetual synthetic asset protocol 永久合成资产协议
-
Jonjon Clark
Mphil。Data Science,BSc (Hons) Computer Science
-
Jason Smythe
BSc (Hons) Computer Science and Mathematics
-
Denham Preen
BSc (Hons) Computer Science
-
Paul Freund
BSc (Hons) Computer Science,Hons Philosophy
-
Guy Paterson-Jones
MSc Mathematics
-
WooSung Dong
Hons。Actuarial Science
-
Michael Young
BEng (Hons) Computer and Electrical Engineering
-
Jono VDM
Hons。Finance and Investments。Passed CFA III exam。
-
Stent
Physics and Mathematics
摘要
Float is a synthetic asset protocol providing decentralized,trustless,and efficient exposure to arbitrary asset classes。The Float alpha smart contracts are incentives based perpetual smart contracts that algorithmically react to market demand for long and short positions on a synthetic asset。Market demand triggers dynamic adjustments of additional protocol rewards (alphaFLT and raw yield) rewarded to users taking valuable market positions。Synthetic asset exposure to the underlying asset class may dynamically fluctuate based on imbalanced market demand for various positions。
Float 是一种合成资产协议,为任意资产类别提供分散的、不可信的、高效的公开。Float alpha 智能合约是基于永久智能合约的激励机制,通过算法对市场对合成资产的多头和空头头寸的需求做出反应。市场需求触发了附加协议奖励 (阿尔法 flt 和原始收益) 的动态调整,这些奖励奖励给拥有宝贵市场地位的用户。综合资产对基础资产类别的风险敞口可能会根据不同头寸的不平衡市场需求动态波动。
The fundamental design of the protocol is highly scalable and abstracts all complexity from the end user allowing fast entry and exit with no minimum trade sizes。Synthetic asset positions can be minted without over-collateralization and without the threat of being liquidated。
该协议的基本设计具有高度可伸缩性,并将所有的复杂性从最终用户中抽象出来,允许快速进出,而不需要最小的交易规模。合成资产头寸可以在没有过度担保的情况下建立,也没有被清算的威胁。
pragma solidity 0.8.9;
import "@float-capital/contracts/Degen.sol";
import "@float-capital/contracts/Chad.sol";
import "@float-capital/contracts/Ape.sol";
contract FloatCapital is Degen, Chad, Ape {
// Your move ...
}
1 概述
Float Capital allows users to create long or short tokenized positions referencing any arbitrary asset。
Float Capital 允许用户创建引用任意资产的多头或空头 token 化头寸。
To expand further:
-
vanilla or leveraged
-
long or short
-
perpetual
-
tokenized exposure (ERC20)
-
to arbitrary asset classes (ETH,BTC,gas,NFTs,commodities …)
-
without liquidations
This DeFi lego is extremely useful for many different reasons to many different users。DeFi 乐高对于许多不同的用户,不同的原因都是相当有用的。
1.1 Alpha 发布
Creating a highly complex and innovative financial protocol is difficult。It presents unique engineering,economic and financial challenges。The core philosophy of Float is rapid and iterative development allowing us to improve and scale at the fastest possible rate while providing safety。To meet the above goal an alpha version has been deployed affording the following advantages:
-
Early user feedback。
-
Test and validate incentive models。
-
Quicker release cycle。
-
Reduce legacy。
-
Improve infrastructure。
The alpha version of Float Capital is deployed live on Polygon with the intention of releasing a new protocol version 4-6 months after the alpha launch based on the insights it affords。To use the live alpha (real money),visit Float Capital and mint a synthetic asset in under a minute。Please note while the protocol is audited,many risks exist。
1.2 白皮书结构
This paper will revolve around explaining the design of the alpha system as depicted in Figure 1。Sections will continually reference Figure 1 throughout the paper。
2 合成资产
Please refer to label 1 in Figure 1 for this section。
2.1 摘要
A user begins by speculating on a certain asset class (long or short)。The user provides DAI,a stable coin pegged to the dollar,and in return receives a synthetic asset representing their position。This receipt is in the form of an ERC20 token。The price of this ERC20 token is such that it tracks the underlying asset class。The user is able to do 3 things with their synthetic asset token。
用户从投机某一资产类别 (做多或做空) 开始。用户提供 DAI,这是一种与美元挂钩的稳定货币,作为回报,用户将获得代表其仓位的合成资产。这个收据是 ERC20 令牌的形式。这个 ERC20 代币的价格是这样的,它跟踪基础资产类别。用户可以使用合成资产令牌做 3 件事。
-
Sell the synth on the open market。在开放市场上销售合成资产
-
Stake the synth to earn alphaFLT。质押合成资产赚取 alphaFLT
-
Burn the synth to redeem DAI equal to the value of the synth burned。燃烧合成资产赎回与合成资产等价的 DAI
2.2 动机
Usually synthetic assets are based upon traditional financial instruments,allowing people to gain exposure to $AMZN
or the $SP500
,for example,on the blockchain。Yet,this is just one of the more common use cases of synthetic assets。Synthetic assets can be created from any quantifiable data feed allowing users to gain exposure to a far larger universe of assets。
In a traditional environment,it would allow users to go long or short on say,for example,the average amount of rainfall in Bordeaux,France,this would allow wine farmers to hedge against poor crop yields in a given season by going short while allowing guesthouses in the region to hedge against rainy weather and a lack in tourism by going long。
In a much more practical and relevant DeFi scenario,it gives users the power to perform powerful DeFi strategies through synthetic assets that previously have not existed。For example,an OHM synth can allow users to hedge and earn high yields on staking while maintaining a delta neutral position。
2.3 方法
All long and short synthetic assets are ERC20 tokenized positions allowing composibiliy across the DeFi ecosystem。The tokens are engineered such that a minted position settles at the next price update received by the smart contract。This system is known as Next Price Execution and thwarts attempts at front running to extract value from the system。Custom hooks in the ERC20 tokens allow the tokens to be minted in a single transaction step and available for immediate use upon settlement (transfer,stake,burn) without any additional user interaction。This hook based lazy allocation method allows a superior user experience where the complexity of the front running prevention is entirely abstracted from the user。
所有的多头和空头合成资产都是 ERC20 通证化的头寸,允许在 DeFi 生态系统中进行组合。代币被设计成在智能合约接收到的下一个价格更新时建立头寸。这个系统被称为下一个价格执行,它阻止了从系统中获取价值的尝试。ERC20 令牌中的自定义钩子允许令牌在单个交易步骤中铸造,并可在结算 (转让、持股、燃烧) 时立即使用,无需任何额外的用户交互。这种基于钩子的延迟分配方法提供了卓越的用户体验,在这种体验中,前端运行预防的复杂性完全从用户中抽象出来。
All synthetic mints and redeems are batched into a single efficient order that is executed upon the next oracle price update。Coupled together with hook execution,this allows arbitrary scaling of entry and exits into the system,making the system suitable for extremely large trade volumes。Oracle price updates from Chainlink occur as fast as every 27 seconds on the Polygon network,allowing extreme speed for entry and exit to the system (sub 1 minute)。
所有的合成铸币和赎回被批量成一个有效的订单,在下一次 oracle 价格更新时执行。再加上钩子的执行,这允许任意扩展进入和退出系统,使系统适合于非常大的交易量。在 Polygon 网络上,来自 Chainlink 的 Oracle 价格更新每27秒发生一次,这使得进入和退出系统的速度非常快 (不到1分钟)。
3 收益与激励
Please refer to label 2 in Figure 1 for this section。
3.1 摘要
All underlying capital that is deposited by users to mint synthetic assets is deposited into a smart contract known as the yield manager。The yield manager lends this underlying capital out in order to earn interest。Interest earned accrues to both synthetic assets (increasing the price) and the treasury。The split is based on the balance of liquidity in the long and short positions。
用户为创造合成资产而存入的所有基础资本都被存入一个名为收益管理器的智能合约。收益管理器将这些资本借出以赚取利息。合成资产 (提高价格) 和国债的利息收入。这种分割是基于多头和空头头寸的流动性平衡。
3.2 方法
The yield manager is a flexible contract that can plug into any yield bearing protocol。Different yield protocols have varying levels of risk and associated returns。From day 1,Float Capital is using Aave in the alpha。Aave is the largest blue chip yield protocol and provides desired risk adjusted returns。Float has been implemented in a modular format to allow use of other yield protocols in the future。A yield manager is deployed per market,allowing scenarios where different synthetic markets may seek yield in differing venues,congruent with the synthetic markets appetite for risk。The decisions above will be conducted by the community (Float Capital DAO) in the near future。
收益管理器是一个灵活的智能合同,可以插入任何收益 bearing 协议。不同的收益协议有不同程度的风险和相关的回报。从第一天开始,Float Capital 就在 alpha 阶段使用 Aave。Aave 是最大的蓝筹股收益率协议,提供理想的风险调整回报。Float 以模块化格式实现,允许在未来使用其他收益协议。每个市场都配置一个收益管理器,允许不同的合成市场在不同的场所寻求收益,与合成市场的风险偏好相一致。上述决定将在不久的将来由社区 (Float Capital DAO) 执行。
3.3 收益分离
Yield is split between the Treasury and the underlying synthetic market。Yield sent to the treasury is protocol revenue。Yield sent to the underlying synthetic market,increases the collateral backing each token and therefore increases the synthetic token price。
收益在国债和基础的合成市场之间分配。送到财政部的收益是协议收入。发送到基础合成市场的收益率,增加了支持每个代币的抵押品,因此增加了合成代币的价格。
The split of interest sent between the treasury and synthetic market is a simple linear function dependant on the balance of long and short liquidity in the market。All yield flows to the treasury if there is equal long and short liquidity (yield is not required to incentivize certain market positions)。The amount of yield flowing to the underlying market increases as the market is more imbalanced。All yield allocated to the underlying synthetic market is allocated to the position (long or short) with less liquidity,as an incentive to attract more liquidity into that position。The purpose being to incentivize equal liquidity in long and short positions。
国债和合成市场之间的利息分配是一个简单的线性函数,它依赖于市场中长期和短期流动性的平衡。如果长期流动性和短期流动性相等,所有收益都会流入国库 (为了刺激某些市场头寸,不需要收益率)。流入基础市场的收益率随着市场的不平衡而增加。所有分配到基础合成市场的收益都被分配到流动性较低的头寸 (多仓或空仓),以吸引更多的流动性进入该头寸。其目的是为了激励多头和空头的流动性。
The yield generated by the whole market is more than would be generated by one side (e.g. if the users of one side put their capital into the lending platform instead of into a Float market) so if all the yield is given to the underbalanced side then an incentive is created for users to add liquidity to that side since they would be earning more yield than if they went directly to the lending platform。In reality it is slightly more complicated because there is another actor,the treasury (a smart contract),that is given a portion of the yield。
整个市场所产生的收益不仅仅是一方所产生的 (例如,如果用户一边把资本的借贷平台而不是变成一个浮动市场) 如果所有的收益给本文一边然后为用户创建一个激励添加流动性那边,因为他们会挣的更多收益比直接去借贷平台要高。在现实中,这要稍微复杂一些,因为还有另一个参与者,即财政部 (智能合约),它获得了一部分收益。
A simple example is as follows。Imagine the capital in the market was imbalanced:the short side only had $100 000 capital while the long side had $500 000。Float will invest the total capital into a lending platform,which we will suppose has an APY (projected interest rate per year) of 8%. If all the yield is given to the short side then the short side would receive a yield of $600 000×8% per year,which is an effective APY of
下面是一个简单的例子。想象一下市场中的资本是不平衡的:做空方只有 10 万美元的资本,而做多方有 50 万美元。Float 将把全部资金投入一个贷款平台,我们假设这个平台的 APY (预计年利率) 为 8%。如果所有的收益都给了做空方,那么做空方将获得$600 000×8% /年的收益,这是一个有效的 APY
$$ \frac {$600000} {$100000} ∗ 8% = 48% $$
4 合成资产价格行为
Please refer to label 3 in Figure 1 for this section。
4.1 摘要
Every few minutes,the smart contract will receive a new price for the underlying asset class。If the price of the asset has increased,underlying short liquidity will transfer to underlying long liquidity。If the price of the asset has decreased,the converse is true。The amount of value transferred between long and shorts is based on the current liquidity held in long and short positions,which can vary based on market demand。The variance in liquidity of long and short positions,can cause the synthetic asset to have floating exposure to the underlying asset。This is expanded upon below。
每隔几分钟,智能合约就会收到标的资产类别的新价格。如果资产价格上涨,标的短期流动性将转移到标的长期流动性。如果资产的价格下降了,反之亦然。多头和空头之间的价值转移是基于多头和空头头寸所持有的当前流动性,这可能会因市场需求而变化。多头和空头头寸的流动性差异,会导致合成资产对标的资产有浮动风险敞口。这将在下面展开。
4.2 敞口基础例子
Where long liquidity = short liquidity,($100,000 of long exposure and $100,000 of short exposure) the following is true:
当多头流动性=空头流动性时 (10 万美元的多头敞口和 10 万美元的空头敞口),下列情况成立:
- in the case that the underlying asset price increases by 1%, 假设基础资产价格上涨 1%,
- value to shift 1% ∗ $100000 = $1000 价值要移动 1% ∗ $100000 = $1000
- the value of the long side will now be worth $101 000,多头的价值现在是$101,000,
- while the value of the short side will be worth $99 000。而空头的价值是$99,000。
Note that the value locked in the system is still $200 000。Changes in the price of the asset simply shift the value between the pools of collateral backing the long and short synthetic tokens。As the price increases,value flows from shorts to longs and visa versa。
请注意,锁定在系统中的价值仍然是 20 万美元。资产价格的变化只是改变了支持多头和空头合成代币的抵押品池之间的价值。随着价格上涨,价值从空头流向多头,反之亦然。
Now that the value on the long and short side is different,there will be floating exposure。Exposure is always based on the notional value of the market position with less liquidity。In this case,that is now the short side worth $99 000。This means that the long side will only have 99,000 / 101,000 = 98% exposure,while the short side will continue to have 99 000 / 99 000 = 100% exposure。
既然多头和空头的价值不同,就会出现浮动风险敞口。风险敞口总是基于流动性较差的市场头寸的名义价值。在这种情况下,空头现在价值 99 000 美元。这意味着做多方只有 99,000 / 101,000 = 98%的敞口,而做空方将继续有 99,000 / 99,000 = 100%的敞口。
Given the above,a subsequent market movement would create the following scernario
鉴于上述情况,随后的市场走势将产生以下情景
-
the underlying asset price again increases by 1%, 基础资产价格再次上涨 1%,
-
value to shift is always based on the price movement multiplied by the notional value of the side with less liquidity。Therefore,1% ∗ $99000 = $900 价值转移总是基于价格变动乘以流动性较差一方的名义价值。因此,1% ∗ $99,000 = $900
-
the value of the long side will now be worth $101,900 (101,000+ 900),多头的价值现在是 101,900 美元 (101,000+ 900)
-
while the value of the short side will be worth $98,100 (99,000 − 900)。而空头的价值为 98,100 美元 (99,000 - 900 美元)。
-
hence mathematically the long side has 98% exposure (1% ∗ 98% ∗ $100000 = $900) as explained。因此,从数学上讲,多头有 98%的敞口 (1% ∗ 98% ∗ $100,000 = $900)。
The reduction in exposure to the underlying asset for the overbalanced side is true for both upward and downward price movements。
在价格上涨和下跌的情况下,对标的资产的过度平衡敞口的减少都是真实的。
4.3 Mathematical Formulation of Floating Point Exposure
4.3.1 Definition of exposure。
It is common in traditional financial markets to talk about ’having exposure’ to an asset。To have exposure to an asset is to be in a position where changes in properties of that asset affect one’s financial investment in that asset。Example:one can be positively exposed to the price of gold,which means that when the price of gold increases then the value of one’s investment will also increase。If the percentage by which the investment changes,𝑝𝐼,is equal to the percentage by which the value of the underlying asset’s property changes,𝑝a,then the exposure is said to be 100%. The exposure can be seen as the factor that 𝑝𝐼 must be multiplied by in order to get 𝑝a。This can be formalized as follows:
$$ \begin {aligned} & Ep {a}=p {I} \ \Rightarrow & E=p {I}\left(p {a}\right)^{-1} \end {aligned} $$
where 𝐸 is the exposure。We can expand the percentage changes in order to get the following definition of exposure:
$$ 𝐸 = \frac {\Delta I} {I} \frac {a} {\Delta a} $$
where 𝐼 is the value of the investment and a is the value of the property of the underlying asset。In this definition we assume that both values are elements of the real numbers。
4.3.2 Market rebalance equation。
Suppose we have a market whose long & short synthetic tokens track the value of some property of some underlying asset,a。Suppose also that the total value that has been invested in the long side of the market is l,and the total value in the short side is s。Consider the case where there is a change in the price of the underlying asset,𝛿a。If the change is positive then value needs to shift from the long side to the short side,and vice versa when the change is negative。The value that is shifted between the long and short sides needs to be such that the maximum exposure for both sides is 100%. The following update equation is the one that Float uses in order to achieve this:
$$ \Delta l = min (l,s) \frac {\Delta a} {a} $$
$$ \Delta s = −min (l,s) \frac {\Delta a} {a} $$
You can see that the exposure is always less than 100% by plugging the above values into the exposure equation (1):
$$ 𝐸_l = \frac {\Delta l} {l} \frac {a} {\Delta a} $$
$$ 𝐸_l =\frac {min (l,s)} {l} \leq 1 $$
$$ 𝐸_s =\frac {\Lambda s} {s} \frac {a} {\Lambda a} $$
$$ 𝐸_s =\frac {−min(l,s)} {l} \leq 1 $$
4.3.3 Differential equations。
Consider the case where m remains fixed and a varies。We can talk about l & s as functions of a。So (2) & (3) become
$$ \frac {dl} {da} =\frac {min (l,s)} {a} $$
$$ \frac {ds} {da}= − \frac {min (l,s)} {a} $$
Solving these differential equations results in the following functions for l & s。The initial conditions are a1,l1,s1。
When l1 ≤ s1:
$$ l(a) =\begin {cases} \frac {l_1} {a_1} a:l \leq s \ −\frac {ma_1} {2a} + m:l > s \ \end {cases} $$
$$ s(a) =\begin {cases} −\frac {l_1} {a_1} a + m:l \leq s \ \frac {ma_1} {2a}:l > s \ \end {cases} $$
where
$$ a_1 =\frac {a_1m} {2l_1} $$
When l1 > s1:
$$ l(a) =\begin {cases} \frac {m} {2a_2} a:l \leq s \ −\frac {ma_2} {2a} + m:l > s \ \end {cases} $$
$$ s(a) =\begin {cases} −\frac {m} {2a_2} a+m:l \leq s \ \frac {ma_2} {2a}:l > s \ \end {cases} $$
where
$$ a_2 =\frac {2a_1s_1} {m} $$
The above equations show the value of the long and short positions as a function of the underlying asset price in the scenarios where long liquidity is greater than short liquidity and vice versa。
4.4 Keeper
The mechanic is such that value shifting and interest accrual should take place every time a price update is made available by an oracle。This means that in order for the synthetic to accurately track the underlying assets,a keeper bot is necessary to continually perform this upkeep。
The first keeper is simply users。All smart contract interactions call a hook that performs this update functionality to ensure an up to date system state。To further improve the accuracy of synth tracking,we have also developed a custom keeper smart contract。When called this smart contract reads whether price updates are available and if so performs upkeep action。The bot uses smart logic to automatically bump gas prices and monitor deviation thresholds of underlying assets ensuring timely upkeep is performed。A redundancy bot further brute force calls the contract periodically if the main bot goes offline。
The system will be moved to a more decentralized chainlink keepers mechanism when this becomes available on the Polygon network。
5 质押
Please refer to label 4 in Figure 1 for this section。
5.1 摘要
Synths can be staked (locked up in a smart contract) in order to earn alphaFLT tokens。The amount of alphaFLT earned is function of the dollar value of the synth staked,the length of time the synth is staked,and the balance of long and short liquidity in the underlying market。Synths may be staked and unstaked at point in time,with users incurring a 0.5% fee when unstaking synthetic assets。
为了获得 alphaFLT 代币,可以对合成资产进行质押 (锁定在智能合约中)。alphaFLT 赚取的金额是由所押合成资产的美元价值、所押合成资产的时间长度以及基础市场中长期和短期流动性的余额所决定的函数。合成资产可以在某个时间点进行质押和解押,当质押合成资产时,用户需支付 0.5%的费用。
5.2 基础
Equal liquidity in long and short positions is desirable as then both long and short synthetic tokens will have perfect exposure (100%) to the underlying asset。Section 2 already described how yield is used in order to incentivize equal liquidity in long and short positions。
多头和空头头寸的同等流动性是可取的,因为多头和空头合成代币都将对标的资产有完美的敞口 (100%)。第 2 节已经描述了如何利用收益率来激励多头和空头仓位的同等流动性。
The second mechanism used for this incentivization is the rate at which alphaFLT tokens accrue to long and short liquidity staked。The basic mechanic is that liquidity staked from an underbalanced position will accrue at a much faster rate than the overbalanced position。This obvious incentive here is for users to mint and stake liquidity of the underbalanced side of the market to take advantage of the much higher rate at which alphaFLT is earned。
用于这种激励的第二种机制是 alphaFLT 代币积累为长期和短期流动性的比率。其基本机制是,欠平衡头寸的流动性积累速度要比超平衡头寸快得多。在这里,这种明显的动机是为了让用户在市场欠平衡的一面铸造和持有流动性,以利用 alphaFLT 赚取的高得多的利率。
Every couple minutes,a new oracle price update is received and users new positions in the system are processed,leading to continued change in the liquidity balance of longs and shorts。There is a significant engineering challenge in providing a dynamic and accurate rate of alphaFLT accrual for all stakers given the liquidity balance is changing so frequently in markets。Fortunately,we are mathematicians with extensive solidity experience。The following sections outline mathematically how we relied on the technique of memoisation plus incentive curves to achieve this desired result。
每隔几分钟,就会收到一个新的预言机价格更新,并处理系统中用户的新头寸,导致多头和空头的流动性平衡持续变化。鉴于市场中的流动性平衡变化如此频繁,为所有利益相关者提供一个动态和准确的 alphaFLT 权责发生率是一个重大的工程挑战。幸运的是,我们是有丰富经验的数学家。以下几节从数学上概述了我们如何依赖记忆技术加上激励曲线来达到这个预期的结果。
Short explanation of the math in _calculateFloatPerSecond
function in Staker.sol
(link to code) works。
5.3 原理
Note that the goal here is to find a way to split up the alphaFLT rewards between the long and short sides of the market。An imbalanced market is undesirable because the exposure on one side will be less than 100%. And so we want to have the alphaFLT rewards adjust in such a way that users are incentivized to rebalance imbalanced markets i.e. give more alphaFLT to the underbalanced side。
5.3.1 Key。
𝐿 value of the Long market side
𝑆 value of the Short market side
𝑀 = 𝐿 + 𝑆 total value in Market
𝐸 a positive Exponent used to modify the slope of the curve
𝜆 percentage offset for market (adjustable variable)
Λ = 𝜆𝑀 offset scaled to market size
𝑑 = 𝐿 − 𝑆 signed imbalance in market
5.3.2 Equations。
Here are the unscaled rewards (alphaFLT per second) for the long & short side as functions of 𝑑:
$$ R {L} (d)=\left{\begin {array} {ll} 1 & :d+\Lambda \leq-M \ R {-} (d) & :0<d+\Lambda<M \ 1-R_ {+} (d) & :-M \leq d+\Lambda \leq 0 \ 0 & :M<d+\Lambda \end {array}\right。 $$
$$ 𝑅_𝑆 (𝑑) = 1 − 𝑅_𝐿(𝑑) $$
where
$$ R_ {-} (d)=\frac {1} {2}\left(1-\frac {d+\Lambda} {M}\right)^{E} $$
$$ R_ {+} (d)=\frac {1} {2}\left(1+\frac {d+\Lambda} {M}\right)^{E} $$
Note that the domains of 𝑅𝐿 and 𝑅𝑆 are both 𝐷 = {𝑑 ∈ R : −𝑀 ≤ 𝑑 < 𝑀}
since 𝑑 = 𝐿 − 𝑆 = 𝑀 − 2𝑆
and 𝑆 has a range of (0,𝑀] (the reason 0 is not included is outside the scope of this derivation)。
Also note that 𝑅𝐿 and 𝑅𝑆 are percentages i.e. 𝑅𝐿 (𝐷) ⊆ [0, 1]
5.3.3 Derivation。
Requirements for the 2 curves 𝑅𝐿 and 𝑅𝑆:
- (1) Both must have a value of 1 2 when 𝐿 = 𝑆 (equal issuance for a balanced market)
- (2) Both must be continuous for all values of 𝐿 & 𝑆
- (3) 𝑅𝐿 +𝑅𝑆 = 1 ∀ 𝐿,𝑆 (we don’t want any alphaFLT to be wasted)
- (4) 𝑅𝐿 increases (with) when 𝐿 decreases and vice-versa for 𝑅𝑆
- (5) Both must have an adjustable intensity;higher intensity meaning that,around the point where 𝐿 = 𝑆,𝑅𝐿 increases faster as 𝐿 decreases,and vice-versa for 𝑅𝑆 i.e. alphaFLT rewards quickly shift toward the underbalanced side as a market becomes imbalanced
- (6) 𝑅𝐿 & 𝑅𝑆 are both ≥ 0 (we can’t have negative alphaFLT issuance)
One way of finding curves that fit is by starting with a = 𝑈 𝑀 where 𝑈 is the value of the underbalanced side i.e.
$$ U =\left{\begin {array} {ll} L & :L \leq S \ S & :S<L \ \end {array}\right。 $$
Consider the case where 𝑈 = 𝐿
If we make 𝑅𝑂 ∝ a (where 𝑂 is the value of the overbalanced side,in this case 𝑂 = 𝑆) then #4 of our requirements is half-satisfied i.e. satisfied just for 𝐿。In fact,if we make 𝑅𝑂 ∝ a 𝐸 then #4 of our requirements is still half-satisfied as long as 𝐸 ∈ N,and we now have #5 half-satisfied。Let
$$ 𝑅_𝑂(a) = a^𝐸 $$
Obviously #2 & #6 are half-satisfied for all 𝐿 ≤ 𝑆,and we can half-satisfy #1 by adjusting the equation to
$$ R_ {O} (a)=\frac {1} {2} (2 a)^{E} $$
since
$$ a=\frac {1} {2} \Longleftrightarrow U=\frac {M} {2} \Longleftrightarrow L=S $$
and
$$ 1^{E}=1 \forall E \Longrightarrow \frac {1} {2} 1^{E}=\frac {1} {2} $$
Finally,if we set 𝑅𝑈 (a) = 1 − 𝑅𝑂 (a) then #3 is satisfied for all 𝐿 ≤ 𝑆。Also,it follows that #1, #2, #4 & #5 are now wholly satisfied for all 𝐿 ≤ 𝑆。
Consider the case where 𝑈 = 𝑆
Similarly,we have 𝑅𝑂 & 𝑅𝑈 that satisfy #1-6 for all 𝑆 < 𝐿。So now all conditions are fully satisfied。
Turn 𝑅𝑂 & 𝑅𝑈 into 𝑅𝐿 & 𝑅𝑆
Start with:
$$ R _{O}=\left{\begin {array} {ll} \frac {1} {2}\left (\frac {2 L} {M}\right)^{E} & :L \leq S \ \frac {1} {2}\left (\frac {2 S} {M}\right)^{E} & :L>S \end {array}\right。 $$
and use definitions of 𝑑 & 𝑀 to get
$$ 2L = M+d \quad \text {and} \quad 2 S=M-d \ \Longrightarrow R_ {O} (d) &=\left{\begin {array} {ll} \frac {1} {2}\left (\frac {M+d} {M}\right)^{E} & :d \leq 0 \ \frac {1} {2}\left (\frac {M-d} {M}\right)^{E} & :d>0 \end {array}\right.\ &=\left{\begin {array} {ll} R {+}^{\prime} (d) \quad:d \leq 0 \ R {-}^{\prime} (d) \quad:d>0 \end {array}\right。 $$
where
$$ R_ {-}^{\prime} (d)=\frac {1} {2}\left(1-\frac {d} {M}\right)^{E} $$
$$ R_ {+}^{\prime} (d)=\frac {1} {2}\left(1+\frac {d} {M}\right)^{E} $$
Also,
$$ R {U} (d)=\left{\begin {array} {ll} 1-R {+}^{\prime} (d) & :d \leq 0 \ 1-R _{-}^{\prime} (d) & :d>0 \end {array}\right。 $$
Now,
$$ \begin {aligned} R_ {L} &=\left{\begin {array} {ll} R {U} & :L \leq S \ R {O} & :L>S \end {array}\right.\ \Longrightarrow R {L} (d) &=\left{\begin {array} {ll} 1-R {+} (d) & :d \leq 0 \ R _{-} (d) & :d>0 \end {array}\right。 \end {aligned} $$
and
$$ \begin {aligned} R_ {S} &=\left{\begin {array} {ll} R {O} \quad:L \leq S \ R {U} \quad:L>S \end {array}\right.\ \Longrightarrow R {S} (d) &=\left{\begin {array} {ll} R {+}^{\prime} (d) & :d \leq 0 \ 1-R {-}^{\prime} (d) & :d>0 \end {array}\right.\ \Longrightarrow R {S} (d) &=1-R_ {L} (d) \end {aligned} $$
All the conditions are satisfied for 𝑅𝐿 & 𝑅𝑆 since they are satisfied for 𝑅𝑈 & 𝑅𝑂,as long as −𝑀 ≤ 𝑑 ≤ 𝑀。There are now only 2 differences between these final equations and the original ones (1) & (2):the variable Λ and the edge cases that it creates。
The percentage offset 𝜆 was added so that if a market tends to always be skewed in a particular direction (e.g. market is stable when long side is 10% more than short side) then we can adjust the alphaFLT rewards to increase incentive for the market to stabilize around the 50/50 (long/short) mark instead。(50/50 markets are preferred because the exposure for both sides is 1。) The percentage offset has to be scaled to the market size in order to give the desired impact,so Λ is added to the equations。Due to the offset 2 new cases were added to the piecewise function to keep condition #4 & #6 satisfied。
5.4 Theory adjusted to Solidity code
𝑅− & 𝑅+ are both adjusted like so:
$$ R_ {-} (d)=\frac {1} {2}\left(1+\frac {d+\Lambda} {M}\right)^{E}=\frac {1} {2} \frac {\left[2\left(S-\frac {\Lambda} {2}\right)\right]^{E}} {M^{E}} $$
$$ R_ {+} (d)=\frac {1} {2}\left(1-\frac {d+\Lambda} {M}\right)^{E}=\frac {1} {2} \frac {\left[2\left(L+\frac {\Lambda} {2}\right)\right]^{E}} {M^{E}} $$
Problem - in the EVM the maximum integer size is 2 256 - so if 𝑀𝐸 > 2 256 we have an overflow。We can prevent this issue by dividing both the numerator and the denominator in the above equations by the same amount before raising them to the power 𝐸。Note we loose precision due to integer division。Let
a = divisorToPreventIntegerOverflowOnExponentiation
then
$$ R_ {-} (d)=\frac {1} {2} \frac {\left[\frac {2\left(s-\frac {\Lambda} {2}\right)} {\alpha}\right]^{E}} {\left (\frac {M} {\alpha}\right)^{E}} $$
$$ R_ {+} (d)=\frac {1} {2} \frac {\left[\frac {2\left(L+\frac {\Lambda} {2}\right)} {\alpha}\right]^{E}} {\left (\frac {M} {\alpha}\right)^{E}} $$
How can we optimise this for solidity?We can use bitshifting rather than division,as long as we keep a a power of 2。Bitshifting left by 5 is the same as dividing by 2 5。
6 ALPHAFLT TOKENS
Please refer to label 5 in Figure 1 for this section。
6.1 Summary
alphaFLT tokens accrued can be burnt in exchange for either the alpha protocol revenues or FLT tokens upon the release of the Float v1 system。The strategic move allows not only the core protocol mechanics to iterate without legacy,but the tokenomics of the system to also improve in the coming release。
6.2 Motivation
The motivation for releasing alphaFLT is the power a two token model affords rapid iteration。When engineering such a revolutionary and complex protocol such as Float,tokenomics are another massive component that warrants meticulous research to ensure long term success of the protocol。Given our interest in deploying the alpha for incentive testing and user insight,the alphaFLT is an opportunity to not be pigeon holed into a legacy tokenomic design that may not be suited for the protocol。
alphaFLT is well thought out v0 tokenomic system that stands to greatly benefit Float early adopters though alpha treasury revenue and favourable conversion into FLT tokens upon the next system release。
7 OTHER
7.1 Float Capital Alpha Audit
Float Capital ran a $50 000 smart contract audit competition where ethereum security experts competed to find vulnerabilities in the float alpha system。The results of the competition can be found here。
It is very important that you understand an audit does not equate to risk free。Many risks are present in the Float Capital alpha system and users should do their own due diligence before minting a synthetic asset。This blog post describes the risks in more detail。
7.2 GEMS
Users who interact with the float capital protocol can receive 250 GEMS per day。These are currently non-transferable ERC20 tokens。The tokens entitle users to special discord permissions,special NFTs,and early release access to name just a few。
7.3 Discounts
Float Capital is pioneering cross protocol partnerships and utility。A flexible fee discount model allows users with certain NFTs to have protocol fee discounts。Initial partnerships with NFT protocols Rumble Kong League ($40m total value) and Wildcards ($200k raised for animal conservation) are just the tip of the iceberg in this innovation。
7.4 Shifting
Float Capital is first synthetic asset protocol (that we are aware of) providing the ability to natively shift synth positions (staked or not) between long and short。
This allows efficient building of delta neutral liquidity vaults,key to scaling to mass market liquidity。
7.5 Governance
Float Capital is a community governed protocol that currently relies on pseudo discord role base governance,where roles are awarded to users based on GEMS collected。In the future,Float Capital will move toward becoming a DAO。
7.6 Alpha Live performance
Since the live alpha has commenced,more than $250 000 has been organically deposited into float to mint synthetic assets,making cheap and fast synth exposure a reality。The goal of the alpha will be to continue adding more synthetic assets and testing current incentive parameters。These learning’s will be integral for future protocol iterations。
7.7 Float v1
The subsequent release following the float alpha is going be informed by the insights from the alpha。The key to the design will be ensuring sustained and efficient protocol liquidity。