Verbobrain
I’m going to go into a little bit of detail about how the bot thinks. I will probably refine this in the future, but for now, here’s a rundown.
We’ll start with the scenario where the bot is ready to bid. Here’s what it does:
- Query eBay for a list of top level categories. Randomly choose three.
- Query eBay again for all auctions ending in the next hour in these categories, for at most as much money as the bot has on hand.
- Ten percent of the time, the bot makes this query Worldwide. The rest of the time it only searches US based auctions.
- Once this list is returned, the bot filters out auctions based on excluded categories, like eBooks.
- The list is further filtered based on any category it has purchased in the last 14 days. This prevents a week of Magic cards.
- The list is then filtered based on keywords in the auction title, like “coupon” or “recipe”, things that usually aren’t shipped.
- Now it has a list of items that are valid to bid on. It chooses one at random.
- It now checks this auction for local pickup only. Currently this has to be done on a per item basis, so this is an easy time to do so.
- It would now filter the description for banned words if I had any.
- The bot is now ready to bid on the auction! It sends the amount of cash it has, plus the item ID, to the bidding program.
- The auction is either won, lost, or can’t be bid on for some reason (minimum bid too high, eBay returned outdated bid amount)
At this point the bot mostly waits to see the outcome. Once an outcome is determined, the bot is in a sort of holding pattern:
- The bot checks if the auction has ended. If it has, the bot sees if it won or lost.
- If it won, there is now a 12 hour window where the bot doesn’t try to bid on anything else.
- If it lost, it will try to bid on things based on a percentage chance based on time since it last won something.
- In either case, if less than 12 hours have passed since it last won something, or if it has less than $1, it won’t bid.
- If more than 12 hours have passed, but less than 24, there is a sliding percentage chance it will bid on something. This is a flimsy attempt to vary the buying time throughout the day, to see different auctions.
- If more than 24 hours have passed it’s always going to try to bid on a random item.
- The bot earns 1/24th of a dollar every hour. It counts all the hours since the first auction, then subtracts all the money it has spent, to determine the current bankroll.
There is a lot of room for improvement, mostly related to issues where it chooses an invalid auction, or no valid results are found for whatever reason. I expect this will become more of an issue as more categories are disallowed, and will revisit things at that time.
There is also currently a minimum delay of 20 minutes before it will notice something crazy happened after it places a bid. I don’t mind this too much overall, as it allows a bit more money to build up, but if crazy things start to pile up it could impact the flow of items, so I may have to tweak things there as well.
I’m very open to feedback on things, and I’d take any ideas that would make the results better!
If I could code… I would make this…