A_Share_investment_Agent  by 24mlight

AI investment system concept project for educational purposes

Created 8 months ago
2,039 stars

Top 21.8% on SourcePulse

GitHubView on GitHub
Project Summary

This project provides a proof-of-concept AI investment system for the A-share market, designed to assist in investment decision-making. It targets individuals interested in exploring AI-driven quantitative trading strategies and offers a modular, agent-based architecture for educational purposes.

How It Works

The system employs a multi-agent architecture, featuring specialized agents for market data analysis, technicals, fundamentals, sentiment, valuation, risk management, and portfolio management. A key innovation is the "Debate Room" module, which incorporates a "Bull Researcher" and "Bear Researcher" to analyze market data from opposing viewpoints. This is further enhanced by integrating a third-party LLM for objective evaluation and a hybrid confidence calculation that fuses traditional metrics with LLM scores, leading to more balanced and comprehensive investment decisions.

Quick Start & Requirements

  • Install: Clone the repository, install Poetry, then run poetry install.
  • Prerequisites: Python 3.x, Poetry. Requires API keys for Google Gemini or OpenAI-compatible services.
  • Setup: Set environment variables (e.g., GEMINI_API_KEY) or configure the .env file.
  • Usage:
    • Command line: poetry run python src/main.py --ticker <stock_code>
    • With reasoning: poetry run python src/main.py --ticker <stock_code> --show-reasoning
    • Backend API: poetry run python run_with_backend.py (access at http://localhost:8000/docs)
  • Docs: Backend API Documentation (once backend is running)

Highlighted Details

  • Supports multiple LLM providers (Google Gemini, OpenAI-compatible).
  • Modular agent design for easy maintenance and extensibility.
  • Includes a "Debate Room" with LLM-based third-party analysis for decision enhancement.
  • Provides a backend API for asynchronous analysis and custom frontend development.
  • Detailed logging for all API calls and agent reasoning processes.

Maintenance & Community

The project is a modification of ai-hedge-fund. The creator invites users to join a paid knowledge community for deeper insights and early access to code. Contact is via WeChat (PareidoliaX). A public WeChat account, "空指针指向量化 Agent," is also mentioned for content.

Licensing & Compatibility

MIT License. Permissive for commercial use and closed-source linking.

Limitations & Caveats

The project is explicitly for educational and research purposes only and is not suitable for actual trading. The backtesting system is still under testing. The README mentions a paid community for additional support and resources.

Health Check
Last Commit

1 month ago

Responsiveness

1 day

Pull Requests (30d)
0
Issues (30d)
2
Star History
80 stars in the last 30 days

Explore Similar Projects

Starred by Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems"), Didier Lopes Didier Lopes(Founder of OpenBB), and
5 more.

qlib by microsoft

1.4%
31k
AI platform for quantitative investment research and production
Created 5 years ago
Updated 3 days ago
Starred by Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems"), Junyang Lin Junyang Lin(Core Maintainer at Alibaba Qwen), and
4 more.

ai-hedge-fund by virattt

2.4%
41k
AI-powered hedge fund proof-of-concept for educational use
Created 9 months ago
Updated 1 day ago
Feedback? Help us improve.