An AI-Powered Financial Document Analysis Tool
This is a powerful tool/approach designed to analyze and extract insights from company annual reports
- Python 3.8 or higher
- Required Python libraries (specified in
requirements.txt
) - Annual report files in PDF format
git clone https://github.com/shoryasethia/FinChat.git
cd FinChat
pip install -r requirements.txt
Place the Annual Report (.pdf)
of a company in the data/pdfs/
directory.
python app.py
In .env
, add your GOOGLE_API_KEY
, if using gemini.py
python gemini.py
- Output: Results will be saved in the
output/
directory.
This launches a Streamlit application for a user-friendly Q&A chatbot experience.
streamlit run main.py
NOTE: To switch off debug mode, set level = "info"
in .streamlit/config.toml
Run the following command for graph-based terminal responses. Ensure you edit the query and select the appropriate mode of search (local
, naive
, global
, hybrid
) as per your requirements.
python graph-rag.py
FinChat/
|-- .gitignore
|-- .streamlit
|-- config.toml
|-- secrets.toml
|-- app.py
|-- context_reduction.py
|-- csv-combine.ipynb
|-- csv2txt.py
|-- data
|-- pdfs
|-- 3M_2018_10K.pdf # Replace this with your desired file
|-- gemini-mask.py
|-- gemini.py
|-- graph-rag.py
|-- images-response.py
|-- LICENSE
|-- lightrag
|-- base.py
|-- lightrag.py
|-- llm.py
|-- operate.py
|-- prompt.py
|-- storage.py
|-- utils.py
|-- __init__.py
|-- __pycache__
|-- main.py
|-- model_loader.py
|-- output
|-- extracted_tables
|-- 3M_2018_10K
|-- data.csv
|-- table_page_8_box_1.png
|-- table_page_13_box_2.png
|-- ...
|-- images
|-- knowledge_graph
|-- graph_chunk_entity_relation.graphml
|-- kv_store_full_docs.json
|-- kv_store_llm_response_cache.json
|-- kv_store_text_chunks.json
|-- lightrag.log
|-- vdb_chunks.json
|-- vdb_entities.json
|-- vdb_relationships.json
|-- parquet
|-- extracted_texts_and_imgs.parquet
|-- extracted_texts_and_imgs_with_responses.csv
|-- txts
|-- final_output.txt
|-- pdf_extractor.py
|-- README.md
|-- requirements.txt
|-- tables-response.py
|-- utils_logging.py
|-- __pycache__
Check out Project Report for details.
Check out streamlit demo
These code files are to create an .html page of past 10 years annual reports for faster analysis and data excess. This html page shows the annual report and have download buttons to download tables in excel format.
Page Url : http://103.42.51.135/drereddy.html
This project is licensed under the MIT License. See the LICENSE file for details.
For any issues or questions, please open an issue in the GitHub repository.