Remix.run Logo
▲ geoffschmidt an hour ago

This is super cool! The rabbit hole goes a bit deeper than I first thought.

Because anyone can tell Opus "go win bouncemarket.minhanhday.com" and with just those words get a pretty good bot, this is in practice a "battle of the bots".

The only unknown is the fractional part of the start position of the ball, which is revealed gradually by the chaotic path of the ball, and a frontier model will quickly realize this and write an exact solver for it. This gives the optimal estimate at time t of the probability of each outcome given the information revealed so far.

Of the bots running now, some seem to have an exact solver while others have a lower quality probabilistic solver. Some bots seem to only bet when there is enough information to be certain, others are willing to bet early when the market is mispricing the risk.

The rate limit of 10 bets a second means that, past a certain point, a bigger bankroll doesn't help. It also means that bets are a scarce resource. You want to bet at the moments when the market maximally misprices the risk, but you don't know when those moments will be because that's a function of what other players do.

To win, you need to do some combination of:

1) Be the first to buy when a bounce reveals new information

2) Be the first to buy when another player makes a non-optimal buy

Both require low latency to the server to win. Only market orders are possible, so if you are not the first you might be severely punished, because if N bots all see an event at the same time, they will pile on (not seeing each other's buys due to the latency in market quotes) and move the market far past fair value, and the Nth bot may buy at a really bad (and unintended) price. Which could then produce a swing in the other direction, so I guess we should expect the market to oscillate. In practice these mispricings seem hard to exploit because they are large but short-lived and so difficult to harvest with market price orders.

Since you asked for feedback, my advice would be:

1) Allow orders other than market orders (eg, add a limit price to the API)

2) Consider running some kind of an auction (once per frame or other time interval) rather than processing orders one at a time

That would make it not be a winner-take-all game based on your distance from the server. On the other hand maybe in this case an orderly marketplace is uninteresting! In that case, if you do #1 but not #2 then you open up some new betting strategies, like trying to catch mispricings due to overcorrection.