EthanAlgoX/AIStock

A multi-agent AI trading system using LLMs to optimize strategies and adapt to market conditions in real-time.

AI Stock – AI‑powered research workspace for equity traders

What it is

  • A web‑based platform that lets individual traders ask natural‑language questions about Chinese, Hong‑Kong or US stocks and get structured research reports. The core engine is an Agent that orchestrates large‑language‑model (LLM) reasoning, deterministic financial tools, and optional “expert” agents that can debate or vote on a topic.

How it works

  1. Conversation first – users start a chat in the Research assistant workspace. The system can pull market data, run screening rules, or invoke pre‑built financial “Skills”.
  2. Independent expert agents – each expert runs as its own LLM‑driven agent with a defined role (e.g., valuation, macro, risk). They can collaborate in three modes:
    • Pipeline: tasks are split and passed along.
    • Debate: agents argue, then a moderator summarises.
    • Voting: each agent submits a report, reviewers vote, and the moderator reports the outcome.
  3. Reports & roundtables – the final output is a saved, readable report. Users can also view the full round‑table transcript showing each expert’s contribution.
  4. Other workspaces – market radar, strategy screening, stock‑research execution, and paper‑trade simulation are all integrated, sharing the same task ledger and capability catalog.

Key components

Component Role
Agent layer Orchestrates LLM calls, tool usage, and expert coordination
Skills Version‑controlled financial methods (e.g., valuation models, risk metrics)
Built‑in Tools Deterministic data fetches and calculations (price history, fundamentals, news)
MCP (Model‑Connector‑Proxy) Plug‑in point for external services (LLM providers, data APIs)
Capability Center UI for enabling/disabling Skills, Tools, data sources, and expert agents
Workspace UI React‑based front‑end (React 19, Vite) with separate routes for each workflow
Backend FastAPI server serving the API and static web build

Tech stack

  • Python 3.10+ – FastAPI backend, agent orchestration, data handling.
  • Node.js 20+ / npm 10+ – React 19 front‑end (apps/dsa-web).
  • LLM integration – configurable providers (e.g., DeepSeek) via environment variables; tool‑calling models are required.
  • Docker/virtual‑env – not mandatory but supported; CI uses GitHub Actions.

Typical workflow for a new user

  1. Clone the repo and set up a Python virtual environment.
  2. Install Python dependencies (pip install -r requirements.txt).
  3. Copy .env.example to .env and add an LLM API key (e.g., DEEPSEEK_API_KEY).
  4. Build the React app (npm ci && npm run build).
  5. Run the server (python main.py --serve-only).
  6. Open http://127.0.0.1:8000, go to Research assistant, ask a question like “What are the growth prospects for Tencent?”
  7. Review the generated report, or start an Expert roundtable to see multiple viewpoints.

Safety & governance

  • All capabilities (Skills, Tools, data sources, experts) are whitelist‑controlled per workspace.
  • The Agent cannot place real orders; only paper‑trade simulations are allowed.
  • Secrets stay in the environment and are never exposed through the API.
  • Execution logs record whether a task completed, partially succeeded, or was blocked.

Who it’s for

  • Individual equity traders or analysts who want AI‑augmented research without building their own pipelines.
  • Developers interested in building LLM‑driven financial agents, as the repo exposes the full agent‑skill‑tool architecture.

Getting started

# Clone and prepare
git clone https://github.com/EthanAlgoX/InvestCrew.git AI-Stock
cd AI-Stock
python3 -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .env   # then add your LLM API key

# Build front‑end
cd apps/dsa-web
npm ci && npm run build
cd ../..

# Run server
python main.py --serve-only --host 127.0.0.1 --port 8000

Visit the UI, configure the model in Settings, and start exploring.

License

  • MIT License – free for personal, research, or commercial use, with the usual disclaimer that the generated analysis is not investment advice.

All information above is taken directly from the repository’s README; no additional features have been inferred.

Related

  • Project
  • Project
  • Project
  • Project