---
title: "Private Legal AI — Whitepaper"
description: "Why privilege makes cloud AI hard for law firms, and how an on-device agent does contract review, case-law research and drafting without sending data."
url: "https://royalsoftworks.com/resources/legal-ai-on-device/"
source: "https://royalsoftworks.com"
format: "markdown"
note: "Markdown rendering of the HTML page at `url`. Same content, same canonical URL."
---

[All resources](https://royalsoftworks.com/resources/)

# Private Legal AI

## An On-Device Agent for Contract Review, Case-Law Research, and Drafting

**A Royal Softworks whitepaper · AssistantGeneral**

---

## Abstract

Legal work is the textbook case for AI that cannot use the cloud. Attorney-client privilege and confidentiality obligations make transmitting matter documents to a third-party AI vendor a professional-responsibility problem — which is why so many firms have banned cloud AI outright. Yet legal work is also document-dense, repetitive at the margins, and exactly the kind of task a capable agent accelerates. AssistantGeneral resolves the tension by running contract analysis, case-law research, and drafting on the lawyer's own machine, with answers tied to source text and a built-in professional disclaimer.

---

## 1\. The problem with cloud legal AI

A cloud legal assistant must receive the documents to help with them. For privileged and confidential material, that transmission is itself the risk — regardless of the vendor's no-training promises or regional hosting. Firms are left choosing between a capability they can't ethically use and going without. Meanwhile, generic chat tools that _can_ be used informally produce ungrounded summaries and, notoriously, fabricated citations — which in legal practice is not an inconvenience but a sanctionable event.

## 2\. The AssistantGeneral approach

AssistantGeneral runs the legal stack locally:

- The **model**, the **document index**, the **embeddings**, and the **generated drafts** all stay on the machine. A cloud model is attached only if the firm explicitly permits it through policy.
- A dedicated **Lawyer agent** carries a non-negotiable disclaimer ("general information, not legal advice — consult a licensed attorney") and a tool set scoped to legal work.
- The **groundedness gate** checks the draft's claims against retrieved evidence and re-grounds unsupported ones before the answer is shown — directly addressing the fabricated-citation failure mode.

## 3\. Capabilities, mapped to real work

AssistantGeneral ships a library of legal workflows that run against the firm's own embedded documents:

**Contract analysis**

- **Clause extraction** — dates, obligations, termination rights, liability caps, and payment terms pulled into a structured table.
- **Red-flag review** — one-sided, unusual, or missing clauses surfaced with plain-English explanations.
- **NDA comparison** — two confidentiality agreements diffed on scope, term, obligations, and remedies.
- **Contract expiry tracking** — a timeline of renewal windows and key dates across the contract set.

**Research**

- **Case-law search** — find on-point opinions, cited by case name and citation, with a preference for controlling jurisdiction and recent decisions.
- **Statutory interpretation** — relevant provisions retrieved from the firm's statute library and explained in plain English with practical guidance.
- **Jurisdiction comparison** — how a topic or obligation is treated across jurisdictions.

**Drafting**

- **Contract template population** — employment agreements, SLAs, NDAs, consultancy and licensing agreements drafted from a plain-English deal description.
- **Letter before action** — formal LBAs for debt recovery, breach, and property disputes.
- **Clause library lookup** — retrieve the firm's pre-approved standard clauses.

**Compliance**

- **Privacy policy auditor** — GDPR/CCPA gap analysis with remediation steps.
- **Data Processing Agreement checker** — verification against GDPR Article 28.

**Operations**

- **Matter intake** and a **legal FAQ bot** over firm materials.

## 4\. How it stays grounded

Every analysis runs over the firm's **own materials**, ingested into a private knowledge base. The hybrid retriever (vector + keyword search, fused and reranked) returns the exact passages the answer relies on, with citation highlight spans — so a clause finding points to the clause. The groundedness gate then verifies the draft against that evidence and re-retrieves for any claim that isn't supported. The Lawyer agent is instructed to quote the source text it relies on and never to assert a definitive legal conclusion.

## 5\. The interface matches the work

A **Legal UI preset** presents a document-centric layout with voice and external connectors hidden — the interface a legal team actually wants, not a general-purpose chat window.

## 6\. For the firm: governance

When a firm standardizes on AssistantGeneral, the enterprise governance plane (running on the firm's _own_ server) provides a shared, access-controlled clause and precedent knowledge base, single sign-on, an audit trail, and a policy that can pin every seat to the on-device model. No client material ever crosses a vendor boundary.

## 7\. Scope and responsibility

AssistantGeneral is a drafting and analysis aid for legal professionals, not a substitute for legal judgment. Its output is general information requiring attorney review; the product states this in every relevant interaction. The value is leverage on the mechanical 80% — extraction, comparison, first drafts, research starting points — under the lawyer's supervision, on data that never leaves the firm.

---

_Evaluate it offline, on a real (redacted) matter, on your own laptop. Contact Royal Softworks._

## Evaluate AssistantGeneral

See the product this paper describes — a private, local-first AI agent with an enterprise control plane that runs on your own infrastructure.

[Explore AssistantGeneral](https://royalsoftworks.com/products/assistant-general/) [Talk to us](https://royalsoftworks.com/contact/)
