akquant 0.3.83__tar.gz → 0.3.85__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {akquant-0.3.83 → akquant-0.3.85}/CHANGELOG.md +21 -0
- {akquant-0.3.83 → akquant-0.3.85}/Cargo.lock +1 -1
- {akquant-0.3.83 → akquant-0.3.85}/Cargo.toml +1 -1
- {akquant-0.3.83 → akquant-0.3.85}/PKG-INFO +1 -1
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/strategy.md +50 -25
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/reference/api.md +3 -1
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/strategy.md +51 -25
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/meta/columnar-rfc.md +1 -1
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/reference/api.md +3 -1
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/06_stock_momentum_rotation_bucket.py +15 -20
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/README.md +6 -6
- {akquant-0.3.83 → akquant-0.3.85}/pyproject.toml +1 -1
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/__init__.py +4 -1
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/backtest/__init__.pyi +2 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/backtest/engine.py +12 -0
- akquant-0.3.85/python/akquant/bar_batch.py +364 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/_facade.py +2 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/_runner.py +6 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/guides/indicators.md +1 -1
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/guides/strategy-skeleton.md +1 -1
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy.py +35 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_events.py +21 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_trading_api.py +6 -1
- {akquant-0.3.83 → akquant-0.3.85}/server.json +3 -3
- {akquant-0.3.83 → akquant-0.3.85}/src/engine/core.rs +72 -14
- {akquant-0.3.83 → akquant-0.3.85}/src/engine/python.rs +4 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/order_ledger.rs +89 -12
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/stages/channel.rs +149 -1
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/stages/strategy.rs +6 -10
- {akquant-0.3.83 → akquant-0.3.85}/tests/fixtures/order_event_traces.json +596 -414
- akquant-0.3.85/tests/test_cancel_same_cycle.py +354 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_public_api.py +3 -3
- akquant-0.3.85/tests/test_on_bars.py +668 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_event_timing.py +39 -1
- {akquant-0.3.83 → akquant-0.3.85}/.github/ISSUE_TEMPLATE/bug_report.yml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/.github/ISSUE_TEMPLATE/config.yml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/.github/ISSUE_TEMPLATE/feature_request.yml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/.github/dependabot.yml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/.github/workflows/deploy-docs.yml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/.github/workflows/docs-quality.yml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/.github/workflows/release.yml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/.gitignore +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/.pre-commit-config.yaml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/CODE_OF_CONDUCT.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/CONTRIBUTING.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/LICENSE +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/README.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/assets/dashboard_preview.png +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/assets/logo.svg +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/assets/social_preview.png +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/CNAME +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/assets/akquant-icon.svg +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/assets/akquant-logo.svg +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/assets/reports/akquant_report.html +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/analyzer_plugin_spec.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/broker_capability_matrix.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/custom_broker_production_checklist.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/custom_broker_registry.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/custom_strategy_loader.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/data_feed_adapter_spec.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/live_functional_quickstart.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/llm.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/ml.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/multi_strategy_guide.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/multi_timeframe_feed_api.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/runtime_config.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/signal_ingestion.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/strategy_style_decision.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/tick_size_alignment.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/timezone.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/advanced/warm_start.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/analysis.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/cross_section_checklist.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/custom_indicator.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/data.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/examples.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/factor.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/indicator_scenario_quickref.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/mcp.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/optimization.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/python_basics.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/quant_basics.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/rust_indicator_reference.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/talib_indicator_playbook.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/testing.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/guide/visualization.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/index.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/meta/architecture.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/meta/internals.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/start/first_strategy.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/start/installation.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/start/quickstart.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/start/setup_guide.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/01_foundations.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/02_programming.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/03_data.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/04_backtest_engine.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/05_strategy.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/06_stock_a.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/07_futures.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/08_options.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/09_funds.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/10_analysis.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/11_optimization.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/12_ml.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/13_visualization.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/14_factor.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/15_live_trading.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/16_rust_indicators.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/en/textbook/index.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/javascripts/mathjax.js +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/javascripts/search-lang-filter.js +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/llms.txt +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/robots.txt +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/adding_a_broker.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/analyzer_plugin_spec.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/broker_capability_matrix.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/custom_broker_production_checklist.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/custom_broker_registry.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/custom_strategy_loader.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/data_feed_adapter_spec.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/live_functional_quickstart.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/llm.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/ml.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/multi_strategy_guide.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/multi_timeframe_feed_api.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/runtime_config.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/signal_ingestion.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/strategy_style_decision.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/tick_size_alignment.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/timezone.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/advanced/warm_start.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/analysis.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/cross_section_checklist.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/custom_indicator.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/data.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/examples.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/factor.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/indicator_scenario_quickref.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/mcp.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/optimization.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/python_basics.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/quant_basics.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/rust_indicator_reference.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/talib_indicator_playbook.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/testing.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/guide/visualization.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/index.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/meta/architecture.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/meta/internals.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/start/first_strategy.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/start/installation.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/start/quickstart.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/start/setup_guide.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/00_glossary.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/01_foundations.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/02_programming.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/03_data.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/04_backtest_engine.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/05_strategy.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/06_stock_a.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/07_futures.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/08_options.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/09_funds.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/10_analysis.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/11_optimization.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/12_ml.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/13_visualization.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/14_factor.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/15_live_trading.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/16_rust_indicators.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/ROADMAP.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/appendix_cite.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/appendix_pitfalls.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/appendix_setup.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/capstone.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/docs/zh/textbook/index.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/01_quickstart.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/02_parameter_optimization.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/03_parameter_optimization_advanced.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/04_mixed_assets.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/05_live_trading_ctp.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/06_complex_orders.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/07_option_test.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/08_event_callbacks.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/09_ml_framework.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/10_ml_walk_forward.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/11_plot_visualization.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/12_wfo_integrated.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/13_quantstats_report.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/14_multi_frequency.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/15_plot_intraday.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/16_adj_returns_signal.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/17_readme_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/18_benchmark_multisymbol.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/19_factor_expression.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/20_risk_management_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/21_warm_start_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/22_strategy_runtime_config_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/23_functional_callbacks_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/24_functional_tick_simulation_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/25_streaming_backtest_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/26_streaming_quickstart.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/27_streaming_monitoring_console.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/28_streaming_alerts_and_persist.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/29_streaming_event_report.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/30_streaming_report_oneclick.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/31_streaming_live_console.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/32_streaming_live_web.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/33_report_and_analysis_outputs.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/34_multi_strategy_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/35_custom_broker_registry_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/36_trailing_orders.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/37_feed_replay_alignment_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/38_live_functional_strategy_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/39_live_broker_submit_order_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/39_live_mixed_broker_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/40_functional_multi_slot_risk_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/41_live_multi_slot_orchestration_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/42_live_broker_event_audit_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/43_target_weights_rebalance.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/44_strategy_source_loader_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/45_talib_indicator_playbook_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/46_broker_profile_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/47_margin_liquidation_audit_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/48_margin_liquidation_priority_compare.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/49_on_expiry_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/50_framework_hooks_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/51_class_tick_callbacks_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/52_pre_open_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/53_timer_to_pre_open_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/54_functional_pre_open_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/55_functional_ml_walk_forward.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/56_functional_warm_start_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/57_functional_multi_slot_warm_start_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/58_incremental_bootstrap_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/59_akshare_etf_rotation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/60_custom_indicator_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/61_indicator_visualization_export_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/61_signal_platform_webhook.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/62_indicator_streaming_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/63_indicator_ws_bridge_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/64_indicator_live_web.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/65_bar_generator.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/66_logging_audit_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/67_lwc_trade_review.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/68_backtest_tick_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/69_live_runtime_config_dispatch_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/70_csv_multi_symbol_import_demo.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/71_native_multi_timeframe_live.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/72_declarative_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/73_lwc_live_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/74_indicator_scripts.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/75_intrabar_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/76_tick_intrabar_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/77_heikin_ashi_indicator.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/78_chart_drawings.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/79_multi_symbol_indicator_timer.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/README.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/benchmark_utils.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/pb_mock.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/01_stock_dual_moving_average.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/02_stock_grid_trading.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/03_stock_atr_breakout.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/04_stock_momentum_rotation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/05_stock_momentum_rotation_timer.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/07_stock_momentum_rotation_on_timer.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/08_target_positions_long_short.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/strategies/09_stock_momentum_rotation_after_bar.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch01_quickstart.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch01_quickstart_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch02_programming.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch03_data.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch04_comparison.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch04_comparison_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch05_strategy.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch05_strategy_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch06_stock_a.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch06_stock_a_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch07_futures.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch07_futures_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch08_options.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch08_options_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch09_funds.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch09_funds_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch09_portfolio.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch09_portfolio_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch10_analysis.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch10_analysis_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch11_optimization.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch11_optimization_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch12_ml.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch12_ml_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch13_visualization.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch13_visualization_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch14_factor.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch15_live_trading.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch15_live_trading_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch15_strategy_loader.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch15_strategy_loader_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch16_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/examples/textbook/ch16_indicators_functional.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/mkdocs.yml +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/akquant.pyi +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/analysis/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/analysis/benchmark.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/analyzer_plugin.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/backtest/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/backtest/_viz.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/backtest/fill_mode.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/backtest/merge.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/backtest/result.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/backtest/tick_input.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/bar_generator.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/chart/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/chart/_drawing.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/chart/_normalize.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/chart/d3kline.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/checkpoint.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/cli.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/config.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/data.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/execution/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/execution/base.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/execution/sim.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/factor/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/factor/engine.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/factor/ops.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/factor/parser.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/feed_adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/fund/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/futures/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/base.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_event_adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_event_bridge.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_event_mapper.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_execution.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_models.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_recovery.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_runtime.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_state_cache.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_stats.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/broker_strategy_api.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/builtins.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/ctp/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/ctp/adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/ctp/native.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/miniqmt/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/miniqmt/stub.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/plugins.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/ptrade/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/ptrade/stub.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/replay/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/brokers/replay/gateway.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/ctp_adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/ctp_native.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/factory.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/local_stop_book.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/mapper.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/miniqmt.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/models.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/order_audit.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/order_errors.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/order_receipt.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/order_submitter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/protocols.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/ptrade.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/registry.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/symbol_match.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/gateway/trader_base.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/indicator_declaration.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/indicator_identity.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/indicator_recording.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/indicator_script.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/indicator_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/_gateway_setup.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/_paper_execution.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/_payload_utils.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/_preload.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/_strategy_maps.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/live/_stream_sink.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/log.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/_drawings.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/_payload.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/_template.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/assets/LICENSE.lightweight-charts +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/assets/NOTICE.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/assets/lightweight-charts.standalone.production.js +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/lwc/review.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/__main__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/guides/data-format.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/guides/market-rules.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/guides/orders-and-positions.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/server.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/api_index.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/check.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/data.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/errors.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/guides.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/paths.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/records.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/service/runs.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/mcp/worker.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/ml/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/ml/model.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/normalize.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/optimize.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/option/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/params.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/params_adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/plot/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/plot/_market_data.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/plot/analysis.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/plot/dashboard.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/plot/indicator.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/plot/report.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/plot/strategy.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/plot/utils.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/precomputed.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/py.typed +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/risk.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/schema.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/sessions_config.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/dedup.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/dispatcher.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/models.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/protocols.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/registry.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/security.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/sinks.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/sources/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/sources/http.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/sources/queue.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/signal/sources/redis_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/sizer.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/stock/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_drawing.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_framework_hooks.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_history.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_inspect.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_loader.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_logging.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_ml.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_order_events.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_position.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_preload.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_runtime_config.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_scheduler.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_stats.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_time.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/strategy_window.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/stream_schema.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/talib/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/talib/_kernels.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/talib/backend.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/talib/core.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/talib/funcs.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/talib/lookback.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/trade_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/utils/__init__.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/utils/inspector.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/python/akquant/utils/price.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/requirements-dev.txt +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/bench_engine_perbar.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/cargo-test.sh +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/check_docs_api_examples.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/check_docs_links.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/check_release.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/dev-check.sh +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/golden_baseline_report.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/profile_backtest.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/scripts/stress_out_of_core.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/account.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/excursion_tests.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/live_stats.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/python.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/result.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/strategy_stats.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/tests.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/tracker.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/analysis/types.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/bin/stub_gen.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/calendar/clock.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/calendar/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/calendar/python.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/calendar/resolver.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/calendar/schedule.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/calendar/trading_calendar.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/clock.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/context.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/aggregator.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/batch.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/client.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/columns.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/compute.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/feed.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/parquet_stream.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/python_window.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/data/window.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/engine/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/engine/state.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/engine/strategy_handler.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/error.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/event.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/event_manager.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/common.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/crypto.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/forex.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/futures.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/matcher.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/option.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/python.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/realtime.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/simulated.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/slippage.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/stock.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/execution/validation.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/history.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/momentum.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/momentum_oscillators.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/momentum_rates.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/moving_average.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/moving_average_compound.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/moving_average_core.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/moving_average_hilbert.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/moving_average_transforms.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/moving_average_windowed.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/trend.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/trend_directional.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/trend_oscillators.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/trend_regression.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/volatility.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/volatility_candle.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/volatility_price.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/volatility_stats.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators/volume.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/indicators.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/lib.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/log_context.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/margin/calculator.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/margin/engine.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/margin/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/china.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/core.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/corporate_action.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/fee_override.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/fund.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/futures.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/manager.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/option.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/simple.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/market/stock.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/model/corporate_action.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/model/instrument.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/model/market_data.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/model/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/model/order.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/model/timer.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/model/types.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/order_manager.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/processor.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/runner.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/stages/cleanup.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/stages/data.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/stages/execution.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/stages/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/stages/shared.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/pipeline/stages/statistics.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/portfolio.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/common.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/config.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/futures.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/manager.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/option.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/portfolio.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/rule.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/stock.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/risk/strategy_limits.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/settlement/expiry.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/settlement/handler.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/settlement/manager.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/settlement/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/settlement/option.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/signal_port.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/src/statistics/mod.rs +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/_checkpoint_0371.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/_mock_ctx.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/_order_event_scenarios.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/_plot_cases.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/fixtures/checkpoint_0371_minute.pkl +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/gateway_contract/test_event_bridge_contract.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/gateway_contract/test_recovery_contract.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/gateway_contract/test_submitter_contract.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/BASELINE_REPORT.md +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_margin/equity_curve.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_margin/metrics.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_margin/orders.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_margin/trading_day_ends.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_night_weekend/equity_curve.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_night_weekend/metrics.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_night_weekend/orders.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_night_weekend/trades.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/futures_night_weekend/trading_day_ends.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/option_basic/equity_curve.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/option_basic/metrics.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/option_basic/orders.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/option_basic/trading_day_ends.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/order_cancel/equity_curve.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/order_cancel/metrics.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/order_cancel/orders.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/order_cancel/trades.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/order_cancel/trading_day_ends.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_minute_auction/equity_curve.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_minute_auction/metrics.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_minute_auction/orders.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_minute_auction/trades.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_minute_auction/trading_day_ends.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_t1/equity_curve.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_t1/metrics.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_t1/orders.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_t1/trades.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/baselines/stock_t1/trading_day_ends.json +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/future_margin.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/future_margin.parquet.sha256 +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/futures_night_weekend.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/futures_night_weekend.parquet.sha256 +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/option_basic.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/option_basic.parquet.sha256 +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/order_cancel.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/order_cancel.parquet.sha256 +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/stock_minute_auction.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/stock_minute_auction.parquet.sha256 +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/stock_t1.parquet +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/data/stock_t1.parquet.sha256 +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/gen_data.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/runner.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/strategies/futures_margin.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/strategies/futures_night_weekend.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/strategies/option_basic.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/strategies/order_cancel.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/strategies/stock_minute_auction.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/strategies/stock_t1.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/golden/test_golden.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/conftest.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_cli.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_api_index.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_check.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_data.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_errors.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_guides.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_main.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_paths.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_records.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_runs.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/mcp_server/test_mcp_server.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_account_risk_rules.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_api_rename_cash.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_api_rename_composites.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_api_rename_equity.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_api_rename_holding_bars.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_api_rename_positions.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_api_rename_rebalance.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_api_rename_scheduler.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_backtest_fund_fee_rules.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_backtest_params.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_backtest_symbol_column_aliases.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_backtest_tick_aggregate.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_backtest_tick_entry.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_backtest_tick_history.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_bar_aggregator_live.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_bar_generator.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_bar_hook_bookkeeping_invariants.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_bench_noise_gate.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_boundary_bar_fill.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_bridge_adapts_events.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_bridge_drives_order_groups.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_dropped_counts_periodic_summary.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_event_adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_event_adapter_local_id.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_event_symbol_filter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_event_task_isolation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_execution_local_stops.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_execution_read_path_parity.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_execution_stop_requeue.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_live_risk_enforcement.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_order_redelivery_dedup.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_plugins.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_position_sync.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_profile_cn_stock.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_recovery_cadence.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_recovery_error_visibility.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_seed_baseline.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_trade_redelivery_dedup.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_broker_trade_stats.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_buying_power_new_symbol.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_cancel_request_persistence.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_candle_exporters.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_candle_render_type.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_chart_d3kline.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_chart_drawing_normalize.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_chart_normalize.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_check_release.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_checkpoint_0371_compat.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_checkpoint_option_rules.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_close_position_delegate.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_composed_ctx_not_ready.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_cost_config_consolidation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_cross_section_day_order_next_open_fill.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_ctp_classify_order_error.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_custom_matcher.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_data_catalog.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_date_only_rewrite_cache.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_day_order_expiry_no_zombie_fill.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_deterministic_order.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_docs_api_examples.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_docs_links.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_drawing_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_dual_stream_freq_inference.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_engine.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_engine_python_crossings.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_event_model_parity.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_examples_regression.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_execution_binding.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_execution_broker.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_execution_broker_reads_routed.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_execution_composed_parity.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_execution_read_delegation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_execution_sim.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_execution_write_delegation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_expiry_terminal_dispatch.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_expiry_trade_accounting.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_factor_engine.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_factor_ops.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_feed_adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_fetch_akshare_symbol.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_fill_mode.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_broker_live_cancel.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_broker_live_reads.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_broker_models_ext.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_broker_state_cache.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_broker_state_invalidation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_broker_submitter_quantity.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_broker_submitter_readiness.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_broker_submitter_signature.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_brokers_paths.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_builtins_registry.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_callbacks.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_cancel_failure.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_ctp_adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_ctp_dual_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_ctp_native.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_expired_order_status.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_factory.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_mapper.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_mixed_market_trader.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_optional_market.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_order_error_classification.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_order_submitter_extra.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_order_tick_reject_soft.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_order_tick_validation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_place_order_failure.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_registry.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_sim_submit_guard.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_symbol_match.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_tif_mapping.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_gateway_trader_base.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_get_order_finalized.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_grid_search_all_failed.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_heikin_ashi.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_history_depth_after_start.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_history_lookback_autogrow.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_hooks_functional_wrapper.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_hooks_inherited_via_base.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_declaration.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_declaration_review.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_dual_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_duplicate_name.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_intrabar.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_live_web_example.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_multi_symbol_access.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_non_finite.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_owner_identity.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_recording.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_indicator_script.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_inspector.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_instrument_default_tick.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_instrument_fee_override.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_instrument_slippage.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_instrument_symbol_suffix_normalization.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_instruments_config_symbol_mismatch.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_lifecycle_hooks.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_lifecycle_review_fixes.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_auto_preload.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_broker_slot_routing.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_duration_wallclock.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_freq_injection.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_market_config_by_asset_type.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_mixed_market_broker.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_multi_slot_windows.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_paper_execution_params.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_preload_normalize.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_preload_runner.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_bounded_session.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_broker_bridge.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_broker_readiness.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_broker_recovery.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_broker_submitter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_client_order_id.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_instrument_snapshots.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_lifecycle.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_no_market_data_warning.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_order_request_cache.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_sigterm_stop.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runner_stop_remap.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_runtime_config_dispatch.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_subscribe_forwards_to_gateway.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_live_summary_stop_reason.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_local_stop_book.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_local_stop_book_threadsafe.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_local_stop_scenario.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_log_sensitive_filter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_lwc_drawings.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_lwc_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_lwc_review.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_merge_results.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_ml_rolling_training_threshold.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_multi_slot_ownership.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_multisymbol_cross_section_consistency.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_naive_timezone.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_normalize.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_oco_bracket_broker_live_scenario.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_on_execution_report_noop.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_on_timer_suspension_deadlock.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_optimize_functional_params.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_optimize_params.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_option_expiry_settlement.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_option_fees.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_option_market_side_effects.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_api_return_values.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_audit.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_callback_dedupe.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_event_traces.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_ledger_binding.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_receipt.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_receipt_backtest.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_order_target_lot_size_alignment.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_orders_df.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_params.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_params_adapter.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_parquet_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_partial_filled_status.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_pickle_model_objects.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_plot_defaults.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_portfolio.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_position_effect_flip.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_pre_open_live_warns.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_product_presets.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_quickstart_stream_consistency.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_reduce_only_sell_affordability.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_removed_wrappers.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_replay_live_end_to_end.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_replay_market_gateway.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_report_helpers.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_report_plot_extensions.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_result_analysis_extensions.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_review_minors_cleanup.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_run_live_indicator_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_session_config.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_session_matching.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_session_resolver.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_signal_module.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_signal_port_injection.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_signal_sources_p3.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_sizer_auto_resize.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_slippage_bare_number.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_sort_determinism.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_source_trading_day.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_stock_tick_validation.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_stop_id_remap_scenario.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_stop_orders.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_stop_retry_client_order_id.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_custom_init_params.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_drawing.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_events_stop_hook.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_extras.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_freq_attribute.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_history_dual_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_history_missing_symbol_warning.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_inspect.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_loader_candidates.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_loader_exports.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_loader_pickle.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_loader_plugins.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_loader_reload.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_ml_dual_stream.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_order_group_lock.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_params.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_session_api.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_sizing_broker_live_guard.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_stats.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_stats_parity.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_strategy_timers_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_stream_series_key.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_subscribe_live_warns.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_suspension_zero_volume_gtc_terminal.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_symbols_filtering.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_symbols_whitelist_rust.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_t_plus_one.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_talib_alignment.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_talib_backend.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_talib_compat.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_target_orders_core.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_tick_indicators.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_tick_input.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_trade_stream_bridge.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_trades_df.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_trading_day_lifecycle.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_utils_price.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_vectorized.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_version.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_viz_namespace.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_volume_limit.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_walk_forward_kwargs.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_warm_start_slippage_inherit.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_warmup_period_per_symbol.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_window_checkpoint.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_window_live_replay.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_window_sessions.py +0 -0
- {akquant-0.3.83 → akquant-0.3.85}/tests/test_window_subscriptions.py +0 -0
|
@@ -7,6 +7,27 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.3.85] - 2026-11-11
|
|
11
|
+
|
|
12
|
+
> 规则版本不变(2.3.1):回测结果不受影响。实盘重写了 `on_cross_section` 的策略,该钩子现在会被调用(此前从不触发)。
|
|
13
|
+
|
|
14
|
+
### Added
|
|
15
|
+
- **`on_bars(batch)`:同一时间片的 bar 到齐后回调一次**(#441,实验性):多标的策略要在每根 bar 上对全部标的统一打分、调仓时,重写 `Strategy.on_bars(batch)`(函数式:`run_backtest(..., on_bars=fn)` / `run_live(..., on_bars=fn)`)。`batch` 是新增的 `akquant.BarBatch`:`batch.bars` 按标的升序,`batch["600000"]` / `batch.get(...)` 按标的取,`batch.missing` 是此前出现过、本片没有 bar 的标的,`batch.flush_reason` 是派发原因。回测(及 `broker="replay"`)在时间片结束、下一片开始之前触发,缺 bar 的时间片与最后一片都触发,其中下的单与在本片最后一根 `on_bar` 里下单同一口径。实盘在此前见过的标的全部到齐时触发,否则等到时间片时刻 + `bars_deadline_seconds`(策略类属性,默认 5 秒,须大于行情源的补发延迟);截止后才到的 bar 只触发 `on_bar`。`on_bar` 不变,两者可同时重写(先逐根 `on_bar`,再 `on_bars`);不重写 `on_bars` 的策略行为与结果不变。
|
|
16
|
+
|
|
17
|
+
### Fixed
|
|
18
|
+
- **实盘里 `on_cross_section` 从不触发**:它的触发时刻原先由回测数据预先算出,实盘(`run_live`,含 `broker="replay"`)没有这一步,重写了该钩子也不会被调用,且没有任何提示。现在实盘按 bar 的到达情况判断:此前见过的标的当日都已出现过 bar 的首个时间片派发后触发,每个交易日一次(到齐即触发,否则等 `bars_deadline_seconds`);当日尚未出现的标的此刻不在交易时段(如没有夜盘的品种)则继续等,在交易时段却没有 bar 的按停牌处理、不等。回测不变。
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
- **文档与示例不再教“在 `on_bar` 里攒满全部标的再执行”**:这种写法只要有一个标的停牌或缺 bar,那一片就凑不齐、整片不触发且没有任何提示。策略指南 3.5 节与 `examples/strategies/06_stock_momentum_rotation_bucket.py` 改用 `on_bars`。
|
|
22
|
+
|
|
23
|
+
## [0.3.84] - 2026-11-09
|
|
24
|
+
|
|
25
|
+
> **规则版本 2.3.1**:同一次回调里下单后又撤掉这张单的策略,回测结果会变(此前撤单被忽略、订单照常成交);带在途订单存档续跑的策略,续跑段的订单回调不再重复。
|
|
26
|
+
|
|
27
|
+
### Fixed
|
|
28
|
+
- **同一次回调里撤掉刚下的单,撤单被忽略、订单照常成交**(#440):在下单的同一次回调里撤这张单——包括在该单的 `on_order(New)` 回调里撤、或在同一个 `on_bar` / `on_timer` / 窗口 bar 回调里下单后立即 `cancel_order`——此前引擎还没登记这张单,撤单被当成未知订单忽略(日志里一条 `Ignored cancel request for unknown order`),订单之后照常成交;而 `get_order` 一直显示 Cancelled(成交后也是)、`get_open_orders` 也不再列出它,账面与实际不符。现在这类撤单会在订单进入引擎时立即执行(撮合之前,含当根收盘成交的设置),策略收到 `on_order(Cancelled)`,订单不会成交;被风控拒掉的单不再多出那条告警;撤一个根本不存在的订单号仍照旧告警。实盘 paper / replay 同样修复,经柜台的实盘不受影响。另外,`get_order` 不再把已成交、已拒等已结束的单显示为已撤。
|
|
29
|
+
- **存档续跑后,订单在终态之后又收到一次旧状态的 `on_order`**:带在途订单存档、续跑时,续跑段里状态有变化的订单可能在终态之后又收到一次旧状态的 `on_order`(如 Cancelled 之后又来一次 New)。现在存档会保存已通知过的订单状态(以及已触发过 `on_reject` 的订单),续跑后不再重复通知。0.3.83 的存档照常可读。
|
|
30
|
+
|
|
10
31
|
## [0.3.83] - 2026-11-08
|
|
11
32
|
|
|
12
33
|
> **规则版本 2.3.0**:持仓超过历史深度的交易,`trades_df` 里的 `mae`、`mfe`、`max_drawdown_pct` 会变成正确值(此前被截断,常见结果是 0),成交、盈亏、权益与各项收益指标不变;取历史 `count` 超过保留长度、或指标回看超出 `lookback` 的策略,此前拿到的是残缺数据,现在自动加长后结果会变。
|
|
@@ -50,6 +50,7 @@ A strategy goes through the following stages from start to finish:
|
|
|
50
50
|
| `on_reject` | First time an order becomes `Rejected` | Log reject reasons, alerting, graceful degradation | `examples/50_framework_hooks_demo.py` |
|
|
51
51
|
| `on_before_trading` | 1ns after the trading day's earliest continuous-auction segment starts (A-shares 09:30; for futures with a night session the trading day starts with the previous trading day's night session, so Monday's trading day fires on Friday at 21:00) | Pre-market checks, trading-date level signal preparation | `examples/50_framework_hooks_demo.py` |
|
|
52
52
|
| `on_pre_open` | 1ns before the trading day's first session segment starts (A-shares before the 09:15 opening call auction; futures with a night session before the previous trading day's 20:55 night auction), never earlier than the previous trading day's end-of-day settlement; same timing in backtest and live | Auction/pre-open signal generation; default `NextOpen()` orders join the opening call-auction match, which is not the same as broker counter support for auction-specific order types | `examples/52_pre_open_demo.py` |
|
|
53
|
+
| `on_bars` | After all bars of a time slice have arrived (backtest: when the slice ends; live: complete or deadline) | Score and rebalance all symbols on every bar | `examples/strategies/06_stock_momentum_rotation_bucket.py` |
|
|
53
54
|
| `on_cross_section` | After the first complete cross-symbol bar slice of the trading day | Cross-sectional same-cycle rebalance using current-day bars/account state | `examples/strategies/09_stock_momentum_rotation_after_bar.py` |
|
|
54
55
|
| `on_after_trading` | After end-of-day settlement completes (backtest: at the close; live: close + `day_close_delay`) | End-of-day summaries, post-close cleanup, archiving | `examples/50_framework_hooks_demo.py` |
|
|
55
56
|
| `on_portfolio_update` | Incrementally when portfolio snapshot changes | Monitor cash/equity changes, push UI or alerts | `examples/50_framework_hooks_demo.py` |
|
|
@@ -80,6 +81,7 @@ Notes:
|
|
|
80
81
|
* `on_before_trading` fires 1ns after the trading day's earliest continuous-auction segment starts (just after 09:30:00 for A-shares); for night-session symbols the trading day starts with the previous trading day's night session, so Monday's trading day fires on Friday at 21:00. A trading day without a continuous-auction segment does not fire it.
|
|
81
82
|
* `on_before_trading` always use a "previous trading day / previous snapshot only" visibility model; inside these callbacks, `get_history()`, `get_account()`, and `equity` must not expose the current day's new bar or the current day's updated account view.
|
|
82
83
|
* `on_cross_section` runs after the framework has seen the first complete cross-symbol slice for the trading day; inside this callback, current-day history and the current account snapshot are visible.
|
|
84
|
+
* Live sessions (including `broker="replay"`) do not know the day's data in advance, so `on_cross_section` is decided by arrival: it fires after the first dispatched time slice in which every previously seen symbol has had a bar that day (immediately when complete, otherwise after `bars_deadline_seconds`, default 5 s). A symbol that has not appeared yet and is outside its trading session (e.g. a product without a night session) is waited for; one that is in session but has no bar is treated as suspended and not waited for. On the first trading day of a session it fires after the first slice reaches its deadline.
|
|
83
85
|
* `on_after_trading` is an **end/wind-down hook** intended for end-of-day statistics, cleanup, and archiving. It fires **after end-of-day settlement completes**: T+1 positions are already unlocked, the day's unfilled Day orders have expired, and orders submitted inside it belong to the next trading day. Backtest settlement runs at the close; live (`run_live`) at close + `day_close_delay` (default 60 seconds). If backtest data ends intraday and the day is never settled, it does not fire. It is a **dedicated event at the day's close** (after settlement, before the next bar), so a `NextOpen()` order submitted inside it fills on the next bar rather than one bar later (#324). If your intent is "decide at close, execute at the next open", the clearer place to order is `on_bar` (next-open) or `on_pre_open`.
|
|
84
86
|
* **`TimeInForce.Day` and next-open expiry semantics**: end-of-day settlement marks any Day order still unfilled that day as `Expired`. For a `NextOpen()` Day order submitted on or after the day's last market event (e.g. `on_cross_section` on daily data), its only matchable slice is the **next day's open**, which comes *after* settlement — so the framework spares such an order once, letting it get that next-open fill chance; it only expires at the closing settlement of the trading day it belongs to if it is still unfilled then (e.g. the symbol is suspended, #334). A same-cycle `CurrentClose()` Day order had its matchable slice on its creation day and so expires at that day's close. Orders submitted at or after the close in a non-continuous session (e.g. on the 15:00 minute bar that ends the closing auction, in `on_after_trading`, or within the live post-close grace window) belong to the next trading day and do not expire that day, whatever the fill mode. If you want a "decide at close, fill next day" order that is not subject to same-day expiry, just use the default `GTC`.
|
|
85
87
|
* To branch on the trading **session** (e.g. futures day/night, call auction vs continuous trading), the framework provides no `on_session_*` callbacks; read `self.ctx.session` (a `TradingSession` enum with 7 values: `Closed`, `OpeningAuction`, `AuctionHold`, `Continuous`, `Break`, `ClosingAuction`, `PostClose`), or use `self.is_market_open()`, `self.session_of(symbol)` and `self.trading_day` directly; see [2.2 Trading Sessions and Trading Days](#trading-session).
|
|
@@ -451,53 +453,71 @@ class CrossSectionStrategy(Strategy):
|
|
|
451
453
|
|
|
452
454
|
Full runnable samples: `examples/strategies/05_stock_momentum_rotation_timer.py` for `on_before_trading`, `examples/strategies/09_stock_momentum_rotation_after_bar.py` for `on_cross_section`, or `examples/strategies/07_stock_momentum_rotation_on_timer.py` for a fixed-time `on_timer` variant.
|
|
453
455
|
|
|
454
|
-
### 3.5 Cross-Section Plan B:
|
|
456
|
+
### 3.5 Cross-Section Plan B: Once Per Time Slice (`on_bars`) {: #on-bars }
|
|
455
457
|
|
|
456
|
-
|
|
458
|
+
When every bar (daily or minute) needs one pass over all symbols, override `on_bars(batch)`: the framework calls it once after all bars sharing a timestamp have arrived. (Experimental; the interface may change.)
|
|
457
459
|
|
|
458
460
|
```python
|
|
459
|
-
from
|
|
461
|
+
from akquant import BarBatch
|
|
460
462
|
|
|
461
|
-
class
|
|
463
|
+
class CrossSectionBarsStrategy(Strategy):
|
|
462
464
|
lookback = IntParam(20, ge=1, le=500, title="Lookback window")
|
|
463
465
|
|
|
464
466
|
def on_start(self):
|
|
465
|
-
self.universe = ["sh600519", "sz000858", "sh601318"]
|
|
466
467
|
self.warmup_period = self.params.lookback + 1
|
|
467
|
-
self.pending = defaultdict(set)
|
|
468
468
|
|
|
469
|
-
def
|
|
470
|
-
self.pending[bar.timestamp].add(bar.symbol)
|
|
471
|
-
if len(self.pending[bar.timestamp]) < len(self.universe):
|
|
472
|
-
return
|
|
473
|
-
self.pending.pop(bar.timestamp, None)
|
|
469
|
+
def on_bars(self, batch: BarBatch):
|
|
474
470
|
scores = {}
|
|
475
|
-
for
|
|
476
|
-
closes = self.get_history(count=self.params.lookback, symbol=symbol, field="close")
|
|
477
|
-
|
|
478
|
-
return
|
|
479
|
-
scores[symbol] = (closes[-1] - closes[0]) / closes[0]
|
|
471
|
+
for bar in batch: # only symbols with a bar in this slice, sorted by symbol
|
|
472
|
+
closes = self.get_history(count=self.params.lookback, symbol=bar.symbol, field="close")
|
|
473
|
+
scores[bar.symbol] = (closes[-1] - closes[0]) / closes[0]
|
|
480
474
|
best = max(scores, key=lambda s: scores[s])
|
|
481
475
|
self.order_target_percent(target_percent=0.95, symbol=best)
|
|
482
476
|
```
|
|
483
477
|
|
|
478
|
+
| Member | Meaning |
|
|
479
|
+
| :--- | :--- |
|
|
480
|
+
| `batch.timestamp` | Slice time in nanoseconds (the `timestamp` of every bar in it) |
|
|
481
|
+
| `batch.bars` / `for bar in batch` | Bars of the slice, sorted by `symbol` |
|
|
482
|
+
| `batch["600000"]` / `batch.get("600000")` / `"600000" in batch` | Lookup by symbol; the first raises `KeyError` when absent, `get` returns `None` |
|
|
483
|
+
| `batch.symbols` | Symbols that have a bar in this slice |
|
|
484
|
+
| `batch.missing` | Symbols seen earlier that have no usable bar in this slice (suspended, no trades, late, or still in warmup); symbols never seen are not listed |
|
|
485
|
+
| `batch.flush_reason` | `"boundary"` / `"complete"` / `"watermark"` / `"deadline"` |
|
|
486
|
+
|
|
487
|
+
When it fires:
|
|
488
|
+
|
|
489
|
+
* **Backtest** (and `broker="replay"`): when the slice ends, before the next one starts (`"boundary"`). Slices with missing bars still fire, and so does the last slice. Orders placed in it fill like orders placed in the last `on_bar` of the slice: at the open of the next bar by default, at the close of this slice with `CurrentClose()`.
|
|
490
|
+
* **Live**: as soon as every previously seen symbol has arrived (`"complete"`); otherwise at slice time + `bars_deadline_seconds` (`"deadline"`); a bar of a later slice arriving before the deadline also fires it (`"watermark"`; history already includes that later bar). The first slice has no earlier symbol set to compare against, so it waits for the deadline.
|
|
491
|
+
* `bars_deadline_seconds` is a strategy class attribute, default 5 seconds. It must exceed the flush delay of the data source: gateways that build bars locally from quotes (e.g. klinedata) emit the bar of a symbol with no further quotes 2–3 seconds after the bar ends. With a suspended symbol, every live slice waits the full deadline.
|
|
492
|
+
* Bars arriving after the deadline only trigger `on_bar`; they are not added to the batch already dispatched (one warning per symbol). The last undispatched slice is dropped when a live session stops.
|
|
493
|
+
|
|
494
|
+
Notes:
|
|
495
|
+
|
|
496
|
+
* When `on_bar` is also overridden, `on_bar` runs for each bar first, then `on_bars`.
|
|
497
|
+
* Base-frequency bars only; window bars from `subscribe_bars` are not included. Bars still in warmup are left out (the symbol is listed in `batch.missing`); slices whose bars are all in warmup do not fire.
|
|
498
|
+
* The callback belongs to no single symbol: `self.current_bar` is `None`; read multi-symbol indicators with `ind.of(symbol)[0]`.
|
|
499
|
+
* Function style: `run_backtest(..., on_bars=fn)` / `run_live(..., on_bars=fn)` with `fn(ctx, batch)`.
|
|
500
|
+
|
|
501
|
+
!!! warning "Do not count bars yourself in `on_bar`"
|
|
502
|
+
Buffering by `timestamp` in `on_bar` and running once all symbols are collected silently skips every slice in which one symbol is suspended or has no bar. Processing the previous slice when the next timestamp shows up is wrong too: the first bar of the next slice is already in history by then, so you read future data, and the last slice never fires.
|
|
503
|
+
|
|
484
504
|
Full runnable sample: `examples/strategies/06_stock_momentum_rotation_bucket.py`.
|
|
485
505
|
|
|
486
506
|
### 3.6 Decision Matrix (A vs B)
|
|
487
507
|
|
|
488
|
-
| Dimension | Plan A:
|
|
508
|
+
| Dimension | Plan A: day-boundary hooks / `on_timer` | Plan B: `on_bars` |
|
|
489
509
|
| :--- | :--- | :--- |
|
|
490
|
-
| Trigger |
|
|
491
|
-
|
|
|
492
|
-
| Complexity | Low
|
|
493
|
-
| Best for | Daily/timed rebalances
|
|
494
|
-
| Common risk | Timer time not aligned with data frequency |
|
|
510
|
+
| Trigger | Once per trading day, or a fixed time (e.g., 14:55) | Once per time slice |
|
|
511
|
+
| Symbols without a bar | Do not affect the trigger | Do not affect the trigger; listed in `batch.missing` |
|
|
512
|
+
| Complexity | Low | Low |
|
|
513
|
+
| Best for | Daily/timed rebalances | Cross-symbol work on every bar (intraday rotation, cross-sectional factors) |
|
|
514
|
+
| Common risk | Timer time not aligned with data frequency | Live deadline shorter than the flush delay of the data source, so batches always miss symbols |
|
|
495
515
|
|
|
496
|
-
Recommendation: use Plan A
|
|
516
|
+
Recommendation: use Plan A for daily or fixed-time rebalances; use Plan B when every bar needs processing.
|
|
497
517
|
|
|
498
518
|
### 3.7 Cross-Section Pitfall Checklist
|
|
499
519
|
|
|
500
|
-
* **Suspensions / missing bars**:
|
|
520
|
+
* **Suspensions / missing bars**: `on_bars` still fires when some symbols have no bar; they are listed in `batch.missing`. Decide before scoring whether to skip them or carry the previous value.
|
|
501
521
|
* **Universe drift**: If constituents change but your universe list is stale, weights and ranks diverge from target; refresh periodically and track effective date.
|
|
502
522
|
* **Rebalance time vs fill mode mismatch**: With `fill_policy=NextOpen()`, close-time signals are filled on the next bar; use `CurrentClose(timer_fill_timing=...)` to make timer fill timing explicit.
|
|
503
523
|
* **Insufficient history windows**: Newly listed or recently resumed symbols may fail window requirements; check `len(closes)` and skip invalid samples.
|
|
@@ -547,6 +567,7 @@ For style selection guidance, see [Strategy Style Decision Guide](../advanced/st
|
|
|
547
567
|
| `on_reject(self, order)` | Not supported | Reject callback, currently class-style only | `examples/08_event_callbacks.py`, `examples/50_framework_hooks_demo.py` |
|
|
548
568
|
| `on_before_trading(self, trading_date, timestamp)` | `on_before_trading(ctx, trading_date, timestamp)` | Trading-day boundary hook, supported by both styles | `examples/50_framework_hooks_demo.py` |
|
|
549
569
|
| `on_after_trading(self, trading_date, timestamp)` | `on_after_trading(ctx, trading_date, timestamp)` | Trading-day boundary hook, supported by both styles | `examples/50_framework_hooks_demo.py` |
|
|
570
|
+
| `on_bars(self, batch)` | `on_bars(ctx, batch)` | Batch callback fired once per time slice, supported by both styles | `examples/strategies/06_stock_momentum_rotation_bucket.py` |
|
|
550
571
|
| `on_cross_section(self, trading_date, timestamp)` | `on_cross_section(ctx, trading_date, timestamp)` | Current-day-aware cross-sectional rebalance hook, supported by both styles | `examples/strategies/09_stock_momentum_rotation_after_bar.py` |
|
|
551
572
|
| `on_portfolio_update(self, snapshot)` | `on_portfolio_update(ctx, snapshot)` | Portfolio snapshot callback, supported by both styles | `examples/50_framework_hooks_demo.py` |
|
|
552
573
|
| `on_error(self, error, source, payload)` | `on_error(ctx, error, source, payload)` | User exception callback, supported by both styles | `examples/22_strategy_runtime_config_demo.py` |
|
|
@@ -609,7 +630,11 @@ class MyStrategy(Strategy):
|
|
|
609
630
|
self.sell(symbol=bar.symbol, quantity=100)
|
|
610
631
|
```
|
|
611
632
|
|
|
612
|
-
**
|
|
633
|
+
**Retained length (how many bars of history the framework keeps per symbol)**: in a backtest it is the largest of `history_depth`, `warmup_period` and the warmup inferred from your indicators. In a live session (`run_live`) it follows `history_depth`; `warmup_period` does not set the history depth directly. With auto-preload on (the feed offers a `history_provider`, as klinedata does by default), it only feeds into the preload count (the largest of 3 × the inferred warmup, 500, `warmup_period` and `history_depth`, capped), and once the preload is done history is enabled at the number of bars actually preloaded. Without a preload, `get_history` raises "History tracking is not enabled" until `set_history_depth` is called. Live strategies that read history should call `self.set_history_depth(N)` explicitly.
|
|
634
|
+
|
|
635
|
+
**Set the history depth in `__init__` / `on_start`**: if `set_history_depth(N)` is first called mid-run (after the session has started), the bars before the call are not backfilled; the window becomes complete only after another N bars.
|
|
636
|
+
|
|
637
|
+
**When `count` exceeds the retained length, the history grows automatically and warns once**: the first time `get_history` / `get_history_df` asks for a larger `count`, the framework grows the retained length to `count` and logs a warning with the value to set; data dropped before the growth cannot be recovered, so the window is complete only from `count` bars later. Call `self.set_history_depth(N)` in `on_start` as the warning suggests (this takes effect in both backtests and live sessions). NaN padding during warmup (not enough data yet) is normal and does not warn. Automatic growth is capped at the larger of 10000 and the `history_depth` / `warmup_period` you declared explicitly: beyond the cap it no longer grows, warns once on its own, and pads with NaN as before, so a `count` that keeps increasing (such as `get_history(self.bars_held)`) cannot grow the buffer without bound in a live session.
|
|
613
638
|
|
|
614
639
|
## 5. Orders & Execution
|
|
615
640
|
|
|
@@ -53,6 +53,7 @@ def run_backtest(
|
|
|
53
53
|
on_expiry: Optional[Callable[[Any, Dict[str, Any]], None]] = None,
|
|
54
54
|
on_pre_open: Optional[Callable[[Any, Dict[str, Any]], None]] = None,
|
|
55
55
|
on_timer: Optional[Callable[[Any, str], None]] = None,
|
|
56
|
+
on_bars: Optional[Callable[[Any, Any], None]] = None,
|
|
56
57
|
context: Optional[Dict[str, Any]] = None,
|
|
57
58
|
history_depth: Optional[int] = None,
|
|
58
59
|
warmup_period: int = 0,
|
|
@@ -100,7 +101,7 @@ def run_backtest(
|
|
|
100
101
|
* `strategy`: Strategy class or instance. Also supports passing an `on_bar` function (functional style).
|
|
101
102
|
* `strategy_source` / `strategy_loader` / `strategy_loader_options`: Dynamic strategy loading entry points. When `strategy=None`, the framework can build the strategy from source, a path, or a custom loader.
|
|
102
103
|
* `initialize` / `on_start` / `on_resume` / `on_stop`: Functional-strategy lifecycle callbacks for initialization, start, resume, and stop stages.
|
|
103
|
-
* `on_tick` / `on_order` / `on_trade` / `on_reject` / `on_before_trading` / `on_after_trading` / `on_cross_section` / `on_portfolio_update` / `on_error` / `on_expiry` / `on_pre_open` / `on_timer` / `on_train_signal`: Functional event callbacks. `on_expiry(ctx, event)` fires only after the engine actually executes expiry settlement/removal; `on_pre_open(ctx, event)` fires 1ns before the trading day's first session segment starts (before the 09:15 opening call auction for A-shares) and suits "pre-open decision, current open fill". For the full timing of the trading-day hooks see [`akquant.Strategy`](#akquantstrategy) below.
|
|
104
|
+
* `on_tick` / `on_order` / `on_trade` / `on_reject` / `on_before_trading` / `on_after_trading` / `on_cross_section` / `on_bars` / `on_portfolio_update` / `on_error` / `on_expiry` / `on_pre_open` / `on_timer` / `on_train_signal`: Functional event callbacks. `on_expiry(ctx, event)` fires only after the engine actually executes expiry settlement/removal; `on_pre_open(ctx, event)` fires 1ns before the trading day's first session segment starts (before the 09:15 opening call auction for A-shares) and suits "pre-open decision, current open fill". For the full timing of the trading-day hooks see [`akquant.Strategy`](#akquantstrategy) below.
|
|
104
105
|
* `symbols`: Symbol or list of symbols. Defaults to `None` (**not passed explicitly**): whatever symbols show up in the data are treated as the ones to run ("data is subscription"), and behavior is identical to before this parameter existed. **Passing it explicitly** — even a value that only lists symbols already present in the data — changes the semantics to "run only these symbols": symbols outside the whitelist are filtered out up front, never enter the engine, and never participate in matching or statistics (backtest results on multi-symbol input can therefore change). Passing an explicit empty collection raises an error rather than degrading to "no filtering". The whitelist is actually the union of `symbols` ∪ `config.instruments` ∪ the symbols already subscribed via `self.subscribe()` during `__init__`; once `symbols` is passed explicitly, calling `subscribe()` on a symbol outside the whitelist inside `on_start` raises `ValueError` (see the `on_start` notes in the "Strategy Lifecycle" section of the [Strategy Guide](../guide/strategy.md)). This validation only applies to backtests: live trading (`run_live`) never ships a whitelist, so `subscribe()` is unconstrained there.
|
|
105
106
|
* **Special case for `run_from_checkpoint`**: the third term of the whitelist union isn't limited to the `subscribe()` calls made during this call's own `__init__` — a warm-started strategy instance carries `_subscriptions` **restored from the pickled snapshot** (i.e. every subscription accumulated during the previous run, including ones added inside `on_start`), and those are folded into the whitelist too. In other words, if stage one's strategy subscribed to a symbol, stage two's whitelist still includes that symbol as long as stage two passes `symbols` — even if stage two never calls `subscribe()` on it again. This is part of the warm start's overall "carry over previous state" semantics, and is **not** fully symmetric with the "`__init__`-stage subscriptions" rule that feeds `run_backtest`'s whitelist; don't assume `run_from_checkpoint`'s effective filtering matches what `run_backtest`'s whitelist rule would predict.
|
|
106
107
|
* **Migration note (legacy `symbols="BENCHMARK"` usage)**: before this change, the signature default for `symbol`/`symbols` was literally the string `"BENCHMARK"` (some warm-start examples in this repo used to pass it explicitly, too). After the upgrade, any explicitly passed value is always treated as a real filter — it is no longer equivalent to "not passed" — and different data shapes now fail in **opposite** directions: with `List[Bar]` / `DataFeed` input, since no symbol in the data literally equals `"BENCHMARK"`, the whitelist admits nothing and the backtest runs empty (with just one WARNING and otherwise silent); with `DataFrame` / `Dict[str, DataFrame]` input, `"BENCHMARK"` instead short-circuits the existing pre-filter check and disables filtering entirely. The fix is simple: **remove** the explicit `symbols="BENCHMARK"` (omit the parameter) rather than migrating it to some other literal.
|
|
@@ -886,6 +887,7 @@ Strategy base class. Users should inherit from this class and override callback
|
|
|
886
887
|
* `on_expiry(event: Dict[str, Any])`: Triggered after an `expiry_date` driven settlement/removal is actually executed. Portfolio state is already updated when the callback runs. See `examples/49_on_expiry_demo.py` for a runnable example.
|
|
887
888
|
* `on_before_trading(trading_date, timestamp)`: Fires 1ns after the trading day's earliest continuous-auction segment starts, at most once per trading day (backtests fire it only for trading days with market data, live sessions for every day in the trading calendar; just after 09:30:00 for A-shares; for futures with a night session the trading day starts with the previous trading day's night session, so Monday's trading day fires on Friday at 21:00; a trading day without a continuous-auction segment does not fire it). This callback follows a "previous trading day / previous snapshot only" visibility model.
|
|
888
889
|
* `on_pre_open(event: Dict[str, Any])`: Fires 1ns before the trading day's first session segment starts, once per trading day (before 09:15 for A-shares, i.e. 09:14:59.999…; for futures with a night session, before the previous trading day's 20:55 night auction), never earlier than the previous trading day's end-of-day settlement; same in backtest and live. Within one trading day it always precedes `on_before_trading`. Use it for "pre-open decision, current open fill" workflows; default order semantics resolve to `NextOpen()`, and such orders join the opening call-auction match (matching happens when continuous trading starts, the fill price is the auction price, and the fill time is the first continuous-trading event). `event["expected_open_at"]` is the trigger time of this call, not the opening time. See `examples/52_pre_open_demo.py`.
|
|
890
|
+
* `on_bars(batch: BarBatch)`: Batch callback (experimental). Fires once per time slice after all bars sharing that timestamp have arrived; `batch` holds them (`batch.bars` sorted by symbol, `batch["600000"]` by symbol, `batch.missing` lists symbols seen earlier that have no bar in this slice, `batch.flush_reason` tells why it fired). In backtests it fires when the slice ends, before the next one starts, and orders placed in it fill like orders placed in the last `on_bar` of the slice. In live trading it fires as soon as every previously seen symbol has arrived, otherwise at slice time + `bars_deadline_seconds` (class attribute, default 5 s). When `on_bar` is also overridden, `on_bar` runs for each bar first. Base-frequency bars only. See the [strategy guide](../guide/strategy.md#on-bars).
|
|
889
891
|
* `on_cross_section(trading_date, timestamp)`: Cross-sectional same-cycle rebalance hook that runs after the first complete cross-symbol bar slice of the trading day, at most once per trading day. Unlike `on_before_trading`, it can see the current day's bar history and current account snapshot, and is intended for same-cycle close-style rebalances. Rebalance cadence (daily/weekly/monthly) is decided with a calendar check inside the hook.
|
|
890
892
|
* `on_after_trading(trading_date, timestamp)`: Fires after end-of-day settlement completes, once per trading day. T+1 positions are unlocked and the day's Day orders have expired by then; orders submitted inside it belong to the next trading day. Backtests fire it at the close; live sessions at close + `day_close_delay` (see [run_live live timezone and sessions](#live-timezone-sessions)). If backtest data ends intraday and the day is not settled, it does not fire, and stopping does not flush it.
|
|
891
893
|
* `on_portfolio_update(snapshot)`: Triggered when cash/equity/position snapshot changes.
|
|
@@ -32,6 +32,7 @@
|
|
|
32
32
|
* `on_before_trading` / `on_after_trading`: 交易日级钩子。
|
|
33
33
|
* `on_pre_open`: 开盘前最后一个合法决策点,适合“盘前信号,本次 open 成交”。
|
|
34
34
|
* `on_cross_section`: 当日首个跨标的完整 bar 切片就绪后触发(每天最多一次,适合基于当日 bar/账户快照做横截面同周期调仓)。
|
|
35
|
+
* `on_bars`: 同一时间片的 bar 到齐后触发一次(每个时间片一次,适合每根 bar 都要跨标的统一处理的策略,见 [3.5](#on-bars))。
|
|
35
36
|
* `on_portfolio_update`: 账户快照变化时触发。
|
|
36
37
|
* `on_error`: 用户回调抛异常时触发,默认触发后继续抛出异常。
|
|
37
38
|
* `on_timer`: 定时器触发时调用 (需手动注册)。
|
|
@@ -52,6 +53,7 @@
|
|
|
52
53
|
| `on_before_trading` | 交易日最早的连续竞价开始后 1ns(A 股 09:30;有夜盘的期货从前一交易日夜盘开始,周一交易日在周五 21:00 触发) | 盘前检查、生成交易日级信号 | `examples/50_framework_hooks_demo.py` |
|
|
53
54
|
| `on_pre_open` | 交易日首个时段开始前 1ns(A 股 09:15 集合竞价前;有夜盘的期货为前一交易日 20:55 夜盘集合竞价前),不早于上一交易日日终结算;回测与实盘一致 | 盘前信号与“本次 open 成交”语义钩子;默认 `NextOpen()` 单参加开盘集合竞价统一撮合,但不等同于券商柜台已支持集合竞价专用委托 | `examples/52_pre_open_demo.py` |
|
|
54
55
|
| `on_cross_section` | 当日首个跨标的完整 bar 切片之后 | 基于当日 bar/账户快照的横截面同周期调仓 | `examples/strategies/09_stock_momentum_rotation_after_bar.py` |
|
|
56
|
+
| `on_bars` | 每个时间片的 bar 到齐后(回测在时间片结束时;实盘到齐或等到截止时间) | 每根 bar 对全部标的统一打分、调仓 | `examples/strategies/06_stock_momentum_rotation_bucket.py` |
|
|
55
57
|
| `on_after_trading` | 日终结算完成后(回测在收盘时刻;实盘在收盘 + `day_close_delay`) | 日终统计、收盘后清理与归档 | `examples/50_framework_hooks_demo.py` |
|
|
56
58
|
| `on_portfolio_update` | 账户快照变化时增量触发 | 监控现金/权益变化、推送 UI 或告警 | `examples/50_framework_hooks_demo.py` |
|
|
57
59
|
| `on_error` | 任一用户回调抛异常时 | 记录异常源、决定继续/中断策略 | `examples/22_strategy_runtime_config_demo.py` |
|
|
@@ -82,6 +84,7 @@
|
|
|
82
84
|
* `on_before_trading` 在交易日最早的连续竞价开始后 1ns 触发(A 股 09:30:00 之后);夜盘品种的交易日从前一交易日夜盘开始,周一交易日在周五 21:00 触发。交易日没有连续竞价段时不触发。
|
|
83
85
|
* `on_before_trading` 始终按“前一交易日/前一时点信息可见”的语义工作;在该回调里,`get_history()`、`get_account()`、`equity` 不应看到当日新 bar 或当日更新后的账户视图。
|
|
84
86
|
* `on_cross_section` 会在框架见到当日首个“跨标的完整切片”后触发;在该回调里,可以看到当日历史和当前账户快照。
|
|
87
|
+
* 实盘(含 `broker="replay"`)事先不知道当日行情,`on_cross_section` 按到达情况判断:此前见过的标的当日都已出现过 bar 的首个时间片派发后触发(到齐即触发,否则等 `bars_deadline_seconds`,默认 5 秒)。当日尚未出现的标的此刻不在交易时段(如没有夜盘的品种)则继续等;在交易时段却没有 bar 的按停牌处理、不等。会话的第一个交易日在首个时间片等到截止时间后触发。
|
|
85
88
|
* `on_after_trading` 是**结束/收尾型钩子**,定位为日终的统计、清理与归档。它在**日终结算完成之后**触发:此时 T+1 持仓已解冻、当日未成交的 Day 单已过期,其中下的单属于下一交易日。回测的日终结算在收盘时刻进行;实盘(`run_live`)在收盘 + `day_close_delay`(默认 60 秒)。回测数据在盘中结束、当日未结算时不触发。它是**当日收盘点的独立事件**(在日终结算之后、早于下一根 bar),因此在其中提交的 `NextOpen()` 单会落在下一根 bar(而非再晚一格,#324)。但若你的意图是“收盘决策、次日开盘成交”,更清晰的写法是在 `on_bar`(next-open)或 `on_pre_open` 中下单。
|
|
86
89
|
* **`TimeInForce.Day` 与 next-open 的过期语义**:日终结算会把当日仍未成交的 Day 单置为 `Expired`。对于在当日最后一个行情事件上或之后(如日线数据下的 `on_cross_section`)提交的 `NextOpen()` Day 单,其唯一可撮合切片是**次日开盘**,晚于结算时点——框架据此豁免这类订单一次,让它先获得次日开盘的成交机会;只有当次日开盘仍未成交(如次日停牌),才在它所属交易日收盘结算时过期(#334)。同一时点成交(`CurrentClose()`)的 Day 单其可撮合切片就在创建当日,因此在创建当日收盘过期。收盘时刻及之后、在非连续竞价时段(如收盘竞价结束的 15:00 分钟 bar、`on_after_trading`、实盘收盘宽限期内)下的单属于下一交易日,不论成交模式都不在当日过期。若希望“收盘决策、次日成交”的委托不受当日过期约束,也可直接使用默认的 `GTC`。
|
|
87
90
|
* 需要按**时段**(如期货日盘/夜盘、集合竞价/连续竞价)分支时,框架不提供 `on_session_*` 回调;请读取 `self.ctx.session`(`TradingSession` 枚举,共 7 个值:`Closed`、`OpeningAuction`、`AuctionHold`、`Continuous`、`Break`、`ClosingAuction`、`PostClose`),或直接用 `self.is_market_open()`、`self.session_of(symbol)` 与 `self.trading_day`,见 [2.2 交易时段与交易日](#trading-session)。
|
|
@@ -625,53 +628,73 @@ class CrossSectionStrategy(Strategy):
|
|
|
625
628
|
|
|
626
629
|
完整示例见:`examples/strategies/05_stock_momentum_rotation_timer.py`(`on_before_trading`)、`examples/strategies/09_stock_momentum_rotation_after_bar.py`(`on_cross_section`)以及 `examples/strategies/07_stock_momentum_rotation_on_timer.py`(`on_timer` 固定时点版本)。
|
|
627
630
|
|
|
628
|
-
### 3.5 横截面方案 B
|
|
631
|
+
### 3.5 横截面方案 B:每个时间片执行一次(`on_bars`) {: #on-bars }
|
|
629
632
|
|
|
630
|
-
|
|
633
|
+
策略每根 bar(日线、分钟线)都要对全部标的统一处理时,重写 `on_bars(batch)`:同一时间片的 bar 到齐后框架回调一次,`batch` 是这一片的全部 bar。(实验性,接口可能调整。)
|
|
631
634
|
|
|
632
635
|
```python
|
|
633
|
-
from
|
|
636
|
+
from akquant import BarBatch
|
|
634
637
|
|
|
635
|
-
class
|
|
638
|
+
class CrossSectionBarsStrategy(Strategy):
|
|
636
639
|
lookback = IntParam(20, ge=1, le=500, title="回看周期")
|
|
637
640
|
|
|
638
641
|
def on_start(self):
|
|
639
|
-
self.universe = ["sh600519", "sz000858", "sh601318"]
|
|
640
642
|
self.warmup_period = self.params.lookback + 1
|
|
641
|
-
self.pending = defaultdict(set)
|
|
642
643
|
|
|
643
|
-
def
|
|
644
|
-
self.pending[bar.timestamp].add(bar.symbol)
|
|
645
|
-
if len(self.pending[bar.timestamp]) < len(self.universe):
|
|
646
|
-
return
|
|
647
|
-
self.pending.pop(bar.timestamp, None)
|
|
644
|
+
def on_bars(self, batch: BarBatch):
|
|
648
645
|
scores = {}
|
|
649
|
-
for
|
|
650
|
-
closes = self.get_history(count=self.params.lookback, symbol=symbol, field="close")
|
|
651
|
-
|
|
652
|
-
return
|
|
653
|
-
scores[symbol] = (closes[-1] - closes[0]) / closes[0]
|
|
646
|
+
for bar in batch: # 只含本片有 bar 的标的,按 symbol 升序
|
|
647
|
+
closes = self.get_history(count=self.params.lookback, symbol=bar.symbol, field="close")
|
|
648
|
+
scores[bar.symbol] = (closes[-1] - closes[0]) / closes[0]
|
|
654
649
|
best = max(scores, key=lambda s: scores[s])
|
|
655
650
|
self.order_target_percent(target_percent=0.95, symbol=best)
|
|
656
651
|
```
|
|
657
652
|
|
|
653
|
+
`BarBatch` 的内容:
|
|
654
|
+
|
|
655
|
+
| 成员 | 说明 |
|
|
656
|
+
| :--- | :--- |
|
|
657
|
+
| `batch.timestamp` | 时间片时刻(纳秒),即其中每根 bar 的 `timestamp` |
|
|
658
|
+
| `batch.bars` / `for bar in batch` | 本片的 bar,按 `symbol` 升序 |
|
|
659
|
+
| `batch["600000"]` / `batch.get("600000")` / `"600000" in batch` | 按标的取;本片没有时前者抛 `KeyError`,`get` 返回 `None` |
|
|
660
|
+
| `batch.symbols` | 本片有 bar 的标的 |
|
|
661
|
+
| `batch.missing` | 此前出现过、本片没有可用 bar 的标的(停牌、无成交、迟到,或仍在预热期);从未出现过的标的不列入 |
|
|
662
|
+
| `batch.flush_reason` | 派发原因:`"boundary"` / `"complete"` / `"watermark"` / `"deadline"`,见下 |
|
|
663
|
+
|
|
664
|
+
触发时机:
|
|
665
|
+
|
|
666
|
+
* **回测**(以及 `broker="replay"`):时间片结束、下一片开始之前触发(`flush_reason="boundary"`)。缺 bar 的时间片照常触发,最后一个时间片也触发。在其中下的单,与在本片最后一根 `on_bar` 里下单同一口径:默认下一根开盘成交,`CurrentClose()` 按本片收盘价成交。
|
|
667
|
+
* **实盘**:此前见过的标的在本片全部到齐时立即触发(`"complete"`);否则等到时间片时刻 + `bars_deadline_seconds`(`"deadline"`);截止前先收到更晚时间片的 bar 也会触发(`"watermark"`,此时取历史已能看到那根更晚的 bar)。第一个时间片没有“此前见过的标的”可比,只能等截止时间。
|
|
668
|
+
* `bars_deadline_seconds` 是策略类属性,默认 5 秒,须大于行情源自己的补发延迟:由报价本地合成 K 线的行情网关(如 klinedata),对没有后续报价的标的要在 K 线结束 2~3 秒后才补发这根 bar。有标的停牌时,实盘每个时间片都会等满截止时间。
|
|
669
|
+
* 截止之后才到的 bar 只触发 `on_bar`,不补进已派发的批次,每个标的告警一次。实盘会话停止时尚未派发的最后一片不派发。
|
|
670
|
+
|
|
671
|
+
几点约定:
|
|
672
|
+
|
|
673
|
+
* 与 `on_bar` 同时重写时,先逐根调用 `on_bar`,再调用 `on_bars`。
|
|
674
|
+
* 批次只含基础周期的 bar;`subscribe_bars` 的窗口 bar 不进批次。仍在预热期内的 bar 不进批次(该标的列在 `batch.missing`),全部在预热期内的时间片不触发。
|
|
675
|
+
* 回调不属于某个标的:`self.current_bar` 为 `None`,多标的指标用 `ind.of(symbol)[0]` 取值。
|
|
676
|
+
* 函数式写法:`run_backtest(..., on_bars=fn)` / `run_live(..., on_bars=fn)`,签名 `fn(ctx, batch)`。
|
|
677
|
+
|
|
678
|
+
!!! warning "不要在 `on_bar` 里自己数“攒满 N 根”"
|
|
679
|
+
`on_bar` 里按 `timestamp` 缓存、攒满全部标的才执行的写法,只要有一个标的停牌或缺 bar,那一片就凑不齐、整片不触发,而且没有任何提示。改成“见到下一个时间戳再处理上一片”也不对:这时下一片的第一根 bar 已经进了历史,取到的是未来数据,最后一片也永远不触发。
|
|
680
|
+
|
|
658
681
|
完整示例见:`examples/strategies/06_stock_momentum_rotation_bucket.py`。
|
|
659
682
|
|
|
660
683
|
### 3.6 方案选型对照 (A vs B)
|
|
661
684
|
|
|
662
|
-
| 维度 | 方案 A
|
|
685
|
+
| 维度 | 方案 A:日界钩子 / `on_timer` | 方案 B:`on_bars` |
|
|
663
686
|
| :--- | :--- | :--- |
|
|
664
|
-
| 触发方式 |
|
|
665
|
-
|
|
|
666
|
-
| 实现复杂度 |
|
|
667
|
-
| 适用场景 |
|
|
668
|
-
| 常见风险 | 定时器时间与数据频率不匹配 |
|
|
687
|
+
| 触发方式 | 每个交易日一次,或固定时点(如 14:55) | 每个时间片一次 |
|
|
688
|
+
| 缺 bar 的标的 | 不影响触发 | 不影响触发,列在 `batch.missing` |
|
|
689
|
+
| 实现复杂度 | 低 | 低 |
|
|
690
|
+
| 适用场景 | 日频/定时调仓 | 每根 bar 都要跨标的处理(分钟级轮动、截面因子) |
|
|
691
|
+
| 常见风险 | 定时器时间与数据频率不匹配 | 实盘截止时间小于行情源补发延迟,批次总是缺标的 |
|
|
669
692
|
|
|
670
|
-
|
|
693
|
+
建议:每天或固定时点调仓用方案 A;每根 bar 都要处理用方案 B。
|
|
671
694
|
|
|
672
695
|
### 3.7 横截面常见坑位清单
|
|
673
696
|
|
|
674
|
-
*
|
|
697
|
+
* **停牌/缺失数据**:某些标的当根无 Bar 时,`on_bars` 照常触发,缺的标的列在 `batch.missing`;打分前决定是跳过还是沿用上一根的值。
|
|
675
698
|
* **Universe 漂移**:成分股调整后若仍用旧列表,会出现权重与真实池不一致;建议定期刷新并记录生效日期。
|
|
676
699
|
* **调仓时点与成交策略错配**:例如 `fill_policy=NextOpen()` 时,收盘时点信号会在下一根撮合;若用 `CurrentClose(...)`,应结合 `timer_fill_timing` 明确 timer 是否当期成交。
|
|
677
700
|
* **历史长度不足**:新上市或停牌恢复标的数据窗口不完整;评分前统一做 `len(closes)` 检查并跳过不足样本。
|
|
@@ -724,6 +747,7 @@ AKQuant 提供了两种风格的策略开发接口:
|
|
|
724
747
|
| `on_before_trading(self, trading_date, timestamp)` | `on_before_trading(ctx, trading_date, timestamp)` | 交易日前边界钩子,两种风格都支持 | `examples/50_framework_hooks_demo.py` |
|
|
725
748
|
| `on_after_trading(self, trading_date, timestamp)` | `on_after_trading(ctx, trading_date, timestamp)` | 交易日后边界钩子,两种风格都支持 | `examples/50_framework_hooks_demo.py` |
|
|
726
749
|
| `on_cross_section(self, trading_date, timestamp)` | `on_cross_section(ctx, trading_date, timestamp)` | 当日可见语义的横截面同周期调仓钩子,两种风格都支持 | `examples/strategies/09_stock_momentum_rotation_after_bar.py` |
|
|
750
|
+
| `on_bars(self, batch)` | `on_bars(ctx, batch)` | 每个时间片一次的批量回调,两种风格都支持 | `examples/strategies/06_stock_momentum_rotation_bucket.py` |
|
|
727
751
|
| `on_portfolio_update(self, snapshot)` | `on_portfolio_update(ctx, snapshot)` | 账户快照回调,两种风格都支持 | `examples/50_framework_hooks_demo.py` |
|
|
728
752
|
| `on_error(self, error, source, payload)` | `on_error(ctx, error, source, payload)` | 用户异常回调,两种风格都支持 | `examples/22_strategy_runtime_config_demo.py` |
|
|
729
753
|
| `on_train_signal(self, context)` | `on_train_signal(ctx)` | ML 滚动训练钩子,两种风格都支持;仅在 ML 滚动训练窗口触发时调用 | `examples/10_ml_walk_forward.py`、`examples/55_functional_ml_walk_forward.py` |
|
|
@@ -766,7 +790,9 @@ AKQuant 提供了两种风格的策略开发接口:
|
|
|
766
790
|
|
|
767
791
|
* **`self.get_history(count, ...)`**: 返回 `numpy.ndarray`,性能最高,适合计算指标。
|
|
768
792
|
* **`self.get_history_df(count, ...)`**: 返回 `pandas.DataFrame`,包含 OHLCV,适合复杂分析。
|
|
769
|
-
*
|
|
793
|
+
* **保留长度(框架为每个标的保留多少根历史)**:回测里取 `history_depth`、`warmup_period` 与指标推断预热期中的最大值。实盘(`run_live`)按 `history_depth` 设置,`warmup_period` 不直接设定历史深度:开启自动预加载时(行情源提供 `history_provider`,如 klinedata,默认开启),它只参与计算预加载根数(取 3 倍推断预热期、500、`warmup_period` 与 `history_depth` 中的最大值,有上限),预加载完成后历史按实际预加载的根数开启;没有预加载时,在调用 `set_history_depth` 之前 `get_history` 会报 “History tracking is not enabled”。需要历史的实盘策略请显式调用 `self.set_history_depth(N)`。
|
|
794
|
+
* **请在 `__init__` / `on_start` 里设置历史深度**:运行中(开跑后)才第一次调用 `set_history_depth(N)` 时,调用之前的行情不会补回,需再积累 N 根 bar 才完整。
|
|
795
|
+
* **`count` 超过保留长度时会自动加长并告警一次**:`count` 更大时,框架第一次遇到就把保留长度加到 `count`,并打一条告警给出该设的值;加长之前已丢掉的数据补不回来,此后满 `count` 根 bar 起才是完整数据。请按告警在 `on_start` 里调用 `self.set_history_depth(N)` 提前设置(回测与实盘都生效)。预热期数据还不够(前面补 NaN)是正常情况,不会告警。自动加长有上限:取 10000 与显式声明的 `history_depth` / `warmup_period` 中的较大值;`count` 超过上限时不再加长,单独告警一次,照旧前面补 NaN,以免 `get_history(self.bars_held)` 这类随时间增长的 `count` 让实盘里的缓冲区无限增长。
|
|
770
796
|
|
|
771
797
|
**`freq` 参数(tick/bar 双流下按需选择粒度)**
|
|
772
798
|
|
|
@@ -215,7 +215,7 @@ res = run_backtest(data=pl_df, strategy=...) # 快速测试仍可传内
|
|
|
215
215
|
|
|
216
216
|
**待决**
|
|
217
217
|
|
|
218
|
-
1.
|
|
218
|
+
1. ~~`on_bars(batch)` 批量回调是否作为一等 API,以及在哪一期引入。~~ 已定(#441):作为一等 API 引入,`Strategy.on_bars(batch: BarBatch)` 每个时间片回调一次,在 Python 框架层实现(收集 + 框架定时器),与列式分期无关;批次里仍是逐根物化的 `Bar` 对象,列式批次(零拷贝视图)留待解耦第 3 步。
|
|
219
219
|
2. 旧 catalog 是否迁移到规范格式。
|
|
220
220
|
|
|
221
221
|
## 14. 风险与对策
|
|
@@ -53,6 +53,7 @@ def run_backtest(
|
|
|
53
53
|
on_expiry: Optional[Callable[[Any, Dict[str, Any]], None]] = None,
|
|
54
54
|
on_pre_open: Optional[Callable[[Any, Dict[str, Any]], None]] = None,
|
|
55
55
|
on_timer: Optional[Callable[[Any, str], None]] = None,
|
|
56
|
+
on_bars: Optional[Callable[[Any, Any], None]] = None,
|
|
56
57
|
context: Optional[Dict[str, Any]] = None,
|
|
57
58
|
history_depth: Optional[int] = None,
|
|
58
59
|
warmup_period: int = 0,
|
|
@@ -208,7 +209,7 @@ def run_from_checkpoint(
|
|
|
208
209
|
* `strategy`: 策略类、策略实例,或 `on_bar` 函数(函数式编程风格)。
|
|
209
210
|
* `strategy_source` / `strategy_loader` / `strategy_loader_options`: 动态策略加载入口。`strategy=None` 时可直接从源码、路径或自定义加载器构造策略。
|
|
210
211
|
* `initialize` / `on_start` / `on_resume` / `on_stop`: 函数式策略生命周期回调;其中 `on_resume(ctx)` 仅在 checkpoint 恢复后的热启动阶段触发,且先于 `on_start(ctx)`。
|
|
211
|
-
* `on_tick` / `on_order` / `on_trade` / `on_reject` / `on_before_trading` / `on_after_trading` / `on_cross_section` / `on_portfolio_update` / `on_error` / `on_expiry` / `on_pre_open` / `on_timer` / `on_train_signal`:
|
|
212
|
+
* `on_tick` / `on_order` / `on_trade` / `on_reject` / `on_before_trading` / `on_after_trading` / `on_cross_section` / `on_bars` / `on_portfolio_update` / `on_error` / `on_expiry` / `on_pre_open` / `on_timer` / `on_train_signal`: 函数式策略事件回调;`on_bars(ctx, batch)` 每个时间片触发一次(实验性),见[策略指南](../guide/strategy.md#on-bars);其中 `on_expiry(ctx, event)` 在引擎实际执行到期结算后触发,`on_pre_open(ctx, event)` 在交易日首个时段开始前 1ns 触发(A 股 09:15 开盘集合竞价前),适合“盘前决策,本次 open 成交”,交易日钩子的完整时点见下文 [`akquant.Strategy`](#akquantstrategy);`on_error(ctx, error, source, payload)` 会在其他用户回调抛出异常时触发;`on_train_signal(ctx)` 仅在 ML 滚动训练窗口触发。
|
|
212
213
|
* `symbols`: 标的代码或代码列表。默认 `None`(**未显式传入**):数据里出现的标的即视为要跑的标的(“数据即订阅”),行为与传入前完全一致。**显式传入**(哪怕传的是当前数据里已有的标的)后语义变为「只跑这些标的」:白名单外的标的会被前置过滤掉,不进入引擎、不参与撮合与统计(多标的输入下,回测结果可能因此变化);显式传入空集合会报错,而不是退化为不过滤。白名单实际由 `symbols` ∪ `config.instruments` ∪(`__init__` 阶段)`self.subscribe()` 已订阅的标的三者合并而成;显式传了 `symbols` 后,`on_start` 里再 `subscribe()` 白名单外的标的会抛 `ValueError`(详见[策略指南](../guide/strategy.md)「策略生命周期」一节 `on_start` 的说明)。此校验仅作用于回测:实盘 `run_live` 从不下发白名单,`subscribe()` 不受约束。
|
|
213
214
|
* **`run_from_checkpoint` 的特例**:白名单合并的第三项不只是本次调用 `__init__` 阶段的 `subscribe()`——热启动恢复出来的策略实例带着**从存档 pickle 恢复的** `_subscriptions`(即上一段运行期间、含 `on_start` 里新增的全部订阅),这些也会并入白名单。也就是说,若阶段一的策略订阅过某个标的,阶段二哪怕不再显式 `subscribe()` 它,只要阶段二传了 `symbols`,该标的仍会留在合并后的白名单里——这是热启动「延续上一段状态」的整体语义的一部分,与「`__init__` 阶段订阅」并入 `run_backtest` 白名单的规则并非完全对称,请勿照搬 `run_backtest` 的白名单范围去推断 `run_from_checkpoint` 的实际过滤结果。
|
|
214
215
|
* **迁移提示(旧版 `symbols="BENCHMARK"` 写法)**:改动前,`symbol`/`symbols` 的签名默认值就是字面量 `"BENCHMARK"`(仓库内部分热启动示例也这么显式写过)。升级后,显式传入的值一律被当作真实过滤条件,不再等价于「未传」,且不同数据形态下会向**相反方向**出错:`List[Bar]` / `DataFeed` 形态因为数据里没有任何标的字面量等于 `"BENCHMARK"`,白名单谁都不放行,回测直接空跑(只有一条 WARNING,其余悄无声息);`DataFrame` / `Dict[str, DataFrame]` 形态则因为 `"BENCHMARK"` 触发了既有前置过滤判据的短路,反而完全不过滤。升级方式很简单:把显式的 `symbols="BENCHMARK"` **删掉(省略该参数)**,不要迁移成其他字面量。
|
|
@@ -954,6 +955,7 @@ def set_log_level(level: Union[str, int]) -> None
|
|
|
954
955
|
* `on_before_trading(trading_date, timestamp)`: 交易日最早的连续竞价开始后 1ns 触发,每个交易日至多一次(回测只为有行情的交易日触发,实盘按交易日历逐日触发;A 股 09:30:00 之后;有夜盘的期货交易日从前一交易日夜盘开始,周一交易日在周五 21:00 触发;交易日没有连续竞价段时不触发)。该回调按“前一交易日/前一时点信息可见”的语义工作。
|
|
955
956
|
* `on_pre_open(event: Dict[str, Any])`: 交易日首个时段开始前 1ns 触发,每个交易日一次(A 股 09:15 前,即 09:14:59.999…;有夜盘的期货为前一交易日 20:55 夜盘集合竞价前),不早于上一交易日的日终结算;回测与实盘一致。同一交易日它一定先于 `on_before_trading`。适合“盘前决策,本次 open 成交”;默认下单语义等价于 `NextOpen()`,这类单参加开盘集合竞价统一撮合(撮合在连续竞价开始时进行,成交价为竞价价,成交时间记在首个连续竞价事件上)。`event["expected_open_at"]` 是本次触发时刻,不是开盘时刻。示例见:`examples/52_pre_open_demo.py`。
|
|
956
957
|
* `on_cross_section(trading_date, timestamp)`: 横截面同周期调仓钩子。在框架看到当日首个“跨标的完整 bar 切片”后触发,每个交易日最多一次;与 `on_before_trading` 不同,它可以看到当日历史和当前账户快照,适合收盘价同周期调仓。调仓频率(日/周/月)在回调内用日历判断。
|
|
958
|
+
* `on_bars(batch: BarBatch)`: 批量回调(实验性)。同一时间片的 bar 到齐后触发一次,`batch` 是这一片的全部 bar(`batch.bars` 按标的升序,`batch["600000"]` 按标的取,`batch.missing` 是此前出现过、本片没有 bar 的标的,`batch.flush_reason` 是派发原因)。回测在时间片结束、下一片开始之前触发,其中下的单与在本片最后一根 `on_bar` 里下单同一口径;实盘在此前见过的标的全部到齐时触发,否则等到时间片时刻 + `bars_deadline_seconds`(策略类属性,默认 5 秒)。与 `on_bar` 同时重写时先逐根 `on_bar` 再 `on_bars`;只含基础周期的 bar。完整说明见[策略指南](../guide/strategy.md#on-bars)。
|
|
957
959
|
* `on_after_trading(trading_date, timestamp)`: 日终结算完成后触发,每个交易日一次。此时 T+1 已解冻、当日 Day 单已过期,其中下的单属于下一交易日。回测在收盘时刻;实盘在收盘 + `day_close_delay`(见 [run_live 实盘时区与交易时段](#live-timezone-sessions))。回测数据在盘中结束、当日未结算时不触发,停止时也不补发。
|
|
958
960
|
* `on_portfolio_update(snapshot)`: 账户快照变化时触发。
|
|
959
961
|
* `on_error(error, source, payload=None)`: 用户回调抛异常时触发。是否在触发 `on_error`
|
|
@@ -1,44 +1,39 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""多股票轮动策略示例(on_bars:每个时间片的 bar 到齐后执行一次).
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
不要在 on_bar 里自己数“攒满 N 根”再执行:有标的停牌或缺 bar 时那一片凑不齐,
|
|
4
|
+
整片都不会触发。on_bars 由框架判断时间片何时结束,缺的标的列在 batch.missing。
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
import math
|
|
4
8
|
|
|
5
9
|
import akquant as aq
|
|
6
10
|
import akshare as ak
|
|
7
11
|
import pandas as pd
|
|
8
|
-
from akquant import
|
|
12
|
+
from akquant import BarBatch, IntParam, Strategy
|
|
9
13
|
|
|
10
14
|
|
|
11
15
|
class BucketMomentumRotationStrategy(Strategy):
|
|
12
|
-
"""
|
|
16
|
+
"""每个时间片的 bar 到齐后执行一次横截面轮动."""
|
|
13
17
|
|
|
14
18
|
lookback_period = IntParam(20, ge=1, le=500, title="动量回看周期")
|
|
15
19
|
|
|
16
20
|
def on_start(self) -> None:
|
|
17
|
-
"""
|
|
21
|
+
"""设置轮动标的列表与数据预热长度."""
|
|
18
22
|
self.symbols = ["sh600519", "sz000858", "sh601318"]
|
|
19
23
|
self.warmup_period = self.params.lookback_period + 1
|
|
20
|
-
self._pending_by_ts: dict[int, set[str]] = defaultdict(set)
|
|
21
|
-
|
|
22
|
-
def on_bar(self, bar: Bar) -> None:
|
|
23
|
-
"""Bar 回调,收齐该 timestamp 后再调仓."""
|
|
24
|
-
current_set = self._pending_by_ts[bar.timestamp]
|
|
25
|
-
current_set.add(bar.symbol)
|
|
26
|
-
if len(current_set) < len(self.symbols):
|
|
27
|
-
return
|
|
28
|
-
self._pending_by_ts.pop(bar.timestamp, None)
|
|
29
|
-
self._rebalance()
|
|
30
24
|
|
|
31
|
-
def
|
|
25
|
+
def on_bars(self, batch: BarBatch) -> None:
|
|
26
|
+
"""批量回调:本时间片的 bar 到齐后调仓一次,只对本片有 bar 的标的打分."""
|
|
32
27
|
scores: dict[str, float] = {}
|
|
33
|
-
for
|
|
28
|
+
for bar in batch:
|
|
29
|
+
symbol = bar.symbol
|
|
34
30
|
closes = self.get_history(
|
|
35
31
|
count=self.params.lookback_period, symbol=symbol, field="close"
|
|
36
32
|
)
|
|
37
|
-
if len(closes) < self.params.lookback_period:
|
|
38
|
-
return
|
|
39
33
|
start = float(closes[0])
|
|
40
34
|
end = float(closes[-1])
|
|
41
|
-
|
|
35
|
+
# 历史不足时前面补 NaN
|
|
36
|
+
if math.isnan(start) or start <= 0:
|
|
42
37
|
continue
|
|
43
38
|
scores[symbol] = (end - start) / start
|
|
44
39
|
|
|
@@ -56,13 +56,13 @@
|
|
|
56
56
|
- 回调内只看到前一交易日 / 前一账户快照。
|
|
57
57
|
- 适合作为日边界准备和统一调仓入口。
|
|
58
58
|
|
|
59
|
-
### 6. [06_stock_momentum_rotation_bucket.py](./06_stock_momentum_rotation_bucket.py) -
|
|
60
|
-
- **目标**:
|
|
61
|
-
- **策略**:
|
|
59
|
+
### 6. [06_stock_momentum_rotation_bucket.py](./06_stock_momentum_rotation_bucket.py) - 每个时间片执行一次的横截面轮动
|
|
60
|
+
- **目标**: 演示用 `on_bars(batch)` 在每个时间片的 bar 到齐后执行一次横截面逻辑。
|
|
61
|
+
- **策略**: 批量回调 + 动量轮动策略。
|
|
62
62
|
- **核心点**:
|
|
63
|
-
-
|
|
64
|
-
-
|
|
65
|
-
-
|
|
63
|
+
- 时间片何时结束由框架判断,不必在 `on_bar` 里自己缓存和计数。
|
|
64
|
+
- 有标的停牌或缺 bar 时照常触发,缺的标的列在 `batch.missing`。
|
|
65
|
+
- 适用于每根 bar(日线、分钟线)都要跨标的打分与调仓的策略。
|
|
66
66
|
|
|
67
67
|
### 7. [07_stock_momentum_rotation_on_timer.py](./07_stock_momentum_rotation_on_timer.py) - `on_timer` 风格的横截面轮动
|
|
68
68
|
- **目标**: 演示把横截面打分与调仓逻辑集中放到 `on_timer` 中。
|
|
@@ -8,7 +8,7 @@ try:
|
|
|
8
8
|
except metadata.PackageNotFoundError:
|
|
9
9
|
__version__ = "0.0.0+unknown"
|
|
10
10
|
|
|
11
|
-
__engine_rule_version__ = "2.3.
|
|
11
|
+
__engine_rule_version__ = "2.3.1" # Increment on behavior-changing updates
|
|
12
12
|
|
|
13
13
|
from . import akquant as _akquant
|
|
14
14
|
from . import log as _log
|
|
@@ -31,6 +31,7 @@ from .backtest import ( # type: ignore
|
|
|
31
31
|
run_backtest,
|
|
32
32
|
run_from_checkpoint,
|
|
33
33
|
)
|
|
34
|
+
from .bar_batch import BarBatch
|
|
34
35
|
from .bar_generator import BarGenerator
|
|
35
36
|
from .checkpoint import load_checkpoint, save_checkpoint
|
|
36
37
|
from .config import (
|
|
@@ -152,6 +153,7 @@ if hasattr(_akquant, "__all__"): # noqa: F405
|
|
|
152
153
|
"inspect_strategy",
|
|
153
154
|
"StrategyRuntimeConfig",
|
|
154
155
|
"InstrumentSnapshot",
|
|
156
|
+
"BarBatch",
|
|
155
157
|
"BarGenerator",
|
|
156
158
|
"register_strategy_loader",
|
|
157
159
|
"resolve_strategy_input",
|
|
@@ -264,6 +266,7 @@ else:
|
|
|
264
266
|
"inspect_strategy",
|
|
265
267
|
"StrategyRuntimeConfig",
|
|
266
268
|
"InstrumentSnapshot",
|
|
269
|
+
"BarBatch",
|
|
267
270
|
"BarGenerator",
|
|
268
271
|
"register_strategy_loader",
|
|
269
272
|
"resolve_strategy_input",
|
|
@@ -64,6 +64,7 @@ class FunctionalStrategy(Strategy):
|
|
|
64
64
|
on_pre_open: Optional[Callable[[Any, Dict[str, Any]], None]] = ...,
|
|
65
65
|
on_timer: Optional[Callable[[Any, str], None]] = ...,
|
|
66
66
|
context: Optional[Dict[str, Any]] = ...,
|
|
67
|
+
on_bars: Optional[Callable[[Any, Any], None]] = ...,
|
|
67
68
|
) -> None: ...
|
|
68
69
|
|
|
69
70
|
class BacktestStreamEvent(TypedDict):
|
|
@@ -122,6 +123,7 @@ def run_backtest(
|
|
|
122
123
|
on_expiry: Optional[Callable[[Any, Dict[str, Any]], None]] = ...,
|
|
123
124
|
on_pre_open: Optional[Callable[[Any, Dict[str, Any]], None]] = ...,
|
|
124
125
|
on_timer: Optional[Callable[[Any, str], None]] = ...,
|
|
126
|
+
on_bars: Optional[Callable[[Any, Any], None]] = ...,
|
|
125
127
|
context: Optional[Dict[str, Any]] = ...,
|
|
126
128
|
history_depth: Optional[int] = ...,
|
|
127
129
|
warmup_period: int = ...,
|