Naive bot implementation ported from example