Strategy & Trade Examples
System Architecture
DATA LAYER
Futu OpenD → HSTECH 5m bars, HSI daily bars, prev closes, σ
Tencent (00700) + Alibaba (09988) → breadth confirmation
SIGNAL LAYER
HSTECH ORB → breakout trigger + MACD + breadth → entry signal
HSI Gap → gap% filter + direction → entry signal
REGIME LAYER
AGREE → both signals same direction → 2× scale on both
CONFLICT → opposite directions → HSTECH 2×, HSI closed
SOLO → one signal only → 1× scale
EXECUTION LAYER
Entry: limit @ ask+0.1% buffer | Exit: limit @ bid (no buffer)
Chase loop every 5s → cancel if drift >1% | Market fallback on exit timeout
Position sizing: equity × 25% × scale ÷ price → floor to 100 shares
Exit Logic
HSTECH ORB Exit
Entry: 50% initial qty, add 50% pyramid at TP1
TP1 = entry × (1 + 0.30 × σ_eff)
Sell 40% at TP1 → SL moves to breakeven
Trail remaining 60% at running_high − 0.40σ
Initial SL = entry × (1 − 0.25 × σ_eff)
σ_eff = daily_σ × 2 (ETF leverage)
HSI Gap Exit
Entry: 50% initial qty, add 50% pyramid at TP1
TP1 = entry × (1 + 2 × |gap%| × 0.40)
Sell 40% at TP1 → SL moves to breakeven
Trail remaining 60% at running_high − 0.40σ × 2
Initial SL = entry × (1 − 2 × |gap%|) × 0.995
EOD hard exit at 15:50 regardless of P&L
SL Reversal
If a stop loss fires before 14:30, the system immediately enters the opposite ETF at the same scale, holds to EOD with no intraday SL. Rationale: an SL hit in the morning often indicates a strong counter-move which may be profitable to ride.
07226 SL hit → enter 07552 | 07552 SL hit → enter 07226
07200 SL hit → enter 07500 | 07500 SL hit → enter 07200
Example 1 — Agree-Day Win
09:35
HSI gap +0.72% detected → BUY 07200 @ 3.746
10:00
ORB window closes — triggers calculated
10:05
HSTECH breaks trigger — MACD ✓ Breadth ✓ → BUY 07226 @ 4.359
15:50
EOD flatten — total P&L: HKD +7,199
Example 2 — SL Reversal
Original trade — 07226 (hit SL)
Reversal trade — 07552 (hold to EOD)
10:00
BUY 07226 @ 4.903 — SL set at 4.831
10:40
SL HIT on 07226 — before 14:30 → trigger reversal
10:40
BUY 07552 @ 6.469 — hold to EOD
15:50
EOD exit 07552 — reversal P&L: HKD +6,082
Example 3 — Conflict Day
HSI gap fires at 09:35 → position opened 1×. HSTECH then breaks in the opposite direction → CONFLICT detected. The HSI position is immediately closed at bid. HSTECH enters at 2× scale.
HSTECH — 07226 (conflict scale 2×)
09:35
HSI gap detected → HSI entered 1×
10:25
HSTECH breaks OPPOSITE to HSI → CONFLICT
10:25
HSI position CLOSED at bid — HSTECH enters 2× scale
10:25
BUY 07226 @ 2.681 SL=2.643 TP1=2.711
15:50
EOD flatten — P&L: HKD +8,313
Example 4 — No-Trade Day
Not every day produces a trade. When filters reject both strategies, the system sleeps until 15:50 and logs a skip note. Selectivity is a feature, not a bug — forcing trades on low-quality days destroys edge.
HSTECH Index — ORB range annotated
⚠ ORB range 0.77% ✓ — but MACD/breadth filters rejected at breakout
⚠ HSI gap -0.07% — below 0.55% minimum → HSI skipped
The system silently skips the day. No positions opened, no orders sent. This is correct behaviour — the strategy only trades high-quality setups.