{"slug": "i-built-an-ai-crypto-trading-bot-then-proved-it-had-no-edge", "title": "I built an AI crypto trading bot, then proved it had no edge", "summary": "A developer built an AI crypto trading bot and rigorously tested it for an edge, finding that the directional LLM-based strategy had no edge after accounting for costs, while a delta-neutral funding carry strategy on altcoin perpetuals showed a small but real structural edge of 10–20% annually with a $100k capacity ceiling. The project is published as open-source research with tools to disprove false edges.", "body_md": "A crypto trading research project — and an honest record of what happened when I tested it for a real edge.\n\nIt started as an AI-driven directional bot: deterministic market features →\nLLM trade suggestions → a multi-gate risk engine → paper/live execution. Then I\ndid the thing most trading projects skip: I tried, rigorously, to **disprove**\nthat it made money. It didn't. So I kept testing — pairs, stat-arb,\ncross-exchange — and disproved those too. One strategy survived: a\n**delta-neutral funding carry** on high-consistency altcoin perpetuals.\n\nThis repo contains both halves: the full directional bot (which has **no edge**,\nand I can show you why) and the carry strategy (which has a **real, structural,\nbut small** edge). The whole point is the methodology — see\n** docs/METHODOLOGY.md**.\n\nReadEducational/research only. Not financial advice. Paper by default. Trading risks total loss. As published, the carry edge is backtested and paper-tested,[DISCLAIMER.md]first.notproven over a long live track record.\n\nMost \"edges\" are illusions that vanish once you account for real costs or test\nout-of-sample. The directional bot's mechanical signal was **+0.035R gross but\n−0.243R after realistic slippage and fees**. The LLM layer (Cerebras and Gemini,\ntested on a gated replay) did **not** beat break-even. Pairs/stat-arb was\noverfit — every pair that looked good in-sample reversed out-of-sample.\nCross-exchange funding differences were already arbitraged to ~0.4%/yr. The only\nthing that held up under honest cost accounting was harvesting funding on\nperpetuals that are *structurally* hard to short, where longs persistently pay\nshorts. Held delta-neutral (long spot + short perp), that pays roughly\n**10–20%/yr, market-neutral**, with a hard **capacity ceiling around $100k**.\n\n| Module | Role |\n|---|---|\n`sentinel.carry` |\nThe strategy that survived. Scanner, simulator, delta-neutral position, risk-parity book, manager, persistence, 24/7 runner |\n`sentinel.core` |\nScheduler, pipeline orchestration, positions, daily report (directional bot) |\n`sentinel.data` |\nCCXT market data, deterministic features, historical cache |\n`sentinel.ai` |\nLLM client, prompts, reflection, offline dataset tooling |\n`sentinel.risk` |\nMulti-gate risk engine, sizing, kill switch |\n`sentinel.exec` |\nBroker interface, paper/MEXC execution |\n`sentinel.backtest` |\nBacktest engine, LLM gated replay, cost sweep — the disproof tools |\n`sentinel.store` |\nSQLite (WAL) persistence |\n`sentinel.admin` |\nTelegram admin bot |\n\nThe carry strategy is deliberately split into a **pure, unit-tested core**\n(scoring, sizing, accounting, scheduling) and a thin **network/time layer**\n(price fetch, the loop). That's why it's testable and restart-safe.\n\nRequires **Python 3.12+**.\n\n```\ngit clone https://github.com/blitzcrieg1/sentinel-trader-research.git\ncd sentinel-trader-research\n\npython -m venv .venv\n# Windows:  .\\.venv\\Scripts\\Activate.ps1\n# Linux/macOS:  source .venv/bin/activate\n\npip install -e .\ncp .env.example .env   # defaults are paper-safe\n```\n\n**Run the carry strategy (paper, no exchange keys needed — public data only):**\n\n```\npython -m sentinel.carry.run --capital 10000 --state data/carry_book.json -v\n```\n\nIt scans MEXC perpetuals, curates a basket by funding *consistency*, opens\nsimulated delta-neutral hedges, accrues funding every 8h (00/08/16 UTC), and\npersists the book so it survives restarts. Add `TELEGRAM_BOT_TOKEN`\n\n+\n`TELEGRAM_ADMIN_CHAT_ID`\n\nto `.env`\n\nfor 8-hourly reports (optional).\n\n**Run the directional bot (paper):**\n\n```\npython -m sentinel.main\n```\n\nIt needs an LLM key (`GEMINI_API_KEY`\n\n) and uses `dummy`\n\nMEXC keys for paper. It\nworks — it just doesn't have an edge. That's the point.\n\n```\npytest          # carry core: scoring, sizing, delta-neutral accounting, persistence\nruff check .\nmypy sentinel/\n```\n\nThe sharpest objection to a consistency-screened basket is survivorship/look-ahead\nbias. `sentinel/carry/walkforward.py`\n\nconfronts it: at each rebalance the basket\nis picked on **past-only** data, scored on the **next, unseen** window, then\nbootstrapped into a 95% CI and compared to a random-selection baseline.\n\n```\npython -m sentinel.carry.walkforward --scan --train 600 --test 120 --top-n 6 -v\n```\n\nIf the edge only existed in hindsight, the out-of-sample yield collapses to the\nbaseline and the CI straddles zero. The no-look-ahead property is unit-tested. See\n[docs/METHODOLOGY.md](/blitzcrieg1/sentinel-trader-research/blob/main/docs/METHODOLOGY.md) §5.5.\n\nAnd because capacity is the whole story for a thin-market edge, `capacity.py`\n\nturns the \"~$100k ceiling\" into a net-yield-vs-notional **curve** (square-root\nmarket impact + participation cap + a sensitivity band):\n\n```\npython -m sentinel.carry.capacity --symbol XMR_USDT -v\n```\n\nLinux + `systemd`\n\n. Units are in `deploy/`\n\n— `sentinel-carry.service`\n\n(the\nstrategy) and `sentinel-trader.service`\n\n(the directional bot). Both run fine on\na small always-on box (a Raspberry Pi or a cheap mini PC). The carry book uses\natomic writes and SQLite uses WAL, so a power loss won't corrupt state.\n\n**It is** an honest, end-to-end study of whether a retail crypto edge exists, with the code to reproduce every finding.**It is** a working, market-neutral carry harvester with a structural reason to work and modest, capacity-limited returns.**It is not** a way to get rich from a small stake. A ~15% market-neutral return is excellent — but 15% of a small number is a small number. At small capital, your savings rate matters far more than any strategy's return.**It is not** financial advice or a turnkey money machine. See[DISCLAIMER.md](/blitzcrieg1/sentinel-trader-research/blob/main/DISCLAIMER.md).\n\nFunding carry is **not new**, and this repo doesn't claim to have discovered it.\nIt's one of the most replicated ideas in crypto, and the structural reason it\nworks is well documented — a [BitMEX study](https://markets.financialcontent.com/chroniclejournal/article/gnwcq-2025-10-14-bitmex-study-finds-cryptocurrency-funding-rates-positive-92-of-the-time)\nfound funding is positive ~92% of the time. There are many implementations:\n\n**Execution / detection bots**— e.g.[aoki-h-jp/funding-rate-arbitrage](https://github.com/aoki-h-jp/funding-rate-arbitrage),[ARBOT](https://github.com/IrakliXYZ/ARBOT),[HL-Delta](https://github.com/cgaspart/HL-Delta). These detect funding opportunities and run the delta-neutral trade. They're useful — but they're*execution engines*: none ship walk-forward validation, an out-of-sample permutation/selection-bias guard, or a capacity curve.**Academic**— e.g. a[leveraged BTC carry study](https://papers.ssrn.com/sol3/papers.cfm?abstract_id=5292305)(~16%/yr, Sharpe 6.1). Rigorous, but single-asset and theoretical.**Honest \"AI bot\" writeups**— e.g.[Jiri Dolejs' LLM trading bot](https://medium.com/@kojott/i-built-an-ai-trading-bot-and-let-it-trade-for-9-days-heres-what-happened-6ceb69ad4d08), which independently reaches the same conclusion about LLM signals that §2 does.\n\nWhat this repo adds is **not the strategy — it's the discipline around it**:\n\n- A documented\n**disproof** of the strategies that*don't*survive (directional, LLM, pairs, cross-exchange), so the carry isn't presented in a vacuum. - A\n**validation layer** the execution bots skip — walk-forward + bootstrap, a permutation test for selection bias, and a capacity curve, all runnable. **Honest limitations**([METHODOLOGY §6](/blitzcrieg1/sentinel-trader-research/blob/main/docs/METHODOLOGY.md)), including the parts that are unproven or only operationally mitigable.\n\nThe edge is the crowded part; the rigor and the candor are the point.\n\n*Built and tested in paper. The hardest and most valuable result here was\nlearning to disprove my own ideas with data.*", "url": "https://wpnews.pro/news/i-built-an-ai-crypto-trading-bot-then-proved-it-had-no-edge", "canonical_source": "https://github.com/blitzcrieg1/sentinel-trader-research", "published_at": "2026-06-17 16:05:20+00:00", "updated_at": "2026-06-17 16:23:55.127751+00:00", "lang": "en", "topics": ["artificial-intelligence", "large-language-models", "ai-research", "ai-tools", "developer-tools"], "entities": ["Cerebras", "Gemini", "MEXC", "CCXT", "Telegram", "SQLite", "Python"], "alternates": {"html": "https://wpnews.pro/news/i-built-an-ai-crypto-trading-bot-then-proved-it-had-no-edge", "markdown": "https://wpnews.pro/news/i-built-an-ai-crypto-trading-bot-then-proved-it-had-no-edge.md", "text": "https://wpnews.pro/news/i-built-an-ai-crypto-trading-bot-then-proved-it-had-no-edge.txt", "jsonld": "https://wpnews.pro/news/i-built-an-ai-crypto-trading-bot-then-proved-it-had-no-edge.jsonld"}}