Anyone know of a ind/script/ea that can filter congestion/range and new trends?

Hi all i’m currently building an EA but i noticed that it generally struggles making profit when stuck in a tight range/ congestion and when it try to trade against a strong breakout/ new trend.

anyone know of a way to help filter for these scenarios?

'best

darth