AI Analysis Pipeline
Clausemaster uses a three-step AI pipeline powered by the Vercel AI SDK to analyze contracts. Choose between our free community model or bring your own API key for premium providers. Each step builds on the previous one to provide comprehensive results.
Pipeline Overview
Classification
Detect contract type & metadata
Extraction
Break down into clauses
Issue Flagging
Flag risks & concerns
All three steps run sequentially using generateObject from the Vercel AI SDK, producing structured JSON output validated against typed schemas.
Step 1: Classification
The first step identifies what kind of contract this is and extracts key metadata.
Detected Fields
Contract Type
e.g., NDA, Employment Agreement, SaaS Terms, Lease
Jurisdiction
Governing law and jurisdiction identified from the text
Parties
Names and roles of all parties to the agreement
Effective Date
Start date or execution date if mentioned
Step 2: Clause Extraction
The contract is broken down into individual clauses, each analyzed for content, category, and bias.
Per-Clause Analysis
Clause Type
Specific type (e.g., Termination, Indemnification, Non-Compete)
Category
Broad category grouping related clause types
Summary
One-line plain-language summary of the clause
Full Text
The exact text extracted from the contract
Bias Assessment
Neutral, Favors Party A, or Favors Party B
Skill Match
Confidence score if matched to a known legal skill
Bias Assessment
Step 3: Issue Flagging
The final step scans for potential problems, missing clauses, unusual terms, and jurisdiction-specific concerns.
Issue Types
Missing Clause
A standard clause expected for this contract type is absent.
Unusual Term
A clause contains non-standard or potentially problematic language.
Jurisdiction Risk
Terms that may conflict with the identified governing jurisdiction.
Ambiguous Language
Vague wording that could lead to differing interpretations.
Compliance Gap
Potential regulatory or compliance issue detected.
Imbalanced Term
A clause significantly favors one party over the other.
Severity Levels
Supported Contract Types
The AI can analyze a wide range of contract types. Common examples include:
AI Providers
Clausemaster supports multiple AI providers. Choose the option that best fits your needs and budget.
Community (Free)
Start analyzing contracts immediately with no API key required. Powered by an open-weights model hosted by the platform.
- No API key or account needed
- Good for getting started and drafting skills
- All pipeline features available
Bring Your Own Key
Use your preferred AI provider for higher quality output or specific model requirements.
- Anthropic (Claude)
- OpenAI (GPT)
- Groq (Llama)
- Mistral
- Together AI (Llama)
How It Works
Your AI provider choice is stored per-account. You can switch providers at any time from Settings. All providers use the same analysis pipeline and produce the same structured output format — only the underlying model differs. API keys are encrypted at rest using AES-256-GCM.
LegalSkills Integration
The analysis pipeline references the LegalSkills knowledge base during clause extraction and issue flagging to improve accuracy.
How It Works
The LegalSkills repository contains structured legal knowledge (clause patterns, boilerplate language, and best practices). During Steps 2 and 3, this knowledge is loaded as read-only reference context for the AI, improving clause identification accuracy and enabling skill match confidence scores.