From 4f1ccde37017cf715ad8767f92fda30fff8bef52 Mon Sep 17 00:00:00 2001 From: momentum dev Date: Thu, 30 Jul 2026 10:17:33 -0500 Subject: [PATCH] docs: Tradier real-money flip runbook (00 cash-account delta) Delta to LIVE-CUTOVER.md (Alpaca-era): 3-line env flip on the existing tradier stack, cash-account GFV cap (1 entry/day), equity floor 270, sandbox-record truncation before first live boot, day-1 naked-stop drill. Co-Authored-By: Claude Fable 5 --- docs/TRADIER-LIVE-FLIP.md | 60 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 docs/TRADIER-LIVE-FLIP.md diff --git a/docs/TRADIER-LIVE-FLIP.md b/docs/TRADIER-LIVE-FLIP.md new file mode 100644 index 0000000..c73199b --- /dev/null +++ b/docs/TRADIER-LIVE-FLIP.md @@ -0,0 +1,60 @@ +# Tradier Real-Money Flip — delta to LIVE-CUTOVER.md + +LIVE-CUTOVER.md was written for Alpaca live (rejected 2026-07-27). Plan of +record is now Tradier real money on the EXISTING tradier parallel stack +(postgres 5434, dashboard 8768). This doc is only the delta. + +## The flip (3 env lines in truenas-compose.tradier.local.yaml, loop + dashboard) + + TRADIER_ENV: live # switches base URL to api.tradier.com + TRADIER_ACCESS_TOKEN: # from the REAL account, never the sandbox token + TRADIER_ACCOUNT_ID: + +Market data stays on Alpaca (unchanged). Rollback = set `TRADIER_ENV: sandbox` ++ sandbox creds, redeploy. + +## Before the flip — owner tasks (nobody else can do these) + +1. Open a Tradier **cash** account (margin needs $2k; $300 = cash), fund $300. +2. Create an API token on the live account. Treat as secret: compose file + only, never the repo, never the config_overrides table. +3. Confirm account approvals: API access enabled on the live account + (Tradier sometimes gates API on request). + +## Before the flip — config (admin UI :8768 or config_overrides on 5434) + +| Knob | Value | Why | +|---|---|---| +| `TRADING_MAX_FRESH_ENTRIES_PER_DAY` | `1` | **Cash account T+1: >1 round trip/day risks good-faith violations; 3 GFVs = 90-day freeze.** Raise only with equity growth or margin. | +| `TRADING_EQUITY_FLOOR` | `270` | Kill switch at 0.90 x $300. | +| `TRADING_MAX_RISK_DOLLARS` | `1000` (keep) | Inert at this equity (16% notional cap = ~$48 positions binds first); harmless. | +| `TRADING_RISK_PER_TRADE_PCT` | `0.05` (keep) | $15 budget; the $48 position cap means actual risk/trade lands ~$2-8. | + +## Before the flip — DB hygiene + +The tradier DB currently holds SANDBOX trade records. Live must start clean +(cutover principle: no blending). Before first live boot: + + TRUNCATE events, telemetry_events; -- on 5434; keep research tables + +(Same pattern as bootstrap_live_db.sh. minute_bars/daily_bars/volume_ratios +stay — that history is real market data and feeds rvol baselines.) + +## Day-1 verification (first hour) + +1. Dashboard badge shows tradier-LIVE (factory label), not sandbox. +2. First fill: check the bracket legs exist at Tradier (stop visible via + by-symbol order lookup) — the 2026-07-28 incident class. +3. **Naked-stop drill (memory: required pre-flip, still undone):** with a + 1-share position open, manually cancel its stop leg in the Tradier UI; + the guard must force-exit within 2 passes. This is the drill on real + plumbing with pocket-change size. +4. Telegram alert received; `python -m research.slippage --since ` + after close — real-fill slippage vs the 0.3-0.5% paper-measured spread. + +## Expectations at $300 + +Positions ~$48 (16% cap), 1-20 shares on $2-20 names. P&L per trade: single +dollars. This proves execution (fills, brackets, stops, GFV discipline), not +income. Sizing scales automatically as equity grows — the knobs above are the +only things to revisit.