All case studies

BullBearPK LangGraph and LangChain workflow
2025
BullBearPK - AI Investment Advisory Platform
AI-powered investment advisory platform for the Pakistan Stock Exchange, pairing real-time price and news ingestion with a LangGraph agent pipeline that explains its reasoning rather than emitting a bare signal.

Stack
- LangGraph
- LangChain
- Flask
- React
- Python
- REST API
- NLP
- Google Colab
Problem
Retail investors in Pakistan lack accessible, AI-driven tools to interpret market sentiment and news for informed decisions on PSX.
Architecture
React SPA -> Flask REST API -> LangGraph/LangChain pipelines -> external news and price APIs, with Colab used for model experimentation.
Workflow

What it does
- Stateful LangGraph pipeline that gathers prices and news, forms a view, and explains the reasoning behind it
- Market sentiment analysis over live Pakistani financial news
- Flask REST API serving a React single-page frontend
- Caching and batched inference to keep latency usable against live data
Challenges & learnings
- Orchestrating LangGraph workflows over real-time data taught me to design agent pipelines that carry state explicitly rather than implicitly.
- Balancing latency against model quality for live sentiment, solved with caching and batched inference.