← 研踪 PaperTrailarXiv:2612.01130 · v2
Benchmarking Small Language Models for Legal Retrieval-Augmented Generation: Structural Validity, Citation Compliance, and Inference Efficiency
首次提交 2026-12-01 14:57
版本更新 2026-12-02 21:54
雷达观测 2026-12-03 12:51
摘要
Retrieval-augmented generation (RAG) can condition language-model responses on external evidence, but its usefulness in legal settings depends on more than fluent text generation. This study benchmarks five small language models (SLMs) in a local legal RAG pipeline using BM25 retrieval over the FIRE 2019 Artificial Intelligence for Legal Assistance (AILA) corpus and inference through llamacpp. For each query, the system retrieves prior case documents, constructs a constrained prompt, and evaluates the generated response for structural usability, citation behaviour, and inference efficiency. Citation-grounded response rate is defined as the proportion of queries for which a structurally usable response contains at least one citation to a retrieved document; citation precision separately measures the proportion of extracted citations that refer to retrieved documents. Neither measure verifies whether a cited case substantively supports a legal claim. Qwen2.5-1.5B achieved a structural usability rate of 1.00 but a citation-grounded response rate of 0.16. Llama-3.2-1B achieved a structural usability rate of 0.92 and the highest mean end-to-end throughput (6.21 tokens/s), while Phi-3 Mini Q4 had the highest citation-grounded response rate (0.38) but the greatest mean time to first token (69.11 s). These results show that structural usability, citation behaviour, and inference efficiency are distinct properties of local SLM-based legal RAG. The study provides a controlled comparison under a shared retrieval and generation protocol and highlights the need to evaluate citation behaviour separately from fluency and latency.
作者备注:13 pages, 4 tables, 2 figures
观测到的版本
相邻记录可能跳过中间版本;首次发现 v2 及以上也会标为版本更新。
v2 · 2026-12-02 21:54 · 最新观测版本
Benchmarking Small Language Models for Legal Retrieval-Augmented Generation: Structural Validity, Citation Compliance, and Inference Efficiency
Retrieval-augmented generation (RAG) can condition language-model responses on external evidence, but its usefulness in legal settings depends on more than fluent text generation. This study benchmarks five small language models (SLMs) in a local legal RAG pipeline using BM25 retrieval over the FIRE 2019 Artificial Intelligence for Legal Assistance (AILA) corpus and inference through llamacpp. For each query, the system retrieves prior case documents, constructs a constrained prompt, and evaluates the generated response for structural usability, citation behaviour, and inference efficiency. Citation-grounded response rate is defined as the proportion of queries for which a structurally usable response contains at least one citation to a retrieved document; citation precision separately measures the proportion of extracted citations that refer to retrieved documents. Neither measure verifies whether a cited case substantively supports a legal claim. Qwen2.5-1.5B achieved a structural usability rate of 1.00 but a citation-grounded response rate of 0.16. Llama-3.2-1B achieved a structural usability rate of 0.92 and the highest mean end-to-end throughput (6.21 tokens/s), while Phi-3 Mini Q4 had the highest citation-grounded response rate (0.38) but the greatest mean time to first token (69.11 s). These results show that structural usability, citation behaviour, and inference efficiency are distinct properties of local SLM-based legal RAG. The study provides a controlled comparison under a shared retrieval and generation protocol and highlights the need to evaluate citation behaviour separately from fluency and latency.
查看此版本解读 →查看此版本原文 ↗v1 · 2026-12-01 14:57
Benchmarking Small Language Models for Legal Retrieval-Augmented Generation: Structural Validity, Citation Compliance, and Inference Efficiency
Retrieval-augmented generation (RAG) can condition language-model responses on external evidence, but its usefulness in legal settings depends on more than fluent text generation. This study benchmarks five small language models (SLMs) in a local legal RAG pipeline using BM25 retrieval over the FIRE 2019 Artificial Intelligence for Legal Assistance (AILA) corpus and inference through llama.cpp. For each query, the system retrieves prior case documents, constructs a constrained prompt, and evaluates the generated response for structural usability, citation behaviour, and inference efficiency. Citation-grounded response rate is defined as the proportion of queries for which a structurally usable response contains at least one citation to a retrieved document; citation precision separately measures the proportion of extracted citations that refer to retrieved documents. Neither measure verifies whether a cited case substantively supports a legal claim. Qwen2.5-1.5B achieved a structural usability rate of 1.00 but a citation-grounded response rate of 0.16. Llama-3.2-1B achieved a structural usability rate of 0.92 and the highest mean end-to-end throughput (6.21 tokens/s), while Phi-3 Mini Q4 had the highest citation-grounded response rate (0.38) but the greatest mean time to first token (69.11 s). These results show that structural usability, citation behaviour, and inference efficiency are distinct properties of local SLM-based legal RAG. The study provides a controlled comparison under a shared retrieval and generation protocol and highlights the need to evaluate citation behaviour separately from fluency and latency.
查看此版本解读 →查看此版本原文 ↗