FinGuru is a news research tool that processes and analyzes news articles from given URLs and PDF. It leverages LangChain, Google embeddings, and Streamlit to provide insights and answers based on the content of the articles.
- Fetch and parse news articles from URLs Or parse data from given pdf
- Split articles into manageable chunks
- Create embeddings for the text using GoogleEmbedding Model
- Store embeddings in a FAISS index for efficient retrieval
- Query the processed data to get answers and sources
- Python 3.7+
- Streamlit
- LangChain
- Google API Key
- GOOGLE_CSE_ID
google gemini-pro
- Issue 1 : Copy pasting article in ChatGPt is tedious
- Issue 2 : We need an aggregate knowledge base
Semantic search
Wikipedia
Google Search
Google Finance
duckduckGo search
git clone https://github.com/mihirh19/news_research_tool_Equity-Research-Analysis-.git
cd news_research_tool_Equity-Research-Analysis-
python -m venv venv
source venv/bin/activate # On Windows use `venv\Scripts\activate`
pip install -r requirements.txt
-
First, you need to set up the proper API keys and environment variables. To set it up, create the GOOGLE_API_KEY in the Google Cloud credential console (https://console.cloud.google.com/apis/credentials) and a GOOGLE_CSE_ID using the Programmable Search Engine (https://programmablesearchengine.google.com/controlpanel/create). Next, it is good to follow the instructions found here.
-
create api key on https://serpapi.com/
GOOGLE_API_KEY = "your-google-api-key"
GOOGLE_CSE_ID = "your-cse-id"
SERP_API_KEY ="your-"
streamlit run app.py
- Open the Streamlit application in your browser.
- Select options From dropdown Menu in the sidebar
- For URL :
- Enter the number of URLs you want to process in the sidebar.
- Provide the URLs for the news articles.
- Click on "Process URLs" to fetch and analyze the articles.
- For pdf
- Upload a PDF.
- Click on "process Pdf" to analyze the PDF.
- Enter a query in the text input box and click "Submit" to get answers based on the processed data.
- enter 3 as number of urls
- provide following urls:
- https://www.moneycontrol.com/news/business/tata-motors-to-use-new-1-billion-plant-to-make-jaguar-land-rover-cars-report-12666941.html
- https://www.moneycontrol.com/news/business/stocks/tata-motors-stock-jumps-x-after-robust-jlr-sales-brokerages-bullish-12603201.html
- https://www.moneycontrol.com/news/business/stocks/buy-tata-motors-target-of-rs-1188-sharekhan-12411611.html
- Click "Process URLs" to start processing.
- Enter a query like
what is the target price of tata motors ?
and clickSubmit
to get the answer.
-
AnnualReport202223.pdf Upload the Given PDF
-
Click "Process PDF" to start processing.
-
Enter a query like
what is the yoy change of revenue of tata motors ?
and clickSubmit
to get answer.
π€ Mihir Hadavani
- Twitter: @mihirh21
- Github: @mihirh19
- LinkedIn: @mihir-hadavani-996263232
Give a βοΈ if this project helped you!