Metadata#
tradeexecutor.state.metadata.Metadata Python class in Trading Strategy framework.
- class Metadata[source]#
Bases:
object
Strategy metadata.
- __init__(name, short_description, long_description, icon_url, started_at, executor_running, on_chain_data=<factory>, backtested_state=None, backtest_notebook=None, backtest_html=None, key_metrics_backtest_cut_off=datetime.timedelta(days=90))#
- Parameters:
name (str) –
started_at (datetime) –
executor_running (bool) –
on_chain_data (OnChainData) –
key_metrics_backtest_cut_off (timedelta) –
- Return type:
None
Methods
__init__
(name, short_description, ...[, ...])create_dummy
()from_dict
(kvs, *[, infer_missing])from_json
(s, *[, parse_float, parse_int, ...])Does this strategy have backtest data available on the file system?
schema
(*[, infer_missing, only, exclude, ...])to_dict
([encode_json])to_json
(*[, skipkeys, ensure_ascii, ...])Attributes
Backtest notebook .html file
Backtest notebook .ipynb file
The previous backtest run results for this strategy.
How many days live data is collected until key metrics are switched from backtest to live trading based
Strategy name
1 sentence
Multiple paragraphs.
For <img src>
When the instance was started last time, UTC
Is the executor main loop running or crashed.
List of smart contracts and related web3 interaction information for this strategy.
- executor_running: bool#
Is the executor main loop running or crashed.
Use /status endpoint to get the full exception info.
Not really a part of metadata, but added here to make frontend queries faster. See also
tradeexecutor.state.executor_state.ExecutorState
.
- on_chain_data: OnChainData#
List of smart contracts and related web3 interaction information for this strategy.
- backtested_state: Optional[State] = None#
The previous backtest run results for this strategy.
Used in the web frontend to display the backtested values.
- key_metrics_backtest_cut_off: timedelta = datetime.timedelta(days=90)#
How many days live data is collected until key metrics are switched from backtest to live trading based
- has_backtest_data()[source]#
Does this strategy have backtest data available on the file system?
- Return type:
- __init__(name, short_description, long_description, icon_url, started_at, executor_running, on_chain_data=<factory>, backtested_state=None, backtest_notebook=None, backtest_html=None, key_metrics_backtest_cut_off=datetime.timedelta(days=90))#
- Parameters:
name (str) –
started_at (datetime) –
executor_running (bool) –
on_chain_data (OnChainData) –
key_metrics_backtest_cut_off (timedelta) –
- Return type:
None