Logo Lanfrica

monfortbrian/Law-RAG

Domaine:

natural language processing

Type de record:

software
Créateur:
mon
Hôte:
Citation-first legal assistant for Rwandan law, powered by Retrieval-Augmented Generation and authoritative legal texts. # Rwanda Law RAG RAG-powered legal assistant for Rwandan law. Ask legal questions in plain language and receive answers grounded in authoritative legal texts, with exact article citations from the Constitution, Penal Code, and Labor Law. **Live demo:** law-rag.streamlit.app ## What it does - Searches 568 legal articles across 3 Rwandan laws - Returns answers with specific article citations - Retrieves 6 relevant articles per query for multi-article legal reasoning - Detects non-legal questions and responds appropriately ## Why Law RAG General LLMs can answer legal questions, but without access to the relevant legal corpus, they may produce incomplete, outdated, or hallucinated responses. Legal work demands verifiable sources and precise citations. Law RAG solves this by: - Grounding every response in an explicit legal knowledge base. - Retrieving the relevant legal articles first, then generating answers strictly from those sources. - Ensuring accuracy, traceability, and legal reliability. ### Approach: Retrieval-Augmented Generation (RAG) 1. Retrieval → fetch relevant legal provisions from authoritative laws. 2. Augmentation → structure a prompt with the retrieved articles. 3. Generation → LLM produces the cited legal answer. Result: answers with article-level provenance. ## Features 🔹Searches 568 legal articles across 3 Rwandan laws. 🔹Returns answers with exact article citations. 🔹Retrieves multiple relevant provisions for multi-article reasoning. 🔹Detects non-legal questions and responds appropriately. ## Laws Covered (Rwanda v1.0) | Law Scope | ------------------------------------------- | ------------------------------------------ | | Constitution of Rwanda (2003, revised 2015) | Fundamental rights, governance, judiciary | | Penal Code (Law No. 68/2018) | Criminal offences and penalties | | Labor Law (Law No. 66/2018) | Employment relations and conditions …