Skip to content
USE CASE: LEGAL & COMPLIANCE

Privilege-protected AI for law

Deploy AI tools for legal work while maintaining attorney-client privilege. Enforce disclaimers, protect confidential information, and create audit trails for regulatory requirements.

AN AUDIT TRAIL THAT CANNOT BE EDITED QUIETLYschematic
event 41PREV0b7e…HASHa91f…event 42PREVa91f…HASH4c02…event 43PREV4c02…HASHd180…event 44PREVd180…HASH77ab…this row alteredso 44’s stored prev no longer matchesevery link after the change fails to verifythe log does not prevent the edit, it makes the edit impossible to hide
Each audit event hashes its own contents together with its predecessor's hash. Alter one row, or remove it, and every hash after it stops matching. That is tamper-evident, which is the claim a regulator can actually check, and a weaker one than tamper-proof.

Where a legal workflow is exposed

  1. 01

    Privilege Policies You Write

    An llm_guard policy can flag or block content that reads as privileged before it reaches an external model. You describe privilege in plain English; an LLM judges each request against it.

  2. 02

    Disclaimer Policies You Write

    An output policy can block a reply that reads as legal advice without the qualification you require. You define the rule; PromptGuard judges the answer against it rather than editing it.

  3. 03

    Confidential Document Protection

    Redact identifiers with a fixed shape, such as emails, phone numbers and national IDs, plus anything matching your own custom rules, such as your matter-number format.

  4. 04

    Client Name Blocklists

    An entity blocklist stops requests that name the clients or matters you list, so they never reach an external model.

  5. 05

    One Project per Practice Group

    Each project has its own policies, API keys and audit trail, so one group's rules and records stay separate from another's.

  6. 06

    Regulatory Audit Trail

    Every scan is recorded with its decision and threat type, and a masked preview unless zero retention is on.

Why PromptGuard for legal?

  • Policies you write for privilege and advice
  • Client and matter blocklists
  • One project per practice group
  • An audit trail of every scan
  • Redaction of identifiers and your own patterns

How it works for legal

  1. 01

    Integrate

    Deploy PromptGuard with your legal AI tools. Works with contract review, research assistants, and document automation.

  2. 02

    Configure

    Add custom rules for your matter numbers and client names, and policies for privilege and legal advice.

  3. 03

    Document

    Generate audit reports for ethics compliance. Demonstrate responsible AI use to regulators and clients.

Securing legal AI applications

python
from promptguard import GuardClient

guard = GuardClient()  # reads PROMPTGUARD_API_KEY

# Custom rules for your matter-number format and client names, and an
# llm_guard policy that flags privileged content, are set on the project.
# Give each practice group its own project and API key.
messages = [{"role": "user", "content": contract_text}]
decision = guard.scan(messages, direction="input")

if decision.blocked:
    raise PermissionError(f"Blocked: {decision.threat_type}")

# A redacted request comes back with the values replaced
messages = decision.redacted_messages or messages

Secure your legal AI

Deploy AI in legal practice while maintaining privilege and regulatory compliance.