Observe
Read public Coinbase candles and open Kalshi markets.
FROM MATHEMATICAL IDEA TO RELIABLE SOFTWARE
In Lesson 01, observations became signals. Now we study how one small Python project turns a BTC 15-minute Strong Momentum signal into a testable paper system—and how careful engineering keeps live execution behind multiple gates.
01 / THE ENGINEERING MISSION
A model is only one part of a trading system. Reliable software must collect data, reject stale inputs, avoid duplicate work, record decisions, reconcile actual fills, settle positions, enforce limits, and fail safely.
The student repository deliberately contains one strategy: BTC 15-minute Strong Momentum. Its small size makes the whole system understandable.
02 / REPOSITORY MAP
Read public Coinbase candles and open Kalshi markets.
Run deterministic filters and rank qualified candidates.
Use SQLite to preserve scans, trades, mode, losses, and P/L.
Report what happened without inventing missing results.
03 / STRONG MOMENTUM
The bot scans once per minute. It does not trade merely because BTC moved; candidates must satisfy time, price, movement, direction, freshness, liquidity, concentration, and estimated-value tests.
The movement from the window reference and latest three-minute movement must point toward the proposed outcome.
If at least 80% of the last ten signals already chose the proposed side, the bot pauses that side.
candidate = (
2 <= minutes_left <= 12
and 0.20 <= ask_price <= 0.85
and spread <= 0.05
and abs(window_move) >= 0.0012
and window_and_3m_directions_agree
and candle_age_seconds <= 120
and estimated_edge >= required_edge
)04 / ONE SIGNAL, TWO EXECUTORS
The strategy logic does not change with mode.
05 / DEFENSE IN DEPTH
Every new ledger starts with enabled = false.
The repository stores credential names, never populated keys.
Status, balance, candidate, and exposure can be inspected without ordering.
Activation requires a deliberate command and exact phrase.
Positions, orders, balance, debit, and limits are checked again.
An unknown executed KXBTC15M order disables future trading.
Actual count, cost, and fees come from the exchange response.
Two losses or a $5 session loss disables live mode.
LIVE CEILINGS IN THE STUDENT REPO
06 / STUDENT WORKSHOP
Clone the repository, read its instructions, and draw the path from public data to report.
git clone https://github.com/preceptress/btc-15-minute-prediction-model.git
cd btc-15-minute-prediction-model
./setup.shPerform a scan, inspect status, and explain why zero trades can be correct.
./venv/bin/python scripts/btc_bot.py cycle
./venv/bin/python scripts/btc_bot.py status
./venv/bin/python scripts/report.pyFind the test proving new ledgers are paper-only. Predict failures before running them.
./venv/bin/python -m unittest discover -s testsTrace one rejected candidate: observation, threshold, Boolean expression, decision.
Create a paper-only hypothesis. Explain how it could help, hurt, and be falsified.
Imagine stale data, duplicate timers, partial fills, failures, leaked secrets, and manual activity.
07 / CAPSTONE
Teams present a bot that is understandable, reproducible, tested, observable, and safe by default. Live readiness is a review outcome—not a deadline.
THE ENGINEER'S QUESTION
“How will this fail—and will it fail safely?”
A strong model is interesting. A strong system is trustworthy.