A trading bot that admits it loses money
A Python toolkit for automating Kalshi prediction-market trades that ships with risk guardrails, paper trading, and an unusually candid disclaimer about losing money.

What it does
This repo is a Python scaffold for automating trades on Kalshi prediction markets. It wraps the exchange’s REST and WebSocket APIs in a signed client, ingests market data into SQLite, and exposes a CLI and Streamlit dashboard to run and monitor strategies. Three example bots ship with the kit: an LLM-driven directional trader, a math-only “safe compounder” that hunts for NO-side edge, and an aggressive “Beast Mode” the authors explicitly warn against using with real money.
The interesting bit
The README is refreshingly honest: it admits the example strategies lose money, clarifies that the “AI” bot calls a single LLM (not an ensemble), and notes that past performance dissolves quickly in prediction markets. That candor is rarer than a profitable edge.
Key highlights
- Pluggable OpenRouter client with model swapping and a daily cost circuit breaker.
- Built-in paper trading and SQLite telemetry for every signal, decision, and P&L tick.
- Risk helpers include fractional Kelly sizing, stop-loss/take-profit exits, and drawdown breakers.
- “Safe Compounder” strategy places resting maker orders on NO-side markets without touching an LLM.
- Unwired scaffolding for multi-agent debate and sentiment analysis sits in
src/agents/andsrc/data/for forking.
Caveats
- The AI directional strategy is not a multi-model ensemble; parallel agent voting in
src/agents/is still unwired. - Several directories contain “scaffolding” rather than fully integrated features.
- Beast Mode exists mainly as a cautionary tale and is explicitly not recommended for live trading.
Verdict
Grab this if you want a well-documented starting point for Kalshi automation and appreciate a maintainer who treats “past results may vary” as a feature, not a bug. Skip it if you need a turnkey money printer—the README will tell you explicitly that you won’t find one here.
Frequently asked
- What is ryanfrigo/kalshi-ai-trading-bot?
- A Python toolkit for automating Kalshi prediction-market trades that ships with risk guardrails, paper trading, and an unusually candid disclaimer about losing money.
- Is kalshi-ai-trading-bot open source?
- Yes — ryanfrigo/kalshi-ai-trading-bot is open source, released under the MIT license.
- What language is kalshi-ai-trading-bot written in?
- ryanfrigo/kalshi-ai-trading-bot is primarily written in Python.
- How popular is kalshi-ai-trading-bot?
- ryanfrigo/kalshi-ai-trading-bot has 506 stars on GitHub.
- Where can I find kalshi-ai-trading-bot?
- ryanfrigo/kalshi-ai-trading-bot is on GitHub at https://github.com/ryanfrigo/kalshi-ai-trading-bot.