TradeGuard
A fully offline, zero-dependency open-source trading behavior analysis tool written in pure Python standard library. It analyzes CSV-formatted trading histories to identify eight high-risk trading habits—such as martingale strategies and revenge trading—and outputs risk audit reports in the form of evidence chains.
Timeline (last 90 days)
TradeGuard is a fully offline, zero-dependency trading behavior analyzer written in pure Python standard library that performs audits via exported CSV trade history and account metrics.
TradeGuard audits against 8 behavioral risk rules, and each finding references the trade number, timestamp, and specific figures that triggered it.
TradeGuard's 8 rules include OVER_LEVERAGE, MARTINGALE, REVENGE_TRADING, RISK_PER_TRADE, DRAWDOWN, LOSS_STREAK, CONCENTRATION, and OVERTRADING.
The OVER_LEVERAGE rule catches notional value exceeding 10x equity, RISK_PER_TRADE catches single-trade risk exceeding 2% of equity, and CONCENTRATION catches a single instrument exceeding 40% of the portfolio.
TradeGuard identifies '6 consecutive trades within 9 minutes after a large loss' as revenge trading.
TradeGuard comes with an evaluation suite; running python eval.py executes all 16 assertions covering multiple scenarios.
The evaluation suite includes a no_network_access assertion to ensure the code makes no network calls, as well as clean_history_scores_zero and every_finding_has_evidence assertions.
TradeGuard uses deterministic rules and transparent thresholds rather than black-box AI risk scoring, making every judgment traceable and explainable.
TradeGuard can generate HTML reports for easy sharing with mentors, proprietary trading firm reviewers, and others.
TradeGuard is a project built for Deriv's "Rise of AI Agents" hackathon.
1 more timeline events
All Facts (11)
TradeGuard is a fully offline, zero-dependency trading behavior analyzer written in pure Python standard library that performs audits via exported CSV trade history and account metrics.
50%UnverifiedTradeGuard audits against 8 behavioral risk rules, and each finding references the trade number, timestamp, and specific figures that triggered it.
50%UnverifiedTradeGuard's 8 rules include OVER_LEVERAGE, MARTINGALE, REVENGE_TRADING, RISK_PER_TRADE, DRAWDOWN, LOSS_STREAK, CONCENTRATION, and OVERTRADING.
50%UnverifiedThe OVER_LEVERAGE rule catches notional value exceeding 10x equity, RISK_PER_TRADE catches single-trade risk exceeding 2% of equity, and CONCENTRATION catches a single instrument exceeding 40% of the portfolio.
50%UnverifiedTradeGuard identifies '6 consecutive trades within 9 minutes after a large loss' as revenge trading.
50%UnverifiedTradeGuard comes with an evaluation suite; running python eval.py executes all 16 assertions covering multiple scenarios.
50%UnverifiedThe evaluation suite includes a no_network_access assertion to ensure the code makes no network calls, as well as clean_history_scores_zero and every_finding_has_evidence assertions.
50%UnverifiedTradeGuard uses deterministic rules and transparent thresholds rather than black-box AI risk scoring, making every judgment traceable and explainable.
50%UnverifiedTradeGuard can generate HTML reports for easy sharing with mentors, proprietary trading firm reviewers, and others.
50%UnverifiedTradeGuard is a project built for Deriv's "Rise of AI Agents" hackathon.
50%UnverifiedThe TradeGuard project repository is at github.com/Zhiyilang/tradeguard and comes with a sample trade history intentionally filled with bad habits.
50%