Legal operations / MCP server

Inspect contract text with transparent, local pattern matching.

Legal Doc Analyzer exposes five MCP tools for extracting contract structure, flagging common risk patterns, comparing revisions, producing plain-English summaries, and checking text for GDPR, CCPA, SOC 2, and HIPAA clause indicators.

5 MCP tools Local text analysis 3 calls total free Node.js 18+

Actual function

What the shipped server does

The server accepts document text through MCP and returns Markdown reports. Its analysis runs locally with regular expressions and curated clause and compliance patterns; it does not call an external API or an LLM.

Input

Plain text supplied in tool arguments. The contract analyzer optionally accepts one of six document types: nda, employment, saas, freelance, lease, or general.

Processing

Pattern matching extracts dates, parties, obligations, terms, and clause indicators. Heuristics assign risk severity, comparison significance, and compliance statuses.

Output

Structured Markdown containing detected items, excerpts, counts, scores, and recommendations. Output quality depends on wording that the shipped patterns recognize.

Tool surface

Five real MCP tools

Basic + Pro

analyze_contract

Identifies document type, parties, dates, obligations, liability language, termination conditions, governing law, and jurisdiction.

Basic + Pro

find_risks

Flags recognized risky or one-sided language and missing safeguards, then returns severity ratings, excerpts, recommendations, and a heuristic 0–100 score.

Basic + Pro

generate_summary

Produces a pattern-derived plain-English summary, key terms, action items, and an executive brief.

Pro

compare_versions

Compares old and new text by section, classifies additions, removals, and modifications, and flags potentially material or risk-increasing changes.

Pro

check_compliance

Checks for text indicators associated with GDPR, CCPA, SOC 2, and HIPAA requirements and returns pass, partial, or fail statuses with suggested language.

Three concrete workflows

Representative MCP calls

Each example uses an exact shipped tool name and only arguments accepted by that tool. Replace the short sample text with the document text you are authorized to analyze.

01 / Contract map

Extract the structure of an employment agreement

Tool: analyze_contract

{
  "document_text": "This Employment Agreement is entered into as of January 1, 2025, between Acme Corp (\"Company\") and Jane Doe (\"Employee\"). Employee shall submit monthly reports. Either party may terminate with 30 days written notice.",
  "document_type": "employment"
}

The report attempts to identify parties, dates, obligations, liability and termination language, and governing-law or jurisdiction text.

02 / Risk screen

Surface recognized risk language and missing safeguards

Tool: find_risks

{
  "document_text": "Contractor shall indemnify and hold harmless Company from any and all claims without limitation. This agreement automatically renews for successive one-year terms unless notice is provided."
}

The report may flag matched clauses, quote excerpts, list absent standard protections, and calculate a weighted heuristic risk score.

03 / Revision check

Compare liability language between two drafts

Tool: compare_versions

{
  "old_version": "8. LIABILITY\nProvider's aggregate liability will not exceed $25,000.",
  "new_version": "8. LIABILITY\nProvider will have unlimited liability for all claims.",
  "labels": {
    "old": "Customer draft",
    "new": "Vendor revision"
  }
}

The report groups section-level changes and assigns heuristic significance and risk impact. It is not a guaranteed complete legal redline.

Setup

Run directly from npm

Open your client's config file

  • Claude Desktop ~/Library/Application Support/Claude/claude_desktop_config.json

    Windows: %APPDATA%\Claude\claude_desktop_config.json. In the app: Settings → Developer → Edit Config.

  • Cursor ~/.cursor/mcp.json

    Or .cursor/mcp.json inside a single project.

  • Windsurf ~/.codeium/windsurf/mcp_config.json

    Cascade panel → MCP icon → edit the raw config.

Paste this entry

All three clients accept the same object. If the file already has an mcpServers block, add just the "legal-doc-analyzer" entry inside it.

{
  "mcpServers": {
    "legal-doc-analyzer": {
      "command": "npx",
      "args": ["-y", "legal-doc-analyzer"]
    }
  }
}

No env block is needed to start: the first 3 tool calls total across this server's tools run without a license.

Using Claude Code instead? One command, no file

$ claude mcp add --transport stdio legal-doc-analyzer -- npx -y legal-doc-analyzer

Check it registered with claude mcp list. Add a key later with --env LICENSE_KEY=your-key placed before --transport.

Restart the client, then confirm it loaded

  • Claude Desktop: quit and reopen the app, then look for Legal Doc Analyzer in the tools/plugin menu.
  • Cursor: Settings → Customize → MCP; the server should list its tools.
  • Windsurf: reload Cascade; the server appears under the MCP panel.
  • Claude Code: run claude mcp list and look for ✔ Connected.

Running npx -y legal-doc-analyzer in a terminal looks frozen — that is correct. It is a stdio server: it waits silently for an MCP client on stdin and never returns a prompt. Press Ctrl+C to exit. Use the config above rather than the bare command; your client starts the process for you.

Add your license key when you buy

A key arrives on screen right after checkout. Add it as an environment variable in the same entry:

{
  "mcpServers": {
    "legal-doc-analyzer": {
      "command": "npx",
      "args": ["-y", "legal-doc-analyzer"],
      "env": {
        "LICENSE_KEY": "paste-your-key-here"
      }
    }
  }
}

Keys are verified offline against a public key compiled into the package — no account, no network check, no usage reporting. Lost the key? Recover it here. More detail on the FAQ.

Access

The free-call limit is shared, not per tool

Free trial

3 calls total

With no license key, the package allows three calls total across all five tools—not three calls for each tool, and not three per day. It is a one-off trial; no account or credit card is required.

By default, usage is stored in ~/.aivp-mcp/usage.json when the filesystem is available, with an in-process fallback if it is not, so restarting does not reset it.

Basic · $20/month

Three licensed tools

Unlimited, licensed access to analyze_contract, find_risks, and generate_summary. The Pro-only tools compare_versions and check_compliance are not included in Basic.

Pro · $35/month

All five licensed tools

Adds unlimited use of the Pro-only tools compare_versions and check_compliance to the three Basic tools.

A purchased key removes the trial counter and unlocks unlimited, ungated calls to the tools in your plan. It is verified fully offline against a public key compiled into the package—no account, no network check, no usage reporting—and stays valid for 365 days.

View Legal Doc Analyzer plans & pricing

Limitations

Use the output as a screening aid, never as a legal conclusion

No legal advice or attorney review

The server provides automated information only. A qualified attorney should review legal rights, obligations, enforceability, and decisions.

No guaranteed detection

Pattern matching can miss unusual drafting, context, cross-references, definitions, exhibits, or jurisdiction-specific meaning, and it can produce false positives.

Scores are heuristics

Risk and compliance scores are calculations over matched text indicators. They are not probabilities, certifications, audits, or proof that a document complies with law.

Text in, text out

The MCP schemas accept document text, not PDF, image, OCR, file-path, or URL inputs. Extract and verify the text before calling a tool.

Start with three free calls

Connect Legal Doc Analyzer, then license it when you are ready.

Add the server to your MCP client with no key and spend the shared three-call trial on a document you are authorized to analyze. Buy Basic or Pro when you want unlimited, ungated calls to the tools in your plan.

Reminder: this is automated pattern analysis, not legal advice. Have a qualified attorney review anything that carries legal weight.