FinanceBot is an AI-powered financial assistant that provides stock analysis using real-time price data, financial metrics, and sentiment from news articles. It uses Groq's llama3-70b model for reasoning and LangChain-style tool invocation to perform structured financial evaluation. Built for investors of all levels β beginner to seasoned β it gives data-backed insights and final investment verdicts.
The workflow of FinanceBot follows a modular toolchain:
- Ticker Resolver: Extracts and corrects stock tickers from user queries (e.g., maps "ICICI" β
ICICIBANK.NS). - Price Fetcher: Pulls latest and 30-day average stock prices using
yfinance. - News Sentiment Analyzer: Scrapes and summarizes recent news to classify sentiment as π Positive, π Negative, or π Neutral.
- Financial Analyzer: Gathers Free Cash Flow, P/E Ratio, ROE, margins, and more.
- Sector Comparator (Optional): Evaluates stock performance vs. peers in the same sector.
- Report Generator: Combines all components into a structured, emoji-rich investment summary with a β Final Verdict.
- π Fetches stock price & trend analysis (e.g., 30-day average)
- π§Ύ Summarizes financial fundamentals (FCF, ROE, Margins, P/E, etc.)
- π° Classifies sentiment using news headlines + Groq-powered reasoning
- π Adds sector-level comparison if needed
- ποΈ Formats response with structured headings and emojis