by ABXK.AI AI Trading

AI Trading Platform: Observing Model Behavior During Strategy Optimization

machine-learningtradingbacktestingoptimizationpython

Initial Observations

In our last post, we built an evaluation framework for measuring system behavior. With that in place, we could observe how the model performed under test conditions.

Diagram showing observed metric changes across 15 iterations
Observed metric distribution across 15 iterations.

Initial metrics showed:

MetricValueNote
Profit Factor0.94Below 1.0
Win Rate4%Low frequency
Average Loss-253%High magnitude
Risk/Reward0.59:1Unfavorable ratio

A Profit Factor below 1.0 indicates negative expected value under the current configuration.

Research Objectives

We defined observation targets for iterative testing:

  1. Profit Factor > 1.0 — Positive expected value
  2. Win Rate stability — Consistent outcome distribution
  3. Loss magnitude reduction — Smaller drawdowns per trade
  4. Risk/Reward ratio — Favorable return distribution

Iteration Log: 15 Versions

The following table documents observed behavior changes across iterations:

VersionParameter ChangeTradesProfit FactorObservation
v1-v4Strict filters0-No signal generation
v5Relaxed filters332-All breakeven exits
v61.0 ATR stops200+0.69Increased loss frequency
v7Breakeven disabled150+1.03First positive PF
v110.75 ATR stops180+1.09Marginal improvement
v13Strict filters2-Insufficient sample
v14Earlier trailing160+0.94Regression observed
v150.6 ATR stops1712.77Significant shift

Non-monotonic behavior was observed. Parameter changes did not consistently improve metrics.

Observed Constraints

Observation 1: Stop-Loss Distance

The initial stop-loss was set at 2.0 ATR (Average True Range). This allowed significant adverse movement before exit. Average loss per stopped trade was -253%.

This represented the largest contributor to negative expected value.

Observation 2: Time Period Sensitivity

Performance varied significantly by time period:

Time PeriodAverage LossNote
1 week-33%High loss magnitude
6 months-99%Severe underperformance
1 year-78%Significant loss
1 month-45%Elevated loss

Certain time horizons showed consistent negative outcomes. This pattern was not anticipated.

Observation 3: Symbol-Specific Behavior

Certain symbols showed divergent behavior:

SymbolWin RateAverage Return
META33%-0.43%

Model performance was not uniform across all instruments.

Observation 4: Breakeven Stop Behavior

A feature moved the stop loss to breakeven after small gains. In theory this reduces risk. In practice, trading costs (fees, spread, slippage) meant breakeven exits produced net negative returns.

This feature contributed to loss accumulation rather than risk reduction.

Parameter Adjustments

The following changes were tested:

Adjustment 1: Stop-Loss Distance

ATR multiplier reduced from 2.0 to 0.6:

ConditionPreviousTested
Normal2.00.6
High volatility2.00.85
Low volatility2.00.5

Observed effect: Average stopped loss changed from -253% to -0.81%. This represented the largest shift in loss magnitude.

Adjustment 2: Trailing Stop Timing

Trailing stop activation was adjusted:

SettingPreviousTested
Trigger at profit1.0R0.7R
Trail distance0.5R0.4R

This configuration triggered profit protection earlier in the trade lifecycle.

Adjustment 3: Time Period Exclusion

Time periods with observed negative performance were excluded:

Excluded: 1 week, 1 month, 2 months, 3 months, 6 months, 1 year

The system no longer generated signals for these time horizons.

Adjustment 4: Symbol Exclusion

Symbols with divergent behavior were excluded:

Excluded: META

Adjustment 5: Breakeven Stop Disabled

The breakeven stop feature was disabled. Its contribution to loss accumulation outweighed its intended risk reduction.

Observed Metric Changes

The following table shows metric distribution before and after parameter adjustments:

MetricInitialAfter AdjustmentsChange
Profit Factor0.942.77+194%
Win Rate4%61.4%Significant shift
Total ReturnNegative+82.79%Direction change
Average Loss-253%-0.71%99.7% reduction
Risk/Reward0.59:11.74:1+195%

These observations reflect one configuration state. Generalizability has not been established.

Sample Distribution

The test sample included 171 trades:

Exit TypeTradesPercentageAverage
Trailing stop11466.7%+1.13%
Stop-loss5733.3%-0.81%
CategoryCountAverage
Positive105+1.23%
Negative66-0.71%

Research Notes

Observations from this iteration cycle:

1. Stop-loss distance affects loss magnitude

Wider stops allowed larger adverse movements before exit. Tighter stops reduced average loss per trade.

2. Time period sensitivity exists

Certain time horizons showed consistent negative outcomes. Segmenting analysis by time period revealed patterns not visible in aggregate data.

3. Earlier trailing affects return capture

Delayed trailing allowed gains to reverse. Earlier activation reduced this effect.

4. Feature interaction with costs

The breakeven stop appeared beneficial in isolation. When trading costs were included, it contributed to losses. Features should be tested with realistic cost models.

5. Non-monotonic optimization

15 iterations were required to observe significant metric shifts. Intermediate versions showed regression. Sequential iteration was necessary.

Configuration Snapshot

The following configuration reflects one observed state of the system during testing. It is not presented as an optimal or transferable setup.

ParameterValue
ATR Multiplier (normal)0.6
ATR Multiplier (high volatility)0.85
ATR Multiplier (low volatility)0.5
Trailing trigger0.7R profit
Trail distance0.4R
Breakeven stopDisabled
Min confidence50
Excluded time periods1w, 1M, 2M, 3M, 6M, 1Y
Excluded symbolsMETA

Next Research Phases

The initial observation target (Profit Factor > 1.0) was observed in this configuration.

Further stages will focus on:

  1. Out-of-sample testing — Observing behavior on unseen data
  2. Live data observation — Monitoring system responses to real-time data streams
  3. Stability analysis — Measuring metric variance over extended periods

No conclusions about deployability are drawn from these observations.

The largest observed effect came from a single parameter change: reducing the ATR multiplier from 2.0 to 0.6 shifted average loss from -253% to -0.81%. This suggests stop-loss distance may be a high-leverage variable in similar configurations.

Learn more about the platform: AI Trading Platform

Previous: Building a Bulletproof Evaluation Framework


This document records observations from iterative testing. Results are specific to the tested configuration and data set.

AI Trading Platform Blog

Read our development journey and latest updates:

AI Trading Platform: Adding CI/CD to Our Development Workflow
AI Trading

AI Trading Platform: Adding CI/CD to Our Development Workflow

We implemented a CI/CD pipeline for the AI Trading Platform. This post documents the approach, the types of bugs it catches, and why automated testing matters …

AI tradingCI/CDautomated testing
AI Adoption in Trading: Why Acting Now Matters
AI Trading

AI Adoption in Trading: Why Acting Now Matters

AI adoption in trading is accelerating. Learn why firms that act now gain an advantage, and how our AI trading platform validates this approach through real …

AI tradingtrading technologypaper trading
AI Trading Platform: Choosing the Right Markets and Trading Style
AI Trading

AI Trading Platform: Choosing the Right Markets and Trading Style

We tested our frozen v0.3 exit strategy across different markets and trading styles. Here is what we learned about CFDs, futures, stocks, and why swing trading …

AI tradingfutures tradingCFD trading
AI Trading Platform: Exit Strategy Breakthrough & Paper Trading System
AI Trading

AI Trading Platform: Exit Strategy Breakthrough & Paper Trading System

Our AI trading platform improved expectancy from near-zero to statistically meaningful levels through a two-stage exit strategy. We also built a causal paper …

machine-learningtradingexit-strategy
AI Trading Platform: Security Audit & Major System Updates
AI Trading

AI Trading Platform: Security Audit & Major System Updates

A comprehensive audit of our AI trading platform reveals a critical security fix, frontend accessibility improvements, and live stats from 33,000+ analyzed …

machine-learningtradingsecurity
AI Trading Platform Update: Building a Bulletproof Evaluation Framework
AI Trading

AI Trading Platform Update: Building a Bulletproof Evaluation Framework

Two days of intensive work on preventing overfitting and data leakage. Here's what we built and what we learned.

machine-learningtradingbacktesting
Building an AI Trading Platform: Our Progress So Far
AI Trading

Building an AI Trading Platform: Our Progress So Far

We are building an AI trading system that learns from its mistakes. Here is what we have done, what works, and what problems we still need to solve.

machine-learningtradingneural-networks
⚠️ Important Notice

The AI Trading Platform is an internal research project operated exclusively by ABXK.AI. It is not publicly accessible and cannot be used by visitors.

Any results, insights, or examples shared on this website or on social media are provided for informational and educational purposes only and do not constitute financial advice.