Author [EN] [ZH] [ES] [PT] [IT] [DE] [FR] [NL] [TR] [SR] [AR] [RU] [EN] [ZH] [ES] [PT] [IT] [DE] [FR] [NL] [TR] [SR] [AR] [RU] [EN] [ZH] [ES] [PT] [IT] [DE] [FR] [NL] [TR] [SR] [AR] [RU] Topic: BitUSD Market Maker Live  (Read 3864 times)

0 Members and 1 Guest are viewing this topic.

Offline bytemaster

BitUSD Market Maker Live
« on: September 11, 2014, 08:32:08 PM »

We have produced a python script that can be used by anyone who wants to help make the BitUSD market and are looking for developers to help make it better!

https://github.com/BitShares/bitshares_toolkit/tree/develop/programs/market_maker

It is a tad crude right now, but we have plans to make this kind of script configurable for anyone who wants to perform this function. 

The rules are simple:
1) Buy BitUSD cheap (a few percent discount)
2) Sell BitUSD at the median price feed (or the latest feed from BTER) which ever is higher (in dollars per BTSX)
3) Adjust orders anytime they deviate from what the new orders would be by more than some tolerance.

Under this plan no *NEW* bitUSD will be created until the peg is hit *AND* everyone buying BitUSD can expect liquidity within just a few percent.   Meanwhile profits can be made every time someone switches sides of the market.

We are providing the script for others so that we can increase liquidity and decrease the spread (as our bots compete against each other ;) )

Users can now purchase BitUSD with confidence that they can sell it when they need to.   

Usage:
Code: [Select]
python main.py USER PASS PORT REAL_NETWORK
Example:
Code: [Select]
  python main.py user pass 8000 true
You can tweak the parameters by editing:
  main.py

Code: [Select]
SPREAD_PERCENT = 0.05  # 5%
TOLERANCE = 0.01 # should be less than SPREAD_PERCENT / 2, the closer the tolerance the more often orders are canceled/updated

MIN_USD_BALANCE = 10  #make sure you retain enough USD to pay fees to update your orders
MIN_BTSX_BALANCE = 100  # make sure you retain enough BTSX to pay fees to update your orders
MIN_USD_ORDER_SIZE = 2  # prevent dust orders
MIN_BTSX_ORDER_SIZE = 100  # minimum order size to prevent dust

MEDIAN_EDGE_MULTIPLE = 1.001 # how far in front of the median price feed do you want to sell.
« Last Edit: September 11, 2014, 08:48:32 PM by bytemaster »
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.

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12058
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BTS: xeroc
  • GitHub: xeroc
Re: BitUSD Market Maker Live
« Reply #1 on: September 11, 2014, 08:34:02 PM »
wow .. thats a free arbitrage bot .. am I right?

you guys rock!
« Last Edit: September 11, 2014, 08:40:03 PM by xeroc »
Give BitShares a try! Use the http://testnet.bitshares.eu provided by http://bitshares.eu powered by ChainSquad GmbH

Online Shentist

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 1605
    • View Profile
    • metaexchange
  • BTS: shentist
Re: BitUSD Market Maker Live
« Reply #2 on: September 11, 2014, 08:42:14 PM »
would it possible if someone can set up a demo bts wallet with this bot to see how it is function?

i would love to run it my technical knowledge is limited.

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12058
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BTS: xeroc
  • GitHub: xeroc
Re: BitUSD Market Maker Live
« Reply #3 on: September 11, 2014, 08:48:38 PM »
from my understanding you just run it like this

python main.py rpcuser rpcpass rpcport 1

gonna try this out tomorrow ..

you will need a local account "local-market-maker"
Give BitShares a try! Use the http://testnet.bitshares.eu provided by http://bitshares.eu powered by ChainSquad GmbH

Offline bytemaster

Re: BitUSD Market Maker Live
« Reply #4 on: September 11, 2014, 08:49:42 PM »
from my understanding you just run it like this

python main.py rpcuser rpcpass rpcport 1

gonna try this out tomorrow ..

I updated the OP with docs on how to use it :)
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.

Offline GaltReport

Re: BitUSD Market Maker Live
« Reply #5 on: September 11, 2014, 08:49:54 PM »
Cool!!

Offline oldman

  • Hero Member
  • *****
  • Posts: 543
    • View Profile
Re: BitUSD Market Maker Live
« Reply #6 on: September 11, 2014, 08:50:01 PM »
Would be great if these types of tools could be implemented in the GUI as wizards/robots.

I am not nearly sophisticated enough to compile/run/interface with a script.

However, I can:

- Open the "AutoTrade" tab

- Agree with a disclaimer

- Select the 'bitUSD Market Maker' bot

- Enter the amount of BTSX/bitUSD I want to trade

- Hit the 'Go' button

My suggestion would be for the devs to add a basic algo toolkit to the GUI that automates basic market operations and can be used on any asset class.

Such a feature set would bring a flood of liquidity *and* further the Bitshares competitive advantage over other platforms.

Offline bytemaster

Re: BitUSD Market Maker Live
« Reply #7 on: September 11, 2014, 08:53:32 PM »
Would be great if these types of tools could be implemented in the GUI as wizards/robots.

I am not nearly sophisticated enough to compile/run/interface with a script.

However, I can:

- Open the "AutoTrade" tab

- Agree with a disclaimer

- Select the 'bitUSD Market Maker' bot

- Enter the amount of BTSX/bitUSD I want to trade

- Hit the 'Go' button

My suggestion would be for the devs to add a basic algo toolkit to the GUI that automates basic market operations and can be used on any asset class.

Such a feature set would bring a flood of liquidity *and* further the Bitshares competitive advantage over other platforms.

Already on the drawing board... this script is just a proof-of-concept while we work to make it easier for small players.
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.

Offline Empirical1.1

  • Hero Member
  • *****
  • Posts: 886
    • View Profile
Re: BitUSD Market Maker Live
« Reply #8 on: September 11, 2014, 08:57:15 PM »

Offline tonyk

  • Hero Member
  • *****
  • Posts: 3309
    • View Profile
Re: BitUSD Market Maker Live
« Reply #9 on: September 11, 2014, 09:03:26 PM »
Where did I loose track with those fast developments?

Code: [Select]
MIN_USD_ORDER_SIZE = 2  # prevent dust orders
Isn't min order 100 BTSX...or is it so just for short orders?

hmm, seeing my own orders I have one for less then 2 BTSX ???

Anybody has any idea what '100 BTSX min' pertains to and if this is still valid at all?

 
« Last Edit: September 11, 2014, 09:05:00 PM by tonyk »
Lack of arbitrage is the problem, isn't it. And this 'should' solves it.

Offline oldman

  • Hero Member
  • *****
  • Posts: 543
    • View Profile
Re: BitUSD Market Maker Live
« Reply #10 on: September 11, 2014, 09:05:42 PM »
Would be great if these types of tools could be implemented in the GUI as wizards/robots.

I am not nearly sophisticated enough to compile/run/interface with a script.

However, I can:

- Open the "AutoTrade" tab

- Agree with a disclaimer

- Select the 'bitUSD Market Maker' bot

- Enter the amount of BTSX/bitUSD I want to trade

- Hit the 'Go' button

My suggestion would be for the devs to add a basic algo toolkit to the GUI that automates basic market operations and can be used on any asset class.

Such a feature set would bring a flood of liquidity *and* further the Bitshares competitive advantage over other platforms.

Already on the drawing board... this script is just a proof-of-concept while we work to make it easier for small players.

Damn, you folks never cease to impress!  +5%

Now, who said unsophisticated players are small players? ;D

Offline Xeldal

Re: BitUSD Market Maker Live
« Reply #11 on: September 11, 2014, 09:07:41 PM »
 +5% Outstanding!
I guess I'll put off sleep for another day.

Offline Method-X

  • Hero Member
  • *****
  • Posts: 1120
  • VIRAL
    • View Profile
    • Learn to code
  • BTS: methodx
Re: BitUSD Market Maker Live
« Reply #12 on: September 11, 2014, 09:11:24 PM »
Wow... You guys must not sleep?

Offline tonyk

  • Hero Member
  • *****
  • Posts: 3309
    • View Profile
Re: BitUSD Market Maker Live
« Reply #13 on: September 11, 2014, 09:15:11 PM »
Wow... You guys must not sleep?

I am pretty sure somebody has succeeded at cloning them... before I can do it, that is...
Lack of arbitrage is the problem, isn't it. And this 'should' solves it.

Offline betax

  • Hero Member
  • *****
  • Posts: 803
    • View Profile
Re: BitUSD Market Maker Live
« Reply #14 on: September 11, 2014, 09:18:59 PM »
 +5% sleep or not sleep that is the question :)
https://metaexchange.info | Bitcoin<->Altcoin exchange | Instant | Safe | Low spreads

 

Google+