Build and Evaluate A High-Precision Legal Expert LLM APP
This project aims to develop a high-precision legal expert system for contract Q&A using Retrieval-Augmented Generation (RAG). The system leverages advanced natural language processing (NLP) techniques to provide accurate and context-aware answers to questions about legal contracts and integrates a powerful language model with a custom retrieval mechanism to provide accurate and contextually relevant answers to contract-related queries.
- Q&A pipeline with RAG using Langchain
- Customizable retriever and generator components
- Evaluation framework using RAGAS metrics
- Optimization techniques for improved performance
├── data
│ ├── contracts
│ └── Q&A
├── Dockerfile
├── evaluation
│ ├── data_processing.ipynb
│ └── ragas.ipynb
├── flask
│ ├── rag_app.py
│ ├── run.py
│ └── src
├── frontend
│ ├── index.html
│ ├── node_modules
│ ├── package.json
│ ├── package-lock.json
│ ├── public
│ ├── README.md
│ ├── src
│ └── vite.config.js
├── LICENSE
├── notebooks
│ ├── Autogen_agent.ipynb
│ ├── Langchain_exp.ipynb
│ └── simple_RAG_.ipynb
├── README.md
├── requirements.txt
└── scripts
├── evaluation.py
└── utils.py
- Clone the repository
git clone https://github.com/temesgen5335/Legal_Expert_Contract_Advisor_RAG.git
- Navigate to project directory
cd Legal_Expert_Contract_Advisor_RAG
- Create a virtual environment
python -m venv venv
- Activate the environment
source venv/bin/activate # On Windows, use venv\Scripts\activate
- Install the required dependencies:
pip install -r requirements.txt
This project is licensed under the Apache License - see the LICENSE file for details.