Sanad
Arabic Legal QA System
A production-grade Arabic legal AI assistant powered by hybrid retrieval-augmented generation (RAG). Delivers verifiable, citation-backed answers grounded in verified civil, criminal, and labor codes.
49.4RPS
Throughput
Locust load-tested
418ms
Latency (P95)
Fast hybrid pipeline
0.0%
Error Rate
14,820 requests
0.90
Faithfulness
Gate threshold 0.75
1,149
Civil Articles
Egyptian Civil Code
78%
Test Coverage
64 pytest suites
Key Capabilities
Engineered for high factual fidelity, legal verification, and sub-second latency
Exact Statutory Citations
Every generated answer links directly to verified law articles, statutory numbers, and official codes.
Hybrid Retrieval (Dense + BM25)
Combines semantic dense embeddings with sparse BM25 keyword matching for rigorous legal term fidelity.
Anti-Hallucination Guardrails
Strict confidence thresholds force the system to decline speculation if no authoritative statute is retrieved.
Legal Terminology Expansion
Specialized Arabic legal thesaurus that maps layman queries into precise juridical and statutory jargon.
Legal Corpora & Coverage
Curated, structured indices parsed and embedded with dense chunking strategies
Egyptian Civil Code
1149+ Articles
Penal & Criminal Procedure Code
500+ Articles
Labor & Employment Laws
Official Statutes
Court of Cassation Rulings
Indexed Precedents
Tech Stack
Python
Backend Engine
FastAPI
API & Streaming
Hybrid RAG
Dense + BM25 Search
Legal LLM
Legal Reasoning
Vector DB
Indexed Law Articles
Guardrails
Attribution & Accuracy
Disclaimer: This platform is developed as a research and decision-support assistant for legal professionals, and does not constitute formal legal counsel.
Explore Sanad Legal QA
Check out the code, chunking methodology, and hybrid RAG implementation for Arabic statutory retrieval.
View Repository on GitHub