Position management does not consult the AI
Once a trade is open, the model's job is over. What happens next is deterministic rule evaluation on every tick, in priority order.
- 01
Emergency exit
A per-position kill switch on unrealized loss. Evaluated first, before anything else, and cannot be overridden by a later rule.
- 02
Profit lock
Closes the position once profit falls a configured percentage below its own peak, so a winning trade does not round-trip back to nothing.
- 03
Break-even
Moves the stop to entry once the trade is far enough ahead. Fires once per position.
- 04
Trailing stop
Follows price in your favour and only ever tightens — it can never be widened by a later evaluation.
- 05
Partial close
Takes part of the position off at a configured level, leaving the remainder running under the same rules.
This is the part that matters when something breaks. If the Python agent crashes, the LLM provider goes down, the database becomes unreachable, or you close the dashboard, these rules keep running. The trading core does not depend on any of them to protect a position that is already open.