Skip to content

Jimlibo/AI-Financial-Analyst

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AI-Financial-Analyst

Python YFinance Serpapi LangChain LangGraph

General

Get a detailed report for a specific stock from a specific exchange, by leveraging the power of LLMs and langgraph.

Future Steps

  • add support for different LLM servings
    • add support for Ollama
    • add support for llama.cpp
  • add UI
    • add home page where stock and exchange are specified
    • add visualization pages with graphs regarding fetched data

Setup

In order to run this repo, first clone it using the following command:

git clone https://github.com/Jimlibo/AI-Financial-Analyst.git

After you have cloned the repository, navigate to the repository and install necessary python packages:

cd AI-Financial-Analyst
pip install -r app/requirements.txt

Run from the CLI

After installing all necessary packages, you can get a detailed financial report for your desired stock, by running the command:

python app/agentic/finance_graph.py --serving-type <the LLM service used> --stock <your stock> --exchange <exchange market of the stock>

In the previous command, you can specify four possible CLI parameters:

  • --serving-type: the service that runs the LLMs (it can be one of 'ollama', 'hugging-face' or 'llama-cpp')
  • --stock: the stock ticker (i.e. AAPL, GOOGL, JPM, etc.)
  • --exchange: the market where the stock is exchanged (i.e. NYSE, NASDAQ, etc.)
  • [--model-name]: an optional parameter, specifying the LLM that will be used
  • [--model-path]: an optional parameter, specifying the filepath of the llama.cpp binary that contains the LLM
  • [--url]: an optional parameter specifying the url of the Ollama service (default is http://localhost:11434)
  • [--config-file]: an optional parameter specifying a .json file containing necessary LLM parameters (url, model_name, model_path)
  • [--dest-dir]: an optional parameter, specifying the directory where fetched data will be stored

For example, to get a financial report on Apple's stock, using the default hugging face models you have to run the following:

python app/agentic/finance_graph.py --serving-type "hugging-face" --stock AAPL --exchange NASDAQ --dest-dir ~/apple_stock_data

To get a detailed description of each possible CLI parameter, you can use the --help option:

python app/agentic/finance_graph.py --help

License

Distributed under the Apache License. See LICENSE for more information.

About

An app that utilizes an agentic workflow capable of producing a detailed report on a specified stock.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages