<!-- Site: TWM Exit Optimization | Version: v1.8.1 | Updated: 2026-04-19 -->

# Results Report — Strategy v9.9.9 | @ES TF1 Long | 2026-04-17 | step=1 (max_count=6) | Trades=13 | PnL=+4.00 pts

**Created:** 2026-04-19 23:11
**Strategy version:** v9.9.9
**Config variant:** exit_counter step=1, max_count=6 (6 ranges x step)
**Config file on disk:** `config_2_indicators_v5_6_0.json`
**Replay date:** 2026-04-17
**Instrument:** @ES (E-mini S&P 500 Futures)
**Bar duration:** 1-second (1-min aggregated)
**Direction:** Long

---

## Index

- [Premarket Price Levels](#premarket-price-levels)
- [Section 1 — PnL / Trade History](#section-1--pnl--trade-history)
- [Section 2 — Per-Trade Analysis](#section-2--per-trade-analysis)
  - [Trade 1](#trade-1)
  - [Trade 2](#trade-2)
  - [Trade 3](#trade-3)
  - [Trade 4](#trade-4)
  - [Trade 5](#trade-5)
  - [Trade 6](#trade-6)
  - [Trade 7](#trade-7)
  - [Trade 8](#trade-8)
  - [Trade 9](#trade-9)
  - [Trade 10](#trade-10)
  - [Trade 11](#trade-11)
  - [Trade 12](#trade-12)
  - [Trade 13](#trade-13)
- [Section 3 — Workflow Pedigree](#section-3--workflow-pedigree)
- [Section 4 — Config Settings at Test Time](#section-4--config-settings-at-test-time)
  - [4.1: config_2_indicators_v5_6_0.json](#41-config_2_indicators_v5_6_0json-v560)
  - [4.2: config_3_time_zones_v5_1_0.json](#42-config_3_time_zones_v5_1_0json-v510)
  - [4.3: config_4_stop_loss_long_v5_3_0.json](#43-config_4_stop_loss_long_v5_3_0json-v530)
  - [4.4: config_5_strategy_long_v1_7_6.json](#44-config_5_strategy_long_v1_7_6json-v176)
  - [4.5: config_6_profit_target_long_v1_0_0.json](#45-config_6_profit_target_long_v1_0_0json-v100)
  - [4.6: config_7_limit_order_long_v1_0_0.json](#46-config_7_limit_order_long_v1_0_0json-v101)

### Premarket Price Levels

| Level | Price | Window |
|-------|-------|--------|
| Prior Day Close | 7076.50 | — |
| Premarket High | 7147.50 | 08:00–09:29 ET |
| Market Open | 7121.50 | 09:31 open |
| Premarket Low | 7099.50 | 08:00–09:29 ET |

---

## Section 1 — PnL / Trade History

| Trade # | Entry Bar | Entry Time | Entry Price | Entry Transition | Exit Bar | Exit Time | Exit Price | Exit Transition (From State) | PnL (pts) | PnL ($) |
|---------|-----------|------------|-------------|------------------|----------|-----------|------------|------------------------------|-----------|---------|
| 1 | 23 | 09:53:27 | 7138.00 | t_110_trade_entry_submitted | 34 | 10:04:48 | 7149.50 | t_226_exit_profit_target_count (State09_YELLOW) | +11.50 | +$575 |
| 2 | 35 | 10:05:00 | 7149.25 | t_110_trade_entry_submitted | 45 | 10:15:43 | 7152.75 | t_226_exit_profit_target_count (State11_RED) | +3.50 | +$175 |
| 3 | 62 | 10:32:00 | 7156.50 | t_110_trade_entry_submitted | 65 | 10:35:28 | 7157.50 | t_221_exit_hard_stop (State09_YELLOW) | +1.00 | +$50 |
| 4 | 71 | 10:41:00 | 7167.25 | t_110_trade_entry_submitted | 78 | 10:48:27 | 7172.25 | t_226_exit_profit_target_count (State09_YELLOW) | +5.00 | +$250 |
| 5 | 80 | 10:50:00 | 7173.25 | t_110_trade_entry_submitted | 85 | 10:55:24 | 7167.50 | t_221_exit_hard_stop (State09_YELLOW) | -5.75 | -$287 |
| 6 | 116 | 11:26:51 | 7167.50 | t_110_trade_entry_submitted | 131 | 11:41:39 | 7172.00 | t_226_exit_profit_target_count (State11_RED) | +4.50 | +$225 |
| 7 | 147 | 11:57:10 | 7174.25 | t_110_trade_entry_submitted | 148 | 11:58:36 | 7170.25 | t_221_exit_hard_stop (State09_YELLOW) | -4.00 | -$200 |
| 8 | 153 | 12:03:35 | 7176.00 | t_110_trade_entry_submitted | 182 | 12:32:15 | 7181.50 | t_226_exit_profit_target_count (State11_RED) | +5.50 | +$275 |
| 9 | 195 | 12:45:26 | 7185.00 | t_110_trade_entry_submitted | 218 | 13:08:13 | 7179.75 | t_221_exit_hard_stop (State09_YELLOW) | -5.25 | -$262 |
| 10 | 256 | 13:46:51 | 7166.50 | t_110_trade_entry_submitted | 278 | 14:08:57 | 7158.25 | t_221_exit_hard_stop (State11_RED) | -8.25 | -$412 |
| 11 | 295 | 14:25:14 | 7164.25 | t_110_trade_entry_submitted | 340 | 15:10:54 | 7154.25 | t_221_exit_hard_stop (State09_YELLOW) | -10.00 | -$500 |
| 12 | 355 | 15:25:20 | 7156.25 | t_110_trade_entry_submitted | 368 | 15:38:29 | 7161.75 | t_226_exit_profit_target_count (State09_YELLOW) | +5.50 | +$275 |
| 13 | 369 | 15:39:00 | 7161.50 | t_110_trade_entry_submitted | 386 | 15:56:00 | 7162.25 | t_220_exit_session_close (State11_RED) | +0.75 | +$37 |
| **TOTAL** | | | | | | | | | **+4.00** | **+$200** |
**Record:** 8W / 5L
**Avg profit:** +0.31 pts | **Max loss:** -10.00 pts | **Avg duration:** 15.5 min | **Win rate:** 61.5%

---

## Section 2 — Per-Trade Analysis

> *Source: `intra_bar_transitions` from `strategy.get_bar_results()`.*

### Trade 1
**Entry 09:53:27 -> Exit 10:04:48 | +11.50 pts | 11 min | Entry offset at fill: ?pts | Max exit_counter: 40 | Max potential profit: +11.25 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 21 | 09:51:00 | 1/1 | 50 | `t_50_bear_trend_met` | State01_WAIT_BEAR_TREND | State02_WAIT_BULL_SHIFT | 7131.25 |
| 22 | 09:52:00 | 1/3 | 60 | `t_60_bull_shift_met` | State02_WAIT_BULL_SHIFT | State03_WAIT_MA_CROSS | 7135.00 |
| 22 | 09:52:00 | 2/3 | 70 | `t_70_ma_bull_cross` | State03_WAIT_MA_CROSS | State04_WAIT_INDICATORS | 7135.00 |
| 22 | 09:52:00 | 3/3 | 80 | `t_80_all_indicators_confirmed` | State04_WAIT_INDICATORS | State05_WAIT_RETEST | 7135.00 |
| 24 | 09:53:01 | 1/4 | 91 | `t_91_midbar_retest_touched` | State05_WAIT_RETEST | State06_WAIT_BREAKOUT | 7136.00 |
| 24 | 09:53:27 | 2/4 | 100 | `t_100_breakout_level_hit` | State06_WAIT_BREAKOUT | State07_ENTRY_GATE | 7138.00 |
| 24 | 09:53:27 | 3/4 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7138.00 |
| 24 | 09:53:28 | 4/4 | 200 | `t_200_yellow_to_green` | State09_YELLOW | State10_GREEN | 7137.75 |
| 25 | 09:54:01 | 1/1 | 201 | `t_201_green_to_yellow` | State10_GREEN | State09_YELLOW | 7137.50 |
| 29 | 09:58:13 | 1/13 | 210 | `t_210_count_criteria [ma]` | State09_YELLOW | State09_YELLOW | 7139.00 |
| 33 | 10:02:49 | 3/4 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7144.50 |
| 35 | 10:04:48 | 1/1 | 226 | `t_226_exit_profit_target_count` | State09_YELLOW | State01_WAIT_BEAR_TREND | 7149.50 |

#### AI Summary

**1. What happened:** Trade 1 entered via `t_110_trade_entry_submitted` at 09:53:27, exited via `EXIT_PROFIT_TARGET_COUNT` at 10:04:48 for +11.50 pts. Exit counter peaked at 40 during this trade.
**2. Entry quality:** Good — entry at 7138.00, initial stop at 7128.0.
**3. Exit quality:** Good — `EXIT_PROFIT_TARGET_COUNT` at 7149.50.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=40: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 2
**Entry 10:05:00 -> Exit 10:15:43 | +3.50 pts | 10 min | Entry offset at fill: ?pts | Max exit_counter: 99 | Max potential profit: +3.75 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 35 | 10:05:00 | 1/2 | 93 | `t_93_lwr_high_bypass` | State01_WAIT_BEAR_TREND | State07_ENTRY_GATE | 7149.25 |
| 35 | 10:05:00 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7149.25 |
| 39 | 10:08:01 | 1/2 | 210 | `t_210_count_criteria [ma]` | State09_YELLOW | State09_YELLOW | 7149.50 |
| 42 | 10:11:32 | 9/24 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7151.00 |
| 43 | 10:12:05 | 1/11 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7150.00 |
| 43 | 10:12:06 | 2/11 | 202 | `t_202_yellow_to_red` | State09_YELLOW | State11_RED | 7150.25 |
| 44 | 10:13:02 | 2/5 | 230 | `t_230_offset_change` | State11_RED | State11_RED | 7149.25 |
| 46 | 10:15:19 | 8/13 | 230 | `t_230_offset_change` | State11_RED | State11_RED | 7150.75 |
| 46 | 10:15:43 | 13/13 | 226 | `t_226_exit_profit_target_count` | State11_RED | State01_WAIT_BEAR_TREND | 7152.75 |

#### AI Summary

**1. What happened:** Trade 2 entered via `t_110_trade_entry_submitted` at 10:05:00, exited via `EXIT_PROFIT_TARGET_COUNT` at 10:15:43 for +3.50 pts. Exit counter peaked at 99 during this trade.
**2. Entry quality:** Good — entry at 7149.25, initial stop at 7143.5.
**3. Exit quality:** Good — `EXIT_PROFIT_TARGET_COUNT` at 7152.75.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=99: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 3
**Entry 10:32:00 -> Exit 10:35:28 | +1.00 pts | 3 min | Entry offset at fill: ?pts | Max exit_counter: 0 | Max potential profit: +6.25 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 62 | 10:32:00 | 1/2 | 93 | `t_93_lwr_high_bypass` | State01_WAIT_BEAR_TREND | State07_ENTRY_GATE | 7156.50 |
| 62 | 10:32:00 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7156.50 |
| 66 | 10:35:05 | 1/18 | 210 | `t_210_count_criteria [ma]` | State09_YELLOW | State09_YELLOW | 7160.50 |
| 66 | 10:35:26 | 16/18 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7158.50 |
| 66 | 10:35:28 | 18/18 | 221 | `t_221_exit_hard_stop` | State09_YELLOW | State01_WAIT_BEAR_TREND | 7157.25 |

#### AI Summary

**1. What happened:** Trade 3 entered via `t_110_trade_entry_submitted` at 10:32:00, exited via `EXIT_HARD_STOP` at 10:35:28 for +1.00 pts. Exit counter peaked at 0 during this trade.
**2. Entry quality:** Good — entry at 7156.50, initial stop at 7151.0.
**3. Exit quality:** Marginal — `EXIT_HARD_STOP` [Type_2_BreakEven] at 7157.50. Stop history: initial 7151.0 -> Type_1_Hard 7151.00 -> Type_2_BreakEven 7157.50.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=0: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 4
**Entry 10:41:00 -> Exit 10:48:27 | +5.00 pts | 7 min | Entry offset at fill: ?pts | Max exit_counter: 82 | Max potential profit: +4.50 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 71 | 10:41:00 | 1/2 | 93 | `t_93_lwr_high_bypass` | State01_WAIT_BEAR_TREND | State07_ENTRY_GATE | 7167.25 |
| 71 | 10:41:00 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7167.25 |
| 74 | 10:43:36 | 1/12 | 210 | `t_210_count_criteria [ma]` | State09_YELLOW | State09_YELLOW | 7168.50 |
| 76 | 10:45:19 | 3/3 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7169.00 |
| 77 | 10:46:57 | 16/16 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7169.50 |
| 79 | 10:48:07 | 5/6 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7169.25 |
| 79 | 10:48:27 | 6/6 | 226 | `t_226_exit_profit_target_count` | State09_YELLOW | State01_WAIT_BEAR_TREND | 7172.25 |

#### AI Summary

**1. What happened:** Trade 4 entered via `t_110_trade_entry_submitted` at 10:41:00, exited via `EXIT_PROFIT_TARGET_COUNT` at 10:48:27 for +5.00 pts. Exit counter peaked at 82 during this trade.
**2. Entry quality:** Good — entry at 7167.25, initial stop at 7159.75.
**3. Exit quality:** Good — `EXIT_PROFIT_TARGET_COUNT` at 7172.25.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=82: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 5
**Entry 10:50:00 -> Exit 10:55:24 | -5.75 pts | 5 min | Entry offset at fill: ?pts | Max exit_counter: 0 | Max potential profit: +0.00 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 80 | 10:50:00 | 1/2 | 93 | `t_93_lwr_high_bypass` | State01_WAIT_BEAR_TREND | State07_ENTRY_GATE | 7173.25 |
| 80 | 10:50:00 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7173.25 |
| 86 | 10:55:24 | 1/1 | 221 | `t_221_exit_hard_stop` | State09_YELLOW | State01_WAIT_BEAR_TREND | 7167.25 |

#### AI Summary

**1. What happened:** Trade 5 entered via `t_110_trade_entry_submitted` at 10:50:00, exited via `EXIT_HARD_STOP` at 10:55:24 for -5.75 pts. Exit counter peaked at 0 during this trade.
**2. Entry quality:** Good — entry at 7173.25, initial stop at 7167.5.
**3. Exit quality:** Poor — `EXIT_HARD_STOP` [Type_1_Hard] at 7167.50. Stop history: initial 7167.5 -> Type_1_Hard 7167.50.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=0: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 6
**Entry 11:26:51 -> Exit 11:41:39 | +4.50 pts | 15 min | Entry offset at fill: ?pts | Max exit_counter: 122 | Max potential profit: +6.25 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 110 | 11:20:00 | 1/1 | 50 | `t_50_bear_trend_met` | State01_WAIT_BEAR_TREND | State02_WAIT_BULL_SHIFT | 7162.50 |
| 114 | 11:24:00 | 1/3 | 60 | `t_60_bull_shift_met` | State02_WAIT_BULL_SHIFT | State03_WAIT_MA_CROSS | 7166.75 |
| 114 | 11:24:00 | 2/3 | 70 | `t_70_ma_bull_cross` | State03_WAIT_MA_CROSS | State04_WAIT_INDICATORS | 7166.75 |
| 114 | 11:24:00 | 3/3 | 80 | `t_80_all_indicators_confirmed` | State04_WAIT_INDICATORS | State05_WAIT_RETEST | 7166.75 |
| 115 | 11:24:01 | 1/1 | 91 | `t_91_midbar_retest_touched` | State05_WAIT_RETEST | State06_WAIT_BREAKOUT | 7165.75 |
| 117 | 11:26:51 | 1/2 | 100 | `t_100_breakout_level_hit` | State06_WAIT_BREAKOUT | State07_ENTRY_GATE | 7167.50 |
| 117 | 11:26:51 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7167.50 |
| 123 | 11:32:37 | 1/2 | 210 | `t_210_count_criteria [ma]` | State09_YELLOW | State09_YELLOW | 7169.75 |
| 128 | 11:37:39 | 8/21 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7172.25 |
| 129 | 11:38:03 | 3/8 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7171.00 |
| 131 | 11:40:32 | 10/27 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7173.25 |
| 131 | 11:40:58 | 26/27 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7172.25 |
| 132 | 11:41:04 | 4/25 | 202 | `t_202_yellow_to_red` | State09_YELLOW | State11_RED | 7171.50 |
| 132 | 11:41:16 | 13/25 | 230 | `t_230_offset_change` | State11_RED | State11_RED | 7171.50 |
| 132 | 11:41:37 | 24/25 | 230 | `t_230_offset_change` | State11_RED | State11_RED | 7172.00 |
| 132 | 11:41:39 | 25/25 | 226 | `t_226_exit_profit_target_count` | State11_RED | State01_WAIT_BEAR_TREND | 7172.25 |

#### AI Summary

**1. What happened:** Trade 6 entered via `t_110_trade_entry_submitted` at 11:26:51, exited via `EXIT_PROFIT_TARGET_COUNT` at 11:41:39 for +4.50 pts. Exit counter peaked at 122 during this trade.
**2. Entry quality:** Good — entry at 7167.50, initial stop at 7162.25.
**3. Exit quality:** Good — `EXIT_PROFIT_TARGET_COUNT` at 7172.00.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=122: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 7
**Entry 11:57:10 -> Exit 11:58:36 | -4.00 pts | 1 min | Entry offset at fill: ?pts | Max exit_counter: 0 | Max potential profit: -0.25 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 133 | 11:43:00 | 1/1 | 50 | `t_50_bear_trend_met` | State01_WAIT_BEAR_TREND | State02_WAIT_BULL_SHIFT | 7168.00 |
| 140 | 11:50:00 | 1/2 | 60 | `t_60_bull_shift_met` | State02_WAIT_BULL_SHIFT | State03_WAIT_MA_CROSS | 7169.75 |
| 140 | 11:50:00 | 2/2 | 70 | `t_70_ma_bull_cross` | State03_WAIT_MA_CROSS | State04_WAIT_INDICATORS | 7169.75 |
| 141 | 11:50:08 | 1/1 | 80 | `t_80_all_indicators_confirmed` | State04_WAIT_INDICATORS | State05_WAIT_RETEST | 7170.50 |
| 143 | 11:52:02 | 1/1 | 91 | `t_91_midbar_retest_touched` | State05_WAIT_RETEST | State06_WAIT_BREAKOUT | 7173.75 |
| 148 | 11:57:10 | 1/2 | 100 | `t_100_breakout_level_hit` | State06_WAIT_BREAKOUT | State07_ENTRY_GATE | 7174.25 |
| 148 | 11:57:10 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7174.25 |
| 149 | 11:58:36 | 1/1 | 221 | `t_221_exit_hard_stop` | State09_YELLOW | State01_WAIT_BEAR_TREND | 7170.00 |

#### AI Summary

**1. What happened:** Trade 7 entered via `t_110_trade_entry_submitted` at 11:57:10, exited via `EXIT_HARD_STOP` at 11:58:36 for -4.00 pts. Exit counter peaked at 0 during this trade.
**2. Entry quality:** Good — entry at 7174.25, initial stop at 7170.25.
**3. Exit quality:** Poor — `EXIT_HARD_STOP` [Type_1_Hard] at 7170.25. Stop history: initial 7170.25 -> Type_1_Hard 7170.25.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=0: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 8
**Entry 12:03:35 -> Exit 12:32:15 | +5.50 pts | 29 min | Entry offset at fill: ?pts | Max exit_counter: 54 | Max potential profit: +5.50 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 150 | 12:00:00 | 1/1 | 50 | `t_50_bear_trend_met` | State01_WAIT_BEAR_TREND | State02_WAIT_BULL_SHIFT | 7169.00 |
| 153 | 12:03:00 | 1/3 | 60 | `t_60_bull_shift_met` | State02_WAIT_BULL_SHIFT | State03_WAIT_MA_CROSS | 7173.75 |
| 153 | 12:03:00 | 2/3 | 70 | `t_70_ma_bull_cross` | State03_WAIT_MA_CROSS | State04_WAIT_INDICATORS | 7173.75 |
| 153 | 12:03:00 | 3/3 | 80 | `t_80_all_indicators_confirmed` | State04_WAIT_INDICATORS | State05_WAIT_RETEST | 7173.75 |
| 154 | 12:03:35 | 1/2 | 93 | `t_93_lwr_high_bypass` | State05_WAIT_RETEST | State07_ENTRY_GATE | 7176.00 |
| 154 | 12:03:35 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7176.00 |
| 161 | 12:10:03 | 1/1 | 202 | `t_202_yellow_to_red` | State09_YELLOW | State11_RED | 7173.00 |
| 164 | 12:13:03 | 1/6 | 210 | `t_210_count_criteria [ma]` | State11_RED | State11_RED | 7176.50 |
| 178 | 12:27:49 | 3/5 | 230 | `t_230_offset_change` | State11_RED | State11_RED | 7176.50 |
| 183 | 12:32:15 | 1/1 | 226 | `t_226_exit_profit_target_count` | State11_RED | State01_WAIT_BEAR_TREND | 7181.50 |

#### AI Summary

**1. What happened:** Trade 8 entered via `t_110_trade_entry_submitted` at 12:03:35, exited via `EXIT_PROFIT_TARGET_COUNT` at 12:32:15 for +5.50 pts. Exit counter peaked at 54 during this trade.
**2. Entry quality:** Good — entry at 7176.00, initial stop at 7166.25.
**3. Exit quality:** Good — `EXIT_PROFIT_TARGET_COUNT` at 7181.50.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=54: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 9
**Entry 12:45:26 -> Exit 13:08:13 | -5.25 pts | 23 min | Entry offset at fill: ?pts | Max exit_counter: 0 | Max potential profit: +0.25 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 192 | 12:42:00 | 1/1 | 50 | `t_50_bear_trend_met` | State01_WAIT_BEAR_TREND | State02_WAIT_BULL_SHIFT | 7181.00 |
| 194 | 12:44:00 | 1/2 | 60 | `t_60_bull_shift_met` | State02_WAIT_BULL_SHIFT | State03_WAIT_MA_CROSS | 7182.75 |
| 194 | 12:44:00 | 2/2 | 70 | `t_70_ma_bull_cross` | State03_WAIT_MA_CROSS | State04_WAIT_INDICATORS | 7182.75 |
| 195 | 12:44:02 | 1/1 | 80 | `t_80_all_indicators_confirmed` | State04_WAIT_INDICATORS | State05_WAIT_RETEST | 7183.00 |
| 196 | 12:45:26 | 1/2 | 93 | `t_93_lwr_high_bypass` | State05_WAIT_RETEST | State07_ENTRY_GATE | 7185.00 |
| 196 | 12:45:26 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7185.00 |
| 206 | 12:55:04 | 1/1 | 202 | `t_202_yellow_to_red` | State09_YELLOW | State11_RED | 7183.00 |
| 215 | 13:04:05 | 1/1 | 203 | `t_203_red_to_yellow` | State11_RED | State09_YELLOW | 7183.25 |
| 219 | 13:08:13 | 1/1 | 221 | `t_221_exit_hard_stop` | State09_YELLOW | State01_WAIT_BEAR_TREND | 7179.25 |

#### AI Summary

**1. What happened:** Trade 9 entered via `t_110_trade_entry_submitted` at 12:45:26, exited via `EXIT_HARD_STOP` at 13:08:13 for -5.25 pts. Exit counter peaked at 0 during this trade.
**2. Entry quality:** Good — entry at 7185.00, initial stop at 7179.75.
**3. Exit quality:** Poor — `EXIT_HARD_STOP` [Type_1_Hard] at 7179.75. Stop history: initial 7179.75 -> Type_1_Hard 7179.75.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=0: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 10
**Entry 13:46:51 -> Exit 14:08:57 | -8.25 pts | 22 min | Entry offset at fill: ?pts | Max exit_counter: 122 | Max potential profit: +2.00 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 255 | 13:45:00 | 1/1 | 50 | `t_50_bear_trend_met` | State01_WAIT_BEAR_TREND | State02_WAIT_BULL_SHIFT | 7160.25 |
| 256 | 13:46:00 | 1/3 | 60 | `t_60_bull_shift_met` | State02_WAIT_BULL_SHIFT | State03_WAIT_MA_CROSS | 7164.75 |
| 256 | 13:46:00 | 2/3 | 70 | `t_70_ma_bull_cross` | State03_WAIT_MA_CROSS | State04_WAIT_INDICATORS | 7164.75 |
| 256 | 13:46:00 | 3/3 | 80 | `t_80_all_indicators_confirmed` | State04_WAIT_INDICATORS | State05_WAIT_RETEST | 7164.75 |
| 257 | 13:46:51 | 1/2 | 93 | `t_93_lwr_high_bypass` | State05_WAIT_RETEST | State07_ENTRY_GATE | 7166.50 |
| 257 | 13:46:51 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7166.50 |
| 260 | 13:49:28 | 1/1 | 210 | `t_210_count_criteria [ma]` | State09_YELLOW | State09_YELLOW | 7166.75 |
| 265 | 13:54:53 | 2/5 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7167.00 |
| 266 | 13:55:44 | 13/18 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7167.50 |
| 268 | 13:57:18 | 2/11 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7167.75 |
| 269 | 13:58:22 | 7/8 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7166.75 |
| 270 | 13:59:06 | 1/1 | 202 | `t_202_yellow_to_red` | State09_YELLOW | State11_RED | 7164.00 |
| 279 | 14:08:57 | 1/1 | 221 | `t_221_exit_hard_stop` | State11_RED | State01_WAIT_BEAR_TREND | 7157.75 |

#### AI Summary

**1. What happened:** Trade 10 entered via `t_110_trade_entry_submitted` at 13:46:51, exited via `EXIT_HARD_STOP` at 14:08:57 for -8.25 pts. Exit counter peaked at 122 during this trade.
**2. Entry quality:** Good — entry at 7166.50, initial stop at 7158.25.
**3. Exit quality:** Poor — `EXIT_HARD_STOP` [Type_1_Hard] at 7158.25. Stop history: initial 7158.25 -> Type_1_Hard 7158.25.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=122: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 11
**Entry 14:25:14 -> Exit 15:10:54 | -10.00 pts | 45 min | Entry offset at fill: ?pts | Max exit_counter: 0 | Max potential profit: +0.75 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 292 | 14:22:00 | 1/1 | 50 | `t_50_bear_trend_met` | State01_WAIT_BEAR_TREND | State02_WAIT_BULL_SHIFT | 7155.00 |
| 294 | 14:24:00 | 1/3 | 60 | `t_60_bull_shift_met` | State02_WAIT_BULL_SHIFT | State03_WAIT_MA_CROSS | 7158.25 |
| 294 | 14:24:00 | 2/3 | 70 | `t_70_ma_bull_cross` | State03_WAIT_MA_CROSS | State04_WAIT_INDICATORS | 7158.25 |
| 294 | 14:24:00 | 3/3 | 80 | `t_80_all_indicators_confirmed` | State04_WAIT_INDICATORS | State05_WAIT_RETEST | 7158.25 |
| 296 | 14:25:14 | 1/3 | 93 | `t_93_lwr_high_bypass` | State05_WAIT_RETEST | State07_ENTRY_GATE | 7164.25 |
| 296 | 14:25:14 | 2/3 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7164.25 |
| 296 | 14:25:15 | 3/3 | 200 | `t_200_yellow_to_green` | State09_YELLOW | State10_GREEN | 7163.50 |
| 299 | 14:28:01 | 1/1 | 201 | `t_201_green_to_yellow` | State10_GREEN | State09_YELLOW | 7161.75 |
| 300 | 14:29:17 | 1/1 | 202 | `t_202_yellow_to_red` | State09_YELLOW | State11_RED | 7158.25 |
| 327 | 14:56:03 | 1/2 | 203 | `t_203_red_to_yellow` | State11_RED | State09_YELLOW | 7160.50 |
| 327 | 14:56:04 | 2/2 | 200 | `t_200_yellow_to_green` | State09_YELLOW | State10_GREEN | 7160.75 |
| 331 | 15:00:01 | 1/1 | 201 | `t_201_green_to_yellow` | State10_GREEN | State09_YELLOW | 7158.50 |
| 341 | 15:10:54 | 1/1 | 221 | `t_221_exit_hard_stop` | State09_YELLOW | State01_WAIT_BEAR_TREND | 7154.00 |

#### AI Summary

**1. What happened:** Trade 11 entered via `t_110_trade_entry_submitted` at 14:25:14, exited via `EXIT_HARD_STOP` at 15:10:54 for -10.00 pts. Exit counter peaked at 0 during this trade.
**2. Entry quality:** Good — entry at 7164.25, initial stop at 7154.25.
**3. Exit quality:** Poor — `EXIT_HARD_STOP` [Type_1_Hard] at 7154.25. Stop history: initial 7154.25 -> Type_1_Hard 7154.25.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=0: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 12
**Entry 15:25:20 -> Exit 15:38:29 | +5.50 pts | 13 min | Entry offset at fill: ?pts | Max exit_counter: 92 | Max potential profit: +5.25 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 341 | 15:11:00 | 1/1 | 50 | `t_50_bear_trend_met` | State01_WAIT_BEAR_TREND | State02_WAIT_BULL_SHIFT | 7153.50 |
| 346 | 15:16:00 | 1/3 | 60 | `t_60_bull_shift_met` | State02_WAIT_BULL_SHIFT | State03_WAIT_MA_CROSS | 7156.25 |
| 346 | 15:16:00 | 2/3 | 70 | `t_70_ma_bull_cross` | State03_WAIT_MA_CROSS | State04_WAIT_INDICATORS | 7156.25 |
| 346 | 15:16:00 | 3/3 | 80 | `t_80_all_indicators_confirmed` | State04_WAIT_INDICATORS | State05_WAIT_RETEST | 7156.25 |
| 348 | 15:17:04 | 1/1 | 91 | `t_91_midbar_retest_touched` | State05_WAIT_RETEST | State06_WAIT_BREAKOUT | 7156.50 |
| 356 | 15:25:20 | 1/2 | 100 | `t_100_breakout_level_hit` | State06_WAIT_BREAKOUT | State07_ENTRY_GATE | 7156.25 |
| 356 | 15:25:20 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7156.25 |
| 366 | 15:35:46 | 1/9 | 210 | `t_210_count_criteria [ma]` | State09_YELLOW | State09_YELLOW | 7158.75 |
| 367 | 15:36:13 | 7/28 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7158.25 |
| 367 | 15:36:46 | 23/28 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7158.50 |
| 368 | 15:37:30 | 11/12 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7158.75 |
| 369 | 15:38:29 | 1/1 | 226 | `t_226_exit_profit_target_count` | State09_YELLOW | State01_WAIT_BEAR_TREND | 7161.75 |

#### AI Summary

**1. What happened:** Trade 12 entered via `t_110_trade_entry_submitted` at 15:25:20, exited via `EXIT_PROFIT_TARGET_COUNT` at 15:38:29 for +5.50 pts. Exit counter peaked at 92 during this trade.
**2. Entry quality:** Good — entry at 7156.25, initial stop at 7152.0.
**3. Exit quality:** Good — `EXIT_PROFIT_TARGET_COUNT` at 7161.75.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=92: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

### Trade 13
**Entry 15:39:00 -> Exit 15:56:00 | +0.75 pts | 17 min | Entry offset at fill: ?pts | Max exit_counter: 91 | Max potential profit: +3.25 pts**

#### Diagnostic Log

| Bar | Timestamp | Chain | Transition # | Transition Name | From State | To State | Price |
|-----|-----------|-------|--------------|-----------------|------------|----------|-------|
| 369 | 15:39:00 | 1/2 | 93 | `t_93_lwr_high_bypass` | State01_WAIT_BEAR_TREND | State07_ENTRY_GATE | 7161.50 |
| 369 | 15:39:00 | 2/2 | 110 | `t_110_trade_entry_submitted` | State07_ENTRY_GATE | State09_YELLOW | 7161.50 |
| 372 | 15:41:02 | 1/9 | 210 | `t_210_count_criteria [ma]` | State09_YELLOW | State09_YELLOW | 7161.75 |
| 376 | 15:45:12 | 3/21 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7163.25 |
| 376 | 15:45:42 | 19/21 | 230 | `t_230_offset_change` | State09_YELLOW | State09_YELLOW | 7161.50 |
| 377 | 15:46:02 | 1/6 | 202 | `t_202_yellow_to_red` | State09_YELLOW | State11_RED | 7161.50 |
| 378 | 15:47:16 | 5/5 | 230 | `t_230_offset_change` | State11_RED | State11_RED | 7161.50 |
| 386 | 15:56:00 | 1/1 | 220 | `t_220_exit_session_close` | State11_RED | State00_IDLE | 7162.25 |

#### AI Summary

**1. What happened:** Trade 13 entered via `t_110_trade_entry_submitted` at 15:39:00, exited via `EXIT_SESSION_CLOSE` at 15:56:00 for +0.75 pts. Exit counter peaked at 91 during this trade.
**2. Entry quality:** Good — entry at 7161.50, initial stop at 7156.5.
**3. Exit quality:** Marginal — `EXIT_SESSION_CLOSE` at 7162.25.
**4. Strategy improvement candidates:**
- step=1 (max_count=6): assess exit tolerance adequacy for this trade.
- Compare vs step=0 baseline: did the counter allow a better exit?
- max_ec=91: verify counter entered tightening range before exit fired.
**5. Risk notes:** Config step=1, max_count=6. Exit counter active throughout trade lifecycle.

---

## Section 3 — Workflow Pedigree

### 3.1 Pipeline Scripts

| Script | Version | Role |
|--------|---------|------|
| `strategy_v9_9_9.py` | v9.9.9 | StrategyRunner — entry/exit orchestration |
| `long_strategy_v1_12_6.py` | vv1_12_6 | LongOrchestrator — entry/exit state machine |
| `results_report_v1_8_1.py` | 1.8.1 | Results report generator |

### 3.2 Supporting Modules

| Module | Role |
|--------|------|
| `bar_source_v9_0_1.py` | CSV replay bar source |
| `bar_aggregator_v9_2_1.py` | 1-sec to N-min bar aggregation |
| `indicator_manager_v9_0_1.py` | Indicator calculation management |
| `trading_authorized_v9_0_0.py` | Trading authorization |

### 3.3 Config JSONs

| File | Version | Description |
|------|---------|-------------|
| `config_2_indicators_v5_6_0.json` | 5.6.0 | 20260418_TWM_combine_Debug_higher_tf |
| `config_3_time_zones_v5_1_0.json` | 5.1.0 | 20260411_TWM_1sec_debug_try_v9_trial2 |
| `config_4_stop_loss_long_v5_3_0.json` | 5.3.0 | 20260411_TWM_1sec_debug_try_v9_trial2 |
| `config_5_strategy_long_v1_7_6.json` | 1.7.6 | Strategy execution config â€” ticker/TF scope, trading mode, session times, transition guards, profit target config, output controls. |
| `config_6_profit_target_long_v1_0_0.json` | 1.0.0 | Profit target configuration for TWM long strategy. Contains Type 1 (premarket resistance limit) and Type 2 (exit counter tightening) profit target parameters. See profit_target_workflow_v1_0_0.md for full logic. |
| `config_7_limit_order_long_v1_0_0.json` | 1.0.1 | Limit order entry configuration for TWM long strategy. Controls the progressive limit order placed below breakout price in state long_06_WAIT_BREAKOUT. See limit_order_workflow_v1_0_0.md for full logic. |

---

## Section 4 — Config Settings at Test Time

> Source: `2_Inputs/3_jsons/`

### 4.1: `config_2_indicators_v5_6_0.json` (v5.6.0)

| Key | Value |
|-----|-------|
| **indicator_dependencies** | |
| &nbsp;&nbsp;`calcShiftDotLevel` | MovingAverageArrayCalculator, calcEnergy, calcVelocityRSI, calcWyckoff |
| &nbsp;&nbsp;`calcBreakoutTWM` | calcCandleCount |
| &nbsp;&nbsp;`calcMorningTrade` | calcBreakoutTWM, calcTradingAuthorized |
| **indicator_properties** | |
| &nbsp;&nbsp;`calcTradingAuthorized` | `version`: 2.1<br>`description`: Determines if timestamps fall within authorized trading time zones<br>`approved_times`: trade_1, trade_2, lunch, trade_3, trade_4<br>`entry_approved_times`: trade_1, trade_2, lunch, trade_3<br>`time_zones`: `pre_session`: {...4 keys}<br>`open`: {...4 keys}<br>`trade_1`: {...4 keys}<br>`trade_2`: {...4 keys}<br>`lunch`: {...4 keys}<br>`trade_3`: {...4 keys}<br>`trade_4`: {...4 keys}<br>`after_hours`: {...4 keys}<br>`closed`: {...4 keys}<br>`timezone`: US/Eastern |
| &nbsp;&nbsp;`calcTrendCounter` | `version`: 2.1<br>`description`: Rolling window trend analysis using 8-bar lookback with sequential counting<br>`lookbackPeriod`: 8<br>`limitPriceDiff`: 0.01<br>`bull_trendCount_Percent`: 10.0<br>`bear_trendCount_Percent`: -10.0<br>`bull_trendCount_Limit`: 2<br>`bear_trendCount_Limit`: 2 |
| &nbsp;&nbsp;`calcCandleCount` | `version`: 2.2<br>`description`: Green/red candle pattern detection using rolling window<br>`lookbackPeriod`: 3<br>`limitCount`: 1 |
| &nbsp;&nbsp;`MovingAverageArrayCalculator` | `version`: 2.2<br>`description`: Multiple EMAs with crossover detection, MA position flags, and trend alignment. Periods vary by ticker and timeframe.<br>`tickers`: `tradeTicker`: `@ES`: `tf1`: 3, 5, 8<br>`tf2`: 3, 5, 8<br>`tf3`: 3, 5, 8<br>`tf4`: 5, 10, 8<br>`tf5`: 5, 10, 8<br>`tf6`: 5, 10, 8<br>`@NQ`: `tf1`: 3, 5, 8<br>`tf2`: 3, 5, 8<br>`tf3`: 3, 5, 8<br>`tf4`: 5, 10, 8<br>`tf5`: 5, 10, 8<br>`tf6`: 5, 10, 8<br>`$ADD`: `@ES`: `tf1`: 3, 8<br>`tf2`: 3, 8<br>`tf3`: 3, 8<br>`tf4`: 3, 8<br>`tf5`: 3, 8<br>`tf6`: 3, 8<br>`@NQ`: `tf1`: 3, 8<br>`tf2`: 3, 8<br>`tf3`: 3, 8<br>`tf4`: 3, 8<br>`tf5`: 3, 8<br>`tf6`: 3, 8<br>`$VIX.X`: `@ES`: `tf1`: 3, 8<br>`tf2`: 3, 8<br>`tf3`: 3, 8<br>`tf4`: 3, 8<br>`tf5`: 3, 8<br>`tf6`: 3, 8<br>`@NQ`: `tf1`: 3, 8<br>`tf2`: 3, 8<br>`tf3`: 3, 8<br>`tf4`: 3, 8<br>`tf5`: 3, 8<br>`tf6`: 3, 8<br>`$TICK`: `@ES`: `tf1`: 3, 8<br>`tf2`: 3, 8<br>`tf3`: 3, 8<br>`tf4`: 3, 8<br>`tf5`: 3, 8<br>`tf6`: 3, 8<br>`@NQ`: `tf1`: 3, 8<br>`tf2`: 3, 8<br>`tf3`: 3, 8<br>`tf4`: 3, 8<br>`tf5`: 3, 8<br>`tf6`: 3, 8 |
| &nbsp;&nbsp;`calcShiftDotLevel` | `version`: 3.2<br>`description`: Weighted ShiftTotal summation of 7 components (Energy, Wyckoff, $ADD MA, $ADD Cls, invVIX MA, $TICK Cls, RSI_lt). Range: -7 to +7.<br>`adspd_threshold`: 50<br>`tick_threshold`: 200<br>`rsi_period`: 7<br>`rsi_ema_period`: 8 |
| &nbsp;&nbsp;`calcWyckoff` | `version`: 2.1<br>`description`: Wyckoff Wave tracking direction and volume accumulation<br>`trend_length`: 5 |
| &nbsp;&nbsp;`calcVelocityRSI` | `version`: 2.3<br>`description`: RSI with 8-period EMA, RSILongTerm_flag, and momentum detection<br>`period`: 7<br>`rsi_ma_period`: 8<br>`rateDecay`: 0.2222222222222222 |
| &nbsp;&nbsp;`calcEnergy` | `version`: 2.1<br>`description`: Energy indicator with TEMA bands and threshold detection<br>`tema_period`: 13<br>`atr_period`: 13<br>`atr_multiplier`: 0.75 |
| &nbsp;&nbsp;`calcCycleOscillator` | `version`: 2.0<br>`description`: Multi-timeframe Stochastic RSI cycle oscillator<br>`cycle_1`: `rsi_length_c1`: 55<br>`stoc_length_c1`: 34<br>`wma_length_c1`: 34<br>`stoch_rsi_c1_mult`: 1.5<br>`cycle_2`: `rsi_length_c2`: 34<br>`stoc_length_c2`: 21<br>`wma_length_c2`: 21<br>`stoch_rsi_c2_mult`: 0.5<br>`cycle_3`: `rsi_length_c3`: 21<br>`stoc_length_c3`: 13<br>`wma_length_c3`: 13<br>`stoch_rsi_c3_mult`: 0.25<br>`tema_atr`: `length_tema`: 21<br>`atr_length`: 14<br>`atr_mult`: 1.0<br>`swing`: `num_swings_to_use`: 5<br>`swing_wing`: 4<br>`near_up_down_turn`: 10.0 |
| &nbsp;&nbsp;`LWR123Calculator` | `version`: 2.2<br>`description`: LWR 1-2-3 reversal pattern detection with HOLB/LOHB breakouts<br>`num_bars`: 21<br>`break_limit`: 4<br>`lohb_offset`: 0.0<br>`holb_offset`: 0.0 |
| &nbsp;&nbsp;`calcBreakoutTWM` | `version`: 3.1<br>`description`: State-based breakout detection with dual independent state machines and breakout_offset<br>`fast_MA_period`: 3<br>`slow_MA_period`: 5<br>`breakout_offset`: 0.25 |
| &nbsp;&nbsp;`calcMorningTrade` | `version`: 2.4<br>`description`: Morning trade momentum detector for open and trade_1 zones<br>`fast_MA_period`: 3<br>`slow_MA_period`: 5<br>`MA_velocity_limit`: 1.5<br>`consecutive_limit`: 5 |
| &nbsp;&nbsp;`PreMarketComparisonCalculator` | `version`: 2.1<br>`description`: Price position relative to pre-market high, low, and session start<br>`limit_tradeProhibit`: 0.02 |

### 4.2: `config_3_time_zones_v5_1_0.json` (v5.1.0)

| Key | Value |
|-----|-------|
| **time_zones** | |
| &nbsp;&nbsp;`pre_session` | `start`: 08:00<br>`end`: 09:30<br>`description`: Pre-market session - same-day premarket (08:00-09:30)<br>`isAuthorized`: false |
| &nbsp;&nbsp;`open` | `start`: 09:30<br>`end`: 09:50<br>`description`: Market open window<br>`isAuthorized`: false |
| &nbsp;&nbsp;`trade_1` | `start`: 09:50<br>`end`: 10:00<br>`description`: Morning trading session<br>`isAuthorized`: true |
| &nbsp;&nbsp;`trade_2` | `start`: 10:00<br>`end`: 12:05<br>`description`: Morning trading session<br>`isAuthorized`: true |
| &nbsp;&nbsp;`lunch` | `start`: 12:05<br>`end`: 12:35<br>`description`: Lunch trading session<br>`isAuthorized`: true |
| &nbsp;&nbsp;`trade_3` | `start`: 12:35<br>`end`: 15:45<br>`description`: Afternoon trading session<br>`isAuthorized`: true |
| &nbsp;&nbsp;`trade_4` | `start`: 15:45<br>`end`: 15:56<br>`description`: Market close trading window<br>`isAuthorized`: true |
| &nbsp;&nbsp;`after_hours` | `start`: 15:56<br>`end`: 17:00<br>`description`: After hours trading<br>`isAuthorized`: false |
| &nbsp;&nbsp;`closed` | `start`: 17:00<br>`end`: 18:00<br>`description`: Market closed - no trading<br>`isAuthorized`: false |
| `approved_times` | trade_1, trade_2, lunch, trade_3, trade_4 |
| `trade_approved_times` | trade_1, trade_2, lunch, trade_3, trade_4 |
| `entry_approved_times` | trade_1, trade_2, lunch, trade_3 |
| `timezone` | US/Eastern |
| `notes` | All times are in EST (Eastern Standard Time) using 24-hour format, pre_session: 6:00 PM - 9:30 AM (15.5 hours) - overnight trading, open: 9:30 AM - 9:38 AM (8 minutes) - market open window, trade_1: 9:38 AM - 10:00 AM (22 minutes) - morning session, trade_2: 10:00 AM - 12:05 PM (2.08 hours) - morning session, lunch: 12:05 PM - 12:35 PM (30 minutes) - lunch session, trade_3: 12:35 PM - 3:45 PM (3.17 hours) - afternoon session, trade_4: 3:45 PM - 3:56 PM (11 minutes) - market close window, after_hours: 3:56 PM - 5:00 PM (1.07 hours) - after hours, closed: 5:00 PM - 6:00 PM (1 hour) - market closed, Total authorized trading: 6.0 hours per day |

### 4.3: `config_4_stop_loss_long_v5_3_0.json` (v5.3.0)

| Key | Value |
|-----|-------|
| **stop_loss_config** | |
| &nbsp;&nbsp;`type_2_isActive` | true |
| &nbsp;&nbsp;`type_3_isActive` | true |
| &nbsp;&nbsp;`type_1_offset` | `@ES`: `tf1`: 1<br>`tf2`: 1<br>`tf3`: 1<br>`tf4`: 1<br>`tf5`: 1<br>`tf6`: 1<br>`@NQ`: `tf1`: 3<br>`tf2`: 3<br>`tf3`: 3<br>`tf4`: 3<br>`tf5`: 3<br>`tf6`: 3 |
| &nbsp;&nbsp;`type_2_profit_limit` | `@ES`: `tf1`: 6<br>`tf2`: 6<br>`tf3`: 6<br>`tf4`: 6<br>`tf5`: 6<br>`tf6`: 6<br>`@NQ`: `tf1`: 18<br>`tf2`: 18<br>`tf3`: 18<br>`tf4`: 18<br>`tf5`: 18<br>`tf6`: 18 |
| &nbsp;&nbsp;`type_2_offset` | `@ES`: `tf1`: 1<br>`tf2`: 1<br>`tf3`: 1<br>`tf4`: 1<br>`tf5`: 1<br>`tf6`: 1<br>`@NQ`: `tf1`: 3<br>`tf2`: 3<br>`tf3`: 3<br>`tf4`: 3<br>`tf5`: 3<br>`tf6`: 3 |
| &nbsp;&nbsp;`type_3_offset` | `@ES`: `tf1`: 0.25<br>`tf2`: 0.25<br>`tf3`: 0.25<br>`tf4`: 0.25<br>`tf5`: 0.25<br>`tf6`: 0.25<br>`@NQ`: `tf1`: 0.25<br>`tf2`: 0.25<br>`tf3`: 0.25<br>`tf4`: 0.25<br>`tf5`: 0.25<br>`tf6`: 0.25 |
| &nbsp;&nbsp;`max_initial_stop_distance` | `@ES`: `tf1`: 10<br>`tf2`: 10<br>`tf3`: 10<br>`tf4`: 10<br>`tf5`: 10<br>`tf6`: 10<br>`@NQ`: `tf1`: 30<br>`tf2`: 30<br>`tf3`: 30<br>`tf4`: 30<br>`tf5`: 30<br>`tf6`: 30 |

### 4.4: `config_5_strategy_long_v1_7_6.json` (v1.7.6)

| Key | Value |
|-----|-------|
| `ticker` | @ES |
| `timeframe` | 1 |
| `account_type` | paper |
| `paper_mode` | true |
| `market_open` | 09:30 |
| `market_close` | 16:00 |
| `timezone` | America/New_York |
| `SAFETY_NOTICE` | This config is for PAPER TRADING ONLY. account_type MUST be 'paper'. |
| `setup_counter_exit_limit` | 12 |
| `setup_counter_velocity_limit` | 3 |
| **lhp_threshold_points** | |
| &nbsp;&nbsp;`@ES` | 1.0 |
| &nbsp;&nbsp;`@NQ` | 1.0 |
| **transition_guards** | |
| &nbsp;&nbsp;`t_50_bear_trend_met_isActive` | true |
| &nbsp;&nbsp;`t_60_bull_shift_met_isActive` | true |
| &nbsp;&nbsp;`t_61_bear_setup_reset_isActive` | true |
| &nbsp;&nbsp;`t_51_velocity_entry_s01_isActive` | false |
| &nbsp;&nbsp;`t_70_ma_bull_cross_isActive` | true |
| &nbsp;&nbsp;`t_71_velocity_entry_s03_isActive` | false |
| &nbsp;&nbsp;`t_80_all_indicators_confirmed_isActive` | true |
| &nbsp;&nbsp;`t_81_velocity_entry_s04_isActive` | true |
| &nbsp;&nbsp;`t_90_ma_retest_touched_isActive` | true |
| &nbsp;&nbsp;`t_91_midbar_retest_touched_isActive` | true |
| &nbsp;&nbsp;`t_92_velocity_entry_s05_isActive` | true |
| &nbsp;&nbsp;`t_93_lwr_high_bypass_isActive` | true |
| &nbsp;&nbsp;`t_94_skip_retest_multi_tf_isActive` | true |
| &nbsp;&nbsp;`t_100_breakout_level_hit_isActive` | true |
| &nbsp;&nbsp;`t_101_velocity_entry_s06_isActive` | true |
| &nbsp;&nbsp;`t_102_skip_breakout_multi_tf_isActive` | true |
| &nbsp;&nbsp;`t_103_breakout_limit_entry_isActive` | false |
| &nbsp;&nbsp;`t_111_entry_blocked_isActive` | true |
| &nbsp;&nbsp;`t_10_entry_window_closed_isActive` | true |
| &nbsp;&nbsp;`t_30_setup_expired_isActive` | true |
| &nbsp;&nbsp;`t_200_exit_session_close_isActive` | true |
| &nbsp;&nbsp;`t_220_exit_session_close_isActive` | true |
| &nbsp;&nbsp;`t_221_exit_hard_stop_isActive` | true |
| &nbsp;&nbsp;`t_211_count_ma_isActive` | true |
| &nbsp;&nbsp;`t_222_exit_ma_isActive` | true |
| &nbsp;&nbsp;`t_212_count_lwr_isActive` | false |
| &nbsp;&nbsp;`t_223_exit_lwr_isActive` | true |
| &nbsp;&nbsp;`t_200_yellow_to_green_isActive` | true |
| &nbsp;&nbsp;`t_202_yellow_to_red_isActive` | true |
| &nbsp;&nbsp;`t_213_count_premarket_s09_isActive` | true |
| &nbsp;&nbsp;`t_224_exit_premarket_s09_isActive` | true |
| &nbsp;&nbsp;`t_201_green_to_yellow_isActive` | true |
| &nbsp;&nbsp;`t_214_count_premarket_s11_isActive` | true |
| &nbsp;&nbsp;`t_225_exit_premarket_s11_isActive` | true |
| &nbsp;&nbsp;`t_203_red_to_yellow_isActive` | true |
| &nbsp;&nbsp;`t_230_offset_change_isActive` | true |
| &nbsp;&nbsp;`t_226_exit_profit_target_count_isActive` | true |
| **profit_target_config** | |
| &nbsp;&nbsp;`_description` | Profit target parameters. premarket_profit_target_offset is the spread below the nearest premarket resistance level above entry at which the profit target is set (Long: target = resistance - offset). |
| &nbsp;&nbsp;`premarket_profit_target_offset` | `@ES`: `tf1`: 1<br>`tf2`: 1<br>`tf3`: 1<br>`tf4`: 1<br>`tf5`: 1<br>`tf6`: 1<br>`@NQ`: `tf1`: 3<br>`tf2`: 3<br>`tf3`: 3<br>`tf4`: 3<br>`tf5`: 3<br>`tf6`: 3 |
| &nbsp;&nbsp;`breakout_offset` | `@ES`: `tf1`: 0.25<br>`tf2`: 0.25<br>`tf3`: 0.25<br>`tf4`: 0.25<br>`tf5`: 0.25<br>`tf6`: 0.25<br>`@NQ`: `tf1`: 0.25<br>`tf2`: 0.25<br>`tf3`: 0.25<br>`tf4`: 0.25<br>`tf5`: 0.25<br>`tf6`: 0.25 |
| &nbsp;&nbsp;`ticker_config` | `@ES`: `dollars_per_point`: 50.0<br>`default_slippage_points`: 0.35<br>`@NQ`: `dollars_per_point`: 20.0<br>`default_slippage_points`: 0.4 |
| **post_replay_outputs** | |
| &nbsp;&nbsp;`_description` | Controls what is written to disk after a replay run completes. All paths relative to project root. |
| &nbsp;&nbsp;`write_indicator_json` | true |
| &nbsp;&nbsp;`write_consolidated_json` | true |
| &nbsp;&nbsp;`indicator_isPlot` | true |
| &nbsp;&nbsp;`strategy_isPlot` | true |
| &nbsp;&nbsp;`json_output_dir` | 3_Outputs/3_jsons/indicator_test |
| &nbsp;&nbsp;`twm_indicators_dir` | 3_Outputs/3_jsons/3_twm_indicators |
| &nbsp;&nbsp;`strategy_output_dir` | 3_Outputs/3_jsons/4_strategies |
| &nbsp;&nbsp;`plot_output_dir` | 3_Outputs/5_plots |
| &nbsp;&nbsp;`plot_start_time` | 09:30 |
| &nbsp;&nbsp;`plot_end_time` | 16:00 |

### 4.5: `config_6_profit_target_long_v1_0_0.json` (v1.0.0)

| Key | Value |
|-----|-------|
| **profit_target_config** | |
| &nbsp;&nbsp;`premarket_profit_target_offset` | `@ES`: `tf1`: 1<br>`tf2`: 1<br>`tf3`: 1<br>`tf4`: 1<br>`tf5`: 1<br>`tf6`: 1<br>`@NQ`: `tf1`: 3<br>`tf2`: 3<br>`tf3`: 3<br>`tf4`: 3<br>`tf5`: 3<br>`tf6`: 3 |
| &nbsp;&nbsp;`exit_counter_config` | `@ES`: `range_1`: {...2 keys}<br>`range_2`: {...2 keys}<br>`range_3`: {...2 keys}<br>`range_4`: {...2 keys}<br>`range_5`: {...2 keys}<br>`range_6`: {...2 keys}<br>`@NQ`: `range_1`: {...2 keys}<br>`range_2`: {...2 keys}<br>`range_3`: {...2 keys}<br>`range_4`: {...2 keys}<br>`range_5`: {...2 keys}<br>`range_6`: {...2 keys} |

### 4.6: `config_7_limit_order_long_v1_0_0.json` (v1.0.1)

| Key | Value |
|-----|-------|
| **entry_limit_config** | |
| &nbsp;&nbsp;`_description` | Progressive limit order offset config. increment defines how many 1-second bars between each step-down. 6 levels step from max offset down to 0 (market order). Tickers share the same timer/increment but have distinct offset values. |
| &nbsp;&nbsp;`increment` | 5 |
| &nbsp;&nbsp;`_thresholds_derived` | level_1: timer âˆˆ [0,5), level_2: [5,10), level_3: [10,15), level_4: [15,20), level_5: [20,25), level_6: [25,âˆž) â†’ market order |
| &nbsp;&nbsp;`@ES` | `level_1`: `sec_count`: 0<br>`entry_offset`: 2.5<br>`level_2`: `sec_count`: 5<br>`entry_offset`: 2.0<br>`level_3`: `sec_count`: 10<br>`entry_offset`: 1.5<br>`level_4`: `sec_count`: 15<br>`entry_offset`: 1.0<br>`level_5`: `sec_count`: 20<br>`entry_offset`: 0.5<br>`level_6`: `sec_count`: 25<br>`entry_offset`: 0 |
| &nbsp;&nbsp;`@NQ` | `level_1`: `sec_count`: 0<br>`entry_offset`: 7.5<br>`level_2`: `sec_count`: 5<br>`entry_offset`: 6.0<br>`level_3`: `sec_count`: 10<br>`entry_offset`: 4.5<br>`level_4`: `sec_count`: 15<br>`entry_offset`: 3.0<br>`level_5`: `sec_count`: 20<br>`entry_offset`: 1.5<br>`level_6`: `sec_count`: 25<br>`entry_offset`: 0 |
