Author Topic: The Future of the BTSX Market Engine...  (Read 12431 times)

0 Members and 1 Guest are viewing this topic.

Offline GaltReport

We plan to make one last change to the market engine prior to locking it in stone for many months ...

Glad to hear this.  i think we are near (past?) the point of diminishing returns with respect to the time spent on this for the return.  Maybe that will free up more time to focus on marketing, partnering and networking to facilitate further BitSharesX/BitUSD utility in all the ways discussed. 

Edit: I have this re-occurring nightmare that someone else is going to come along with less tech but better marketing/partnering and eat our lunch. :(
« Last Edit: October 02, 2014, 05:01:43 pm by GaltReport »

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12922
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BitShares: xeroc
  • GitHub: xeroc
very detail, much rules, .. aehm .. screw it ... nicely written .. we should copy&pasta this into the wiki ..
I will be offline for the weekend so maybe some else can handly it ..

It's exciting to see babies grow!

Xeldal

  • Guest
 +5% This is fantastic! Great work!  +5%

Offline bytemaster

We plan to make one last change to the market engine prior to locking it in stone for many months and changing to a much slower release cycle.

Short orders can only get filled under these conditions:

1) There is someone willing to buy BitUSD at the price feed
2) AND Your short order offers the highest interest rate
3) AND Your price limit is lower than the feed  (BTSX per USD) or you didn't specify a price limit.
4) AND You have enough collateral to provide 2x backing at the feed price (amount of USD for short sale will vary with feed price)
5) OR Your price limit is higher than the feed (BTSX per USD) and someone is willing to buy at your price limit.

Short orders are forced to cover after 30 days by taking the best offers at the time.  No fee is charged.
Short orders are forced to cover when 75% of their collateral is required to cover, leaving the short with 25% of the collateral minus a 5% fee. 
The 5% fee is assessed as a percent of the collateral left over after covering.

The maximum interest rate shorts can pay is 1000% APR
The initial collateral ratio will be 3x rather than 2x  (2x from short + 1x from long)

Interest charged will accumulate to the yield fund.

How is this better than *everything else* we have tried before it? 
1) First attempt charged a *fee* for short overlap, this fee basically bid up the spread and the amount of time a short would have to wait to cover profitably and made market makers unprofitable.
2) Second attempt (currently implemented) has shorts bid up collateral, but this provides less and less benefit to the network as prices go higher... ie: 10x collateral only provides 5% more downward protection than 5x collateral. 

How can I be sure we "have it right now"? 
1) It only makes sense that if you are borrowing USD you should be paying interest....
2) It only makes sense that if you are borrowing USD there is a fixed repayment time...
3) We are not price fixing the interest rate, it is being set at "auction" at the current price feed.
4) Time based fees encourage covering sooner rather than holding forever which improves liquidity.
5) It only makes sense that the creditors (holders of it BitUSD) be compensated for their risk at market rates.
6) BitUSD supply will rise to meet the demand of the shorts and the market activity will be more robust

It has been very tricky to figure out this market with two dimensions (price and interest) and we have been evolving toward steadily improving systems.   The great thing about this latest solution is that it realizes almost all of my original goal of interest paying BitUSD funded by the shorts.   BTS with market based interest rates..... you know those two upgrades we talked about 6 months ago that were being postponed until we tried the interest-free version.    Well in just 1 month we have learned, adapted, and deployed a system that does what I thought would take 6 months and a new DAC to implement. 

We have only had to make one compromise so far:  price feeds. 

The remaining weaknesses are: 
  1) shorts don't get to pick the price, just a limit and the rate 
  2) the price feed is slow to update and does not allow internal price discovery.
  3) the market is asymmetric (you cannot short BTSX backed by USD)
  4) you cannot short BitGLD backed by BitUSD (or any other combo)
 
We have a roadmap for addressing all of these:

1) Implementing a bond market that allows USD longs to LEND to shorts for fixed term with a bid/ask system setting the interest rate.  This will create no new BitUSD but will give shorts freedom to set their price without respect to the feed and hold for longer than 30 days.

2) Implementing a prediction market that trades on the ERROR in the price feed.  This prediction market will then allow continuous, real time, price discovery on the blockchain by continuously discovering the % delta between the price feed and real price.  It can be speculated on without losing any exposure to BTSX and with limits that can be used to halt trading on the USD/BTSX market if the feed error is too great.   The USD/BTSX market can then use FEED_PRICE * PERCENT_ERROR.   In this way delegates are only responsible for "getting close" with their feeds and a free market will continuously update the price at which shorts can execute.

These last 2 items are not critical and price feeds are likely more accurate than a thin error market.   For this reason we will not be implementing them until after BitAssets have proven themselves for 3+ months *AND* we have done a very careful test network.   Getting BitUSD right has required rapid tweaking and updates, but the rate of change is not healthy for BTSX or others and has many risks due to bugs.   So I think these last two enhancements are not high priority and we will instead focus on light weight clients, multi-sig, etc.

We are working to make BTSX and the toolkit the most robust financial platform we can with as little trust as possible in anything but the market.
For the latest updates checkout my blog: http://bytemaster.bitshares.org
Anything said on these forums does not constitute an intent to create a legal obligation or contract between myself and anyone else.   These are merely my opinions and I reserve the right to change them at any time.