Trading and Crypto

AI Trading, How a ChatGPT-Built Bot Chased $2,647/Day With Crypto Arbitrage

AI Trading Bot I Built With ChatGPT Made $2,647/Day (Full Guide)

Video: AI Trading Bot I Built With ChatGPT Made $2,647/Day (Full Guide)

ยท based on the channel Andrew Collins

AI trading means using a large language model such as ChatGPT to write, debug and iterate on the code that executes trades automatically โ€” in this case a Python crypto arbitrage bot that, according to the breakdown, made $2,647 in a single day. The full guide and source code are available at the full guide and source code download, and the build is documented end to end by Andrew Collins, from the first prompt to a live test.

What AI trading actually means in this build

The core idea is narrow and mechanical: the bot does not predict prices, it compares them. It scans several crypto exchanges and decentralized venues at once, looks for the same asset quoted at different prices, and buys on the cheaper venue while selling on the more expensive one. ChatGPT's role is not to pick coins or forecast direction โ€” it is to write the Python that connects to exchange APIs, reads order books, calculates the spread, and fires both legs of the trade.

That distinction matters. Most "AI trading" marketing implies a model that knows where the market is going. What is shown here is closer to classic algorithmic trading with an LLM as the programmer: the intelligence sits in the infrastructure and the rules, not in a price prediction. The edge, if there is one, comes from market inefficiencies โ€” momentary gaps between venues โ€” rather than from forecasting.

The build covers the whole loop: prompt, generated code, a walkthrough of every line, a backtest on historical price data, and a live run with real P&L. The architecture is deliberately simple โ€” one script, a list of venues, a threshold, and a loop.

The exact workflow: prompt, generate, review, test

The workflow is repeatable, and that is the most transferable part of the whole exercise. It runs in five stages:

  1. Write a prompt that specifies the strategy precisely: arbitrage across named venues, the trading pair, the minimum spread, the maximum position size, and the requirement to account for fees.
  2. Let ChatGPT generate the Python bot โ€” API connectors, order-book parsing, spread calculation and order execution.
  3. Read every line before running anything. The model will happily produce code that works syntactically and is wrong economically.
  4. Backtest against historical price data to see how often the spread actually clears costs.
  5. Run live with a small size, watch the logs, and feed the failures back into the prompt.

The prompt is the lever. Vague instructions produce a bot that trades constantly and loses money on fees; specific instructions โ€” minimum profit after gas and slippage, retry logic for failed transactions, a hard cap per trade โ€” produce something that behaves like a risk-managed system. The troubleshooting loop is where most of the real work happens: when gas prices spike or slippage eats the expected profit, you describe the failure to ChatGPT and ask for a specific fix, not a rewrite.

Gas fees, slippage and why the headline number is not net profit

A $2,647 day is a gross figure from one live session, and anyone treating it as a repeatable daily income is misreading it. Arbitrage on decentralized venues carries two costs that routinely erase thin spreads: gas fees paid per transaction, and slippage โ€” the difference between the quoted price and the price you actually get when your order hits a thin pool.

On a decentralized exchange, an arbitrage trade is at least two transactions, often more if a leg fails and has to be retried. During congestion, gas can multiply several times over within minutes, turning a profitable-looking spread into a loss. Slippage does the same from the other direction: the price gap you detected may be gone by the time your transaction is mined, or your own order may move the pool enough to close it.

The fix is not a better model, it is a stricter threshold. A trade should only execute when the observed spread exceeds gas plus expected slippage plus a safety margin. That threshold is the single most important number in the bot, and it is a parameter you set, not something ChatGPT invents. Failed transactions need explicit handling too โ€” a leg that reverts should not leave the bot holding a one-sided position.

Backtesting before risking capital

Backtesting is the step that separates a demo from a system. The approach shown is to replay historical price data across the venues the bot monitors, apply the same threshold logic, and count how many of the detected spreads would have survived gas and slippage at the time. Most apparent arbitrage opportunities disappear under that filter, which is exactly the point of running it.

Practical checks worth building into the backtest:

  • Use timestamped order-book snapshots, not last-trade prices, because arbitrage depends on what you could actually have bought and sold.
  • Model fees and gas at realistic levels, including periods of congestion rather than only calm ones.
  • Include failed-transaction rates; a strategy that assumes every trade lands is not a strategy.
  • Compare results across different minimum-spread thresholds to see where the trade count collapses.

If the backtest shows a handful of trades per week rather than hundreds per day, that is a finding, not a failure. Arbitrage is opportunistic by nature.

Typical questions and doubts from traders

Three concerns come up repeatedly around builds like this. The first is whether such a bot is genuinely "AI" โ€” it is, in the sense that the code was written by a model, but the trading logic is deterministic rules. The second is whether it survives real conditions: gas spikes, slippage, reverted transactions and venues that rate-limit or block automated traffic. The third is whether the code is safe to run, since a bot with API keys and withdrawal permissions is a security problem before it is a trading problem.

On the technical side, monitoring multiple contracts and handling failed transactions is the part that looks hardest and is usually the easiest to fix with a well-scoped prompt. On the economic side, the honest answer is that the bot is only as good as your definition of a profitable opportunity. If you define profit before costs, you have built a machine for donating fees to exchanges.

Where the code and the guide live

The complete walkthrough and the bot's source code are collected in one place: the full guide and source code. That is the practical entry point if you want to reproduce the build rather than read about it โ€” the prompt, the Python files and the setup steps are all there. Treat it as a starting point for your own testing, not as a turnkey income stream, and run everything first on small size with a backtest behind it.

Conclusion

AI trading, as demonstrated in this build, is less about prediction and more about using ChatGPT to compress the time between an idea and working code โ€” a Python arbitrage bot that scans venues, checks the spread against gas and slippage, and executes automatically. The $2,647 day is the headline, but the durable lessons are the threshold logic, the backtest, and the handling of failed transactions. Andrew Collins walks through the prompt, the code and the live test in the video breakdown, and the full guide and source code are available at the full guide and source code download. Start small, measure net of costs, and treat every headline number as a gross one.

Key takeaways

  • The bot in the breakdown is a Python crypto arbitrage bot generated almost entirely by ChatGPT from a single prompt.
  • Reported result: $2,647 of profit in one day from arbitrage trades, before the real-world friction of gas fees and slippage is fully accounted for.
  • The strategy scans multiple exchanges and decentralized venues for price gaps and executes both legs automatically, 24/7.
  • Profitability depends on thresholds you define: a trade is only taken when the spread exceeds gas plus slippage by a set margin.
  • Backtesting on historical price data comes before any live capital is deployed.

Source: AI Trading Bot I Built With ChatGPT Made $2,647/Day (Full Guide) ยท Markdown version

Questions & answers

Is AI trading just ChatGPT picking which coins to buy?

No. In this build ChatGPT writes and debugs the Python code, while the trading decisions come from fixed rules: compare prices across venues, check that the spread exceeds gas plus slippage plus a margin, then execute both legs. The model is the programmer, not the forecaster.

Why is the reported $2,647 per day not realistic as steady income?

That figure is gross profit from one live session. Arbitrage spreads are thin and intermittent, and gas fees, slippage and failed transactions eat into them. A realistic expectation comes from a backtest that models those costs at congested-market levels, not from a single day's result.

How do I stop the bot from losing money on fees?

Set a minimum profit threshold that must be cleared after estimated gas and slippage, cap position size per trade, and add retry logic so a reverted leg does not leave you with a one-sided position. Review the logs regularly and tighten the threshold whenever costs rise.

Do I need to be a developer to build this?

Not strictly โ€” ChatGPT generates the code from a detailed prompt. But you do need to read and understand what it produced before running it with real funds, because a bot holding API keys and trading permissions is a security risk as well as a financial one.

Keep reading