One of the hardest things I have learned in moving from discretionary futures trading toward automation is that writing the rule is rarely the difficult part.
The difficult part is explaining everything the trader knew before deciding whether to follow it.
A trader may spend years learning when a market is liquid, when a breakout is genuine, when volatility is changing character, or when the best decision is simply to stay out. If that judgment can be converted into code, it becomes repeatable, scalable and free from fatigue or emotion.
But something usually changes in the translation.
An algorithm can reproduce a rule. It is much harder for it to reproduce the context in which an experienced trader decides whether that rule should matter.
Traders rarely follow rules in isolation
A discretionary trader might describe a strategy simply: buy a breakout above a certain level, sell when momentum weakens, or avoid trading when volatility becomes excessive.
Yet that description often leaves out most of the real decision.
Before entering, the trader may already have considered the speed of the market, recent failed breakouts, liquidity around key levels, the time of day, the behaviour of related markets and whether price is moving smoothly or erratically.
Much of this happens almost automatically.
Ask an experienced trader why they ignored a seemingly valid signal and the answer may simply be: “The market did not feel right.”
That sounds unscientific. In reality, it can represent years of compressed pattern recognition.
The challenge for automation is not merely to eliminate that intuition. It is to understand what information the intuition was processing.
Coding the signal is the easy part
Most trading strategies can be expressed mathematically.
A moving average can be calculated. Volume can be measured. Volatility can be classified. Breakouts, spreads and order-flow conditions can all be converted into rules.
The harder problem is defining the environment in which those signals remain meaningful.
A strategy might perform well in a liquid, orderly market and behave very differently during a sudden withdrawal of liquidity. A model trained during one volatility regime may continue producing technically correct signals after the structure of the market has changed.
From the algorithm’s perspective, the rule has not failed.
From the trader’s perspective, the market is no longer behaving in the same way.
This distinction matters because markets are not laboratory environments. Participants adapt. Liquidity moves. Correlations change. News alters behaviour. Strategies themselves can influence the environment in which they operate.
The code sees variables. The experienced trader is often asking whether the relationship between those variables still makes sense.
Some knowledge is difficult to label
Artificial intelligence does not automatically solve this problem.
Machine-learning systems are excellent at identifying relationships in large datasets, but the quality of their conclusions still depends on how the problem is defined.
Suppose a trader avoids a position because liquidity appears fragile.
What exactly does “fragile” mean?
Is it thinner market depth? Faster order cancellation? More slippage? Larger price movement for the same volume? A change in the behaviour of market makers? Or some combination of these?
A human may recognise the condition without formally separating its components.
For a machine to identify it consistently, those components eventually have to be measured.
This is one of the most useful consequences of automation. It forces traders to challenge their own assumptions. What they once described as instinct may turn out to be a collection of observable market behaviours.
But not everything is so easily reduced to a variable.
The danger of false precision
When experience becomes code, the system can also appear more precise than the underlying knowledge really is.
A trader might say, “I usually avoid this setup when volatility is unusually high.”
A programmer must eventually define what “unusually high” means.
The moment the idea becomes code, ambiguity has to disappear.
That is useful, but it can also create false confidence.
A threshold of 24.7 may look scientific, even when it is only a precise expression of an inherently imprecise judgment.
Markets rarely respect the exact boundaries programmers assign to them.
For this reason, a robust trading system should not be judged only by how precisely it reproduces historical decisions. It should also be tested on how well it behaves when those boundaries are slightly wrong.
If a small parameter change destroys the strategy, the model may have captured history rather than market behaviour.
The ability to abstain matters
One of the biggest lessons from translating discretionary ideas into systematic trading is that a good algorithm does not need an answer for every market condition.
Human traders understand this intuitively.
Sometimes there is no trade.
Automated systems, however, are often designed with an implicit pressure to classify every situation: bullish or bearish, buy or sell, risk-on or risk-off.
That can be dangerous.
In financial AI, the ability to abstain may be as important as the ability to predict.
A system that recognises uncertainty, reduces exposure or stops trading when the conditions supporting its edge are no longer present may ultimately be more valuable than one that produces slightly better predictions in normal conditions.
In other words, one of the most important pieces of trader intuition to encode may not be how to enter a position.
It may be knowing when the model should not trust itself.
The real challenge is knowing what not to automate
The debate is often framed as human traders versus machines. That misses the more important question.
Machines are superior at consistency, calculation, monitoring large numbers of variables and executing predefined decisions without emotion.
Experienced traders can still be better at recognising structural change, questioning whether historical relationships remain relevant and dealing with situations that fall outside the assumptions of a model.
The objective should not be to make machines imitate traders.
It should be to identify which parts of trading judgment can be measured reliably, which decisions are robust enough to automate, and which parts still require caution.
Turning trader intuition into code is not simply a programming exercise.
It is an exercise in understanding what the trader actually knows.
Sometimes the most important discovery is not what can be automated, but what gets lost along the way.
Amir Naser Hojati is a futures trader with more than 15 years of experience in financial markets, focusing on algorithmic trading, market structure, liquidity and AI-driven trading systems. He has contributed articles on AI, trading technology and market risk to international financial publications and is the founder of a fintech company developing automated trading technology

