tradingstrategy-ai/trading-strategy
소개
탈중앙화 거래소의 정량적 금융 분석과 트레이딩 알고리즘을 위한 Python 프레임워크
비즈니스 및 금융What you can do
- Supports multiple blockchains like Ethereum mainnet, Binance Smart Chain and Polygon
- Access trading data from on-chain decentralised exchanges like SushiSwap, QuickSwap and PancakeSwap
- Integration with Jupyter Notebook for easy manipulation of data. See example notebooks.
- Write algorithmic trading strategies for decentralised exchange
측정된 스타 증가
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- +1
- in 1 month
- 기록 수집 중
서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.
README.md
OriginalTrading Strategy framework for Python
Trading Strategy framework is a Python framework for algorithmic trading on decentralised exchanges.
- Download decentralised finance market data sets
- Develop and backtest trading strategies in Jupyter Notebook
- Live trade execution for onchain trading
- Smart contract vault support for turning your trading strategy to a third-party investable vault
The trading-strategy library provides data fetching for backtesting and live trading.
It is using backtesting data and real-time price feeds from Trading Strategy Protocol.
Use cases
Analyse cryptocurrency investment opportunities on decentralised exchanges (DEXes)
Creating trading algorithms and trading bots that trade on DEXes
Deploy trading strategies as on-chain smart contracts where users can invest and withdraw with their wallets
Features
Supports multiple blockchains like Ethereum mainnet, Binance Smart Chain and Polygon
Access trading data from on-chain decentralised exchanges like SushiSwap, QuickSwap and PancakeSwap
Integration with Jupyter Notebook for easy manipulation of data. See example notebooks.
Write algorithmic trading strategies for decentralised exchange
Getting started
See the Getting Started repository and the rest of the Trading Strategy documentation.
For JSON-only vault readiness polling and ETag-verified price snapshots, see Vault scan readiness receipts.
Historical HyperCore deposit permission uses original observation clocks,
separately from price/publication time. See
convert_vault_prices_to_vault_state()
for explicit permission-history input and
select_permission_state() for snapshot
precedence and uncertainty handling. Recovered legacy flags use inferred price
clocks with visible provenance. Recorded leader shares and deposit caps remain
readable when older schemas have no separate capacity clock. A zero cap blocks
deposits without declaring the venue closed; a NULL cap remains unknown. Newer
coherent responses, including unknowns, replace the whole policy snapshot.
Prerequisites
Python 3.10
Understanding Python package management and installation (unless using Dev Container from teh above)
Installing the package
You can install this package with
Poetry as a dependency:
poetry add trading-strategy -E direct-feed
Poetry, local development:
poetry install -E direct-feed
Pip:
pip install "trading-strategy[direct-feed]"
Note: trading-strategy package provides trading data
download and management functionality only. If you want to developed
automated trading strategies you need to install trade-executor package as well.
Documentation
Community
Read more documentation how to develop this package.
License
GNU AGPL 3.0.
Vault permission sidecars
The vault-state converter preserves explicit permission/capacity projections, including unknown values and original evidence clocks. For older sidecars without those projections it uses the shared eth-defi Hyperliquid classifier; it does not maintain another leader-share threshold or HLP-parent exception. Missing relationship metadata remains uncertain rather than being assumed to identify a normal vault.
Legacy sidecars without permission/capacity projections require
eth_defi.hyperliquid.vault.classify_hyperliquid_vault_deposit, introduced in
eth-defi PR #1596.
PyPI release 1.2 does not contain this API. Development and CI therefore use the
Git source pinned in the development dependency group and lockfile (44f365a,
GitHub HEAD checked on 27 October 2026); poetry install --all-extras installs
that source, including the current Web3 7 dependency stack.
The library's version-based dependency allows a parent trade-executor checkout
to supply its editable deps/web3-ethereum-defi Git checkout. That is the normal
notebook/strategy setup; it must contain the shared classifier. The development
Git pin is not imposed on that parent project's dependency resolution. Update
source pins deliberately rather than using a moving branch in the lockfile.
Price-only conversion and sidecars with recorded permission/capacity fields do
not import or call the classifier. A missing explanatory reason string alone
does not trigger protocol reclassification. Strategy admission policy belongs
to the executor's tradeexecutor.strategy.vault_closure module.
관련 프로젝트 살펴보기
불러오는 중…