Challenge
My largest project so far: an automation platform built to get the most out of the Dual Investments offered by the Gate.io exchange. It brings data analysis, tracking and automation together in a single system.
What is a Dual anyway?
A Dual Investment is a crypto product that pays a fixed yield but ties the payout currency to the market price. You deposit, say, USDT and set a target price ("strike") plus an expiry date. If the price meets a certain condition at expiry, your deposit is converted at the strike into the other currency (for example BTC). If it does not, you get your USDT back plus interest. Either way you earn the agreed yield. You just don't know in advance which of the two currencies you'll be paid out in. Hence "dual": two possible outcome currencies, a guaranteed yield, but a price risk on the conversion direction.
My platform guides you from A to Z. It optimizes the yield and manages the risk to reach a good entry price depending on your strategy. Once configured, it can largely run on its own. A price risk always remains.
Solution
The tracker unifies the ingestion, archiving and orchestration of Duals. Through currently three different modes, each user can configure their risk profile as they like and keep an overview of their investments. Behind the scenes, exchange data is normalized, investment state is persisted in PostgreSQL, and analytics are exposed that make active exposure, settlement progress and completed cycles easier to audit.
- Ingests plans and order events into a consistent lifecycle model.
- Tracks active, settled and pending positions with clear operational state.
- Includes configurable automation with dry-run execution before live actions.
- Runs in Docker so the system can be deployed and reviewed consistently.
Outcome
The project turns a trading workflow into an auditable operations tool. The important value is not a flashy chart, it is reliable state, safety controls and a dashboard that makes decisions visible before automation acts.
Evolution
The current product is the seventh iteration of an idea that began as a single 234-line Python script in 2024. Across 498 commits it grew from a Streamlit data viewer into a multi-user platform, survived a full FastAPI and Next.js rebuild, migrated from SQLite to PostgreSQL, and was hardened for live trading. The timeline below reconstructs each era from its historical commit. Each view was launched live against public market data from Gate.io and captured by screenshot.
