llm-agent-trader  by jason8745

AI stock trading backtester

Created 4 months ago
337 stars

Top 81.6% on SourcePulse

GitHubView on GitHub
Project Summary

LLM Agent Trader is an AI-powered backtesting system designed for evaluating stock trading strategies. It leverages Large Language Models (LLMs) to analyze trading decisions, providing an intelligent framework for quantitative traders, researchers, and developers to test and refine their approaches. The system aims to offer a more nuanced and adaptive strategy evaluation than traditional rule-based backtesters.

How It Works

The architecture features a Next.js frontend interacting with a FastAPI backend. The core LLM Streaming Backtest Engine integrates LLMs (Azure OpenAI or Google Gemini) with a Technical Analysis Engine and a Risk Management Module. It fetches stock data via YFinance and logs backtest results in an SQLite Database. The LLM component generates trading signals, which are then processed for performance calculation and result recording.

Quick Start & Requirements

  • Installation: make install
  • Environment Setup: Copy .env.example to .env and configure LLM API keys (Azure OpenAI or Google Gemini) within the .env file.
  • Prerequisites: Native make support is expected on macOS/Linux. Windows users may require WSL, Git Bash, or a separate make utility installation.
  • Run: make run (access via http://localhost:3000)
  • Other Commands: make stop, make test, make clean, make format.

Highlighted Details

  • Integrates LLMs (Azure OpenAI, Google Gemini) for intelligent trading signal generation and strategy analysis.
  • Modular architecture separating frontend, backend, LLM engine, and data services.
  • Utilizes YFinance for historical stock data retrieval.

Maintenance & Community

No specific information regarding maintainers, community channels (e.g., Discord/Slack), or project roadmap is provided in the README.

Licensing & Compatibility

The repository's license is not specified in the provided README. Compatibility for commercial use or integration with closed-source systems is undetermined.

Limitations & Caveats

Windows users may encounter difficulties with the make commands, necessitating the use of WSL or alternative command-line environments. Configuration of external LLM API keys (Azure OpenAI or Google Gemini) is mandatory for operation. The project appears to be in an early stage, with no explicit mention of testing, benchmarks, or production readiness.

Health Check
Last Commit

2 weeks ago

Responsiveness

Inactive

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

Explore Similar Projects

Feedback? Help us improve.