Domain-Adapted Hybrid Mamba–Attention SLM for Legal Billing Review: A Cost-Effective Alternative to Frontier APIs
Venkata Sree Karthikeya Gattupalli
Abstract
Domain-specialized small language models can approach frontier-API quality at a fraction of the inference cost, but the evidence is mostly from single-field extraction. We test whether adapter-only specialization holds on a full operational pipeline, through outside-counsel legal-billing review. We train a rank-256 LoRA adapter on nvidia/Nemotron-Elastic-12B, a 12B hybrid Mamba–attention base, interleaving a multi-gigabyte legal-billing corpus 75/25 with Tulu-3-SFT, the first LoRA continued-pretraining recipe we know of for this hybrid family. On a 531-record held-out benchmark spanning nine operational task types, the adapter reaches 74.0% decision-match, statistically level with the mid-tier zero-shot frontier (Gemini 3.1 Pro 77.9%, Claude Sonnet 4.6 77.5%; overlapping 95% CIs) and 8.4 points behind GPT-5.5 (82.4%), at \$0.50 per 1,000 bills against \$6.75–\$22.50 for the panel. On the schema-specific audit_state.event field every frontier model scores 0% even with three in-context exemplars, evidence that the vocabulary advantage is a property of fine-tuning, not a zero-shot artifact. We also measure a specialization cost: structured-output discipline regresses sharply (15% of format probes emit valid JSON, all code-correct when they do), even as the model retains moderate domain knowledge (46%). We release the recipe, the evaluation harness, the held-out set, and per-record predictions; the trained adapter weights and corpus are available on request for non-commercial use.
Chat is not available.
Successful Page Load