investing-algorithm-framework 6.3.0__tar.gz → 6.3.1__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.
Files changed (194) hide show
  1. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/PKG-INFO +89 -114
  2. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/README.md +87 -113
  3. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/__init__.py +3 -1
  4. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/app.py +69 -7
  5. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/__init__.py +10 -5
  6. investing_algorithm_framework-6.3.1/investing_algorithm_framework/domain/data_provider.py +172 -0
  7. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/exceptions.py +17 -0
  8. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/backtesting/backtest_report.py +129 -12
  9. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/order/order.py +22 -0
  10. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/trading_data_types.py +1 -0
  11. investing_algorithm_framework-6.3.1/investing_algorithm_framework/domain/order_executor.py +63 -0
  12. investing_algorithm_framework-6.3.1/investing_algorithm_framework/domain/portfolio_provider.py +62 -0
  13. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/utils/__init__.py +6 -2
  14. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/utils/backtesting.py +180 -14
  15. investing_algorithm_framework-6.3.1/investing_algorithm_framework/download_data.py +70 -0
  16. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/__init__.py +4 -1
  17. investing_algorithm_framework-6.3.1/investing_algorithm_framework/infrastructure/data_providers/__init__.py +19 -0
  18. investing_algorithm_framework-6.3.1/investing_algorithm_framework/infrastructure/data_providers/ccxt.py +313 -0
  19. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/services/market_service/ccxt_market_service.py +1 -1
  20. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/__init__.py +2 -1
  21. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/market_credential_service.py +8 -1
  22. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/market_data_source_service/__init__.py +3 -1
  23. investing_algorithm_framework-6.3.1/investing_algorithm_framework/services/market_data_source_service/data_provider_service.py +179 -0
  24. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/trade_service/trade_service.py +22 -6
  25. investing_algorithm_framework-6.3.1/investing_algorithm_framework/test.py +16 -0
  26. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/pyproject.toml +2 -2
  27. investing_algorithm_framework-6.3.0/investing_algorithm_framework/domain/singleton.py +0 -9
  28. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/LICENSE +0 -0
  29. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/__init__.py +0 -0
  30. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/algorithm.py +0 -0
  31. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/context.py +0 -0
  32. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/stateless/__init__.py +0 -0
  33. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/stateless/action_handlers/__init__.py +0 -0
  34. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/stateless/action_handlers/action_handler_strategy.py +0 -0
  35. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/stateless/action_handlers/check_online_handler.py +0 -0
  36. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/stateless/action_handlers/run_strategy_handler.py +0 -0
  37. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/stateless/exception_handler.py +0 -0
  38. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/strategy.py +0 -0
  39. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/task.py +0 -0
  40. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/__init__.py +0 -0
  41. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/controllers/__init__.py +0 -0
  42. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/controllers/orders.py +0 -0
  43. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/controllers/portfolio.py +0 -0
  44. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/controllers/positions.py +0 -0
  45. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/create_app.py +0 -0
  46. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/error_handler.py +0 -0
  47. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/responses.py +0 -0
  48. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/run_strategies.py +0 -0
  49. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/schemas/__init__.py +0 -0
  50. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/schemas/order.py +0 -0
  51. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/schemas/portfolio.py +0 -0
  52. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/schemas/position.py +0 -0
  53. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/app/web/setup_cors.py +0 -0
  54. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/__init__.py +0 -0
  55. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/cli.py +0 -0
  56. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/deploy_to_azure_function.py +0 -0
  57. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/initialize_app.py +0 -0
  58. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/.gitignore.template +0 -0
  59. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/app-web.py.template +0 -0
  60. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/app.py.template +0 -0
  61. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/app_azure_function.py.template +0 -0
  62. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/app_web.py.template +0 -0
  63. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/azure_function_function_app.py.template +0 -0
  64. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/azure_function_host.json.template +0 -0
  65. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/azure_function_local.settings.json.template +0 -0
  66. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/data_providers.py.template +0 -0
  67. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/env.example.template +0 -0
  68. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/env_azure_function.example.template +0 -0
  69. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/market_data_providers.py.template +0 -0
  70. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/readme.md.template +0 -0
  71. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/requirements.txt.template +0 -0
  72. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/requirements_azure_function.txt.template +0 -0
  73. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/run_backtest.py.template +0 -0
  74. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/cli/templates/strategy.py.template +0 -0
  75. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/create_app.py +0 -0
  76. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/dependency_container.py +0 -0
  77. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/config.py +0 -0
  78. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/constants.py +0 -0
  79. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/data_structures.py +0 -0
  80. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/decimal_parsing.py +0 -0
  81. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/metrics/__init__.py +0 -0
  82. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/metrics/price_efficiency.py +0 -0
  83. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/__init__.py +0 -0
  84. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/app_mode.py +0 -0
  85. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/backtesting/__init__.py +0 -0
  86. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/backtesting/backtest_date_range.py +0 -0
  87. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/backtesting/backtest_position.py +0 -0
  88. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/backtesting/backtest_reports_evaluation.py +0 -0
  89. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/base_model.py +0 -0
  90. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/date_range.py +0 -0
  91. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/market/__init__.py +0 -0
  92. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/market/market_credential.py +0 -0
  93. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/market_data_type.py +0 -0
  94. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/order/__init__.py +0 -0
  95. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/order/order_side.py +0 -0
  96. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/order/order_status.py +0 -0
  97. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/order/order_type.py +0 -0
  98. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/portfolio/__init__.py +0 -0
  99. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/portfolio/portfolio.py +0 -0
  100. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/portfolio/portfolio_configuration.py +0 -0
  101. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/portfolio/portfolio_snapshot.py +0 -0
  102. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/position/__init__.py +0 -0
  103. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/position/position.py +0 -0
  104. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/position/position_snapshot.py +0 -0
  105. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/strategy_profile.py +0 -0
  106. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/time_frame.py +0 -0
  107. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/time_interval.py +0 -0
  108. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/time_unit.py +0 -0
  109. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/tracing/__init__.py +0 -0
  110. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/tracing/trace.py +0 -0
  111. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/trade/__init__.py +0 -0
  112. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/trade/trade.py +0 -0
  113. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/trade/trade_risk_type.py +0 -0
  114. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/trade/trade_status.py +0 -0
  115. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/trade/trade_stop_loss.py +0 -0
  116. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/trade/trade_take_profit.py +0 -0
  117. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/models/trading_time_frame.py +0 -0
  118. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/services/__init__.py +0 -0
  119. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/services/market_credential_service.py +0 -0
  120. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/services/market_data_sources.py +0 -0
  121. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/services/market_service.py +0 -0
  122. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/services/portfolios/__init__.py +0 -0
  123. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/services/portfolios/portfolio_sync_service.py +0 -0
  124. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/services/rounding_service.py +0 -0
  125. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/services/state_handler.py +0 -0
  126. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/stateless_actions.py +0 -0
  127. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/strategy.py +0 -0
  128. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/utils/csv.py +0 -0
  129. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/utils/polars.py +0 -0
  130. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/utils/random.py +0 -0
  131. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/utils/signatures.py +0 -0
  132. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/utils/stoppable_thread.py +0 -0
  133. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/domain/utils/synchronized.py +0 -0
  134. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/database/__init__.py +0 -0
  135. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/database/sql_alchemy.py +0 -0
  136. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/__init__.py +0 -0
  137. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/decimal_parser.py +0 -0
  138. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/market_data_sources/__init__.py +0 -0
  139. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/market_data_sources/ccxt.py +0 -0
  140. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/market_data_sources/csv.py +0 -0
  141. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/market_data_sources/pandas.py +0 -0
  142. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/market_data_sources/us_treasury_yield.py +0 -0
  143. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/model_extension.py +0 -0
  144. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/order/__init__.py +0 -0
  145. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/order/order.py +0 -0
  146. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/order/order_metadata.py +0 -0
  147. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/order_trade_association.py +0 -0
  148. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/portfolio/__init__.py +0 -0
  149. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/portfolio/portfolio_snapshot.py +0 -0
  150. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/portfolio/sql_portfolio.py +0 -0
  151. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/position/__init__.py +0 -0
  152. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/position/position.py +0 -0
  153. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/position/position_snapshot.py +0 -0
  154. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/trades/__init__.py +0 -0
  155. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/trades/trade.py +0 -0
  156. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/trades/trade_stop_loss.py +0 -0
  157. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/models/trades/trade_take_profit.py +0 -0
  158. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/__init__.py +0 -0
  159. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/order_metadata_repository.py +0 -0
  160. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/order_repository.py +0 -0
  161. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/portfolio_repository.py +0 -0
  162. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/portfolio_snapshot_repository.py +0 -0
  163. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/position_repository.py +0 -0
  164. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/position_snapshot_repository.py +0 -0
  165. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/repository.py +0 -0
  166. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/trade_repository.py +0 -0
  167. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/trade_stop_loss_repository.py +0 -0
  168. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/repositories/trade_take_profit_repository.py +0 -0
  169. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/services/__init__.py +0 -0
  170. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/services/azure/__init__.py +0 -0
  171. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/services/azure/state_handler.py +0 -0
  172. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/services/market_service/__init__.py +0 -0
  173. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/services/performance_service/__init__.py +0 -0
  174. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/services/performance_service/backtest_performance_service.py +0 -0
  175. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/infrastructure/services/performance_service/performance_service.py +0 -0
  176. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/backtesting/__init__.py +0 -0
  177. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/backtesting/backtest_service.py +0 -0
  178. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/configuration_service.py +0 -0
  179. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/market_data_source_service/backtest_market_data_source_service.py +0 -0
  180. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/market_data_source_service/market_data_source_service.py +0 -0
  181. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/order_service/__init__.py +0 -0
  182. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/order_service/order_backtest_service.py +0 -0
  183. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/order_service/order_service.py +0 -0
  184. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/portfolios/__init__.py +0 -0
  185. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/portfolios/backtest_portfolio_service.py +0 -0
  186. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/portfolios/portfolio_configuration_service.py +0 -0
  187. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/portfolios/portfolio_service.py +0 -0
  188. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/portfolios/portfolio_snapshot_service.py +0 -0
  189. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/portfolios/portfolio_sync_service.py +0 -0
  190. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/position_service.py +0 -0
  191. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/position_snapshot_service.py +0 -0
  192. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/repository_service.py +0 -0
  193. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/strategy_orchestrator_service.py +0 -0
  194. {investing_algorithm_framework-6.3.0 → investing_algorithm_framework-6.3.1}/investing_algorithm_framework/services/trade_service/__init__.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: investing-algorithm-framework
3
- Version: 6.3.0
3
+ Version: 6.3.1
4
4
  Summary: A framework for creating trading bots
5
5
  Author: MDUYN
6
6
  Requires-Python: >=3.10
@@ -8,7 +8,7 @@ Classifier: Programming Language :: Python :: 3
8
8
  Classifier: Programming Language :: Python :: 3.10
9
9
  Classifier: Programming Language :: Python :: 3.11
10
10
  Classifier: Programming Language :: Python :: 3.12
11
- Requires-Dist: Flask (>=2.3.2)
11
+ Requires-Dist: Flask (>=3.1.0)
12
12
  Requires-Dist: Flask-Cors (>=3.0.9,<5.0.0)
13
13
  Requires-Dist: Flask-Migrate (>=2.6.0)
14
14
  Requires-Dist: SQLAlchemy (>=2.0.18)
@@ -30,31 +30,16 @@ Requires-Dist: tqdm (>=4.66.1)
30
30
  Requires-Dist: wrapt (>=1.16.0)
31
31
  Description-Content-Type: text/markdown
32
32
 
33
- <br/>
34
- <div align="center">
35
- <h1><a href="https://investing-algorithm-framework.com" target="_blank">Investing Algorithm Framework</a></h4>
36
- </div>
37
- <br/>
38
-
39
- <div align="center">
40
- <b>Rapidly build and deploy quantitative strategies and trading bots</b>
41
- </div>
42
- <br/>
43
-
44
- <p align="center">
45
- <a target="_blank" href="https://investing-algorithm-framework.com">View Docs</a>
46
- <a href="https://investing-algorithm-framework.com/Getting%20Started/installation)">Getting Started</a>
47
- </p>
33
+ <div align="center"> <h1><a href="https://investing-algorithm-framework.com" target="_blank">Investing Algorithm Framework</a></h1> <p><b>Rapidly build, backtest, and deploy quantitative strategies and trading bots</b></p> <a target="_blank" href="https://investing-algorithm-framework.com">📖 View Documentation</a> | <a href="https://investing-algorithm-framework.com/Getting%20Started/installation">🚀 Getting Started</a> </div>
48
34
 
49
35
  ---
50
36
 
51
- <a href=https://investing-algorithm-framework.com><img src="https://img.shields.io/badge/docs-website-brightgreen"></a>
52
- [![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)
53
- [![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)
54
- [![Downloads](https://pepy.tech/badge/investing-algorithm-framework)](https://pepy.tech/badge/investing-algorithm-framework)
55
- [![Current Version](https://img.shields.io/pypi/v/investing_algorithm_framework.svg)](https://img.shields.io/pypi/v/investing_algorithm_framework.svg)
56
- <a href="https://www.reddit.com/r/InvestingBots/"><img src="https://img.shields.io/reddit/subreddit-subscribers/investingbots?style=social"></a> <br/>
57
- [![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
+ <div align="center"> <a href="https://investing-algorithm-framework.com">
38
+ <a target="_blank" href="https://discord.gg/dQsRmGZP"><img src="https://img.shields.io/discord/1345358169777635410.svg?color=7289da&label=TradeBotLab%20Discord&logo=discord&style=flat"></a>
39
+ <img src="https://img.shields.io/badge/docs-website-brightgreen"></a> <a href="https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/publish.yml"><img src="https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/publish.yml/badge.svg"></a> <a href="https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/test.yml"><img src="https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/test.yml/badge.svg"></a> <a href="https://pepy.tech/project/investing-algorithm-framework"><img src="https://pepy.tech/badge/investing-algorithm-framework"></a> <a href="https://pypi.org/project/investing-algorithm-framework/"><img src="https://img.shields.io/pypi/v/investing-algorithm-framework.svg"></a> <a href="https://www.reddit.com/r/InvestingBots/"><img src="https://img.shields.io/reddit/subreddit-subscribers/investingbots?style=social"></a> <a href="https://github.com/coding-kitties/investing-algorithm-framework/stargazers"><img src="https://img.shields.io/github/stars/coding-kitties/investing-algorithm-framework.svg?style=social&label=Star"></a>
40
+ </div>
41
+
42
+ > If you like what we do, consider starring, sharing and contributing!
58
43
 
59
44
  ## Sponsors
60
45
 
@@ -66,66 +51,54 @@ Description-Content-Type: text/markdown
66
51
  </picture>
67
52
  </a>
68
53
 
69
- ## Features and planned features:
70
-
71
- - [x] **Based on Python 3.10+**: Windows, macOS and Linux.
72
- - [x] **Documentation**: [Documentation](https://investing-algorithm-framework.com)
73
- - [x] **Persistence of portfolios, orders, positions and trades**: Persistence is achieved through sqlite.
74
- - [x] **Limit orders**: Create limit orders for buying and selling.
75
- - [x] **Trade models**: Models and functionality for trades, trades stop losses (fixed and trailing) and take profits (fixed and trailing).
76
- - [x] **Market data sources**: Market data sources for OHLCV data and ticker data, and extendible with custom data and events.
77
- - [x] **Polars and Pandas dataframes support** Out of the box dataframes support for fast data processing ([pola.rs](https://pola.rs/), [pandas](https://pandas.pydata.org/)).
78
- - [x] **Azure Functions support**: Stateless running for cloud function deployments in Azure.
79
- - [x] **Live trading**: Live trading.
80
- - [x] **Backtesting and performance analysis reports** [example](./examples/backtest_example)
81
- - [x] **Backtesting multiple algorithms with different backtest date ranges** [example](./examples/backtests_example)
82
- - [x] **Backtesting and results evaluation**: Compare multiple backtests and run experiments. Save and load backtests. Save strategies as part of the backtest. [docs](https://investing-algorithm-framework.com/Getting%20Started/backtesting)
83
- - [x] **Order execution**: Currently support for a wide range of crypto exchanges through [ccxt](https://github.com/ccxt/ccxt) (Support for traditional asset brokers is planned).
84
- - [x] **Web API**: Rest API for interacting with your deployed trading bot
85
- - [x] **PyIndicators**: Works natively with [PyIndicators](https://github.com/coding-kitties/PyIndicators) for technical analysis on your Pandas and Polars dataframes.
86
- - [ ] **Builtin WebUI (Planned)**: Builtin web UI to manage your bot and evaluate your backtests.
87
- - [ ] **Manageable via Telegram (Planned)**: Manage the bot with Telegram.
88
- - [ ] **Performance status report via Web UI and telegram(Planned)**: Provide a performance status of your current trades.
89
- - [ ] **CI/CD integration (Planned)**: Tools for continuous integration and deployment (version tracking, comparison of backtests, automatic deployments).
90
- - [ ] **Tracing and replaying of strategies in backtests (Planned)**: Tracing and replaying of strategies in backtests for specific dates and date ranges so you can evaluate your strategy step by step.
91
- - [ ] **AWS Lambda support (Planned)**: Stateless running for cloud function deployments in AWS.
92
- - [ ] **Azure App services support (Planned)**: deployments in Azure app services with Web UI.
93
-
94
- ## Quickstart
95
-
96
- 1. First install the framework using `pip`. The Investing Algorithm Framework is hosted on [PyPi](https://pypi.org/project/Blankly/).
54
+
55
+ ## 🌟 Features
56
+
57
+ - [x] Python 3.10+: Cross-platform support for Windows, macOS, and Linux.
58
+ - [x] Backtesting: Simulate strategies with detailed performance reports.
59
+ - [x] Live Trading: Execute trades in real-time with support for multiple exchanges via ccxt.
60
+ - [x] Portfolio Management: Manage portfolios, trades, and positions with persistence via SQLite.
61
+ - [x] Market Data Sources: Fetch OHLCV, ticker, and custom data with support for Polars and Pandas.
62
+ - [x] Azure Functions Support: Deploy stateless trading bots to Azure.
63
+ - [x] Web API: Interact with your bot via REST API.
64
+ - [x] PyIndicators Integration: Perform technical analysis directly on your dataframes.
65
+ - [x] Extensibility: Add custom strategies, data providers, order executors so you can connect your trading bot to your favorite exchange or broker.
66
+
67
+ ## 🚀 Quickstart
68
+
69
+ Installation
70
+ Install the framework via [PyPI](https://pypi.org/project/investing-algorithm-framework/):
71
+
72
+ 1. First install the framework using `pip`. The Investing Algorithm Framework is hosted on [PyPi].
97
73
 
98
74
  ```bash
99
- $ pip install investing-algorithm-framework
75
+ pip install investing-algorithm-framework
100
76
  ```
101
77
 
102
- 2. Next, just run:
78
+ Run the following command to set up your project:
103
79
 
104
80
  ```bash
105
- $ investing-algorithm-framewor init
81
+ investing-algorithm-framewor init
106
82
  ```
107
83
 
108
- or if you want the web version:
84
+ For a web-enabled version:
109
85
 
110
86
  ```bash
111
- $ investing-algorithm-framework init --web
87
+ investing-algorithm-framework init --web
112
88
  ```
113
- > You can always change the app to the web version by changing the `app.py` file.
114
-
115
- The command will create the file `app.py` and an example script called `strategy.py`.
116
89
 
117
- From there, you start building your trading bot in the `strategy.py`.
90
+ This will create:
118
91
 
119
- More information can be found on our [docs](https://docs.blankly.finance)
92
+ * app.py: The entry point for your bot.
93
+ * strategy.py: A sample strategy file to get started.
120
94
 
121
- > Make sure you leave the `app.py` file as is, as it is the entry point for the framework.
122
- > You can change the `bot.py` file to your liking and add other files to the working directory.
123
- > The framework will automatically pick up the files in the working directory.
124
- ```
95
+ > Note: Keep the app.py file as is. You can modify strategy.py and add additional files to build your bot.
96
+ > You can always change the app to the web version by changing the `app.py` file.
125
97
 
126
- ## Example implementation
98
+ ---
127
99
 
128
- The following algorithm connects to binance and buys BTC every 2 hours.
100
+ ## 📈 Example: A Simple Trading Bot
101
+ The following example connects to Binance and buys BTC every 2 hours.
129
102
 
130
103
  ```python
131
104
  import logging.config
@@ -189,7 +162,7 @@ if __name__ == "__main__":
189
162
 
190
163
  > You can find more examples [here](./examples) folder.
191
164
 
192
- ## Backtesting and experiments
165
+ ## 🔍 Backtesting
193
166
 
194
167
  The framework also supports backtesting and performing backtest experiments. After a backtest, you can print a report that shows the performance of your trading bot.
195
168
 
@@ -302,45 +275,38 @@ Take profits overview
302
275
  ╰────────────────────┴───────────────┴──────────┴──────────┴─────────────────────────────────────┴──────────────┴────────────────┴─────────────────────────────────┴──────────────┴─────────────┴───────────────╯
303
276
  ```
304
277
 
305
- ### Backtest experiments
278
+ ## 🌐 Deployment to Azure
306
279
 
307
- The framework also supports backtest experiments. Backtest experiments allows you to
308
- compare multiple algorithms and evaluate their performance. Ideally,
309
- you would do this by parameterizing your strategy and creating a factory function that
310
- creates the algorithm with the different parameters. You can find an example of this
311
- in the [backtest experiments example](./examples/backtest_experiment).
280
+ Prerequisites
312
281
 
313
- ## Broker/Exchange configuration
282
+ Ensure Azure Functions Core Tools are installed:
314
283
 
315
- The framework has by default support for [ccxt](https://github.com/ccxt/ccxt).
316
- This should allow you to connect to a lot of brokers/exchanges.
284
+ ```bash
285
+ npm install -g azure-functions-core-tools@4 --unsafe-perm true
286
+ ```
287
+ Deploying to Azure
288
+ Use the provided deployment script:
317
289
 
318
- ```python
319
- from investing_algorithm_framework import PortfolioConfiguration, \
320
- MarketCredential, create_app
321
- app = create_app()
322
- app.add_market_credential(
323
- MarketCredential(
324
- market="<your market>",
325
- api_key="<your api key>",
326
- secret_key="<your secret key>",
327
- )
328
- )
329
- app.add_portfolio_configuration(
330
- PortfolioConfiguration(
331
- market="<your market>",
332
- initial_balance=400,
333
- trading_symbol="EUR"
334
- )
335
- )
290
+ This script:
291
+
292
+ ```
293
+ investing-algorithm-framework deploy
336
294
  ```
337
295
 
338
- ## Performance
296
+ This script:
297
+
298
+ * Creates Azure resources (e.g., storage accounts, function apps).
299
+ * Sets environment variables for the Azure Function.
300
+ * Deploys your bot to Azure.
339
301
 
340
- We are continuously working on improving the performance of the framework. If
341
- you have any suggestions, please let us know.
302
+ ## 📚 Documentation
303
+ Comprehensive documentation is available at [investing-algorithm-framework.com](https://investing-algorithm-framework.com).
342
304
 
343
- ## Installation for local development
305
+ ## 🛠️ Development
306
+
307
+ Local Development
308
+
309
+ Clone the repository and install dependencies using Poetry:
344
310
 
345
311
  The framework is built with poetry. To install the framework for local development, you can run the following commands:
346
312
 
@@ -361,11 +327,11 @@ To run the tests, you can run the following command:
361
327
  python -m unittest discover -s tests
362
328
  ```
363
329
 
364
- ## Disclaimer
330
+ ## ⚠️ Disclaimer
331
+
365
332
 
366
333
  If you use this framework for your investments, do not risk money
367
- which you are afraid to lose, until you have clear understanding how
368
- the framework works. We can't stress this enough:
334
+ which you are afraid to lose, until you have clear understanding how the framework works. We can't stress this enough:
369
335
 
370
336
  BEFORE YOU START USING MONEY WITH THE FRAMEWORK, MAKE SURE THAT YOU TESTED
371
337
  YOUR COMPONENTS THOROUGHLY. USE THE SOFTWARE AT YOUR OWN RISK.
@@ -374,6 +340,8 @@ THE AUTHORS AND ALL AFFILIATES ASSUME NO RESPONSIBILITY FOR YOUR INVESTMENT RESU
374
340
  Also, make sure that you read the source code of any plugin you use or
375
341
  implementation of an algorithm made with this framework.
376
342
 
343
+ We welcome contributions! Check out the project board and issues to get started.
344
+
377
345
  ## Documentation
378
346
 
379
347
  All the documentation can be found online
@@ -386,17 +354,7 @@ contributing page at the website.
386
354
  If you'd like to chat with investing-algorithm-framework users
387
355
  and developers, [join us on Slack](https://inv-algo-framework.slack.com) or [join us on reddit](https://www.reddit.com/r/InvestingBots/)
388
356
 
389
- ## Acknowledgements
390
-
391
- We want to thank all contributors to this project. A full list of all the people that contributed to the project can be
392
- found [here](https://github.com/investing-algorithms/investing-algorithm-framework/blob/master/AUTHORS.md)
393
-
394
- ### [Bugs / Issues](https://github.com/investing-algorithms/investing-algorithm-framework/issues?q=is%3Aissue)
395
-
396
- 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)
397
- first. If it hasn't been reported, please [create a new issue](https://github.com/investing-algorithms/investing-algorithm-framework/issues/new).
398
-
399
- ### Contributing
357
+ ## 🤝 Contributing
400
358
 
401
359
  The investing algorithm framework is a community driven project.
402
360
  We welcome you to participate, contribute and together help build the future trading bots developed in python.
@@ -409,3 +367,20 @@ You can pick up a task by assigning yourself to it.
409
367
  This will ensure that interested parties can give valuable feedback on the feature, and let others know that you are working on it.
410
368
 
411
369
  **Important:** Always create your feature or hotfix against the `develop` branch, not `main`.
370
+
371
+ ## 📬 Support
372
+
373
+ * Slack Community
374
+ * Reddit Community
375
+
376
+
377
+ ## 🏆 Acknowledgements
378
+
379
+ We want to thank all contributors to this project. A full list of all the people that contributed to the project can be
380
+ found [here](https://github.com/investing-algorithms/investing-algorithm-framework/blob/master/AUTHORS.md)
381
+
382
+ ### [Bugs / Issues](https://github.com/investing-algorithms/investing-algorithm-framework/issues?q=is%3Aissue)
383
+
384
+ 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)
385
+ first. If it hasn't been reported, please [create a new issue](https://github.com/investing-algorithms/investing-algorithm-framework/issues/new).
386
+
@@ -1,28 +1,13 @@
1
- <br/>
2
- <div align="center">
3
- <h1><a href="https://investing-algorithm-framework.com" target="_blank">Investing Algorithm Framework</a></h4>
4
- </div>
5
- <br/>
6
-
7
- <div align="center">
8
- <b>Rapidly build and deploy quantitative strategies and trading bots</b>
9
- </div>
10
- <br/>
11
-
12
- <p align="center">
13
- <a target="_blank" href="https://investing-algorithm-framework.com">View Docs</a>
14
- <a href="https://investing-algorithm-framework.com/Getting%20Started/installation)">Getting Started</a>
15
- </p>
1
+ <div align="center"> <h1><a href="https://investing-algorithm-framework.com" target="_blank">Investing Algorithm Framework</a></h1> <p><b>Rapidly build, backtest, and deploy quantitative strategies and trading bots</b></p> <a target="_blank" href="https://investing-algorithm-framework.com">📖 View Documentation</a> | <a href="https://investing-algorithm-framework.com/Getting%20Started/installation">🚀 Getting Started</a> </div>
16
2
 
17
3
  ---
18
4
 
19
- <a href=https://investing-algorithm-framework.com><img src="https://img.shields.io/badge/docs-website-brightgreen"></a>
20
- [![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)
21
- [![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)
22
- [![Downloads](https://pepy.tech/badge/investing-algorithm-framework)](https://pepy.tech/badge/investing-algorithm-framework)
23
- [![Current Version](https://img.shields.io/pypi/v/investing_algorithm_framework.svg)](https://img.shields.io/pypi/v/investing_algorithm_framework.svg)
24
- <a href="https://www.reddit.com/r/InvestingBots/"><img src="https://img.shields.io/reddit/subreddit-subscribers/investingbots?style=social"></a> <br/>
25
- [![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!
5
+ <div align="center"> <a href="https://investing-algorithm-framework.com">
6
+ <a target="_blank" href="https://discord.gg/dQsRmGZP"><img src="https://img.shields.io/discord/1345358169777635410.svg?color=7289da&label=TradeBotLab%20Discord&logo=discord&style=flat"></a>
7
+ <img src="https://img.shields.io/badge/docs-website-brightgreen"></a> <a href="https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/publish.yml"><img src="https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/publish.yml/badge.svg"></a> <a href="https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/test.yml"><img src="https://github.com/coding-kitties/investing-algorithm-framework/actions/workflows/test.yml/badge.svg"></a> <a href="https://pepy.tech/project/investing-algorithm-framework"><img src="https://pepy.tech/badge/investing-algorithm-framework"></a> <a href="https://pypi.org/project/investing-algorithm-framework/"><img src="https://img.shields.io/pypi/v/investing-algorithm-framework.svg"></a> <a href="https://www.reddit.com/r/InvestingBots/"><img src="https://img.shields.io/reddit/subreddit-subscribers/investingbots?style=social"></a> <a href="https://github.com/coding-kitties/investing-algorithm-framework/stargazers"><img src="https://img.shields.io/github/stars/coding-kitties/investing-algorithm-framework.svg?style=social&label=Star"></a>
8
+ </div>
9
+
10
+ > If you like what we do, consider starring, sharing and contributing!
26
11
 
27
12
  ## Sponsors
28
13
 
@@ -34,66 +19,54 @@
34
19
  </picture>
35
20
  </a>
36
21
 
37
- ## Features and planned features:
38
-
39
- - [x] **Based on Python 3.10+**: Windows, macOS and Linux.
40
- - [x] **Documentation**: [Documentation](https://investing-algorithm-framework.com)
41
- - [x] **Persistence of portfolios, orders, positions and trades**: Persistence is achieved through sqlite.
42
- - [x] **Limit orders**: Create limit orders for buying and selling.
43
- - [x] **Trade models**: Models and functionality for trades, trades stop losses (fixed and trailing) and take profits (fixed and trailing).
44
- - [x] **Market data sources**: Market data sources for OHLCV data and ticker data, and extendible with custom data and events.
45
- - [x] **Polars and Pandas dataframes support** Out of the box dataframes support for fast data processing ([pola.rs](https://pola.rs/), [pandas](https://pandas.pydata.org/)).
46
- - [x] **Azure Functions support**: Stateless running for cloud function deployments in Azure.
47
- - [x] **Live trading**: Live trading.
48
- - [x] **Backtesting and performance analysis reports** [example](./examples/backtest_example)
49
- - [x] **Backtesting multiple algorithms with different backtest date ranges** [example](./examples/backtests_example)
50
- - [x] **Backtesting and results evaluation**: Compare multiple backtests and run experiments. Save and load backtests. Save strategies as part of the backtest. [docs](https://investing-algorithm-framework.com/Getting%20Started/backtesting)
51
- - [x] **Order execution**: Currently support for a wide range of crypto exchanges through [ccxt](https://github.com/ccxt/ccxt) (Support for traditional asset brokers is planned).
52
- - [x] **Web API**: Rest API for interacting with your deployed trading bot
53
- - [x] **PyIndicators**: Works natively with [PyIndicators](https://github.com/coding-kitties/PyIndicators) for technical analysis on your Pandas and Polars dataframes.
54
- - [ ] **Builtin WebUI (Planned)**: Builtin web UI to manage your bot and evaluate your backtests.
55
- - [ ] **Manageable via Telegram (Planned)**: Manage the bot with Telegram.
56
- - [ ] **Performance status report via Web UI and telegram(Planned)**: Provide a performance status of your current trades.
57
- - [ ] **CI/CD integration (Planned)**: Tools for continuous integration and deployment (version tracking, comparison of backtests, automatic deployments).
58
- - [ ] **Tracing and replaying of strategies in backtests (Planned)**: Tracing and replaying of strategies in backtests for specific dates and date ranges so you can evaluate your strategy step by step.
59
- - [ ] **AWS Lambda support (Planned)**: Stateless running for cloud function deployments in AWS.
60
- - [ ] **Azure App services support (Planned)**: deployments in Azure app services with Web UI.
61
-
62
- ## Quickstart
63
-
64
- 1. First install the framework using `pip`. The Investing Algorithm Framework is hosted on [PyPi](https://pypi.org/project/Blankly/).
22
+
23
+ ## 🌟 Features
24
+
25
+ - [x] Python 3.10+: Cross-platform support for Windows, macOS, and Linux.
26
+ - [x] Backtesting: Simulate strategies with detailed performance reports.
27
+ - [x] Live Trading: Execute trades in real-time with support for multiple exchanges via ccxt.
28
+ - [x] Portfolio Management: Manage portfolios, trades, and positions with persistence via SQLite.
29
+ - [x] Market Data Sources: Fetch OHLCV, ticker, and custom data with support for Polars and Pandas.
30
+ - [x] Azure Functions Support: Deploy stateless trading bots to Azure.
31
+ - [x] Web API: Interact with your bot via REST API.
32
+ - [x] PyIndicators Integration: Perform technical analysis directly on your dataframes.
33
+ - [x] Extensibility: Add custom strategies, data providers, order executors so you can connect your trading bot to your favorite exchange or broker.
34
+
35
+ ## 🚀 Quickstart
36
+
37
+ Installation
38
+ Install the framework via [PyPI](https://pypi.org/project/investing-algorithm-framework/):
39
+
40
+ 1. First install the framework using `pip`. The Investing Algorithm Framework is hosted on [PyPi].
65
41
 
66
42
  ```bash
67
- $ pip install investing-algorithm-framework
43
+ pip install investing-algorithm-framework
68
44
  ```
69
45
 
70
- 2. Next, just run:
46
+ Run the following command to set up your project:
71
47
 
72
48
  ```bash
73
- $ investing-algorithm-framewor init
49
+ investing-algorithm-framewor init
74
50
  ```
75
51
 
76
- or if you want the web version:
52
+ For a web-enabled version:
77
53
 
78
54
  ```bash
79
- $ investing-algorithm-framework init --web
55
+ investing-algorithm-framework init --web
80
56
  ```
81
- > You can always change the app to the web version by changing the `app.py` file.
82
57
 
83
- The command will create the file `app.py` and an example script called `strategy.py`.
58
+ This will create:
84
59
 
85
- From there, you start building your trading bot in the `strategy.py`.
60
+ * app.py: The entry point for your bot.
61
+ * strategy.py: A sample strategy file to get started.
86
62
 
87
- More information can be found on our [docs](https://docs.blankly.finance)
88
-
89
- > Make sure you leave the `app.py` file as is, as it is the entry point for the framework.
90
- > You can change the `bot.py` file to your liking and add other files to the working directory.
91
- > The framework will automatically pick up the files in the working directory.
92
- ```
63
+ > Note: Keep the app.py file as is. You can modify strategy.py and add additional files to build your bot.
64
+ > You can always change the app to the web version by changing the `app.py` file.
93
65
 
94
- ## Example implementation
66
+ ---
95
67
 
96
- The following algorithm connects to binance and buys BTC every 2 hours.
68
+ ## 📈 Example: A Simple Trading Bot
69
+ The following example connects to Binance and buys BTC every 2 hours.
97
70
 
98
71
  ```python
99
72
  import logging.config
@@ -157,7 +130,7 @@ if __name__ == "__main__":
157
130
 
158
131
  > You can find more examples [here](./examples) folder.
159
132
 
160
- ## Backtesting and experiments
133
+ ## 🔍 Backtesting
161
134
 
162
135
  The framework also supports backtesting and performing backtest experiments. After a backtest, you can print a report that shows the performance of your trading bot.
163
136
 
@@ -270,45 +243,38 @@ Take profits overview
270
243
  ╰────────────────────┴───────────────┴──────────┴──────────┴─────────────────────────────────────┴──────────────┴────────────────┴─────────────────────────────────┴──────────────┴─────────────┴───────────────╯
271
244
  ```
272
245
 
273
- ### Backtest experiments
246
+ ## 🌐 Deployment to Azure
274
247
 
275
- The framework also supports backtest experiments. Backtest experiments allows you to
276
- compare multiple algorithms and evaluate their performance. Ideally,
277
- you would do this by parameterizing your strategy and creating a factory function that
278
- creates the algorithm with the different parameters. You can find an example of this
279
- in the [backtest experiments example](./examples/backtest_experiment).
248
+ Prerequisites
280
249
 
281
- ## Broker/Exchange configuration
250
+ Ensure Azure Functions Core Tools are installed:
282
251
 
283
- The framework has by default support for [ccxt](https://github.com/ccxt/ccxt).
284
- This should allow you to connect to a lot of brokers/exchanges.
252
+ ```bash
253
+ npm install -g azure-functions-core-tools@4 --unsafe-perm true
254
+ ```
255
+ Deploying to Azure
256
+ Use the provided deployment script:
257
+
258
+ This script:
285
259
 
286
- ```python
287
- from investing_algorithm_framework import PortfolioConfiguration, \
288
- MarketCredential, create_app
289
- app = create_app()
290
- app.add_market_credential(
291
- MarketCredential(
292
- market="<your market>",
293
- api_key="<your api key>",
294
- secret_key="<your secret key>",
295
- )
296
- )
297
- app.add_portfolio_configuration(
298
- PortfolioConfiguration(
299
- market="<your market>",
300
- initial_balance=400,
301
- trading_symbol="EUR"
302
- )
303
- )
304
260
  ```
261
+ investing-algorithm-framework deploy
262
+ ```
263
+
264
+ This script:
265
+
266
+ * Creates Azure resources (e.g., storage accounts, function apps).
267
+ * Sets environment variables for the Azure Function.
268
+ * Deploys your bot to Azure.
305
269
 
306
- ## Performance
270
+ ## 📚 Documentation
271
+ Comprehensive documentation is available at [investing-algorithm-framework.com](https://investing-algorithm-framework.com).
307
272
 
308
- We are continuously working on improving the performance of the framework. If
309
- you have any suggestions, please let us know.
273
+ ## 🛠️ Development
310
274
 
311
- ## Installation for local development
275
+ Local Development
276
+
277
+ Clone the repository and install dependencies using Poetry:
312
278
 
313
279
  The framework is built with poetry. To install the framework for local development, you can run the following commands:
314
280
 
@@ -329,11 +295,11 @@ To run the tests, you can run the following command:
329
295
  python -m unittest discover -s tests
330
296
  ```
331
297
 
332
- ## Disclaimer
298
+ ## ⚠️ Disclaimer
299
+
333
300
 
334
301
  If you use this framework for your investments, do not risk money
335
- which you are afraid to lose, until you have clear understanding how
336
- the framework works. We can't stress this enough:
302
+ which you are afraid to lose, until you have clear understanding how the framework works. We can't stress this enough:
337
303
 
338
304
  BEFORE YOU START USING MONEY WITH THE FRAMEWORK, MAKE SURE THAT YOU TESTED
339
305
  YOUR COMPONENTS THOROUGHLY. USE THE SOFTWARE AT YOUR OWN RISK.
@@ -342,6 +308,8 @@ THE AUTHORS AND ALL AFFILIATES ASSUME NO RESPONSIBILITY FOR YOUR INVESTMENT RESU
342
308
  Also, make sure that you read the source code of any plugin you use or
343
309
  implementation of an algorithm made with this framework.
344
310
 
311
+ We welcome contributions! Check out the project board and issues to get started.
312
+
345
313
  ## Documentation
346
314
 
347
315
  All the documentation can be found online
@@ -354,17 +322,7 @@ contributing page at the website.
354
322
  If you'd like to chat with investing-algorithm-framework users
355
323
  and developers, [join us on Slack](https://inv-algo-framework.slack.com) or [join us on reddit](https://www.reddit.com/r/InvestingBots/)
356
324
 
357
- ## Acknowledgements
358
-
359
- We want to thank all contributors to this project. A full list of all the people that contributed to the project can be
360
- found [here](https://github.com/investing-algorithms/investing-algorithm-framework/blob/master/AUTHORS.md)
361
-
362
- ### [Bugs / Issues](https://github.com/investing-algorithms/investing-algorithm-framework/issues?q=is%3Aissue)
363
-
364
- 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)
365
- first. If it hasn't been reported, please [create a new issue](https://github.com/investing-algorithms/investing-algorithm-framework/issues/new).
366
-
367
- ### Contributing
325
+ ## 🤝 Contributing
368
326
 
369
327
  The investing algorithm framework is a community driven project.
370
328
  We welcome you to participate, contribute and together help build the future trading bots developed in python.
@@ -376,4 +334,20 @@ You can pick up a task by assigning yourself to it.
376
334
  **Note** before starting any major new feature work, *please open an issue describing what you are planning to do*.
377
335
  This will ensure that interested parties can give valuable feedback on the feature, and let others know that you are working on it.
378
336
 
379
- **Important:** Always create your feature or hotfix against the `develop` branch, not `main`.
337
+ **Important:** Always create your feature or hotfix against the `develop` branch, not `main`.
338
+
339
+ ## 📬 Support
340
+
341
+ * Slack Community
342
+ * Reddit Community
343
+
344
+
345
+ ## 🏆 Acknowledgements
346
+
347
+ We want to thank all contributors to this project. A full list of all the people that contributed to the project can be
348
+ found [here](https://github.com/investing-algorithms/investing-algorithm-framework/blob/master/AUTHORS.md)
349
+
350
+ ### [Bugs / Issues](https://github.com/investing-algorithms/investing-algorithm-framework/issues?q=is%3Aissue)
351
+
352
+ 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)
353
+ first. If it hasn't been reported, please [create a new issue](https://github.com/investing-algorithms/investing-algorithm-framework/issues/new).
@@ -18,6 +18,7 @@ from investing_algorithm_framework.infrastructure import \
18
18
  CCXTTickerMarketDataSource, CSVOHLCVMarketDataSource, \
19
19
  CSVTickerMarketDataSource, AzureBlobStorageStateHandler
20
20
  from .create_app import create_app
21
+ from .download_data import download
21
22
 
22
23
  __all__ = [
23
24
  "Algorithm",
@@ -75,5 +76,6 @@ __all__ = [
75
76
  "MarketDataType",
76
77
  "TradeRiskType",
77
78
  "Context",
78
- "APPLICATION_DIRECTORY"
79
+ "APPLICATION_DIRECTORY",
80
+ "download"
79
81
  ]