Hello everyone,

I am working on a private automated trading system and I am looking for high-level architecture feedback only. I am not sharing or selling any source code.

The system has grown over time and now includes several decision layers: signal logic, learning/scoring logic, reversal/retest logic, spread guards, daily risk limits, position protection, break-even logic, trailing stop, and diagnostics.

The main issue is that the system is becoming too monolithic. There are many filters and guard conditions, and sometimes different modules can compete with each other. For example, one module may detect a valid trade candidate, while another guard blocks it, and the final reason shown in diagnostics is not always clear.

My current plan is not to split everything into many files immediately. Instead, I am thinking about first building a central Decision Engine with a clear flow:

Signal → Override Candidate → Guards → Final Decision → Execution → Protection

The goal would be:

1. One final trade decision per tick/bar.
2. One clear EntrySource or decision source.
3. Guards should only block or explain, not create separate competing decisions.
4. Execution should be separated from decision-making.
5. Risk and protection management should be centralised.
6. Diagnostics should clearly show: Signal, Guard, Entry, Protection.

My question is:

For a growing automated trading system, is it better to first centralise the decision logic into one clean Decision Engine before splitting the code into separate modules/files?

Or would you recommend modularising first and then cleaning the decision flow afterwards?

I would appreciate any architecture-level feedback from people who have built or maintained automated trading systems.