One of the issues with market making is directional moves. In equity markets the makers handle this with derivatives to keep their overall exposure market neutral.
In steem-engine, we don't have that option.
So if I want to make a market in BTCP, I have issues both in tracking the change in price and in the change in demand.
We've seen the past few days how much the market price itself can move. But then if the maker gets a sustained demand in one direction, the cash balances on one side of the trade dwindle. For example, if people keep selling STEEMP to buy BTCP, then STEEMP balances go up and the BTCP balances go down. Eventually, the maker needs to unwind that position and sell the BTCP.
The most basic way to handle this is to widen the spread as directionality increases. I was talking about this with aggy the other day. He mentioned increasing the spread with each trade in one direction. But that doesn't go far enough. The spread needs to adjust dynamically based on direction and size. So if tradeA is to buy 0.002 BTCP for 50 STEEMP, that has a much different impact on the liquidity of the market compared to tradeB to buy 1 BTCP for 30000 STEEMP.
My first thought of how to handle this is to widen based on the percentage impact on the remaining cash balance. So if the maker has 100 BTCP, the 1 BTCP order reduces the cash balance by 1% and the normal spread is 2% then the spread widens by 1% to 3%. And then the reverse is true for bringing the maker back into neutral.
But that still doesn't solve the issue of a sustained trend. If people just end up selling STEEMP for BTCP, then the maker needs to rectify that periodically. And that means sending STEEMP to an outside exchange, selling for BTC, and depositing it back into steem-engine as BTCP. Along the way, there are steem-engine fees, exchange fees, network fees, and slippage on the trading price. A lot of exchanges will refund fees to market makers as payment for providing liquidity, so maybe you could get those waived, but those other fees remain. That might be a 1% cost on the total amount needed to be exchanged. And that needs to be incorporated into the spread on steem-engine.
I'm following your project with interest. Hopefully, some of these ideas will be useful to you.
RE: And So It Begins: Steem-Engine Trading Bot Incoming