anti-gambling-trader-tw
免費開源的投資反詐、交易統計與自動化交易程式工具:預設 PaperBroker,提供 14 種券商/交易所選項;交易紀錄分析在本機執行。
尚未偵測到更新。GitHub 發布版本後會顯示在這裡。
個人 GitHub 帳號下公開儲存庫的擁有者可以登入並驗證所有權,自行管理介紹,無需管理員核准。
登入並產生驗證檔案,在 30 分鐘內將其提交至此儲存庫的預設分支。其他分支或分叉儲存庫中的檔案無效。然後在下方檢查檔案,即可無需管理員核准直接管理專案。請保留檔案以維持管理權限。
如需登入,將前往登入頁面。登入後請回到此處,再次點擊所選的驗證按鈕。
在專案資料夾中執行 /nomorevibe verify,即可驗證所有權並自行管理介紹。
一分鐘完成驗證製作者的介紹僅有上面的一句話。 更多詳情請閱讀儲存庫 README。 儲存庫 README ↗
正在載入完整 README。
檢視完整 README ↗A live exchange in your browser: real order book, real market data, structured trading games. Open-source, built at Oxford, free for any student, society, or classroom.
alphabook.uk — sign up and trade in under a minute.
The skills trading firms actually test — market making, probability calibration, pricing under pressure — are taught almost nowhere outside the firms themselves. AlphaBook makes them trainable: a real price-time-priority matching engine, live market data, and games modelled on trading-floor exercises, all with virtual balances and zero real-money risk.
We use it to run live trading bootcamps and competitions for the Oxford student quant community, including the Oxford Alpha Fund: an instructor creates a game, scripts the news flow, and a room of students competes on a shared order book with a real-time P&L leaderboard.
Every mode has a live leaderboard. Works solo too — the market-maker bot is always on the other side.
We are seeking grant funding to turn the simulator into an adaptive teaching platform:
Xue (Snow) Yan (project lead) · Siyu (Sylvia) Li · Nick Wang · Fiona (Yiran) Zhang · Xinyun Jiang · Yiluan (Eylan) Zeng
| Layer | Technology |
|---|---|
| Backend | Python 3.11 / FastAPI / Uvicorn |
| Frontend | Jinja2 + vanilla JavaScript |
| Data & auth | Cloud Firestore (async) + Firebase Auth |
| Real-time | WebSockets (book snapshot broadcast on every trade) |
| Market data | Stooq quotes + synthetic tick engine |
| Deploy | Docker → Cloud Run + Firebase Hosting |
Key modules in app/: order_book.py (matching engine: price-time priority, partial fills), market_maker.py (two-sided quoting with realistic depth and delayed sweeps), market_data.py (real quotes blended with synthetic ticks), fiveos.py / headline.py / poker_auction.py / mental_math.py (game engines), admin.py (games, news, leaderboard, users). Tests live in tests/; CI runs ruff + pytest on every push.
Market Simulation Coding (algo_engine.py + market_sim_py.py + world.py) is client-side: players run their bot on their own machine and reach the market only through an authenticated, rate-limited order gateway (algo_ratelimit.py caps it at ~10 orders/sec). No player code runs on the server, so there is nothing to sandbox — the engine only validates and matches orders on arrival. The same is true of the world layer (world.py), where an empire action is validated JSON just like an order; it holds the map, the buildings, the units and the combat, and is kept pure and seeded so the whole ruleset is testable without standing up a market. A player's trading P&L is their build budget, which is the only coupling between the two halves. Both keep their own books and fictional items, separate from the live stock market. Full write-up — architecture, the API, and a strategy-writing guide with worked examples — in docs/market_sim_py.md.
Prerequisites: Python 3.11+, a free Firebase project (Auth + Firestore).
git clone https://github.com/snowy615/alphaBook.git
cd alphaBook
python3 -m venv venv && source venv/bin/activate
pip install -r requirements.txt
cp .env.example .env # fill in Firebase config — see SETUP.md
python -m uvicorn app.main:app --reload
Open http://localhost:8000. Full Firebase setup and Cloud Run deployment: SETUP.md.
PRs welcome — see CONTRIBUTING.md. MIT licensed (LICENSE).