StockTradebyZ  by SebastienZh

Semi-automatic A-share stock selection

Created 10 months ago
1,336 stars

Top 29.7% on SourcePulse

GitHubView on GitHub
Project Summary

Summary

AgentTrader is a semi-automatic stock selection project for the Chinese A-share market, targeting investors and researchers. It automates initial screening using quantitative rules and provides AI-driven chart analysis via Gemini for re-evaluation, aiming to streamline the stock selection process.

How It Works

The system follows a four-step pipeline: fetching daily K-line data via Tushare, applying quantitative rules (currently B1 strategy) for pre-selection, exporting candidate charts, and finally using Gemini for AI-powered chart review and scoring. This hybrid approach combines rule-based filtering with AI's visual pattern recognition.

Quick Start & Requirements

Installation requires cloning the repo, pip install -r requirements.txt, and setting TUSHARE_TOKEN and GEMINI_API_KEY environment variables. Run the full pipeline with python run_all.py, using flags like --skip-fetch. Chart export needs the kaleido library. Configuration is managed via YAML files in config/.

Highlighted Details

  • Features an AI-driven chart review system using Gemini to score stock candidates.
  • Implements a semi-automatic workflow combining quantitative pre-selection (B1 strategy) with AI re-evaluation.
  • Supports configurable parameters for data fetching, selection thresholds, and AI review delay to manage API rate limits.

Maintenance & Community

The project is copyrighted by SebastienZh (2026). No community channels or contributor details are provided in the README.

Licensing & Compatibility

Released under CC BY-NC 4.0, permitting non-commercial use, research, and distribution with attribution. Commercial use, sale, or profit-oriented deployment is strictly prohibited.

Limitations & Caveats

Currently implements only the B1 quantitative strategy, with plans for expansion. Requires valid Tushare and Gemini API keys, plus the kaleido library. Gemini API rate limiting is possible and adjustable via request_delay. The non-commercial license restricts its use in commercial applications.

Health Check
Last Commit

4 weeks ago

Responsiveness

Inactive

Pull Requests (30d)
1
Issues (30d)
3
Star History
250 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.