strategy#

tradeexecutor.strategy module.

Module description#

Strategy core - the internal state data structures.

This is the code of the strategy execution engine. We define how the data structures look like and what actions are possible.

All data structures are based on dataclass DLS and dataclasses_json serialisation.

The main tradeexecutor.state.State class serialises the whole strategy execution state in one go and passes it to the web client as one JSON download.

Submodules#

tradeexecutor.strategy.approval

Trade approval models.

tradeexecutor.strategy.bootstrap

Loading Python strategy modules.

tradeexecutor.strategy.cycle

Strategy cycle definitions.

tradeexecutor.strategy.default_routing_options

Default routing options for trading strategies.

tradeexecutor.strategy.description

Strategy execution description.

tradeexecutor.strategy.dummy

Trader where all assets are maintained on a single hot wallet.

tradeexecutor.strategy.execution_context

Execution modes.

tradeexecutor.strategy.execution_model

Strategy execution model.

tradeexecutor.strategy.factory

Strategy initialisation using factory design pattern.

tradeexecutor.strategy.output

Helpers for outputting strategy execution information to Python logging and Discord.

tradeexecutor.strategy.pandas_trader

Trading Strategy internal strategy types using Pandas data and decide_trades functino.

tradeexecutor.strategy.pricing_model

Asset pricing model.

tradeexecutor.strategy.qstrader

QSTrader portfolio construction model based strategy types.

tradeexecutor.strategy.reserve_currency

Reserve currency options for strategies.

tradeexecutor.strategy.routing

Trade routing instructions.

tradeexecutor.strategy.runner

Strategy execution core.

tradeexecutor.strategy.stoploss

Stop loss trade logic.

tradeexecutor.strategy.strategy_module

Describe strategy modules and their loading.

tradeexecutor.strategy.strategy_type

Declarate what kind of strategy types our strategy loader and backtesting framework supports.

tradeexecutor.strategy.trading_strategy_universe

Trading Strategy oracle data integration.

tradeexecutor.strategy.universe_model

Construct the trading universe for the strategy.

tradeexecutor.strategy.valuation

Valuation models for the portfolio.