Python framework for DeFi trading strategy development
Top 89.7% on sourcepulse
This Python framework enables quantitative financial analysis and algorithmic trading on decentralized exchanges (DEXes). It targets quantitative analysts, developers, and researchers interested in building, backtesting, and deploying automated trading strategies on blockchains like Ethereum, Binance Smart Chain, and Polygon, leveraging on-chain data from DEX aggregators.
How It Works
The framework utilizes the Trading Strategy Protocol for data fetching, supporting both historical backtesting and real-time price feeds. It integrates with Jupyter Notebooks for interactive development and allows strategies to be deployed as on-chain smart contracts, enabling users to invest directly via their wallets.
Quick Start & Requirements
poetry add trading-strategy -E direct-feed
or pip install "trading-strategy[direct-feed]"
. For automated trading, install trade-executor
separately.Highlighted Details
Maintenance & Community
Active community with resources on their website, Blog, Twitter, Discord, and Telegram.
Licensing & Compatibility
Licensed under GNU AGPL 3.0. This license is copyleft and may impose restrictions on linking with proprietary or closed-source software.
Limitations & Caveats
The trading-strategy
package itself only provides data fetching and management. Development of automated trading strategies requires the separate installation and integration of the trade-executor
package.
10 hours ago
1 week