BitShares Forum

Main => General Discussion => Topic started by: bytemaster on April 16, 2015, 02:28:35 pm

Title: BitAssets 2.0 - For Community Review
Post by: bytemaster on April 16, 2015, 02:28:35 pm
BitAssets 2.0

The goal of creating a stable, highly liquid, accurate pegged crypto currency has been as elusive as it is desirable for those interested in a trust-free digital currency.   BitShares has experimented with several approaches and has devised an approach that largely works, but which is still lacking.   This paper presents a new approach to establishing a trust-free pegged crypto-currency.  In this new approach the market rules are simple and a price feed has minimal ability to impact the market.

In finance, a contract for difference (CFD) is a contract between two parties, typically described as "buyer" and "seller", stipulating that the seller will pay to the buyer the difference between the current value of an asset and its value at contract time (If the difference is negative, then the buyer pays instead to the seller). In effect CFDs are financial derivatives, that allow traders to take advantage of prices moving up (long positions) or prices moving down (short positions) on underlying financial instruments and are often used to speculate on those markets.

BitShares takes the concept of a contract for difference and applies it to a crypto-currency relative to a national currency and settles it in the crypto currency.   For the purpose of this paper we will assume a CFD between BitShares BTS and the US Dollar and call the long position BitUSD.  Normally contracts have different settlement dates backed by different collateral amounts which makes them infungible.  BitShares attempts to make all BitUSD positions fungible and thus usable as a currency. 

The challenge with this approach is that there are no expirations on the BitUSD positions which creates a situation where the two sides of the market have no means of settling at a fair price if one side of the market refuses to settle.    In order to address this concern BitShares has gone to great lengths to force all short positions to cover at a fair price every 30 days and guarantee redeemability to the BitUSD holders but BitShares has no ability to guarantee redeemability to the shorts.     In order to guarantee redeemability to the longs the market must limit the price at which new shorts can sell.  This creates an artificial barrier that is highly dependent upon a price feed in order to prevent abuse.

In an ideal world the market would operate freely and the CFD would settle all parties at a fair price once.   If we assume that short and long positions settle at a trusted price once per year, then market forces will drive the price of the long side to follow the real-time USD value without the need to publish a price all year, only a single price is needed once per year.

Unfortunately, this forced settlement would expose users of the long position to the underlying crypto-currency once per year.   To give users an option to stay in BitUSD year-round means that two parallel CFD markets would be required that settle once per year offset by 6 months.  A user that wishes to have no exposure to the underlying crypto-currency can switch which CFD market they are in every 6 months.

Minimizing Market Manipulation at Settlement
Because settlement depends upon a price feed, market participants need confidence that the settlement price will be reasonable and free from any surprises.   To achieve this the price feed must be provided by multiple sources that are unlikely to collude and it must be provided on a daily basis.   To further protect market participants from sudden price movements or changes in the behavior of the feed producers, the 30 day moving average (or median) of the price feed could be used as the settlement price.   

From the perspective of a prediction market, speculating on the future value  of a 30 day moving average is nearly identical to speculating on the exact price any time the event is more than 30 days in the future.   This means that 11 months out of the year the prediction market will track the instantaneous price changes.   During the last 30 days the market will start to have more information about the 30 days that are factored into the moving average and the price will start to converge on the moving average rather than tracking the instantaneous price.

If you assume there exist two markets offset by 6 months, then the real time price from the second market can be averaged into the price feed to further reduce the impact of any individual feed producer from attempting to manipulate the price for gain. 


Creating a Pegged Asset without Expiration

The process of rebalancing an account between two different CFD markets can be mostly automated.  A market making bot can issue a new asset without any expiration that can always be redeemed for the long position with more than 30 days until expiration.   Every 6 months this bot would rebalance its portfolio of assets.   10 months out of every year the two CFD markets should have a near 1:1 price which means that that natural spreads between the two otherwise nearly identical markets would allow the bot to convert with minimal cost.  As the issuer of an asset, the bot would be generating income from every place its asset is used in other markets.   This is a very valuable service that should easily cover the cost of rebalancing the portfolio over 5 months.   The bot could rebalance its portfolio by enabling a lower spread with no fees when converting from a longer expiration CFD to a  shorter expiration CFD.

In a flat market the 30 day moving average is above the daily price half of the time and below the daily price the other half of the time.   This means that half of the time the expiring long position will be worth more than the long position expiring 6 months later and the trading bot would have no trouble liquidating any remaining stock in the last month.   This leaves only the situation when the 30 day moving average makes the expiring position less desirable than the position 6 months away.   In this event the trading bot would be exposed to the difference between the 30 day moving average and the real time price if it was unable to migrate positions in the 5 prior months.   

Because the bot needs to mitigate risk it would be designed to offer a slowly growing discount on the earlier expiring contract.  This discount wouldn’t need to be much, likely a fraction of a percent and far below the income earned from trading commissions which would allow the bot to operate profitably. 

Protecting Margin Positions

While a price feed is not needed all year, it may be beneficial to publish a feed for the sole purpose of protecting short positions from being squeezed in a thin market.   Market purists would consider the risk of a short squeeze as motivation for having higher collateral.  Either approach may be used and should be viable. 

Conclusion

A trusted organization can create an asset that will follow the value of any price feed assuming the feed is predictable based upon public information.  This organization needs no ties to the outside financial system and can consist of members elected by the stakeholders.   In other words we can assume the two market issued assets and the user issued asset can be managed by a multi-sig account defined as the current set of elected delegates.   

The primary downside to this approach to pegging an asset is that it divides liquidity among 3 different markets rather than concentrating it within a single market.  Fortunately arbitrage between these three markets is relatively cheap and instant which will make them function nearly as one.  This is especially true if the exchange can simultaneously trade across all three markets in a single order.




Title: Re: BitAssets 2.0 - For Community Review
Post by: btswildpig on April 16, 2015, 02:41:06 pm
Any plan involving a set in stone day is easy for an attack from the long position of BitUSD .

Esp. all the volume from half a year settle on a single day ....bloody ...

They can just spread rumors or even bad news in the last 30 days to drive the price down and earn more BTS without even spending money .
Title: Re: BitAssets 2.0 - For Community Review
Post by: wuyanren on April 16, 2015, 03:07:15 pm
BM gege,  Can release a stable synchronization wallet? we come to talk about the other
Title: Re: BitAssets 2.0 - For Community Review
Post by: wuyanren on April 16, 2015, 03:14:27 pm
BM gege,I think you do not live in the shadow of idealism
Title: Re: BitAssets 2.0 - For Community Review
Post by: Empirical1.2 on April 16, 2015, 03:15:47 pm
I don't understand CFD's or this very well.

I can see that the advantage of this model is less reliance on price feeds.

The trading bot mentioned is mainly facilitating moving over to the next contract as opposed to being a market maker that lets you buy and sell BitUSD for BTS whenever you want right?

If so why would this model be much more liquid? 
Title: Re: BitAssets 2.0 - For Community Review
Post by: Bitcoinfan on April 16, 2015, 03:39:50 pm
So in other words:

CFD = True Prediction Market that resolves at expiration.  Two PM's 1 year long each, but offset by six months.

UIA will sollicit outcomes from the 2 CFD's on a rolling basis which should bring UIA at Par value.

This was my quick digest.  Am I getting this correct?  Wouldn't that mean, the mechanisms of short vs longs bettors would have to be relegated to the CFD's and no longer in the actual Bitasset itself?
Title: Re: BitAssets 2.0 - For Community Review
Post by: xiahui135 on April 16, 2015, 03:53:06 pm
why not just cancel the short peroid, so people can buy back as they wish if it is not explosed.
Title: Re: BitAssets 2.0 - For Community Review
Post by: oldman on April 16, 2015, 04:16:21 pm
I've a fairly good grasp of what BM is proposing and am on the fence - I'd like to see Arhag weigh in on this.
Title: Re: BitAssets 2.0 - For Community Review
Post by: NewMine on April 16, 2015, 04:17:54 pm
Are you proposing that people be capped in to a position for 6 months? As in I cant just hold bitUSD for ever, I will get assigned BTS after 6 months? Or are you saying once i choose BitUSD, i cant move freely between bts and bitUSD except every six months?
Title: Re: BitAssets 2.0 - For Community Review
Post by: starspirit on April 16, 2015, 04:23:43 pm
Unfortunately I think the market theory is incorrect.

In traditional currency markets, the market will have different expectations for where the two markets will close 6 months and a year from now. In currency forward markets, this would be reflected in different forward prices at each term (and a corresponding yield curve, with implied forward interest rates in each future period). If there were a change in the implied forward interest rates in the market beyond the expiry of the front CFD, it would not affect the valuation of the front-dated CFD, but it would affect the valuation of the far-dated CFD. That is, the returns on each CFD, on any timeframe, are different, due to shifting market expectations in the later period.

If the bitAssets are structured as forwards like this, then there would be no correspondence in price or price movement.

If the intent would be to have a floating accrual ("yield") of some sort to reflect these valuation changes instead of price, the accrual would have to allow both positive and negative yield. Otherwise a downward valuation in the corresponding forward rate relative to the spot rate could not be reflected. And as per above, this would be a different accrual on each CFD. I don't know how one might do this in practice, but even if it could be done the asset pool would consist of two CFD assets plus two corresponding positive or negative accruals.  The NAV of the asset would not match either of the CFD values, so it could not be redeemable for either without the possibility of inequity and exploitation.
Title: Re: BitAssets 2.0 - For Community Review
Post by: merivercap on April 16, 2015, 04:24:03 pm
If the problem is the settlement price for the CFD, why not use the mid-market rate between bid & asks based on volume in the order book?

It is a common social convention to split the difference whenever there is a disagreement on price.

Title: Re: BitAssets 2.0 - For Community Review
Post by: Bitcoinfan on April 16, 2015, 04:27:26 pm
Are you proposing that people be capped in to a position for 6 months? As in I cant just hold bitUSD for ever, I will get assigned BTS after 6 months? Or are you saying once i choose BitUSD, i cant move freely between bts and bitUSD except every six months?

What I am guessing is that there are three markets.  If you buy the BitUSD market and not the CDF one, you will have stability without a investment expiration. It will be continuous.   
Title: Re: BitAssets 2.0 - For Community Review
Post by: Shentist on April 16, 2015, 05:21:36 pm
you said "simple" , it is not!

i would have to read it multiple times to undestand it. I am not native speaker, so.....

everytime the market is not behavior "fine" we change something??

I think this is not a good solution. In my view the market circle of long and short is broken, because you can't go "long" bitUSD

what about:

1. make it possible to go "short" bitshares or "long" bitUSD. So i could go long the same way i go short "bitUSD" but i need bitUSD to make this
2. the output of this contract would be "bitBTS" and the holders will get a yield from the "shorters"
3. now we have a fully function cycle of long and shorts in the market and someone who want to go long bitUSD he has to buy some on the internal market

and

we need to discuss 200% collateral and the 30 day rule. I would love to replace it with something simpler. Maybe after 30 days the interest will get paid and the collateral will get adjust to the collateral at this
point in time.

4. we should also consider to do "shorts" and "longs" x % away from the feed price
Title: Re: BitAssets 2.0 - For Community Review
Post by: zerosum on April 16, 2015, 06:24:21 pm
you said "simple" , it is not!

i would have to read it multiple times to undestand it. I am not native speaker, so.....

everytime the market is not behavior "fine" we change something??


we need to discuss 200% collateral and the 30 day rule.
+5%

I agree. With this new thing expect a stable client by 2027...
Title: Re: BitAssets 2.0 - For Community Review
Post by: pc on April 16, 2015, 07:02:04 pm
Being forced to roll over twice a year might be a no-go when you're in a jurisdiction where trades are taxed.
Title: Re: BitAssets 2.0 - For Community Review
Post by: bytemaster on April 16, 2015, 07:09:20 pm
Thanks for all of the feedback.   My take away is the following:

1) Tax implications could become a mess
2) It certainly isn't simpler when you look at 3 assets instead of 1, though each CFD is simpler.
3) The individual CFDs may not trade 1:1 as expected.

Overall a single CFD may be good for day traders and those looking for a low risk way to hold USD short term, but long term holding is not as viable and it wouldn't make as good of a currency.

Primary goal I am trying to figure out is how to simplify the price feed, roll over, etc.   
Title: Re: BitAssets 2.0 - For Community Review
Post by: luckybit on April 16, 2015, 07:14:55 pm
It's too early to focus on stability. The focus probably should be on future proofing the technology because right now no one is buying crypto anyway. Even Bitcoins aren't selling much so who are the new customers going to be?

I realize this could change pretty fast but right now we are at all time low Bitcoin prices if you're thinking about it the typical pattern. This is basically the best time to buy Bitcoin but at the same time that is also the worst time to buy anything else but Bitcoin and people don't even have enough sense to buy Bitcoin.

Conclusion? Focus should be on innovation rather than chasing mass adoption. We might not see mass adoption happen until summer 2016.
Title: Re: BitAssets 2.0 - For Community Review
Post by: karnal on April 16, 2015, 07:32:07 pm
bytemaster, would you elaborate in which aspect(s) are bitshare(s) lacking, and whether the current design has nonrecoverable fatal flaws?
Title: Re: BitAssets 2.0 - For Community Review
Post by: Bitcoinfan on April 16, 2015, 07:43:37 pm
bytemaster, would you elaborate in which aspect(s) are bitshare(s) lacking, and whether the current design has nonrecoverable fatal flaws?

ditto
Title: Re: BitAssets 2.0 - For Community Review
Post by: mf-tzo on April 16, 2015, 07:45:59 pm
What about creating Forward Bitasset Agreements, I will call them FBAs as follows:

One can go long or short in bitusd and take a position for the USD via FBA USD

Settlement is once per month at month end.

Settlement price at month end is the average of daily feed prices.

FBAs are traded daily for the current month, the next month and the next etc.. i.e. we can trade FBA up to 5 years.

Ideally we should trade the current month, the current Quarter, the remaining Quarters and the Next year. No point more than that in crypto space for the time beeing.

The above will create on a daily basis a forward curve for the bitUSD:BTS price and will increase liquidity and demand for bitusd and BTS..

The blockchain will be the clearing house for all the FBAs..In order to avoid failure of settlement the system will do a daily mark to market for the owner of the FBAs and do automatically a margin call if the daily m2m is negative or release of funds if positive on a daily basis. This way all FBAs even if they are for a future date, in reality are cleared on a daily basis...

Any thoughts? 
Title: Re: BitAssets 2.0 - For Community Review
Post by: speedy on April 16, 2015, 07:47:46 pm
To guarantee redeemability to the shorts why not just make BitUSD that hasnt moved for a year expire? You could offer the option to pay a tiny extra transaction fee if you really want to hold BitUSD forever, but most people probably would never need this. Anyone who trusts that BitUSD really works is long term bullish on BTS so would not want to hold BitUSD for an entire year anyway.

Then every day you have up to 1/365 of all BitUSD being sold back. This would at least partially help shorters who need to cover.

This is a lot simpler than creating multiple phased BitUSD markets.
Title: Re: BitAssets 2.0 - For Community Review
Post by: merivercap on April 16, 2015, 07:49:02 pm
If the problem is the settlement price for the CFD, why not use the mid-market rate between bid & asks based on volume in the order book?

It is a common social convention to split the difference whenever there is a disagreement on price.

I was going to add also if you use the mid-market rate between bid & asks for settlement it would be hard to manipulate the order book because you would have to place orders on the book to sway pricing one way or the other and you would effectively bring more liquidity to the market.   You will be 'making' the market and providing liquidity if you tried to manipulate the market and that helps with price discovery even more. 

Also rather than having an expiration date, why not just mark-to-market daily?  Hence both short & long have liquidity and everyone will effectively have the CFD contracts rolled over daily automatically and have fungibility.   The problem may be if there will be enough stable supply of bitAssets to meet demand.  If you have enough BTS you can short bitAssets into existence so if your business relies on having a fixed supply of bitAssets you can make sure you have enough BTS to cover any supply shortfalls in bitAssets. 

Finally the available bitAsset supply should ultimately be tied to the fundamental value of the collateral:  BTS, the organization/DAC that receives BTS via transaction fees as 'revenue' and whose 'income' is revenue minus 'expenses' (ie. delegate fees) that results in 'profit' to members or 'stakeholders'.   Because income for a growth company is not necessarily desired and investors would usually want 'profits' poured back into grow the company you can use price to sales (ie. revenue) P/S as a better rough proxy for estimating the value of the DAC rather than P/E. (You can also use a discounted cash flow (DCF) model for valuation if you wanted.)  The maximum P/S ratio of Facebook & Twitter in the trailing twelve month (TTM) is about 25 so that might be the max P/S you would use to estimate the max value of BTS (The US stock market is overvalued btw.  On the other hand Facebook/Twitter is already past the mid-point of it's S-curve growth so they may be somewhat conservative comparisons)

Hence it would be good to have higher collateral when the bitAsset supply is too great relative to the value of the collateral based on P/S to prevent bubbles and lower collateral requirements when the value of the collateral is much higher relative to the bitAsset supply.
Title: Re: BitAssets 2.0 - For Community Review
Post by: bytemaster on April 16, 2015, 07:56:24 pm
bytemaster, would you elaborate in which aspect(s) are bitshare(s) lacking, and whether the current design has nonrecoverable fatal flaws?
ditto

Observations over the past 6 months have taught me a lot:

1) Yield harvesting makes yield inconsequential
2) Interest is easily avoided anytime there is no demand to sell at the feed
3) Forced covering every 30 days puts a lot of unnecessary dependence upon the price feed and scares away shorts
4) Long positions can hold out forever if they are large enough and concentrated enough to collude which means shorts are unable to exit at reasonable prices
5) All of the above cause negative outcomes for shorts in bear markets for BTS.

It is all caused by asymmetry in being forced to cover.  I want to simplify each individual asset so that both parties take symmetric risks.

Title: Re: BitAssets 2.0 - For Community Review
Post by: mf-tzo on April 16, 2015, 08:15:39 pm
@ BM..I suggest you read my post about FBA USD below..It is easy and straight forward..This will eliminate the need for the 30 days covering the short and will certainly increase liquidity and will eliminate all the current problems...From where I come I saw this happened. It is a proven theory.

Feed prices will create a fair settlement of the agreements which will be cleared on a daily basis.I am really bad in explaining things but I pretty sure it is the best solution to increase liquidity. Do I need to go in more details on how this works or this is clear but you don't think it is what we need?

 
Title: Re: BitAssets 2.0 - For Community Review
Post by: bytemaster on April 16, 2015, 08:18:15 pm
@ BM..I suggest you read my post about FBA USD below..It is easy and straight forward..This will eliminate the need for the 30 days covering the short and will certainly increase liquidity and will eliminate all the current problems...From where I come I saw this happened. It is a proven theory.

Feed prices will create a fair settlement of the agreements which will be cleared on a daily basis.I am really bad in explaining things but I pretty sure it is the best solution to increase liquidity. Do I need to go in more details on how this works or this is clear but you don't think it is what we need?

What post about FBA? 
Title: Re: BitAssets 2.0 - For Community Review
Post by: mf-tzo on April 16, 2015, 08:24:34 pm
What about creating Forward Bitasset Agreements, I will call them FBAs as follows:

One can go long or short in bitusd and take a position for the USD via FBA USD

Settlement is once per month at month end.

Settlement price at month end is the average of daily feed prices.

FBAs are traded daily for the current month, the next month and the next etc.. i.e. we can trade FBA up to 5 years.

Ideally we should trade the current month, the current Quarter, the remaining Quarters and the Next year. No point more than that in crypto space for the time beeing.

The above will create on a daily basis a forward curve for the bitUSD:BTS price and will increase liquidity and demand for bitusd and BTS..

The blockchain will be the clearing house for all the FBAs..In order to avoid failure of settlement the system will do a daily mark to market for the owner of the FBAs and do automatically a margin call if the daily m2m is negative or release of funds if positive on a daily basis. This way all FBAs even if they are for a future date, in reality are cleared on a daily basis...

Any thoughts?
Title: Re: BitAssets 2.0 - For Community Review
Post by: mf-tzo on April 16, 2015, 09:01:48 pm
To put it in a numerical example what I mean:

Assuming for simplicity 4 days instead of 1 month (until expiry of the Agreement) and the current BTSUSD at day zero price is $1. I believe that upon expiry the BTSUSD will be more so I buy 1 contract FBA BTSUSD @ $1 for expiry after 4 days.

Assuming the daily feed prices. f1=$1.5 , f2=$2 , f3=$0.5 , f4= $4

What will happen on a daily basis is the following:

Average d1=1.25 , therefore +$0.25 on my account
Average d2=1.50, therefore another +$0.25 on my account ($1.5 - $1 - $0.25)
Average d3=1.25, therefore margin call -$0.25 ($1.25 - $1 - $0.25 - $0.25)
Average d4= 1.8, therefore +$0.55 ($1.8 - $1 - $0.25 - $0.25 +$0.25)

Total gain until the expiry of  my contract $0.8 (0.25+0.25-0.25+0.55) but settled on a daily basis.

Now with this way you create liquid contracts that can be traded on a daily basis at specific expiry dates (1 month, 1 Q. 6M, 1Y). This way we create a forward curve for BTSBitUSD.

Benefits:
Increased liquidity
Hedging of BTS exposure
Shorts will cover sooner
Bitshares becomes the first decentralized clearing house for bitassets (I always thought BTS as a big derivative clearing house)

Negatives:
I can't think any..