NOMOS: A Retrieval-Augmented Generation Framework for Jurisdiction-Specific Legal Question Answering over Indian Statutory Corpora
Abstract
Access to legal information in India remains disproportionately limited due to the complexity of statutory language, jurisdictional specificity, and the absence of AI tools designed for the Indian legal context. General-purpose large language models (LLMs), while capable of broad question answering, frequently hallucinate legal statutes, fail to cite sources precisely, and lack coverage of India-specific legislation such as the Bharatiya Nyaya Sanhita (BNS) 2023. This paper presents Nomos, a Retrieval-Augmented Generation (RAG) framework tailored for Indian statutory law. Nomos integrates a curated legal corpus spanning ten major Indian Acts and a legal dictionary -amounting to approximately $\mathbf{2, 3 2 0, 0 0 0}$ characters of statutory text - with a locally deployed Llama 3.2 language model served via Ollama, a ChromaDB vector store, and sentence-level embeddings generated by MiniLM-L6-v2 (384 dimensions). The system delivers jurisdiction-specific, source-attributed answers grounded in retrieved statutory chunks, preserving user privacy through entirely local inference. Evaluation across four dimensions -citation accuracy, hallucination resistance, jurisdictional specificity, and privacy - combines a manually annotated pilot benchmark $(N=24$ queries) for Nomos with qualitative comparison against general-purpose LLMs and keyword-based legal search tools. The system architecture, corpus construction methodology, chunking strategy, and prompt design are described in detail, along with a comparative analysis against general LLMs and keyword-based legal search tools.