Keep track of the information generated for each stage of the trading strategy, at a granular level. On this page: Strategy Trigger Stage, Strategy Open Stage, Strategy Manage Stage, and Strategy Close Stage.

The Superalgos Protocol implements a trading framework by which strategies within a trading system are described in stages. The trading bot uses these definitions during runtime.

The concept of strategy stages in the context of the trading engine is an extension of the original concept, useful to keep track of the activity of the trading bot and organize the information processed during runtime.

Use these sections of the trading engine if you wish to track exactly what is going on, at a granular level, step by step, from the instant a strategy is triggered until it is closed, with the information segregated by strategy stage.

The exercise may be particularly useful to grasp the intricacies of the workings of the trading bot or to research particular behaviors.

Strategy Trigger Stage

Strategy trigger stage is the section of the data structure that keeps track of information specific to the scope of the trigger stage during the period the stage is open.

The trigger stage is active from the instant the trigger-on event is triggered until either the trigger-off event or the take position event gets triggered. Therefore, this section of the data structure features information spaning those periods only.


Strategy Trigger Stage

Begin

End

Exit Type

Status

Begin Rate

End Rate

Strategy Open Stage

Strategy open stage is the section of the data structure that keeps track of information specific to the scope of the open stage during the period the stage is open.

The open stage is open from the instant the take position event gets triggered, and starts closing from the instant one of the following things happen:

  • the target size is filled,

  • the close stage event is triggered,

  • the take profit or stop loss targets are hit.

Therefore, this section of the data structure features information spaning those periods only.


Strategy Open Stage

Begin

End

Exit Type

Status

Begin Rate

End Rate

Stage Base Asset

Target Size

Size Placed

Size Filled

Fees Paid

Stage Quoted Asset

Target Size

Size Placed

Size Filled

Fees Paid

Strategy Manage Stage

Strategy manage stage is the section of the data structure that keeps track of information specific to the scope of the manage stage during the period the stage is open.

The manage stage is active from the instant the take position event is triggered until the instant either the stop or take profit targets are hit.

Therefore, this section of the data structure features information spaning those periods only.


Strategy Manage Stage

Begin

End

Exit Type

Status

Begin Rate

End Rate

Strategy Close Stage

Strategy close stage is the section of the data structure that keeps track of information specific to the scope of the close stage during the period the stage is open.

The close stage is active from the instant either the stop loss or take profit targets are hit until the instant the target size is filled or the close stage event is triggered.

Therefore, this section of the data structure features information spaning those periods only.


Strategy Close Stage

Begin

End

Exit Type

Status

Begin Rate

End Rate

Stage Base Asset

Target Size

Size Placed

Size Filled

Fees Paid

Stage Quoted Asset

Target Size

Size Placed

Size Filled

Fees Paid