Equity Research LLM Agent
A multi-agent Python system for comprehensive stock analysis and equity research reporting.
Overview
equity-research-agent leverages multiple specialized sub-agents to perform:
- Fundamental analysis (financial statements, ratios, trends)
- Technical analysis (price data, indicators)
- Fund flow analysis (capital inflow/outflow, liquidity)
- Policy analysis (government/regulatory news)
The main agent coordinates these sub-agents and synthesizes their findings into a unified research report.
Features
- Modular agent-based architecture
- Integrates API, Google Search, and MCP tools for data gathering
- Generates detailed, structured equity research reports
- Flexible report output formats (PDF/HTML) with full Chinese language support
- Send reports via email to a specified recipient or distribution group
Project Structure
pyproject.toml
uv.lock
stock_analysis_agent/
agent.py
config.py
.env
...
sub_agents/
fundamental_agent/
fund_agent/
policy_agent/
technical_agent/
mcp/
Requirements
- Developed and tested on Linux. Performance on Windows is not garanteed.
- Python 3.11+
- Dependencies as listed in pyproject.toml, including:
Setup on Linux
1. Environment Rebuilding
To recreate the project's virtual environment using uv, follow these steps:
i. Install uv (if not already installed)
pip install uv
ii. Clone the repository and navigate into it
git clone https://github.com/CarlosFinEngg/equity-research-agent.git
cd equity-research-agent
iii. Sync the environment to match pyproject.toml and uv.lock
uv sync
iv. Activate the virtual environment
source .venv/bin/activate
2. MCP Configuration
For the setup of MCP servers, please refer to the following:
If you use local MCP servers:
- clone the MCP repo to this project's root folder (parallel with
stock_analysis_agent) - rebuild the venv within the MCP's folder
If you use hosted MCP servers:
- add you API key to .env
Lastly, configure the parameters of StdioServerParameters() in agents according to the specific requirement of MCPs.
Usage
- Add a
.envfile instock_analysis_agent/and configure environment variables (e.g. LLM and MCP host platform API key) in as needed, for example:
GOOGLE_GENAI_USE_VERTEXAI=FALSE
GOOGLE_API_KEY=...
OPENAI_API_KEY=...
SMITHERY_API_KEY=...
-
Configure LLM models in
stock_analysis_agent/config.py -
Activate venv
source .venv/bin/activate
- Then run the agent in ADK WEB:
adk web
or run in Terminal:
adk run stock_analysis_agent
The analysis report will be generated in both Markdown format and your chosen output format (PDF/HTML). The reports can be found in the reports directory with the following naming convention:
reports/
equity_research_report_<company_name>_<ticker>_<YYYYMMDD>.md
equity_research_report_<company_name>_<ticker>_<YYYYMMDD>.html # or .pdf
License
MIT
Disclaimer
This project is for educational and informational purposes only. Analyses are generated by AI and does not constitute financial advice. Please conduct your own research or consult a qualified advisor before making investment decisions.
