Senor 2.0 is an LLM-powered chatbot designed to help Indian citizens understand and navigate legal procedures. It ingests legal documents from various sources, semantically processes them, and responds with context-rich, updated legal guidance.
- Reads legal data from SQL databases, JSON files, and PDFs.
- Uses LangChain for semantic chunking of documents.
- Generates vector embeddings using Gemini's
embedding-001model. - Stores and retrieves relevant document chunks from Pinecone.
- Re-ranks retrieved chunks using Pinecone's
bge-reranker-v2-m3. - Runs LLM calls using Gemini-2.0-flash for answering user queries.
- Integrates an AI agent via Agno to fetch up-to-date responses using DuckDuckGo.
- Evaluate chatbot performance using Ragas.
- Provides RESTful API access using FastAPI.
- Ingests legal documents from SQL, JSON, and PDF sources.
- Modular pipeline for easy integration of new data sources.
- Semantic chunking for improved context and recall.
- Stores document embeddings for retrieval.
- Uses
bge-reranker-v2-m3to enhance relevance of search results.
- Exposes endpoints for query processing, data fetching, and user interactions.
- Adds real-time search capability using DuckDuckGo.
- Option to refine or replace RAG answers with updated information.
- Enables LLM response evaluation.
- Tracks performance metrics and answer quality.
- Python
- LangChain
- FastAPI
- Docker
- Pinecone
- Gemini
- Ragas
- Agno
Before you begin, ensure you have the following:
- Docker
- Python 3.10+
- Pinecone API Key
- Gemini API Key