StrategyFactory#
tradeexecutor.strategy.factory.StrategyFactory Python class in Trading Strategy framework.
- class StrategyFactory[source]#
Bases:
Protocol
A callable that creates a new strategy when loaded from an external script.
- __init__(*args, **kwargs)#
Methods
__init__
(*args, **kwargs)- __call__(*, execution_model, sync_model, pricing_model_factory, valuation_model_factory, client, timed_task_context_manager, approval_model, routing_model=None, **kwargs)[source]#
- Parameters:
ignore –
execution_model (ExecutionModel) – TODO
sync_method – TODO
pricing_model_factory (Callable[[ExecutionModel, StrategyExecutionUniverse, RoutingModel], PricingModel]) – TODO
valuation_model_factory (ValuationModelFactory) – TODO
client (Optional[BaseClient]) – TODO
timed_task_context_manager (AbstractContextManager) – TODO
approval_model (ApprovalModel) – TODO
routing_model (Optional[RoutingModel]) – Strategy factory can create its own routing model, or accept the passed one. Passing it here is mainly used in the tests as a shortcut.
kwargs –
sync_model (SyncModel) –
- Returns:
- Return type:
- __init__(*args, **kwargs)#