Skip to content

Latest commit

 

History

History
133 lines (90 loc) · 4.91 KB

README.md

File metadata and controls

133 lines (90 loc) · 4.91 KB

FinMAS: Financial Analysis using LLM Multi-Agent Systems

CrewAI LlamaIndex OpenAI Groq Hugging Face Panel Hero License: MIT

This repo contains the code for WQU Capstone project where we investigate the use of LLM multi-agent systems for solving tasks in the financial domain. We use the CrewAI framework to orchestrate the agents, and the LlamaIndex framework to creating vector store index from unstructured text data like news and SEC filings.

4 crews have been created that have different focus, with different data sources. A final combined crew is created that combines data from news, SEC filings and market data to provide a final stock analysis that includes a recommendation.

The following screenshots illustrate a output from the combined crew and the main dashboard.

Combined analysis

Main dashboard

Web app architecture

The following diagram shows how the different components of the web app are connected together.

Getting started

1. Installation

To install the app do the following:

  1. Clone the repo
git clone https://github.com/KevorkSulahian/agentic-llm-for-better-results.git
cd agentic-llm-for-better-results
  1. Create a virtual environment and install the dependencies into the environment.

We recommend using the uv package manager to install the dependencies.

From the root of the project run the following command to install the latest dependencies without the development dependencies:

uv sync --upgrade --no-dev

If you want to use standard pip instead, use the following:

python -m venv .venv
source .venv/bin/activate  # macOS or Linux
.venv\Scripts\activate  # Windows
pip install -r requirements.txt
  1. Set up .env file with necessary API keys.

2. Running the app

Activate the virtual environment and start the server by using panel:

source .venv/bin/activate  # macOS or Linux
.venv\Scripts\activate  # Windows
panel serve finmas/panel/app.py --show

If you want to start the app with a specific ticker like META:

panel serve finmas/panel/app.py --show --args --args META

We use Alpha Vantage to get fundamental data (income statements).
You can create your .env file by copying the .env.template file in the repo. Set the following API keys in the .env file in the repo folder:

Virtual environment

To install the virtual environment, we use the extremely fast uv project manager. Install uv using the standalone installer is recommended. To create or sync a virtual environment the following command can be used in the project folder:

uv sync

To exclude the development dependencies (like pre-commit) append the --no-dev flag to the command:

uv sync --no-dev

To add or remove packages, simply use uv add <package> or uv remove <package>.

Activate the virtual environment with the following command:

source .venv/bin/activate  # macOS or Linux
.venv\Scripts\activate  # Windows