# QuantConnect/Lean

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/quantconnect-lean).**

16,537 stars · 4,347 forks · C# · apache-2.0

## Links

- GitHub: https://github.com/QuantConnect/Lean
- Homepage: https://lean.io
- awesome-repositories: https://awesome-repositories.com/repository/quantconnect-lean.md

## Topics

`algorithm` `algorithmic-trading-engine` `c-sharp` `finance` `forex` `lean-engine` `options` `python` `quantconnect` `stock-indicators` `trading` `trading-algorithms` `trading-bot` `trading-platform` `trading-strategies`

## Description

Lean is an algorithmic trading engine and quantitative finance platform designed for the development, backtesting, and live execution of automated trading strategies. It provides a comprehensive framework for processing time-series market data, managing multi-asset portfolios, and conducting quantitative research across diverse financial markets.

The platform distinguishes itself through a modular, event-driven architecture that decouples strategy logic from data ingestion and brokerage connectivity. By utilizing standardized interfaces for data providers and brokerage abstractions, it enables users to normalize heterogeneous market feeds and execute trades across multiple asset classes within a unified environment. This design ensures that trading logic remains consistent whether operating in a historical simulation or a live market setting.

Beyond core execution, the framework includes integrated tools for technical indicator calculation, portfolio risk management, and performance analytics. It supports the entire research lifecycle, from hypothesis testing and parameter optimization to the management of asset universes and automated order execution. The system also provides mechanisms for persistent state management and project synchronization to maintain continuity across development and deployment environments.

## Tags

### Business & Productivity Software

- [Algorithmic Trading Frameworks](https://awesome-repositories.com/f/business-productivity-software/algorithmic-trading-frameworks.md) — Provides a framework for backtesting and executing automated trading strategies across multiple asset classes using historical and real-time market data.
- [Automated Trading Engines](https://awesome-repositories.com/f/business-productivity-software/automated-trading-engines.md) — Connects algorithmic models to brokerage accounts to automate order submission and manage market exposure with precision and efficiency.
- [Trading Execution Engines](https://awesome-repositories.com/f/business-productivity-software/trading-execution-engines.md) — Connects algorithmic strategies to brokerage accounts to automate order submission and portfolio management in real-time. ([source](https://lean.io/docs/v2/lean-cli))
- [Trading Strategy Backtesters](https://awesome-repositories.com/f/business-productivity-software/trading-strategy-backtesters.md) — Provides tools for building and testing automated financial trading strategies using historical market data to validate performance.
- [Trading Simulation Engines](https://awesome-repositories.com/f/business-productivity-software/trading-simulation-engines.md) — Simulates historical market conditions to evaluate the effectiveness and risk metrics of trading algorithms within a controlled environment.
- [Automated Risk Management](https://awesome-repositories.com/f/business-productivity-software/automated-risk-management.md) — Monitors market conditions and applies hedging and position sizing rules to mitigate financial exposure. ([source](https://lean.io/docs/))
- [Exchange Abstraction Layers](https://awesome-repositories.com/f/business-productivity-software/exchange-abstraction-layers.md) — Standardizes order execution and portfolio management by mapping generic trading commands to specific API implementations for various financial exchanges.
- [Strategy Performance Analyzers](https://awesome-repositories.com/f/business-productivity-software/trading-risk-analysis/strategy-performance-analyzers.md) — Compiles detailed analytical summaries and visualizations of algorithm performance to provide professional insights into trading results and risk metrics. ([source](https://lean.io/docs/v2/lean-cli))

### Scientific & Mathematical Computing

- [Backtesting Engines](https://awesome-repositories.com/f/scientific-mathematical-computing/quantitative-finance/backtesting-engines.md) — Simulates algorithm performance against historical market data to evaluate strategy effectiveness and risk metrics. ([source](https://lean.io/docs/))
- [Research Platforms](https://awesome-repositories.com/f/scientific-mathematical-computing/quantitative-finance/research-platforms.md) — Offers a development environment for researching investment hypotheses, optimizing strategy parameters, and managing complex portfolio risk through mathematical modeling.
- [Order Execution Engines](https://awesome-repositories.com/f/scientific-mathematical-computing/order-execution-engines.md) — Implements pluggable algorithms to manage the efficient entry and exit of trades while accounting for market impact and slippage. ([source](https://lean.io/docs/))
- [Financial Analysis Tools](https://awesome-repositories.com/f/scientific-mathematical-computing/quantitative-finance/financial-analysis-tools.md) — Analyzes large datasets and tests investment hypotheses through mathematical modeling to identify profitable trading signals and market trends.
- [Research and Data Analysis Tools](https://awesome-repositories.com/f/scientific-mathematical-computing/research-analysis-workflows/research-and-data-analysis-tools.md) — Facilitates interactive data analysis and strategy prototyping using historical market data to validate trading ideas. ([source](https://lean.io/docs/v2/lean-cli))

### Data & Databases

- [Financial Data Processing](https://awesome-repositories.com/f/data-databases/financial-data-processing.md) — Provides a toolkit for importing, generating, and analyzing time-series market data to drive decision-making in automated trading workflows.
- [Asset Filtering](https://awesome-repositories.com/f/data-databases/asset-filtering.md) — Provides utilities for defining and curating subsets of financial assets for analysis and automated scanning. ([source](https://lean.io/docs/))
- [Portfolio Rebalancing](https://awesome-repositories.com/f/data-databases/data-partitioning-strategies/automatic-rebalancing/portfolio-rebalancing.md) — Provides automated logic for adjusting asset holdings to meet target portfolio allocations based on mathematical models. ([source](https://lean.io/docs/))
- [Custom Data Ingestion](https://awesome-repositories.com/f/data-databases/custom-data-augmentation-frameworks/custom-data-ingestion.md) — Imports proprietary time-series signals from external databases, files, or streaming sockets to augment backtesting models and live trading strategies. ([source](https://lean.io/docs/))

### Artificial Intelligence & ML

- [Portfolio Rebalancing](https://awesome-repositories.com/f/artificial-intelligence-ml/portfolio-optimization-algorithms/portfolio-rebalancing.md) — Constructs and rebalances diversified investment portfolios across equities, forex, and crypto to optimize risk and returns in real-time.
- [Technical Indicators](https://awesome-repositories.com/f/artificial-intelligence-ml/agentic-systems-frameworks/integration-deployment/agent-frameworks/tool-definitions-and-registration/custom-tool-definitions/technical-indicators.md) — Applies mathematical functions to market data to identify trends and generate signals for automated trading logic. ([source](https://lean.io/docs/))

### Software Engineering & Architecture

- [Simulation Engines](https://awesome-repositories.com/f/software-engineering-architecture/event-driven-architectures/simulation-engines.md) — Processes discrete time-series events through a synchronized clock to ensure deterministic execution of trading logic across historical and live environments.
- [Trading Strategy Optimizers](https://awesome-repositories.com/f/software-engineering-architecture/performance-reliability/performance-optimization/computational-efficiency/cpu-optimization-strategies/trading-strategy-optimizers.md) — Runs multiple strategy iterations in parallel to identify optimal parameters while managing resource consumption. ([source](https://lean.io/docs/v2/lean-cli))
- [Trading Frameworks](https://awesome-repositories.com/f/software-engineering-architecture/vault-standards/multi-asset-vaults/trading-frameworks.md) — Executes strategies across diverse asset classes including equities, forex, and crypto within a single unified portfolio. ([source](https://lean.io/docs/))
- [Data Provider Plugins](https://awesome-repositories.com/f/software-engineering-architecture/software-architecture/architectural-patterns/modular-decoupled-design/decoupled-architectures/data-provider-plugins.md) — Decouples raw data ingestion from strategy logic by using standardized interfaces to normalize diverse market feeds into a unified internal format.
- [Project Lifecycle Management](https://awesome-repositories.com/f/software-engineering-architecture/project-management-governance/project-management/project-lifecycle-management.md) — Organizes algorithm files and deployment configurations into structured projects to streamline the development and execution lifecycle. ([source](https://lean.io/docs/v2/lean-cli))

### Networking & Communication

- [Market Data Normalizers](https://awesome-repositories.com/f/networking-communication/market-data-normalizers.md) — Transforms heterogeneous market data from multiple sources into a consistent structure to facilitate accurate cross-asset analysis and backtesting.

### Development Tools & Productivity

- [Trading Strategy Lifecycles](https://awesome-repositories.com/f/development-tools-productivity/component-lifecycle-management/trading-strategy-lifecycles.md) — Manages the execution of trading algorithms through modular stages including initialization, data processing, order management, and final performance reporting.

### DevOps & Infrastructure

- [Cloud Synchronization Tools](https://awesome-repositories.com/f/devops-infrastructure/cloud-synchronization-tools.md) — Synchronizes local project files with remote cloud environments to ensure consistent development and execution across machines. ([source](https://lean.io/docs/v2/lean-cli/key-concepts/getting-started))
