Get a detailed report for a specific stock from a specific exchange, by leveraging the power of LLMs and langgraph.
- 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
In order to run this repo, first clone it using the following command:
git clone https://github.com/Jimlibo/AI-Financial-Analyst.gitAfter you have cloned the repository, navigate to the repository and install necessary python packages:
cd AI-Financial-Analyst
pip install -r app/requirements.txtAfter 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_dataTo get a detailed description of each possible CLI parameter, you can use the --help option:
python app/agentic/finance_graph.py --helpDistributed under the Apache License. See LICENSE for more information.