investing-algorithm-framework 3.7.0__py3-none-any.whl → 7.19.15__py3-none-any.whl

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.

Potentially problematic release.


This version of investing-algorithm-framework might be problematic. Click here for more details.

Files changed (256) hide show
  1. investing_algorithm_framework/__init__.py +168 -45
  2. investing_algorithm_framework/app/__init__.py +32 -1
  3. investing_algorithm_framework/app/algorithm/__init__.py +7 -0
  4. investing_algorithm_framework/app/algorithm/algorithm.py +239 -0
  5. investing_algorithm_framework/app/algorithm/algorithm_factory.py +114 -0
  6. investing_algorithm_framework/app/analysis/__init__.py +15 -0
  7. investing_algorithm_framework/app/analysis/backtest_data_ranges.py +121 -0
  8. investing_algorithm_framework/app/analysis/backtest_utils.py +107 -0
  9. investing_algorithm_framework/app/analysis/permutation.py +116 -0
  10. investing_algorithm_framework/app/analysis/ranking.py +297 -0
  11. investing_algorithm_framework/app/app.py +1933 -589
  12. investing_algorithm_framework/app/app_hook.py +28 -0
  13. investing_algorithm_framework/app/context.py +1725 -0
  14. investing_algorithm_framework/app/eventloop.py +590 -0
  15. investing_algorithm_framework/app/reporting/__init__.py +27 -0
  16. investing_algorithm_framework/app/reporting/ascii.py +921 -0
  17. investing_algorithm_framework/app/reporting/backtest_report.py +349 -0
  18. investing_algorithm_framework/app/reporting/charts/__init__.py +19 -0
  19. investing_algorithm_framework/app/reporting/charts/entry_exist_signals.py +66 -0
  20. investing_algorithm_framework/app/reporting/charts/equity_curve.py +37 -0
  21. investing_algorithm_framework/app/reporting/charts/equity_curve_drawdown.py +74 -0
  22. investing_algorithm_framework/app/reporting/charts/line_chart.py +11 -0
  23. investing_algorithm_framework/app/reporting/charts/monthly_returns_heatmap.py +70 -0
  24. investing_algorithm_framework/app/reporting/charts/ohlcv_data_completeness.py +51 -0
  25. investing_algorithm_framework/app/reporting/charts/rolling_sharp_ratio.py +79 -0
  26. investing_algorithm_framework/app/reporting/charts/yearly_returns_barchart.py +55 -0
  27. investing_algorithm_framework/app/reporting/generate.py +185 -0
  28. investing_algorithm_framework/app/reporting/tables/__init__.py +11 -0
  29. investing_algorithm_framework/app/reporting/tables/key_metrics_table.py +217 -0
  30. investing_algorithm_framework/app/reporting/tables/stop_loss_table.py +0 -0
  31. investing_algorithm_framework/app/reporting/tables/time_metrics_table.py +80 -0
  32. investing_algorithm_framework/app/reporting/tables/trade_metrics_table.py +147 -0
  33. investing_algorithm_framework/app/reporting/tables/trades_table.py +75 -0
  34. investing_algorithm_framework/app/reporting/tables/utils.py +29 -0
  35. investing_algorithm_framework/app/reporting/templates/report_template.html.j2 +154 -0
  36. investing_algorithm_framework/app/stateless/action_handlers/__init__.py +4 -2
  37. investing_algorithm_framework/app/stateless/action_handlers/action_handler_strategy.py +1 -1
  38. investing_algorithm_framework/app/stateless/action_handlers/check_online_handler.py +1 -1
  39. investing_algorithm_framework/app/stateless/action_handlers/run_strategy_handler.py +14 -7
  40. investing_algorithm_framework/app/strategy.py +664 -84
  41. investing_algorithm_framework/app/task.py +5 -3
  42. investing_algorithm_framework/app/web/__init__.py +2 -1
  43. investing_algorithm_framework/app/web/create_app.py +4 -2
  44. investing_algorithm_framework/cli/__init__.py +0 -0
  45. investing_algorithm_framework/cli/cli.py +226 -0
  46. investing_algorithm_framework/cli/deploy_to_aws_lambda.py +501 -0
  47. investing_algorithm_framework/cli/deploy_to_azure_function.py +718 -0
  48. investing_algorithm_framework/cli/initialize_app.py +603 -0
  49. investing_algorithm_framework/cli/templates/.gitignore.template +178 -0
  50. investing_algorithm_framework/cli/templates/app.py.template +18 -0
  51. investing_algorithm_framework/cli/templates/app_aws_lambda_function.py.template +48 -0
  52. investing_algorithm_framework/cli/templates/app_azure_function.py.template +14 -0
  53. investing_algorithm_framework/cli/templates/app_web.py.template +18 -0
  54. investing_algorithm_framework/cli/templates/aws_lambda_dockerfile.template +22 -0
  55. investing_algorithm_framework/cli/templates/aws_lambda_dockerignore.template +92 -0
  56. investing_algorithm_framework/cli/templates/aws_lambda_readme.md.template +110 -0
  57. investing_algorithm_framework/cli/templates/aws_lambda_requirements.txt.template +2 -0
  58. investing_algorithm_framework/cli/templates/azure_function_function_app.py.template +65 -0
  59. investing_algorithm_framework/cli/templates/azure_function_host.json.template +15 -0
  60. investing_algorithm_framework/cli/templates/azure_function_local.settings.json.template +8 -0
  61. investing_algorithm_framework/cli/templates/azure_function_requirements.txt.template +3 -0
  62. investing_algorithm_framework/cli/templates/data_providers.py.template +17 -0
  63. investing_algorithm_framework/cli/templates/env.example.template +2 -0
  64. investing_algorithm_framework/cli/templates/env_azure_function.example.template +4 -0
  65. investing_algorithm_framework/cli/templates/market_data_providers.py.template +9 -0
  66. investing_algorithm_framework/cli/templates/readme.md.template +135 -0
  67. investing_algorithm_framework/cli/templates/requirements.txt.template +2 -0
  68. investing_algorithm_framework/cli/templates/run_backtest.py.template +20 -0
  69. investing_algorithm_framework/cli/templates/strategy.py.template +124 -0
  70. investing_algorithm_framework/create_app.py +40 -6
  71. investing_algorithm_framework/dependency_container.py +72 -56
  72. investing_algorithm_framework/domain/__init__.py +71 -47
  73. investing_algorithm_framework/domain/backtesting/__init__.py +21 -0
  74. investing_algorithm_framework/domain/backtesting/backtest.py +503 -0
  75. investing_algorithm_framework/domain/backtesting/backtest_date_range.py +96 -0
  76. investing_algorithm_framework/domain/backtesting/backtest_evaluation_focuss.py +242 -0
  77. investing_algorithm_framework/domain/backtesting/backtest_metrics.py +459 -0
  78. investing_algorithm_framework/domain/backtesting/backtest_permutation_test.py +275 -0
  79. investing_algorithm_framework/domain/backtesting/backtest_run.py +605 -0
  80. investing_algorithm_framework/domain/backtesting/backtest_summary_metrics.py +162 -0
  81. investing_algorithm_framework/domain/backtesting/combine_backtests.py +280 -0
  82. investing_algorithm_framework/domain/config.py +59 -91
  83. investing_algorithm_framework/domain/constants.py +13 -38
  84. investing_algorithm_framework/domain/data_provider.py +334 -0
  85. investing_algorithm_framework/domain/data_structures.py +3 -2
  86. investing_algorithm_framework/domain/exceptions.py +51 -1
  87. investing_algorithm_framework/domain/models/__init__.py +17 -12
  88. investing_algorithm_framework/domain/models/data/__init__.py +7 -0
  89. investing_algorithm_framework/domain/models/data/data_source.py +214 -0
  90. investing_algorithm_framework/domain/models/data/data_type.py +46 -0
  91. investing_algorithm_framework/domain/models/event.py +35 -0
  92. investing_algorithm_framework/domain/models/market/market_credential.py +55 -1
  93. investing_algorithm_framework/domain/models/order/order.py +77 -83
  94. investing_algorithm_framework/domain/models/order/order_status.py +2 -2
  95. investing_algorithm_framework/domain/models/order/order_type.py +1 -3
  96. investing_algorithm_framework/domain/models/portfolio/portfolio.py +81 -3
  97. investing_algorithm_framework/domain/models/portfolio/portfolio_configuration.py +26 -3
  98. investing_algorithm_framework/domain/models/portfolio/portfolio_snapshot.py +108 -11
  99. investing_algorithm_framework/domain/models/position/__init__.py +2 -1
  100. investing_algorithm_framework/domain/models/position/position.py +12 -0
  101. investing_algorithm_framework/domain/models/position/position_size.py +41 -0
  102. investing_algorithm_framework/domain/models/risk_rules/__init__.py +7 -0
  103. investing_algorithm_framework/domain/models/risk_rules/stop_loss_rule.py +51 -0
  104. investing_algorithm_framework/domain/models/risk_rules/take_profit_rule.py +55 -0
  105. investing_algorithm_framework/domain/models/snapshot_interval.py +45 -0
  106. investing_algorithm_framework/domain/models/strategy_profile.py +19 -151
  107. investing_algorithm_framework/domain/models/time_frame.py +37 -0
  108. investing_algorithm_framework/domain/models/time_interval.py +33 -0
  109. investing_algorithm_framework/domain/models/time_unit.py +66 -2
  110. investing_algorithm_framework/domain/models/trade/__init__.py +8 -1
  111. investing_algorithm_framework/domain/models/trade/trade.py +295 -171
  112. investing_algorithm_framework/domain/models/trade/trade_status.py +9 -2
  113. investing_algorithm_framework/domain/models/trade/trade_stop_loss.py +332 -0
  114. investing_algorithm_framework/domain/models/trade/trade_take_profit.py +365 -0
  115. investing_algorithm_framework/domain/order_executor.py +112 -0
  116. investing_algorithm_framework/domain/portfolio_provider.py +118 -0
  117. investing_algorithm_framework/domain/services/__init__.py +2 -9
  118. investing_algorithm_framework/domain/services/portfolios/portfolio_sync_service.py +0 -6
  119. investing_algorithm_framework/domain/services/state_handler.py +38 -0
  120. investing_algorithm_framework/domain/strategy.py +1 -29
  121. investing_algorithm_framework/domain/utils/__init__.py +12 -7
  122. investing_algorithm_framework/domain/utils/custom_tqdm.py +22 -0
  123. investing_algorithm_framework/domain/utils/dates.py +57 -0
  124. investing_algorithm_framework/domain/utils/jupyter_notebook_detection.py +19 -0
  125. investing_algorithm_framework/domain/utils/polars.py +53 -0
  126. investing_algorithm_framework/domain/utils/random.py +29 -0
  127. investing_algorithm_framework/download_data.py +108 -0
  128. investing_algorithm_framework/infrastructure/__init__.py +31 -18
  129. investing_algorithm_framework/infrastructure/data_providers/__init__.py +36 -0
  130. investing_algorithm_framework/infrastructure/data_providers/ccxt.py +1143 -0
  131. investing_algorithm_framework/infrastructure/data_providers/csv.py +568 -0
  132. investing_algorithm_framework/infrastructure/data_providers/pandas.py +599 -0
  133. investing_algorithm_framework/infrastructure/database/__init__.py +6 -2
  134. investing_algorithm_framework/infrastructure/database/sql_alchemy.py +86 -12
  135. investing_algorithm_framework/infrastructure/models/__init__.py +6 -11
  136. investing_algorithm_framework/infrastructure/models/order/__init__.py +2 -1
  137. investing_algorithm_framework/infrastructure/models/order/order.py +35 -49
  138. investing_algorithm_framework/infrastructure/models/order/order_metadata.py +44 -0
  139. investing_algorithm_framework/infrastructure/models/order_trade_association.py +10 -0
  140. investing_algorithm_framework/infrastructure/models/portfolio/__init__.py +1 -1
  141. investing_algorithm_framework/infrastructure/models/portfolio/portfolio_snapshot.py +8 -0
  142. investing_algorithm_framework/infrastructure/models/portfolio/{portfolio.py → sql_portfolio.py} +17 -5
  143. investing_algorithm_framework/infrastructure/models/trades/__init__.py +9 -0
  144. investing_algorithm_framework/infrastructure/models/trades/trade.py +130 -0
  145. investing_algorithm_framework/infrastructure/models/trades/trade_stop_loss.py +59 -0
  146. investing_algorithm_framework/infrastructure/models/trades/trade_take_profit.py +55 -0
  147. investing_algorithm_framework/infrastructure/order_executors/__init__.py +21 -0
  148. investing_algorithm_framework/infrastructure/order_executors/backtest_oder_executor.py +28 -0
  149. investing_algorithm_framework/infrastructure/order_executors/ccxt_order_executor.py +200 -0
  150. investing_algorithm_framework/infrastructure/portfolio_providers/__init__.py +19 -0
  151. investing_algorithm_framework/infrastructure/portfolio_providers/ccxt_portfolio_provider.py +199 -0
  152. investing_algorithm_framework/infrastructure/repositories/__init__.py +8 -0
  153. investing_algorithm_framework/infrastructure/repositories/order_metadata_repository.py +17 -0
  154. investing_algorithm_framework/infrastructure/repositories/order_repository.py +5 -0
  155. investing_algorithm_framework/infrastructure/repositories/portfolio_repository.py +1 -1
  156. investing_algorithm_framework/infrastructure/repositories/position_repository.py +11 -0
  157. investing_algorithm_framework/infrastructure/repositories/repository.py +81 -27
  158. investing_algorithm_framework/infrastructure/repositories/trade_repository.py +71 -0
  159. investing_algorithm_framework/infrastructure/repositories/trade_stop_loss_repository.py +29 -0
  160. investing_algorithm_framework/infrastructure/repositories/trade_take_profit_repository.py +29 -0
  161. investing_algorithm_framework/infrastructure/services/__init__.py +4 -4
  162. investing_algorithm_framework/infrastructure/services/aws/__init__.py +6 -0
  163. investing_algorithm_framework/infrastructure/services/aws/state_handler.py +113 -0
  164. investing_algorithm_framework/infrastructure/services/azure/__init__.py +5 -0
  165. investing_algorithm_framework/infrastructure/services/azure/state_handler.py +158 -0
  166. investing_algorithm_framework/services/__init__.py +113 -16
  167. investing_algorithm_framework/services/backtesting/__init__.py +0 -7
  168. investing_algorithm_framework/services/backtesting/backtest_service.py +566 -359
  169. investing_algorithm_framework/services/configuration_service.py +77 -11
  170. investing_algorithm_framework/services/data_providers/__init__.py +5 -0
  171. investing_algorithm_framework/services/data_providers/data_provider_service.py +850 -0
  172. investing_algorithm_framework/services/market_credential_service.py +16 -1
  173. investing_algorithm_framework/services/metrics/__init__.py +114 -0
  174. investing_algorithm_framework/services/metrics/alpha.py +0 -0
  175. investing_algorithm_framework/services/metrics/beta.py +0 -0
  176. investing_algorithm_framework/services/metrics/cagr.py +60 -0
  177. investing_algorithm_framework/services/metrics/calmar_ratio.py +40 -0
  178. investing_algorithm_framework/services/metrics/drawdown.py +181 -0
  179. investing_algorithm_framework/services/metrics/equity_curve.py +24 -0
  180. investing_algorithm_framework/services/metrics/exposure.py +210 -0
  181. investing_algorithm_framework/services/metrics/generate.py +358 -0
  182. investing_algorithm_framework/services/metrics/mean_daily_return.py +83 -0
  183. investing_algorithm_framework/services/metrics/profit_factor.py +165 -0
  184. investing_algorithm_framework/services/metrics/recovery.py +113 -0
  185. investing_algorithm_framework/services/metrics/returns.py +452 -0
  186. investing_algorithm_framework/services/metrics/risk_free_rate.py +28 -0
  187. investing_algorithm_framework/services/metrics/sharpe_ratio.py +137 -0
  188. investing_algorithm_framework/services/metrics/sortino_ratio.py +74 -0
  189. investing_algorithm_framework/services/metrics/standard_deviation.py +157 -0
  190. investing_algorithm_framework/services/metrics/trades.py +500 -0
  191. investing_algorithm_framework/services/metrics/treynor_ratio.py +0 -0
  192. investing_algorithm_framework/services/metrics/ulcer.py +0 -0
  193. investing_algorithm_framework/services/metrics/value_at_risk.py +0 -0
  194. investing_algorithm_framework/services/metrics/volatility.py +97 -0
  195. investing_algorithm_framework/services/metrics/win_rate.py +177 -0
  196. investing_algorithm_framework/services/order_service/__init__.py +3 -1
  197. investing_algorithm_framework/services/order_service/order_backtest_service.py +76 -89
  198. investing_algorithm_framework/services/order_service/order_executor_lookup.py +110 -0
  199. investing_algorithm_framework/services/order_service/order_service.py +407 -326
  200. investing_algorithm_framework/services/portfolios/__init__.py +3 -1
  201. investing_algorithm_framework/services/portfolios/backtest_portfolio_service.py +37 -3
  202. investing_algorithm_framework/services/portfolios/portfolio_configuration_service.py +22 -8
  203. investing_algorithm_framework/services/portfolios/portfolio_provider_lookup.py +106 -0
  204. investing_algorithm_framework/services/portfolios/portfolio_service.py +96 -28
  205. investing_algorithm_framework/services/portfolios/portfolio_snapshot_service.py +97 -28
  206. investing_algorithm_framework/services/portfolios/portfolio_sync_service.py +116 -313
  207. investing_algorithm_framework/services/positions/__init__.py +7 -0
  208. investing_algorithm_framework/services/positions/position_service.py +210 -0
  209. investing_algorithm_framework/services/repository_service.py +8 -2
  210. investing_algorithm_framework/services/trade_order_evaluator/__init__.py +9 -0
  211. investing_algorithm_framework/services/trade_order_evaluator/backtest_trade_oder_evaluator.py +113 -0
  212. investing_algorithm_framework/services/trade_order_evaluator/default_trade_order_evaluator.py +51 -0
  213. investing_algorithm_framework/services/trade_order_evaluator/trade_order_evaluator.py +80 -0
  214. investing_algorithm_framework/services/trade_service/__init__.py +7 -1
  215. investing_algorithm_framework/services/trade_service/trade_service.py +1013 -315
  216. investing_algorithm_framework/services/trade_service/trade_stop_loss_service.py +39 -0
  217. investing_algorithm_framework/services/trade_service/trade_take_profit_service.py +41 -0
  218. investing_algorithm_framework-7.19.15.dist-info/METADATA +537 -0
  219. investing_algorithm_framework-7.19.15.dist-info/RECORD +263 -0
  220. investing_algorithm_framework-7.19.15.dist-info/entry_points.txt +3 -0
  221. investing_algorithm_framework/app/algorithm.py +0 -1105
  222. investing_algorithm_framework/domain/graphs.py +0 -382
  223. investing_algorithm_framework/domain/metrics/__init__.py +0 -6
  224. investing_algorithm_framework/domain/models/backtesting/__init__.py +0 -11
  225. investing_algorithm_framework/domain/models/backtesting/backtest_date_range.py +0 -43
  226. investing_algorithm_framework/domain/models/backtesting/backtest_position.py +0 -120
  227. investing_algorithm_framework/domain/models/backtesting/backtest_report.py +0 -580
  228. investing_algorithm_framework/domain/models/backtesting/backtest_reports_evaluation.py +0 -243
  229. investing_algorithm_framework/domain/models/trading_data_types.py +0 -47
  230. investing_algorithm_framework/domain/models/trading_time_frame.py +0 -223
  231. investing_algorithm_framework/domain/services/market_data_sources.py +0 -344
  232. investing_algorithm_framework/domain/services/market_service.py +0 -153
  233. investing_algorithm_framework/domain/singleton.py +0 -9
  234. investing_algorithm_framework/domain/utils/backtesting.py +0 -472
  235. investing_algorithm_framework/infrastructure/models/market_data_sources/__init__.py +0 -12
  236. investing_algorithm_framework/infrastructure/models/market_data_sources/ccxt.py +0 -559
  237. investing_algorithm_framework/infrastructure/models/market_data_sources/csv.py +0 -254
  238. investing_algorithm_framework/infrastructure/models/market_data_sources/us_treasury_yield.py +0 -47
  239. investing_algorithm_framework/infrastructure/services/market_service/__init__.py +0 -5
  240. investing_algorithm_framework/infrastructure/services/market_service/ccxt_market_service.py +0 -455
  241. investing_algorithm_framework/infrastructure/services/performance_service/__init__.py +0 -7
  242. investing_algorithm_framework/infrastructure/services/performance_service/backtest_performance_service.py +0 -2
  243. investing_algorithm_framework/infrastructure/services/performance_service/performance_service.py +0 -350
  244. investing_algorithm_framework/services/backtesting/backtest_report_writer_service.py +0 -53
  245. investing_algorithm_framework/services/backtesting/graphs.py +0 -61
  246. investing_algorithm_framework/services/market_data_source_service/__init__.py +0 -8
  247. investing_algorithm_framework/services/market_data_source_service/backtest_market_data_source_service.py +0 -150
  248. investing_algorithm_framework/services/market_data_source_service/market_data_source_service.py +0 -189
  249. investing_algorithm_framework/services/position_service.py +0 -31
  250. investing_algorithm_framework/services/strategy_orchestrator_service.py +0 -264
  251. investing_algorithm_framework-3.7.0.dist-info/METADATA +0 -339
  252. investing_algorithm_framework-3.7.0.dist-info/RECORD +0 -147
  253. /investing_algorithm_framework/{domain → services}/metrics/price_efficiency.py +0 -0
  254. /investing_algorithm_framework/services/{position_snapshot_service.py → positions/position_snapshot_service.py} +0 -0
  255. {investing_algorithm_framework-3.7.0.dist-info → investing_algorithm_framework-7.19.15.dist-info}/LICENSE +0 -0
  256. {investing_algorithm_framework-3.7.0.dist-info → investing_algorithm_framework-7.19.15.dist-info}/WHEEL +0 -0
@@ -1,339 +0,0 @@
1
- Metadata-Version: 2.1
2
- Name: investing-algorithm-framework
3
- Version: 3.7.0
4
- Summary: A framework for creating trading bots
5
- Author: MDUYN
6
- Requires-Python: >=3.8.1,<4.0.0
7
- Classifier: Programming Language :: Python :: 3
8
- Classifier: Programming Language :: Python :: 3.9
9
- Classifier: Programming Language :: Python :: 3.10
10
- Classifier: Programming Language :: Python :: 3.11
11
- Classifier: Programming Language :: Python :: 3.12
12
- Requires-Dist: Flask (>=2.3.2,<3.0.0)
13
- Requires-Dist: Flask-Cors (>=3.0.9,<5.0.0)
14
- Requires-Dist: Flask-Migrate (>=2.6.0,<3.0.0)
15
- Requires-Dist: MarkupSafe (>=2.1.2,<3.0.0)
16
- Requires-Dist: SQLAlchemy (>=2.0.18,<3.0.0)
17
- Requires-Dist: ccxt (>=4.2.48,<5.0.0)
18
- Requires-Dist: dependency-injector (>=4.40.0,<5.0.0)
19
- Requires-Dist: jupyter (>=1.0.0,<2.0.0)
20
- Requires-Dist: marshmallow (>=3.5.0,<4.0.0)
21
- Requires-Dist: plotly (>=5.22.0,<6.0.0)
22
- Requires-Dist: polars[numpy,pandas] (>=0.20.10,<0.21.0)
23
- Requires-Dist: python-dateutil (>=2.8.2,<3.0.0)
24
- Requires-Dist: schedule (>=1.1.0,<2.0.0)
25
- Requires-Dist: tabulate (>=0.9.0,<0.10.0)
26
- Requires-Dist: tqdm (>=4.66.1,<5.0.0)
27
- Requires-Dist: wrapt (>=1.16.0,<2.0.0)
28
- Description-Content-Type: text/markdown
29
-
30
- <a href=https://investing-algorithm-framework.com><img src="https://img.shields.io/badge/docs-website-brightgreen"></a>
31
- [![Build](https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/publish.yml/badge.svg)](https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/publish.yml)
32
- [![Tests](https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/test.yml/badge.svg?branch=master)](https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/test.yml)
33
- [![Downloads](https://pepy.tech/badge/investing-algorithm-framework)](https://pepy.tech/badge/investing-algorithm-framework)
34
- [![Current Version](https://img.shields.io/pypi/v/investing_algorithm_framework.svg)](https://img.shields.io/pypi/v/investing_algorithm_framework.svg)
35
- <a href="https://www.reddit.com/r/InvestingBots/"><img src="https://img.shields.io/reddit/subreddit-subscribers/investingbots?style=social"></a> <br/>
36
- [![GitHub stars](https://img.shields.io/github/stars/coding-kitties/investing-algorithm-framework.svg?style=social&label=Star&maxAge=1)](https://github.com/SeaQL/sea-orm/stargazers/) If you like what we do, consider starring, sharing and contributing!
37
-
38
- ###### Sponsors
39
- <p align="left">
40
- <a href="https://finterion.com">
41
- <img alt="Finterion" src="static/sponsors/finterion.png" width="200px" />
42
- </a>
43
- </p>
44
-
45
- # [Investing Algorithm Framework](https://github.com/coding-kitties/investing-algorithm-framework)
46
-
47
- The Investing Algorithm Framework is a Python tool that enables swift and
48
- elegant development of trading bots. It comes with all the necessary
49
- components for creating algorithms, including data provisioning,
50
- portfolio management, and order execution.
51
-
52
- Features:
53
- * Order execution and tracking
54
- * Broker and exchange connections through [ccxt](https://github.com/ccxt/ccxt)
55
- * Backtesting and performance analysis reports [example](./examples/backtest_example)
56
- * Backtesting multiple algorithms with different backtest date ranges [example](./examples/backtests_example)
57
- * Portfolio management and tracking
58
- * Tracing for analyzing and debugging your trading bot
59
- * Web API for interacting with your deployed trading bot
60
- * Data persistence through sqlite db or an in-memory db
61
- * Stateless running for cloud function deployments
62
- * Polars dataframes support out of the box for fast data processing [pola.rs](https://pola.rs/)
63
-
64
- ## Example implementation
65
- The following algorithm connects to binance and buys BTC every 5 seconds.
66
- It also exposes an REST API that allows you to interact with the algorithm.
67
- ```python
68
- import pathlib
69
- from investing_algorithm_framework import create_app, PortfolioConfiguration, \
70
- RESOURCE_DIRECTORY, TimeUnit, CCXTOHLCVMarketDataSource, Algorithm, \
71
- CCXTTickerMarketDataSource, MarketCredential, SYMBOLS
72
-
73
- # Define the symbols you want to trade for optimization, otherwise the
74
- # algorithm will check if you have orders and balances on all available
75
- # symbols on the market
76
- symbols = ["BTC/EUR"]
77
-
78
- # Define resource directory and the symbols you want to trade
79
- config = {
80
- RESOURCE_DIRECTORY: pathlib.Path(__file__).parent.resolve()
81
- SYMBOLS: symbols
82
- }
83
-
84
- # Define market data sources
85
- # OHLCV data for candles
86
- bitvavo_btc_eur_ohlcv_2h = CCXTOHLCVMarketDataSource(
87
- identifier="BTC-ohlcv",
88
- market="BITVAVO",
89
- symbol="BTC/EUR",
90
- timeframe="2h",
91
- window_size=200
92
- )
93
- # Ticker data for orders, trades and positions
94
- bitvavo_btc_eur_ticker = CCXTTickerMarketDataSource(
95
- identifier="BTC-ticker",
96
- market="BITVAVO",
97
- symbol="BTC/EUR",
98
- )
99
- app = create_app(config=config)
100
- algorithm = Algorithm()
101
- app.add_market_credential(MarketCredential(
102
- market="bitvavo",
103
- api_key="<your api key>",
104
- secret_key="<your secret key>",
105
- ))
106
- app.add_portfolio_configuration(
107
- PortfolioConfiguration(
108
- market="bitvavo",
109
- trading_symbol="EUR",
110
- initial_balance=400
111
- )
112
- )
113
- app.add_algorithm(algorithm)
114
-
115
- @algorithm.strategy(
116
- # Run every two hours
117
- time_unit=TimeUnit.HOUR,
118
- interval=2,
119
- # Specify market data sources that need to be passed to the strategy
120
- market_data_sources=[bitvavo_btc_eur_ticker, bitvavo_btc_eur_ohlcv_2h]
121
- )
122
- def perform_strategy(algorithm: Algorithm, market_data: dict):
123
- # By default, ohlcv data is passed as polars df in the form of
124
- # {"<identifier>": <dataframe>} https://pola.rs/,
125
- # call to_pandas() to convert to pandas
126
- polars_df = market_data["BTC-ohlcv"]
127
- print(f"I have access to {len(polars_df)} candles of ohlcv data")
128
-
129
- # Ticker data is passed as {"<identifier>": <ticker dict>}
130
- ticker_data = market_data["BTC-ticker"]
131
- unallocated_balance = algorithm.get_unallocated()
132
- positions = algorithm.get_positions()
133
- trades = algorithm.get_trades()
134
- open_trades = algorithm.get_open_trades()
135
- closed_trades = algorithm.get_closed_trades()
136
-
137
- # Create a buy oder
138
- algorithm.create_limit_order(
139
- target_symbol="BTC/EUR",
140
- order_side="buy",
141
- amount=0.01,
142
- price=ticker_data["ask"],
143
- )
144
-
145
- # Close a trade
146
- algorithm.close_trade(trades[0].id)
147
-
148
- # Close a position
149
- algorithm.close_position(positions[0].get_symbol())
150
-
151
- if __name__ == "__main__":
152
- app.run()
153
- ```
154
-
155
- > You can find more examples [here](./examples) folder.
156
-
157
- ## Backtesting and experiments
158
- The framework also supports backtesting and performing backtest experiments. After
159
- a backtest, you can print a report that shows the performance of your trading bot.
160
-
161
- To run a single backtest you can use the example code that can be found [here](./examples/backtest).
162
-
163
- ### Backtesting report
164
- You can use the ```pretty_print_backtest``` function to print a backtest report.
165
- For example if you run the [moving average example trading bot](./examples/crossover_moving_average_trading_bot)
166
- you will get the following backtesting report:
167
-
168
- ```bash
169
-
170
- :%%%#+- .=*#%%% Backtest report
171
- *%%%%%%%+------=*%%%%%%%- ---------------------------
172
- *%%%%%%%%%%%%%%%%%%%%%%%- Start date: 2023-08-24 00:00:00
173
- .%%%%%%%%%%%%%%%%%%%%%%# End date: 2023-12-02 00:00:00
174
- #%%%####%%%%%%%%**#%%%+ Number of days: 100
175
- .:-+*%%%%- -+..#%%%+.+- +%%%#*=-: Number of runs: 1201
176
- .:-=*%%%%. += .%%# -+.-%%%%=-:.. Number of orders: 40
177
- .:=+#%%%%%*###%%%%#*+#%%%%%%*+-: Initial balance: 400.0
178
- +%%%%%%%%%%%%%%%%%%%= Final balance: 428.2434
179
- :++ .=#%%%%%%%%%%%%%*- Total net gain: 28.2434 7.061%
180
- :++: :+%%%%%%#-. Growth: 28.2434 7.061%
181
- :++: .%%%%%#= Number of trades closed: 20
182
- :++: .#%%%%%#*= Number of trades open(end of backtest): 0
183
- :++- :%%%%%%%%%+= Percentage positive trades: 30.0%
184
- .++- -%%%%%%%%%%%+= Percentage negative trades: 70.0%
185
- .++- .%%%%%%%%%%%%%+= Average trade size: 100.9692 EUR
186
- .++- *%%%%%%%%%%%%%*+: Average trade duration: 83.6 hours
187
- .++- %%%%%%%%%%%%%%#+=
188
- =++........:::%%%%%%%%%%%%%%*+-
189
- .=++++++++++**#%%%%%%%%%%%%%++.
190
-
191
- Price noise
192
-
193
- Positions overview
194
- ╭────────────┬──────────┬──────────────────────┬───────────────────────┬──────────────┬───────────────┬───────────────────────────┬────────────────┬───────────────╮
195
- │ Position │ Amount │ Pending buy amount │ Pending sell amount │ Cost (EUR) │ Value (EUR) │ Percentage of portfolio │ Growth (EUR) │ Growth_rate │
196
- ├────────────┼──────────┼──────────────────────┼───────────────────────┼──────────────┼───────────────┼───────────────────────────┼────────────────┼───────────────┤
197
- │ EUR │ 428.243 │ 0 │ 0 │ 428.243 │ 428.243 │ 100.0000% │ 0 │ 0.0000% │
198
- ├────────────┼──────────┼──────────────────────┼───────────────────────┼──────────────┼───────────────┼───────────────────────────┼────────────────┼───────────────┤
199
- │ DOT │ 0 │ 0 │ 0 │ 0 │ 0 │ 0.0000% │ 0 │ 0.0000% │
200
- ├────────────┼──────────┼──────────────────────┼───────────────────────┼──────────────┼───────────────┼───────────────────────────┼────────────────┼───────────────┤
201
- │ BTC │ 0 │ 0 │ 0 │ 0 │ 0 │ 0.0000% │ 0 │ 0.0000% │
202
- ╰────────────┴──────────┴──────────────────────┴───────────────────────┴──────────────┴───────────────┴───────────────────────────┴────────────────┴───────────────╯
203
- Trades overview
204
- ╭─────────┬─────────────────────┬─────────────────────┬────────────────────┬──────────────┬──────────────────┬───────────────────────┬────────────────────┬─────────────────────╮
205
- │ Pair │ Open date │ Close date │ Duration (hours) │ Size (EUR) │ Net gain (EUR) │ Net gain percentage │ Open price (EUR) │ Close price (EUR) │
206
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
207
- │ DOT-EUR │ 2023-11-24 12:00:00 │ 2023-11-27 14:00:00 │ 74 │ 107.55 │ -1.9587 │ -1.8212% │ 4.777 │ 4.69 │
208
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
209
- │ DOT-EUR │ 2023-11-20 00:00:00 │ 2023-11-21 08:00:00 │ 32 │ 109.39 │ -4.5949 │ -4.2005% │ 4.9875 │ 4.778 │
210
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
211
- │ BTC-EUR │ 2023-11-19 22:00:00 │ 2023-11-22 00:00:00 │ 50 │ 109.309 │ -2.7624 │ -2.5272% │ 34159.1 │ 33295.9 │
212
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
213
- │ BTC-EUR │ 2023-11-06 12:00:00 │ 2023-11-13 14:00:00 │ 170 │ 107.864 │ 6.1015 │ 5.6567% │ 32685.9 │ 34534.9 │
214
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
215
- │ DOT-EUR │ 2023-10-20 12:00:00 │ 2023-10-27 08:00:00 │ 164 │ 99.085 │ 10.9799 │ 11.0813% │ 3.5465 │ 3.9395 │
216
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
217
- │ BTC-EUR │ 2023-10-14 04:00:00 │ 2023-10-27 22:00:00 │ 330 │ 97.4278 │ 24.137 │ 24.7742% │ 25638.9 │ 31990.7 │
218
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
219
- │ DOT-EUR │ 2023-10-14 04:00:00 │ 2023-10-17 14:00:00 │ 82 │ 99.5572 │ -1.8877 │ -1.8961% │ 3.56 │ 3.4925 │
220
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
221
- │ DOT-EUR │ 2023-10-07 08:00:00 │ 2023-10-08 08:00:00 │ 24 │ 99.9498 │ -1.5708 │ -1.5716% │ 3.8815 │ 3.8205 │
222
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
223
- │ BTC-EUR │ 2023-09-27 10:00:00 │ 2023-10-05 20:00:00 │ 202 │ 98.2888 │ 3.433 │ 3.4927% │ 25202.2 │ 26082.5 │
224
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
225
- │ DOT-EUR │ 2023-09-27 10:00:00 │ 2023-10-03 20:00:00 │ 154 │ 98.7893 │ 1.2085 │ 1.2233% │ 3.842 │ 3.889 │
226
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
227
- │ DOT-EUR │ 2023-09-25 12:00:00 │ 2023-09-27 04:00:00 │ 40 │ 98.9193 │ -0.5194 │ -0.5251% │ 3.809 │ 3.789 │
228
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
229
- │ DOT-EUR │ 2023-09-14 16:00:00 │ 2023-09-18 02:00:00 │ 82 │ 98.9419 │ -0.0912 │ -0.0921% │ 3.799 │ 3.7955 │
230
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
231
- │ BTC-EUR │ 2023-09-07 06:00:00 │ 2023-09-10 16:00:00 │ 82 │ 98.6093 │ 0.3412 │ 0.3460% │ 24051 │ 24134.3 │
232
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
233
- │ DOT-EUR │ 2023-09-07 00:00:00 │ 2023-09-09 02:00:00 │ 50 │ 98.9158 │ -0.2358 │ -0.2383% │ 3.986 │ 3.9765 │
234
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
235
- │ DOT-EUR │ 2023-09-05 14:00:00 │ 2023-09-06 12:00:00 │ 22 │ 99.2132 │ -1.1909 │ -1.2003% │ 3.999 │ 3.951 │
236
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
237
- │ DOT-EUR │ 2023-09-04 16:00:00 │ 2023-09-04 22:00:00 │ 6 │ 99.355 │ -0.5671 │ -0.5708% │ 3.942 │ 3.9195 │
238
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
239
- │ DOT-EUR │ 2023-09-04 10:00:00 │ 2023-09-04 14:00:00 │ 4 │ 99.4774 │ -0.4889 │ -0.4914% │ 3.968 │ 3.9485 │
240
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
241
- │ BTC-EUR │ 2023-08-26 10:00:00 │ 2023-08-26 18:00:00 │ 8 │ 99.0829 │ -0.03 │ -0.0302% │ 24166.6 │ 24159.3 │
242
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
243
- │ DOT-EUR │ 2023-08-25 10:00:00 │ 2023-08-28 10:00:00 │ 72 │ 99.659 │ -0.6975 │ -0.6999% │ 4.1435 │ 4.1145 │
244
- ├─────────┼─────────────────────┼─────────────────────┼────────────────────┼──────────────┼──────────────────┼───────────────────────┼────────────────────┼─────────────────────┤
245
- │ DOT-EUR │ 2023-08-24 00:00:00 │ 2023-08-25 00:00:00 │ 24 │ 99.9999 │ -1.3626 │ -1.3626% │ 4.1465 │ 4.09 │
246
- ╰─────────┴─────────────────────┴─────────────────────┴────────────────────┴──────────────┴──────────────────┴───────────────────────┴────────────────────┴─────────────────────╯
247
- ```
248
-
249
- ### Backtest experiments
250
- The framework also supports backtest experiments. Backtest experiments allows you to
251
- compare multiple algorithms and evaluate their performance. Ideally,
252
- you would do this by parameterizing your strategy and creating a factory function that
253
- creates the algorithm with the different parameters. You can find an example of this
254
- in the [backtest experiments example](./examples/backtest_experiment).
255
-
256
- ## Broker/Exchange configuration
257
- The framework has by default support for [ccxt](https://github.com/ccxt/ccxt).
258
- This should allow you to connect to a lot of brokers/exchanges.
259
-
260
- ```python
261
- from investing_algorithm_framework import PortfolioConfiguration, \
262
- MarketCredential, create_app
263
- app = create_app()
264
- app.add_market_credential(
265
- MarketCredential(
266
- market="<your market>",
267
- api_key="<your api key>",
268
- secret_key="<your secret key>",
269
- )
270
- )
271
- app.add_portfolio_configuration(
272
- PortfolioConfiguration(
273
- market="<your market>",
274
- initial_balance=400,
275
- track_from="01/01/2022",
276
- trading_symbol="EUR"
277
- )
278
- )
279
- ```
280
-
281
- ## Performance
282
- We are continuously working on improving the performance of the framework. If
283
- you have any suggestions, please let us know.
284
-
285
- ## Download
286
- You can download the framework with pypi.
287
-
288
- ```bash
289
- pip install investing-algorithm-framework
290
- ```
291
-
292
- ## Disclaimer
293
- If you use this framework for your investments, do not risk money
294
- which you are afraid to lose, until you have clear understanding how
295
- the framework works. We can't stress this enough:
296
-
297
- BEFORE YOU START USING MONEY WITH THE FRAMEWORK, MAKE SURE THAT YOU TESTED
298
- YOUR COMPONENTS THOROUGHLY. USE THE SOFTWARE AT YOUR OWN RISK.
299
- THE AUTHORS AND ALL AFFILIATES ASSUME NO RESPONSIBILITY FOR YOUR INVESTMENT RESULTS.
300
-
301
- Also, make sure that you read the source code of any plugin you use or
302
- implementation of an algorithm made with this framework.
303
-
304
- ## Documentation
305
-
306
- All the documentation can be found online
307
- at the [documentation webstie](https://investing-algorithm-framework.com)
308
-
309
- In most cases, you'll probably never have to change code on this repo directly
310
- if you are building your algorithm/bot. But if you do, check out the
311
- contributing page at the website.
312
-
313
- If you'd like to chat with investing-algorithm-framework users
314
- and developers, [join us on Slack](https://inv-algo-framework.slack.com) or [join us on reddit](https://www.reddit.com/r/InvestingBots/)
315
-
316
- ## Acknowledgements
317
- We want to thank all contributors to this project. A full list of all
318
- the people that contributed to the project can be
319
- found [here](https://github.com/investing-algorithms/investing-algorithm-framework/blob/master/AUTHORS.md)
320
-
321
- ### [Bugs / Issues](https://github.com/investing-algorithms/investing-algorithm-framework/issues?q=is%3Aissue)
322
-
323
- If you discover a bug in the framework, please [search our issue tracker](https://github.com/investing-algorithms/investing-algorithm-framework/issues?q=is%3Aissue)
324
- first. If it hasn't been reported, please [create a new issue](https://github.com/investing-algorithms/investing-algorithm-framework/issues/new).
325
-
326
- ### Contributing
327
- The investing algorithm framework is a community driven project.
328
- We welcome you to participate, contribute and together help build
329
- the future trading bots developed in python.
330
-
331
- Feel like the framework is missing a feature? We welcome your pull requests!
332
- If you want to contribute to the project roadmap, please take a look at the [project board](https://github.com/coding-kitties/investing-algorithm-framework/projects?query=is%3Aopen).
333
- You can pick up a task by assigning yourself to it.
334
-
335
- **Note** before starting any major new feature work, *please open an issue describing what you are planning to do*.
336
- This will ensure that interested parties can give valuable feedback on the feature, and let others know that you are working on it.
337
-
338
- **Important:** Always create your feature or hotfix against the `develop` branch, not `master`.
339
-
@@ -1,147 +0,0 @@
1
- investing_algorithm_framework/__init__.py,sha256=Zb8jDyYDFjBvEZhjmoH83MDGy2nAwvIuVcKBRCi2qR8,2585
2
- investing_algorithm_framework/app/__init__.py,sha256=MsdCLd2Z6a-xMk3U1ExPPAhxg-DvvHELsIRbsumxcek,501
3
- investing_algorithm_framework/app/algorithm.py,sha256=qF47kOdFmeSOLY0eJrdwLmUCEsOUHW9WqbRd7YuahbI,36933
4
- investing_algorithm_framework/app/app.py,sha256=Ge1YsoKtnVXk0fjIN-pTtUAgCramQbCerpzS1zgbFYQ,32400
5
- investing_algorithm_framework/app/stateless/__init__.py,sha256=VuEfb7QqDsfpFCnZdpvw8vvpNMRqOb-3w0yOpHiYlWg,1092
6
- investing_algorithm_framework/app/stateless/action_handlers/__init__.py,sha256=fn3Cz-Yr3NuHc5sW4A7Cjma2jrCx6Y8LG7zunyvQSgI,2362
7
- investing_algorithm_framework/app/stateless/action_handlers/action_handler_strategy.py,sha256=Ws687Syr1ytQFXaOMpp2CGKqw2ru22elTdWuVA5IiMc,154
8
- investing_algorithm_framework/app/stateless/action_handlers/check_online_handler.py,sha256=kpU7vG9zMjRi8q335MT7qov_SW0GHu1Sz0YLPHZrzUM,452
9
- investing_algorithm_framework/app/stateless/action_handlers/run_strategy_handler.py,sha256=2DF3EKmvVe04wrOuilRppNDyJFC8GmdOdeqc4DZP6h8,1062
10
- investing_algorithm_framework/app/stateless/exception_handler.py,sha256=EoujrXd_TJ0cXLsEukRgdT7bw_kAH6OiCpZGcV8bVhc,1085
11
- investing_algorithm_framework/app/strategy.py,sha256=p7Tn9TlUHk1b6TXq357ecFkYK0b8zmvRpDOVgpu_zgU,6047
12
- investing_algorithm_framework/app/task.py,sha256=O8CnJT-cJfQVvC0ZG_w489KLLAemSrkyihHvQsuDvoE,963
13
- investing_algorithm_framework/app/web/__init__.py,sha256=vtmNhjqhbO69A51H-Gwgrr6-M_aErO4EOFjPbCM5Wzg,134
14
- investing_algorithm_framework/app/web/controllers/__init__.py,sha256=qTw0_R49TYrSsmGGodeFd_f9EaJZn0cOjK6hIiwKo9g,587
15
- investing_algorithm_framework/app/web/controllers/orders.py,sha256=aCqS58I7ClNHIapimYFJYzQh7JGM_SW0nTMKB1V6-0A,694
16
- investing_algorithm_framework/app/web/controllers/portfolio.py,sha256=oS9NTgZR_JmEcxfcRJ4EmKe85xcx9ucdzl8tDM5UmRs,727
17
- investing_algorithm_framework/app/web/controllers/positions.py,sha256=4NgJFPQqcootqMzJT_jUaicPp9DRGcc_TFU9V8iGxBQ,617
18
- investing_algorithm_framework/app/web/create_app.py,sha256=cyCvTSuM7FtUQNc3xnBH459qJUZKXWNd3QVhKRaPYIw,506
19
- investing_algorithm_framework/app/web/error_handler.py,sha256=cDvJn8r9ShIEqnAsaPBVRymow_sZ3Xcpc3DUXtTbd34,2020
20
- investing_algorithm_framework/app/web/responses.py,sha256=xbipQc0vcXHK6ouinsPdDHMHTxeLPebg-8uyeCG7zxQ,585
21
- investing_algorithm_framework/app/web/run_strategies.py,sha256=H3EHtFORA9MX3CYc7F0csCY2dTEt48FCRP5Wp-1V28U,158
22
- investing_algorithm_framework/app/web/schemas/__init__.py,sha256=pSkgN5AGiW48BD0vaQDdQQ6N90ryxGIimgEYJ-elSGY,361
23
- investing_algorithm_framework/app/web/schemas/order.py,sha256=MwDJ-5vWwBEr21JqL-WuZfttAhyFP7_8qp5QMYiCyco,442
24
- investing_algorithm_framework/app/web/schemas/portfolio.py,sha256=COXC_kpBUgPOBWy5ENtcfEs5U7lVrN8zxQYBqH9trfo,743
25
- investing_algorithm_framework/app/web/schemas/position.py,sha256=vLAFaXlPtlhmMaB_Jai9xRCvCM_5lLuiaDQ_2Z39TfE,438
26
- investing_algorithm_framework/app/web/setup_cors.py,sha256=ASCon0U0d7cedI-s37fdztDJozVvbNiYWYDLTHDydv8,80
27
- investing_algorithm_framework/create_app.py,sha256=E6bIvmQfeSKkTZ7piRkJD65hA62Hr-hOAZhKJ_ZIekE,603
28
- investing_algorithm_framework/dependency_container.py,sha256=z4jEkr8Rq_gnzVOUAP_vdyAhkirKQ5I4WFZGNtCo3D0,6170
29
- investing_algorithm_framework/domain/__init__.py,sha256=us0g4S4jPfJuGLmEMrdzclFfbSxH_HiftvP9K0im-e0,4218
30
- investing_algorithm_framework/domain/config.py,sha256=EdLrij0FMaMYu9KwbKr4qyV3Txi5JtWF3xCOGg3SavA,3728
31
- investing_algorithm_framework/domain/constants.py,sha256=OdLku4ukgiR0Ns1X4HPxqtlukwFsRlxXbDUdn5J3fE8,2293
32
- investing_algorithm_framework/domain/data_structures.py,sha256=xYaZJCdm1vweo9OoRvR4RNt_A3TxiG4Nd4bQz2K5_9s,962
33
- investing_algorithm_framework/domain/decimal_parsing.py,sha256=NtMNkxZyWrFHxGKd6gLIDmWF88BYcTl8tYaAaKO1tlg,823
34
- investing_algorithm_framework/domain/exceptions.py,sha256=3Er4UFN5oSUrJUbgEmcaZGtYJwW5WPbxWzT3BrZNHZk,1628
35
- investing_algorithm_framework/domain/graphs.py,sha256=xrabzNN3XyWiADAbLmwboOPwlHHxiMRQBik1ij-dUDo,12084
36
- investing_algorithm_framework/domain/metrics/__init__.py,sha256=e2nZ1UNihBZ0VjDXivmd6sxz0VL1cPwQ9yESn0w-zvc,106
37
- investing_algorithm_framework/domain/metrics/price_efficiency.py,sha256=hpt1Nyk7s_jxFeqEVeQV9FH5N4RzJx6SP072L4z9fYw,1844
38
- investing_algorithm_framework/domain/models/__init__.py,sha256=kF5yQfyofxICBZYqyfmr9Mj7DHNTUDwrttgKtM84vvg,1139
39
- investing_algorithm_framework/domain/models/app_mode.py,sha256=V1p9QMSNLlz6KjPib8d1J2EaSZh7jmXjZ1V2DFOrIaU,812
40
- investing_algorithm_framework/domain/models/backtesting/__init__.py,sha256=abUeBmDxjPOnyvh06a-0TAabQrS1om3Fe88ojqBGsl4,328
41
- investing_algorithm_framework/domain/models/backtesting/backtest_date_range.py,sha256=CG0qfkoriXq6d0yKGIgieRUrcqVvFAIL0qBz9WaCgmQ,1048
42
- investing_algorithm_framework/domain/models/backtesting/backtest_position.py,sha256=sevPiTwWlUI0hd1MfBYuX933rPcqQTC79pEKhBw1LjE,2860
43
- investing_algorithm_framework/domain/models/backtesting/backtest_report.py,sha256=GOaS2EWve9-9WTXpRNhVzGo3sQf1dq3EqErl-kIq5-U,17232
44
- investing_algorithm_framework/domain/models/backtesting/backtest_reports_evaluation.py,sha256=03BdF0Ts7tkBANjI8np0zgUoxu45-gfIwEt7YKgZq-A,8303
45
- investing_algorithm_framework/domain/models/base_model.py,sha256=1_DMaDR13gc6l5yWpMgKaAK7OJstc4lmvZV5DhwYM6o,659
46
- investing_algorithm_framework/domain/models/market/__init__.py,sha256=FUZOmpJgtCn7IM-5Kn464kY-_JLJQGCtwv5HLjlOrvk,87
47
- investing_algorithm_framework/domain/models/market/market_credential.py,sha256=82K3tZHD9opEgIHIzLvhJU0QJWOvvT6p0TwYZd1CbMk,779
48
- investing_algorithm_framework/domain/models/order/__init__.py,sha256=ELj0kT4YAhBOECQJBMTZzQ80yatrbbPf_A5iNAMN4X8,193
49
- investing_algorithm_framework/domain/models/order/order.py,sha256=_lJR2J2Q2g0x61OaeXTV_ZPVOeO3Bvbx2SXpkx8kal0,11833
50
- investing_algorithm_framework/domain/models/order/order_side.py,sha256=lMSTM8rb_Q3qgApryI0RXKiAAeGKDDlyu3q9bbuAQ-w,814
51
- investing_algorithm_framework/domain/models/order/order_status.py,sha256=7BpFOcJ1NEeOZfolmE32mHRrI_afkBUBLR2gh-aGfA0,937
52
- investing_algorithm_framework/domain/models/order/order_type.py,sha256=xL8YVlcwCNKv44MRNAwSVs_ZGemfMSYYwxkNMp7ai-M,751
53
- investing_algorithm_framework/domain/models/portfolio/__init__.py,sha256=gMMZG6Owvbsq7jL9PhhRbqV8tM9oebGUY8Yc6zedHj4,230
54
- investing_algorithm_framework/domain/models/portfolio/portfolio.py,sha256=1w-lYO6Y01DFmQ77OxIK3bXsXAIEphJ_x4oWwWNZT5o,2495
55
- investing_algorithm_framework/domain/models/portfolio/portfolio_configuration.py,sha256=ztl6DeD4DGpekZvB4ApIoKwx9gdQtVkVyRthbtjEu7I,1752
56
- investing_algorithm_framework/domain/models/portfolio/portfolio_snapshot.py,sha256=8eDg4HSGuhAve1cslNxvRZqra8Kw8Psl6lkEJ9EQYlU,3141
57
- investing_algorithm_framework/domain/models/position/__init__.py,sha256=Iv4-DUwgwf521P5qCu6R3WSVZxPeEtGoHP8WsS3qNUU,123
58
- investing_algorithm_framework/domain/models/position/position.py,sha256=Eul8AoPkDUNwmmIgE6dFob4qodtYU69J-mDpB46aEGo,1251
59
- investing_algorithm_framework/domain/models/position/position_snapshot.py,sha256=BpMhUTn--oUVXQHi62uOb4Ac7yuBwHW3iUCFpBPOtW0,1131
60
- investing_algorithm_framework/domain/models/strategy_profile.py,sha256=7-dmzr4YbStntIPz5SEPddThAGsLJH_Fo_jRexAnFTQ,4598
61
- investing_algorithm_framework/domain/models/time_frame.py,sha256=IfdaIhqX6FgjQV3g78meyhGod93dU7qeBLwHQ4CzNmc,2659
62
- investing_algorithm_framework/domain/models/time_interval.py,sha256=PyA0JeGgV51kf0sZ1yeQ52BCLsrJqlqD1FxGm53qioY,2798
63
- investing_algorithm_framework/domain/models/time_unit.py,sha256=r_K1aOmak5Z9UtZ-TTjGPWct1KOdR6SdRiD0IaqkqBI,2011
64
- investing_algorithm_framework/domain/models/tracing/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
65
- investing_algorithm_framework/domain/models/tracing/trace.py,sha256=iAVEN102-y_7Wj9Qg7kdti8-2I63Y8UG0SF3V2pkHj8,699
66
- investing_algorithm_framework/domain/models/trade/__init__.py,sha256=nDlk5m0q4DcA7SX53vQoqrkdtzMbvm_E2GPNg2WVjf4,99
67
- investing_algorithm_framework/domain/models/trade/trade.py,sha256=srYrxjsIcUUu9q698otxrU83F_qmU04KhXiRFv8XnSo,7787
68
- investing_algorithm_framework/domain/models/trade/trade_status.py,sha256=dB0kdO_WJqJ9wgnR4mG7QjRNPqBVJVr7ivYwNBX868A,807
69
- investing_algorithm_framework/domain/models/trading_data_types.py,sha256=sVk8ATXllJDIvRluqm08O_UkgDzCJO6l02k0C-kJwyg,1119
70
- investing_algorithm_framework/domain/models/trading_time_frame.py,sha256=DrFDjxJ1K5LgCnSi5q4ZrDCugfq6n_ETbxhaCbYVf1o,6791
71
- investing_algorithm_framework/domain/services/__init__.py,sha256=uXReS56GjKpvrE-aG0BaGh8ALaC8_qSxAlQi2akw7Ho,634
72
- investing_algorithm_framework/domain/services/market_credential_service.py,sha256=Ib_lFd0R7oumtuEf4YR8nX8oAH1pKa0AOk4WKPbiU0c,1047
73
- investing_algorithm_framework/domain/services/market_data_sources.py,sha256=Jk7vhIxB9t5MJKW7jrSGCGsZ7Pw34o7PvDsJeNa-56A,8682
74
- investing_algorithm_framework/domain/services/market_service.py,sha256=rou3pWVuR7DTLb1nj-HcPCuolOw2HA_Cvzh6YrkrLQ8,3693
75
- investing_algorithm_framework/domain/services/portfolios/__init__.py,sha256=8N1Dh9GESzE7AN776F8Duql5yblKf9SjcwZAX0C6RaE,115
76
- investing_algorithm_framework/domain/services/portfolios/portfolio_sync_service.py,sha256=h5xCvlC6Ie2HHKlNrI3lwMKzQXDTiillxHeYxXBIXZ0,320
77
- investing_algorithm_framework/domain/services/rounding_service.py,sha256=aY2H5nNVxAsc1JRdA2Qwoe8LmGVjf1UaQ0R-hqYgXu8,699
78
- investing_algorithm_framework/domain/singleton.py,sha256=lgWZOWFBU4WlIe-h6p_MHd2MNOQSICtFR9HvdtVNqbQ,258
79
- investing_algorithm_framework/domain/stateless_actions.py,sha256=DHhuI_3oL6JqWWucsZNvB3a9vFthZAk20Rg89_lc9o8,156
80
- investing_algorithm_framework/domain/strategy.py,sha256=bLiMll_hoOjCjgeSnTN5a9sriPgL8N4qULqDxD9zsQk,1805
81
- investing_algorithm_framework/domain/utils/__init__.py,sha256=NxBU78OEvDbsCxjsxHxTMTImVS987ZE25Drsa0tIhA8,750
82
- investing_algorithm_framework/domain/utils/backtesting.py,sha256=RvkFXTBCayJmwHXuwcUc4s5fjzW64vG2L4cpCerobso,19991
83
- investing_algorithm_framework/domain/utils/csv.py,sha256=QK7EC_jY4u9s97OFOcoxwZsBPGTnO79Z4qx07ms4MWI,2746
84
- investing_algorithm_framework/domain/utils/random.py,sha256=vnebSD_MeZfn-tRRzJ1SIe4ChHAZWbk4HhHPlWvEeLI,275
85
- investing_algorithm_framework/domain/utils/signatures.py,sha256=MO2hCrrnQjbsT6guX4AdeJfcAP55pRXtjJ73uX1cjaI,417
86
- investing_algorithm_framework/domain/utils/stoppable_thread.py,sha256=z3-OGZ-wrygfYn4zhB3COHdB43qQYa65TeShyVokSp0,608
87
- investing_algorithm_framework/domain/utils/synchronized.py,sha256=YjvutHxMh5r1WEpOYPAXm7_xHRaDzj5YTj7HqfKqJm0,253
88
- investing_algorithm_framework/infrastructure/__init__.py,sha256=bGujBxdNAMG7eUbNO1MLE0qqCS2lGKliT1tBhNFpSN0,1277
89
- investing_algorithm_framework/infrastructure/database/__init__.py,sha256=6t-_-w0RuQLRkbUIN1lL0N4MzJePmcjRuV96Kzo3_n4,176
90
- investing_algorithm_framework/infrastructure/database/sql_alchemy.py,sha256=0-U82pBl59UP1-a3gYq169T94gwMtutmZu2V3uzx0jM,1386
91
- investing_algorithm_framework/infrastructure/models/__init__.py,sha256=HGVWg4vlj59hjuXIZnCLLRglHdEHZNOJ7y6DiM7vdnE,700
92
- investing_algorithm_framework/infrastructure/models/decimal_parser.py,sha256=s19k4gUh5qhZg-PcPzGFKqQ8xK4Z9OtefnTT2YgRojY,327
93
- investing_algorithm_framework/infrastructure/models/market_data_sources/__init__.py,sha256=F6ACSFTGebWOQTs8dyA3JBHfMPI6gsuysdIQvZwrsEI,437
94
- investing_algorithm_framework/infrastructure/models/market_data_sources/ccxt.py,sha256=gX5LukH5KuNDDpb9-MdI2FYU_yPnfTisGYdL1v8x5Ck,18940
95
- investing_algorithm_framework/infrastructure/models/market_data_sources/csv.py,sha256=LOXnMZ-Doe5vYSSOIdh8lLvzGI0sVO8imORXGmgcAvg,8730
96
- investing_algorithm_framework/infrastructure/models/market_data_sources/us_treasury_yield.py,sha256=myxKObB2w4gQYQ9PFwXIYEoTwwP0c_VXBd42lZmyo9M,1641
97
- investing_algorithm_framework/infrastructure/models/model_extension.py,sha256=EiSSs-Jq27gBhLnlIKvEjDoJz7iMPFxkFBg5cesU694,142
98
- investing_algorithm_framework/infrastructure/models/order/__init__.py,sha256=GsODcaQAOz9ezWNoDhtb3zv2X4k09yerw18BzkeOgdw,52
99
- investing_algorithm_framework/infrastructure/models/order/order.py,sha256=KsVn4AIH4Piaw46OsTYbvDxReLp5P1_sA--XuBp9jM8,5387
100
- investing_algorithm_framework/infrastructure/models/portfolio/__init__.py,sha256=Eth4uKjIerR99GnjTXihxJzFsudxVcHdO4M_v6TgE7M,141
101
- investing_algorithm_framework/infrastructure/models/portfolio/portfolio.py,sha256=SgK9fOrmlJAuEdMmH1nUvFAvZyYx6Ayq0-6LSTmRXjE,3226
102
- investing_algorithm_framework/infrastructure/models/portfolio/portfolio_snapshot.py,sha256=4FW3AdaYkYpR6nAwGieqdkEFp9hxxALRVjK3jI6t4CI,1238
103
- investing_algorithm_framework/infrastructure/models/position/__init__.py,sha256=nNEWciIXWZyFIYZVEkAGB21Kf9QXkWzcdcL4uKiHjFo,135
104
- investing_algorithm_framework/infrastructure/models/position/position.py,sha256=CmSX7KNKJ0vkJ8Z7eq2DzARCdPGYGHH6sChJ0aS2nfM,1898
105
- investing_algorithm_framework/infrastructure/models/position/position_snapshot.py,sha256=F8pcpppTIH89JAPSqDlp7zCVRvElUKcH3odGELlh1w8,842
106
- investing_algorithm_framework/infrastructure/repositories/__init__.py,sha256=mcitbd3wEzQsdAAjROgMCyasVL462yW_4jH-TowUqzI,482
107
- investing_algorithm_framework/infrastructure/repositories/order_repository.py,sha256=dD8nXnXlHZUqefYoqxurg0jFt2rCCzBzfGa8NBniC78,3351
108
- investing_algorithm_framework/infrastructure/repositories/portfolio_repository.py,sha256=2hkp7fIxst9pMJEDj-rG_sd0be9ZfyqQyl75fG7Eg4w,1073
109
- investing_algorithm_framework/infrastructure/repositories/portfolio_snapshot_repository.py,sha256=K24hMQQpryLnnKE5YPqLBuj5cMaLdAr-O6vS6wdwECU,1967
110
- investing_algorithm_framework/infrastructure/repositories/position_repository.py,sha256=7pbk-sul_M1Rv535NOhNaWbp9lAGz8jv4oUKm623IW8,1994
111
- investing_algorithm_framework/infrastructure/repositories/position_snapshot_repository.py,sha256=GT1TkoHdy1L7ZNspDsMqWY8R2tjINz7XBYunuebzLAg,680
112
- investing_algorithm_framework/infrastructure/repositories/repository.py,sha256=A4J0sd40S3V-d-ufXegsi2-Tkg1V_ySeytT0_UkG-JA,7661
113
- investing_algorithm_framework/infrastructure/services/__init__.py,sha256=NjyvvSXd0mMNRAkNpGg9me0t_kpTy-x5gl7g6pClozc,163
114
- investing_algorithm_framework/infrastructure/services/market_service/__init__.py,sha256=9FfnY6mZBqQpN0dC0PH4IpzW1D1daoGBQGOhxuqAqUA,91
115
- investing_algorithm_framework/infrastructure/services/market_service/ccxt_market_service.py,sha256=ahC3y1I0a2kVCE-6cV8IfjUMkXTCagXCnoOL7WrMVY0,15545
116
- investing_algorithm_framework/infrastructure/services/performance_service/__init__.py,sha256=9xmu6jE4umF8MUTfCGr5ZZzDkqpKpDTLiERV1Aals3E,195
117
- investing_algorithm_framework/infrastructure/services/performance_service/backtest_performance_service.py,sha256=ZnhrkRUPKbVimBvbhFl8yBDINIEFkqSoylYHMxI1kG8,43
118
- investing_algorithm_framework/infrastructure/services/performance_service/performance_service.py,sha256=fyr5LVVaM2txeIDmloe5i3SXlVGGTDiuK7P_51RVRBA,11933
119
- investing_algorithm_framework/services/__init__.py,sha256=2m241MqFi0Y8x3Co4QRztmcvrgV__yQakZQ_B2vUKnk,1470
120
- investing_algorithm_framework/services/backtesting/__init__.py,sha256=uur8kTBK1QanVFCrNeSWVQavbOhiCR5ag7EEIhbdG_Q,362
121
- investing_algorithm_framework/services/backtesting/backtest_report_writer_service.py,sha256=HN_phAL4xXjX9TSlRh8iqDVPvWt6hjQIas9vLbDvqhA,1998
122
- investing_algorithm_framework/services/backtesting/backtest_service.py,sha256=YXMHGUiuZK2IDyK4vtJTVEPOyaL17hqoGG-Sm5r9hU8,17899
123
- investing_algorithm_framework/services/backtesting/graphs.py,sha256=JBqvmeBYWo_WfQdAXZ8ukhahvArrZVcH2zHMWjr-5X0,1550
124
- investing_algorithm_framework/services/configuration_service.py,sha256=ebSZAVETJ3VPTyB7ya1-ymrc88bJZAe8WBm-tcyOkx8,624
125
- investing_algorithm_framework/services/market_credential_service.py,sha256=HQ0AAD31jtPknSe4sMPEAvkNxFGDmE99EWWp_wF1sS8,821
126
- investing_algorithm_framework/services/market_data_source_service/__init__.py,sha256=OHcq-NQdGICzlbLmBk9eM2Lp6IiJYJpsCqkuc35e4jM,235
127
- investing_algorithm_framework/services/market_data_source_service/backtest_market_data_source_service.py,sha256=FvxHxWTZQiFNZo_1olXx5D9wi-cb2nSqhAIw1wR3-CU,5809
128
- investing_algorithm_framework/services/market_data_source_service/market_data_source_service.py,sha256=Vlwvgumfh46GE-trHNHjs0DIbDXJo4zdFjBOkqCSzwQ,7391
129
- investing_algorithm_framework/services/order_service/__init__.py,sha256=lT_DPbnIZKFBgYMIRi3yAekzYrQQgwlmOIX6cNs04wE,159
130
- investing_algorithm_framework/services/order_service/order_backtest_service.py,sha256=pM0zjF5jHdegT0Sqt0Ny7nutCcVAUUwA_SUkSMp-ZMk,7747
131
- investing_algorithm_framework/services/order_service/order_service.py,sha256=dF77G4KeVYHzb7icohQ9VDpZDdwPm2yWf2w9KDKi71Y,26845
132
- investing_algorithm_framework/services/portfolios/__init__.py,sha256=6WZ46a2bY22MS_ZhOdJpzmoMDdm7WwSYnSXkOt-TuVo,509
133
- investing_algorithm_framework/services/portfolios/backtest_portfolio_service.py,sha256=7DOsQPepbeX9snhIYKyKvCBiYuc76oZJEosv0p95Hgc,825
134
- investing_algorithm_framework/services/portfolios/portfolio_configuration_service.py,sha256=X6ZMiSnBipTMGGzOyn2dVgHPRmXez3PvMv9PfCVP5w0,2055
135
- investing_algorithm_framework/services/portfolios/portfolio_service.py,sha256=fG-HixbeWb-Vgq6d_6Ok0R2w9GthmP5onaihLndKtaM,4493
136
- investing_algorithm_framework/services/portfolios/portfolio_snapshot_service.py,sha256=MkZXZY9bwAi-OcwL-GAYyDcYKMVfgXxDoJjuHqSCSuE,1984
137
- investing_algorithm_framework/services/portfolios/portfolio_sync_service.py,sha256=d83gd59Qj5Izdq3iq4wXtSVVhBP8g9D6d5ztbmuLnrw,16127
138
- investing_algorithm_framework/services/position_service.py,sha256=PR4EdT7AmlMa-RSh1ve_XP5yF6GHzvubHSycXsXdjXo,1052
139
- investing_algorithm_framework/services/position_snapshot_service.py,sha256=QPY0xp3ky5rJgGev3PBpIalvS2xKlRLGXr-3TyA2zng,525
140
- investing_algorithm_framework/services/repository_service.py,sha256=1GTnWHImgQyyVpPyX6-yo1T7d-09v4uRWBtfKbZfoFY,995
141
- investing_algorithm_framework/services/strategy_orchestrator_service.py,sha256=gS7Va7H_2lX9d3oxltBQqR_O3-dm6Ya6IEEEMm1Lq84,8077
142
- investing_algorithm_framework/services/trade_service/__init__.py,sha256=AcwPyJjDRdiREnl_MWMkDSc-V-ZjXtvpHD6eQT9mc1o,68
143
- investing_algorithm_framework/services/trade_service/trade_service.py,sha256=b0KP47tDWLuET7_qlPkSBkLre9TZfq2RSlRtveeH0o8,14761
144
- investing_algorithm_framework-3.7.0.dist-info/LICENSE,sha256=wbVEDvoZiMPHufRY3sLEffvAr7GH5hOIngHF8y4HFQg,11343
145
- investing_algorithm_framework-3.7.0.dist-info/METADATA,sha256=lnWFEMk6LuI59x4tSa18tHOOOrBggfBXnz0mQTLlAkU,31593
146
- investing_algorithm_framework-3.7.0.dist-info/WHEEL,sha256=FMvqSimYX_P7y0a7UY-_Mc83r5zkBZsCYPm7Lr0Bsq4,88
147
- investing_algorithm_framework-3.7.0.dist-info/RECORD,,