From bd6080b8f5a69e02e73bb5c7e0bdc1c5b3828438 Mon Sep 17 00:00:00 2001 From: "wangwenxi.handsome" Date: Wed, 23 Jun 2021 11:54:05 +0800 Subject: [PATCH] yaml update --- .../ALSTM/workflow_config_alstm_Alpha158.yaml | 36 +++++++++++---- .../ALSTM/workflow_config_alstm_Alpha360.yaml | 38 ++++++++++++---- .../workflow_config_catboost_Alpha158.yaml | 36 +++++++++++---- .../workflow_config_catboost_Alpha360.yaml | 36 +++++++++++---- ...rkflow_config_doubleensemble_Alpha158.yaml | 42 +++++++++++++----- ...rkflow_config_doubleensemble_Alpha360.yaml | 44 ++++++++++++++----- .../GATs/workflow_config_gats_Alpha158.yaml | 38 ++++++++++++---- .../GATs/workflow_config_gats_Alpha360.yaml | 38 ++++++++++++---- .../GRU/workflow_config_gru_Alpha158.yaml | 36 +++++++++++---- .../GRU/workflow_config_gru_Alpha360.yaml | 38 ++++++++++++---- .../LSTM/workflow_config_lstm_Alpha158.yaml | 36 +++++++++++---- .../LSTM/workflow_config_lstm_Alpha360.yaml | 38 ++++++++++++---- .../workflow_config_lightgbm_Alpha158.yaml | 38 ++++++++++++---- .../workflow_config_lightgbm_Alpha360.yaml | 38 ++++++++++++---- ..._config_lightgbm_configurable_dataset.yaml | 38 ++++++++++++---- .../workflow_config_linear_Alpha158.yaml | 44 ++++++++++++++----- .../MLP/workflow_config_mlp_Alpha158.yaml | 38 ++++++++++++---- .../MLP/workflow_config_mlp_Alpha360.yaml | 38 ++++++++++++---- .../SFM/workflow_config_sfm_Alpha360.yaml | 36 +++++++++++---- .../TCTS/workflow_config_tcts_Alpha360.yaml | 38 ++++++++++++---- .../TFT/workflow_config_tft_Alpha158.yaml | 36 +++++++++++---- .../workflow_config_TabNet_Alpha158.yaml | 36 +++++++++++---- .../workflow_config_TabNet_Alpha360.yaml | 36 +++++++++++---- .../workflow_config_xgboost_Alpha158.yaml | 36 +++++++++++---- .../workflow_config_xgboost_Alpha360.yaml | 36 +++++++++++---- 25 files changed, 722 insertions(+), 222 deletions(-) diff --git a/examples/benchmarks/ALSTM/workflow_config_alstm_Alpha158.yaml b/examples/benchmarks/ALSTM/workflow_config_alstm_Alpha158.yaml index 878e3c065..74c69873f 100755 --- a/examples/benchmarks/ALSTM/workflow_config_alstm_Alpha158.yaml +++ b/examples/benchmarks/ALSTM/workflow_config_alstm_Alpha158.yaml @@ -34,19 +34,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: ALSTM @@ -81,13 +96,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/ALSTM/workflow_config_alstm_Alpha360.yaml b/examples/benchmarks/ALSTM/workflow_config_alstm_Alpha360.yaml index 6226cdaf2..95eab9f76 100644 --- a/examples/benchmarks/ALSTM/workflow_config_alstm_Alpha360.yaml +++ b/examples/benchmarks/ALSTM/workflow_config_alstm_Alpha360.yaml @@ -26,19 +26,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: ALSTM @@ -71,13 +86,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/CatBoost/workflow_config_catboost_Alpha158.yaml b/examples/benchmarks/CatBoost/workflow_config_catboost_Alpha158.yaml index af556dc87..72f906f0e 100644 --- a/examples/benchmarks/CatBoost/workflow_config_catboost_Alpha158.yaml +++ b/examples/benchmarks/CatBoost/workflow_config_catboost_Alpha158.yaml @@ -12,19 +12,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: CatBoostModel @@ -53,13 +68,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/CatBoost/workflow_config_catboost_Alpha360.yaml b/examples/benchmarks/CatBoost/workflow_config_catboost_Alpha360.yaml index f7dc26f5d..82e7d8bf2 100644 --- a/examples/benchmarks/CatBoost/workflow_config_catboost_Alpha360.yaml +++ b/examples/benchmarks/CatBoost/workflow_config_catboost_Alpha360.yaml @@ -19,19 +19,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: CatBoostModel @@ -60,13 +75,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/DoubleEnsemble/workflow_config_doubleensemble_Alpha158.yaml b/examples/benchmarks/DoubleEnsemble/workflow_config_doubleensemble_Alpha158.yaml index a12df802d..a18399e9d 100644 --- a/examples/benchmarks/DoubleEnsemble/workflow_config_doubleensemble_Alpha158.yaml +++ b/examples/benchmarks/DoubleEnsemble/workflow_config_doubleensemble_Alpha158.yaml @@ -12,19 +12,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: DEnsembleModel @@ -75,16 +90,21 @@ task: train: [2008-01-01, 2014-12-31] valid: [2015-01-01, 2016-12-31] test: [2017-01-01, 2020-08-01] - record: + record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp - kwargs: + kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp - kwargs: + kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/DoubleEnsemble/workflow_config_doubleensemble_Alpha360.yaml b/examples/benchmarks/DoubleEnsemble/workflow_config_doubleensemble_Alpha360.yaml index 415448f0b..50c908253 100644 --- a/examples/benchmarks/DoubleEnsemble/workflow_config_doubleensemble_Alpha360.yaml +++ b/examples/benchmarks/DoubleEnsemble/workflow_config_doubleensemble_Alpha360.yaml @@ -19,19 +19,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: DEnsembleModel @@ -82,16 +97,21 @@ task: train: [2008-01-01, 2014-12-31] valid: [2015-01-01, 2016-12-31] test: [2017-01-01, 2020-08-01] - record: + record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp - kwargs: + kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp - kwargs: - config: *port_analysis_config \ No newline at end of file + kwargs: + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/GATs/workflow_config_gats_Alpha158.yaml b/examples/benchmarks/GATs/workflow_config_gats_Alpha158.yaml index 71454e7f9..643c73d49 100644 --- a/examples/benchmarks/GATs/workflow_config_gats_Alpha158.yaml +++ b/examples/benchmarks/GATs/workflow_config_gats_Alpha158.yaml @@ -33,19 +33,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: GATs @@ -80,13 +95,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/GATs/workflow_config_gats_Alpha360.yaml b/examples/benchmarks/GATs/workflow_config_gats_Alpha360.yaml index d778c9b1b..fd6051dbe 100644 --- a/examples/benchmarks/GATs/workflow_config_gats_Alpha360.yaml +++ b/examples/benchmarks/GATs/workflow_config_gats_Alpha360.yaml @@ -26,19 +26,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: GATs @@ -72,13 +87,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/GRU/workflow_config_gru_Alpha158.yaml b/examples/benchmarks/GRU/workflow_config_gru_Alpha158.yaml index d3078314c..0418afda2 100755 --- a/examples/benchmarks/GRU/workflow_config_gru_Alpha158.yaml +++ b/examples/benchmarks/GRU/workflow_config_gru_Alpha158.yaml @@ -34,19 +34,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: GRU @@ -80,13 +95,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/GRU/workflow_config_gru_Alpha360.yaml b/examples/benchmarks/GRU/workflow_config_gru_Alpha360.yaml index 2494d40f0..fad0a27e6 100644 --- a/examples/benchmarks/GRU/workflow_config_gru_Alpha360.yaml +++ b/examples/benchmarks/GRU/workflow_config_gru_Alpha360.yaml @@ -26,19 +26,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: GRU @@ -70,13 +85,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/LSTM/workflow_config_lstm_Alpha158.yaml b/examples/benchmarks/LSTM/workflow_config_lstm_Alpha158.yaml index 14dd69d0a..e4b71cd52 100755 --- a/examples/benchmarks/LSTM/workflow_config_lstm_Alpha158.yaml +++ b/examples/benchmarks/LSTM/workflow_config_lstm_Alpha158.yaml @@ -34,19 +34,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: LSTM @@ -80,13 +95,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/LSTM/workflow_config_lstm_Alpha360.yaml b/examples/benchmarks/LSTM/workflow_config_lstm_Alpha360.yaml index 2aa5fd061..4690e9f78 100644 --- a/examples/benchmarks/LSTM/workflow_config_lstm_Alpha360.yaml +++ b/examples/benchmarks/LSTM/workflow_config_lstm_Alpha360.yaml @@ -26,19 +26,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: LSTM @@ -70,13 +85,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/LightGBM/workflow_config_lightgbm_Alpha158.yaml b/examples/benchmarks/LightGBM/workflow_config_lightgbm_Alpha158.yaml index 88202be1b..38fa6a043 100644 --- a/examples/benchmarks/LightGBM/workflow_config_lightgbm_Alpha158.yaml +++ b/examples/benchmarks/LightGBM/workflow_config_lightgbm_Alpha158.yaml @@ -12,19 +12,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: LGBModel @@ -54,13 +69,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/LightGBM/workflow_config_lightgbm_Alpha360.yaml b/examples/benchmarks/LightGBM/workflow_config_lightgbm_Alpha360.yaml index 92df15133..f5b94ce1b 100644 --- a/examples/benchmarks/LightGBM/workflow_config_lightgbm_Alpha360.yaml +++ b/examples/benchmarks/LightGBM/workflow_config_lightgbm_Alpha360.yaml @@ -19,19 +19,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: LGBModel @@ -61,13 +76,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/LightGBM/workflow_config_lightgbm_configurable_dataset.yaml b/examples/benchmarks/LightGBM/workflow_config_lightgbm_configurable_dataset.yaml index 335dc2093..4454f884e 100644 --- a/examples/benchmarks/LightGBM/workflow_config_lightgbm_configurable_dataset.yaml +++ b/examples/benchmarks/LightGBM/workflow_config_lightgbm_configurable_dataset.yaml @@ -27,19 +27,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: LGBModel @@ -69,13 +84,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/Linear/workflow_config_linear_Alpha158.yaml b/examples/benchmarks/Linear/workflow_config_linear_Alpha158.yaml index ef2fee4c5..179538149 100644 --- a/examples/benchmarks/Linear/workflow_config_linear_Alpha158.yaml +++ b/examples/benchmarks/Linear/workflow_config_linear_Alpha158.yaml @@ -26,19 +26,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: LinearModel @@ -57,16 +72,21 @@ task: train: [2008-01-01, 2014-12-31] valid: [2015-01-01, 2016-12-31] test: [2017-01-01, 2020-08-01] - record: + record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp - kwargs: - ana_long_short: True + kwargs: + ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp - kwargs: + kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/MLP/workflow_config_mlp_Alpha158.yaml b/examples/benchmarks/MLP/workflow_config_mlp_Alpha158.yaml index b177a810b..befd4b62c 100644 --- a/examples/benchmarks/MLP/workflow_config_mlp_Alpha158.yaml +++ b/examples/benchmarks/MLP/workflow_config_mlp_Alpha158.yaml @@ -39,19 +39,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: DNNModelPytorch @@ -83,13 +98,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/MLP/workflow_config_mlp_Alpha360.yaml b/examples/benchmarks/MLP/workflow_config_mlp_Alpha360.yaml index 18920399f..cc0e9a62c 100644 --- a/examples/benchmarks/MLP/workflow_config_mlp_Alpha360.yaml +++ b/examples/benchmarks/MLP/workflow_config_mlp_Alpha360.yaml @@ -27,19 +27,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: DNNModelPytorch @@ -70,13 +85,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/SFM/workflow_config_sfm_Alpha360.yaml b/examples/benchmarks/SFM/workflow_config_sfm_Alpha360.yaml index a23fe3854..885eddebf 100644 --- a/examples/benchmarks/SFM/workflow_config_sfm_Alpha360.yaml +++ b/examples/benchmarks/SFM/workflow_config_sfm_Alpha360.yaml @@ -26,19 +26,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: SFM @@ -73,13 +88,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/TCTS/workflow_config_tcts_Alpha360.yaml b/examples/benchmarks/TCTS/workflow_config_tcts_Alpha360.yaml index 589f4b43e..9e97ad874 100644 --- a/examples/benchmarks/TCTS/workflow_config_tcts_Alpha360.yaml +++ b/examples/benchmarks/TCTS/workflow_config_tcts_Alpha360.yaml @@ -30,19 +30,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: TCTS @@ -81,13 +96,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: - config: *port_analysis_config \ No newline at end of file + config: *port_analysis_config + risk_analysis_freq: day \ No newline at end of file diff --git a/examples/benchmarks/TFT/workflow_config_tft_Alpha158.yaml b/examples/benchmarks/TFT/workflow_config_tft_Alpha158.yaml index dba37ab63..92b64cfbf 100644 --- a/examples/benchmarks/TFT/workflow_config_tft_Alpha158.yaml +++ b/examples/benchmarks/TFT/workflow_config_tft_Alpha158.yaml @@ -14,19 +14,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: TFTModel @@ -46,13 +61,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/TabNet/workflow_config_TabNet_Alpha158.yaml b/examples/benchmarks/TabNet/workflow_config_TabNet_Alpha158.yaml index cf8ef7411..c8ebaf8fb 100644 --- a/examples/benchmarks/TabNet/workflow_config_TabNet_Alpha158.yaml +++ b/examples/benchmarks/TabNet/workflow_config_TabNet_Alpha158.yaml @@ -26,19 +26,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: TabnetModel @@ -63,13 +78,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/TabNet/workflow_config_TabNet_Alpha360.yaml b/examples/benchmarks/TabNet/workflow_config_TabNet_Alpha360.yaml index 5023e9b3d..fffdfcad1 100644 --- a/examples/benchmarks/TabNet/workflow_config_TabNet_Alpha360.yaml +++ b/examples/benchmarks/TabNet/workflow_config_TabNet_Alpha360.yaml @@ -26,19 +26,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: TabnetModel @@ -63,13 +78,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/XGBoost/workflow_config_xgboost_Alpha158.yaml b/examples/benchmarks/XGBoost/workflow_config_xgboost_Alpha158.yaml index 4caaa6f62..6d6762027 100644 --- a/examples/benchmarks/XGBoost/workflow_config_xgboost_Alpha158.yaml +++ b/examples/benchmarks/XGBoost/workflow_config_xgboost_Alpha158.yaml @@ -12,19 +12,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: XGBModel @@ -52,13 +67,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day diff --git a/examples/benchmarks/XGBoost/workflow_config_xgboost_Alpha360.yaml b/examples/benchmarks/XGBoost/workflow_config_xgboost_Alpha360.yaml index 7887a25a6..ed8e8c495 100644 --- a/examples/benchmarks/XGBoost/workflow_config_xgboost_Alpha360.yaml +++ b/examples/benchmarks/XGBoost/workflow_config_xgboost_Alpha360.yaml @@ -19,19 +19,34 @@ data_handler_config: &data_handler_config port_analysis_config: &port_analysis_config strategy: class: TopkDropoutStrategy - module_path: qlib.contrib.strategy.strategy + module_path: qlib.contrib.strategy kwargs: + model: + dataset: topk: 50 n_drop: 5 backtest: - verbose: False - limit_threshold: 0.095 + start_time: 2017-01-01 + end_time: 2020-08-01 account: 100000000 benchmark: *benchmark - deal_price: close - open_cost: 0.0005 - close_cost: 0.0015 - min_cost: 5 + executor: + class: NestedExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: week + inner_executor: + class: SimulatorExecutor + module_path: qlib.backtest.executor + kwargs: + time_per_step: day + generate_report: True + verbose: True + inner_strategy: + class: TWAPStrategy + module_path: qlib.contrib.strategy.rule_strategy + track_data: True + generate_report: True task: model: class: XGBModel @@ -59,13 +74,18 @@ task: record: - class: SignalRecord module_path: qlib.workflow.record_temp - kwargs: {} + kwargs: + model: + dataset: - class: SigAnaRecord module_path: qlib.workflow.record_temp kwargs: ana_long_short: False ann_scaler: 252 + model: + dataset: - class: PortAnaRecord module_path: qlib.workflow.record_temp kwargs: config: *port_analysis_config + risk_analysis_freq: day