# TradingBite Platform — Full A→Z Roadmap

**Goal:** TradingView-*class* UX (not a clone): OANDA/FXCM FX charts, free/OSS indicators, long backtesting, TradingBite Pine logic ported to TypeScript over time.

**Application workspace:** `C:\Users\akfai\Downloads\Cursor Project\TradingBite-Platform`  
**Pine legacy (read-only reference):** `C:\Users\akfai\Downloads\Cursor Project\TradingBite`

---

## How to read this doc

| Symbol | Meaning |
|--------|---------|
| **Phase** | Build order; don’t skip foundations |
| **Gate** | Must pass before next phase |
| **MVP** | Minimum you can use daily |
| **V1** | Shareable product for others |

Estimated calendar time (solo, part-time): **MVP ~8–12 weeks**, **V1 ~6–9 months**.

---

## A. Vision and boundaries (Week 0)

### A1 — Product definition

**TradingBite Platform is:**

- Web chart terminal for FX (expand later)
- Broker-backed prices (OANDA v20, FXCM where available)
- Indicator library (OSS + TradingBite studies)
- Backtest lab with **local long history**
- Optional: MT5 bridge later

**Not v1:** Pine runtime in browser, social feed, licensed global equities feed, native mobile apps.

### A2 — Legal and naming

See [../legal/README.md](../legal/README.md).

**Gate A:** Product brief + OANDA-first (see [ADR-001](../decisions/ADR-001-stack-and-oanda-first.md)).

---

## B. Architecture (Week 0–1)

See [../architecture/SYSTEM-OVERVIEW.md](../architecture/SYSTEM-OVERVIEW.md).

### B3 — Repo layout (Phase C+)

```text
TradingBite-Platform/
  apps/web/
  packages/          # when needed: core, broker-oanda, indicators, backtest-engine
  data/              # gitignored warehouse
  docs/
```

**Gate B:** ADR accepted; normalized OHLCV documented.

---

## C. Foundations (Week 1–2)

See [PHASE-C-SCOPE.md](./PHASE-C-SCOPE.md) for enforced scope in this repository.

**Gate C:** OANDA EUR/USD H1 proof + app shell + server-side secrets.

---

## D. Chart MVP (Week 2–4)

Candlesticks, TFs, symbol catalog, live updates, layout persistence.

**Gate D:** Symbol/TF switch + live demo updates.

---

## E. Historical warehouse (Week 4–6)

Schema, backfill, incremental sync, chart reads from DB.

**Gate E:** ≥ 3 years M15 majors stored locally.

---

## F. Indicators (Week 6–9)

Framework, OSS set, Pine → TS ports from `../TradingBite/*.pine` with golden tests.

**Gate F:** 5 OSS + 1 TB proprietary on chart.

---

## G. Drawings and multi-chart (Week 9–11)

**Gate G:** Drawings persist across refresh.

---

## H. Backtest lab (Week 11–15)

Closed-bar engine, metrics, equity curve, warehouse-backed long runs.

**Gate H:** 5-year M15 backtest; no-lookahead test.

---

## I. Watchlists, alerts, journal (Week 15–18)

**Gate I:** Alert fires once per condition.

---

## J. FXCM adapter (Week 18–20)

**Gate J:** Chart works with adapter swap.

---

## K. Auth and deploy (Week 20–24)

**Gate K:** HTTPS + login + saved layout.

---

## L. Quality and polish (ongoing)

Testing pyramid, performance, docs.

---

## M. Post-V1

Optimizer, walk-forward, MT5 bridge, PWA, etc.

---

## N. TV-like feature map

| Feature | Phase |
|---------|-------|
| Chart + TFs | D |
| Deep history | E |
| Indicators | F |
| Drawings | G |
| Strategy tester | H |
| Watchlists / alerts | I |
| Pine editor | **No** |

---

## O. Risk register

API limits → warehouse; FXCM region → OANDA-first; Pine parity → golden tests; over-scope → phase gates.

---

## R. Definition of done

**MVP:** OANDA multi-TF/symbol, local multi-year history, 8+ indicators (1 TB), backtest on warehouse.

**V1:** Auth, layouts, watchlists, alerts, optional FXCM, deployed HTTPS.

---

*Roadmap v1.0 for TradingBite-Platform. Full sprint detail preserved in conversation kickoff; update gates in PROJECT-STATUS.md as phases complete.*
