A production-ready AI assistant using LangGraph, AWS Bedrock Nova Lite, and LangSmith for intelligent book queries with full observability.
Simple routing with LangGraph workflows - good for learning basics
Custom supervisor pattern with agent memory - good for understanding multi-agent concepts
Full LangGraph StateGraph implementation with LangSmith integration:
- Proper State Management: TypedDict state across all nodes
- Supervisor Node: Intelligent routing with LLM
- Specialist Agent Nodes: BookDetails, Reviews, Recommendation, General
- LangSmith Tracing: Full observability and debugging
- Visual Workflow: See execution graph
- Production Ready: Scalable and maintainable
- 📚 Query book details and specifications
- ⭐ Get book reviews and ratings
- 🎯 Personalized book recommendations
- 💡 Answer general questions about books
- 🤖 Multi-agent coordination for complex queries
- 🔍 LangSmith tracing for debugging
- 📊 Real-time analytics dashboard
- 🗺️ Visual workflow graphs
pip install -r requirements.txtcp .env.example .env
# Edit .env with your AWS credentials
# Optionally add LangSmith API key for tracingpython3 scraper.py# Recommended: LangGraph with LangSmith
python3 app_langgraph.py
# Or try other implementations:
python3 app.py # Simple single-agent
python3 app_multiagent.py # Custom multi-agentSee QUICKSTART.md for detailed instructions and LANGSMITH_SETUP.md for tracing setup.
The scraper uses:
- Google Books API for book details (title, author, pages, description, ratings)
- Mock reviews generated based on ratings (real review APIs require authentication)
Run python scraper.py to collect data for 10 categories with 10 books each.
- "What's the page count of Harry Potter?"
- "What do readers think about 1984?"
- "Recommend a good science fiction book"
- "Compare reviews of two fantasy books" (multi-agent)
- "Who wrote The Great Gatsby?"
- 📖
QUICKSTART.md- Step-by-step setup guide - 🏗️
ARCHITECTURE.md- Multi-agent design details - 🔍
LANGSMITH_SETUP.md- LangSmith tracing configuration - 📊
IMPLEMENTATIONS.md- Compare all three implementations - 🗂️
PROJECT_STRUCTURE.md- File organization
Enable tracing to debug and monitor your agents:
- Sign up at https://smith.langchain.com
- Get your API key
- Add to
.env:
LANGCHAIN_TRACING_V2=true
LANGCHAIN_API_KEY=your_key_here
LANGCHAIN_PROJECT=book-assistant-multiagentSee LANGSMITH_SETUP.md for detailed instructions.
- LangGraph: Agent workflow orchestration
- LangSmith: Tracing and monitoring
- AWS Bedrock Nova Lite: LLM inference
- Gradio: Web interface
- Google Books API: Book data source