> Contract review assistant analyzing agreements against playbooks. GREEN/YELLOW/RED severity. Use when reviewing vendor contracts, SaaS agreements, service agreements, or generating redline suggestions.
npx skills add https://github.com/borghei/Claude-Skills --skill contract-review
> ⚠️ EXPERIMENTAL — This skill is provided for educational and informational purposes only. It does NOT constitute legal advice. All responsibility for usage rests with the user. Consult qualified legal professionals before acting on any output.
Automated contract review tools that analyze agreements against organizational playbooks, classify clause risk with GREEN/YELLOW/RED severity, and generate prioritized redline suggestions with fallback positions.
Before reviewing the contract, confirm these inputs. If any is unknown or vague, ASK — do not assume:
Stop rule: ask only the 2-3 that most change the output. If the user says "just draft it," proceed and list your assumptions at the top of the review.
Analyzes contract text files for clause types, missing standard clauses, and risk indicators.
# Analyze a contract file
python scripts/contract_analyzer.py contract.txt
# JSON output for pipeline integration
python scripts/contract_analyzer.py agreement.md --json
# Save analysis to file
python scripts/contract_analyzer.py contract.txt --output analysis.json --json
What it detects:
Risk Classification:
| Level | Meaning | Action |
|-------|---------|--------|
| RED | Deal-breaker risk | Must negotiate before signing |
| YELLOW | Material concern | Should negotiate, may accept with mitigation |
| GREEN | Standard or favorable | Acceptable as-is |
Takes contract analysis JSON and generates formatted redline suggestions with priority tiers.
# Generate redlines from analysis
python scripts/contract_analyzer.py contract.txt --json --output analysis.json
python scripts/redline_generator.py analysis.json
# JSON output
python scripts/redline_generator.py analysis.json --json
# Save redlines to file
python scripts/redline_generator.py analysis.json --output redlines.md
Output includes:
Priority Tiers:
| Tier | Label | Description |
|------|-------|-------------|
| 1 | Must-Have | Deal-breakers; walk away if rejected |
| 2 | Should-Have | Strong preferences; push hard but negotiable |
| 3 | Nice-to-Have | Concession candidates; trade for Tier 1-2 wins |
references/clause_analysis_guide.md
Deep reference covering 8+ clause types:
references/negotiation_playbook.md
Negotiation priority framework with:
.txt or .md filecontract_analyzer.py with --json flagredline_generator.py on analysis outputcontract_analyzer.py in text mode for quick scan| Problem | Cause | Solution |
|---------|-------|----------|
| Error: File not found | Contract file path is incorrect or file does not exist | Verify the file path; use absolute paths if relative paths fail |
| No clauses detected | Contract uses unusual formatting or non-standard clause headers | Ensure contract is plain text; strip PDF artifacts before analysis |
| All clauses marked GREEN | Contract is genuinely favorable, or text extraction missed key sections | Manually verify critical clauses (liability, indemnification, IP) are present in the input file |
| Redline generator produces empty output | Analysis JSON has no YELLOW or RED findings | Confirm analysis JSON is valid; re-run analyzer if contract was updated |
| False positive on uncapped liability | Liability section references a cap elsewhere in the document | Review the full Limitation of Liability section; the tool scans for cap keywords within each clause boundary |
| Missing clause false positive | Clause exists but uses non-standard heading (e.g., "Damages Cap" instead of "Limitation of Liability") | The analyzer checks multiple heading variants; add custom aliases if your organization uses unique terminology |
Covers:
Does NOT cover:
ra-qm-team skills for regulatory compliance (GDPR, SOC 2, etc.)| Anti-Pattern | Why It Fails | Better Approach |
|-------------|-------------|-----------------|
| Signing contracts with only GREEN findings and no human review | Automated analysis cannot catch context-dependent risks, ambiguous language, or business-specific concerns | Always have qualified counsel review before execution, even on all-GREEN contracts |
| Treating all RED findings as equal | Some RED items are structural deal-breakers while others may be resolvable with a single word change | Use the redline generator to assess effort and fallback positions for each RED finding |
| Skipping the redline fallback positions | Entering negotiation with only preferred positions leaves no room for strategic concession | Always prepare Must-Have fallbacks and identify Nice-to-Have items to trade away |
| Running analysis on poorly extracted text | PDF-to-text conversion artifacts break clause detection patterns | Clean the text file before analysis: remove headers, footers, page numbers, and formatting artifacts |
Purpose: Analyzes contract text files for clause types, identifies missing standard clauses, and flags risk indicators with GREEN/YELLOW/RED severity classification.
Usage:
python scripts/contract_analyzer.py <contract_file> [--json] [--output FILE]
Flags:
| Flag | Short | Default | Description |
|------|-------|---------|-------------|
| contract_file | *(positional)* | | Path to contract text file (.txt or .md) |
| --json | | off | Output in JSON format |
| --output | -o | *(stdout)* | Write output to file |
Example Output (JSON):
{
"file": "vendor_agreement.txt",
"clauses_found": [
{
"type": "limitation_of_liability",
"severity": "RED",
"text_snippet": "...liability shall not be limited...",
"risk_flags": ["uncapped_liability"],
"notes": "No liability cap found; uncapped exposure"
}
],
"missing_clauses": ["force_majeure", "data_protection"],
"risk_summary": {"RED": 2, "YELLOW": 3, "GREEN": 5},
"overall_risk": "RED"
}
Purpose: Takes contract analysis JSON and generates formatted redline suggestions with priority tiers, rationale, and fallback positions.
Usage:
python scripts/redline_generator.py <analysis_json> [--json] [--output FILE]
Flags:
| Flag | Short | Default | Description |
|------|-------|---------|-------------|
| analysis_json | *(positional)* | | Path to contract analysis JSON file |
| --json | | off | Output in JSON format |
| --output | -o | *(stdout)* | Write output to file |
Example Output:
REDLINE SUGGESTIONS
===================
[MUST-HAVE] Limitation of Liability — Uncapped Liability
Severity: RED
Preferred: "Aggregate liability shall not exceed 12 months of fees paid."
Rationale: Uncapped liability creates unlimited financial exposure.
Fallback: "Aggregate liability shall not exceed 24 months of fees paid."
[SHOULD-HAVE] Indemnification — Unilateral Indemnification
Severity: YELLOW
Preferred: "Each party shall indemnify the other for breaches of this Agreement."
Rationale: Mutual indemnification balances risk between parties.
Fallback: "Indemnification obligations shall be subject to the liability cap."
Integration with protocols.io API for managing scientific protocols. This skill should be used when working with protocols.io to search, create, update, or publish protocols; manage protocol steps and materials; handle discussions and comments; organize workspaces; upload and manage files; or integrate protocols.io functionality into workflows. Applicable for protocol discovery, collaborative protocol development, experiment tracking, lab protocol management, and scientific documentation.
Analyzes job descriptions and generates tailored resumes that highlight relevant experience, skills, and achievements to maximize interview chances
Generate Excalidraw diagrams from natural language descriptions. Use when asked to "create a diagram", "make a flowchart", "visualize a process", "draw a system architecture", "create a mind map", or "generate an Excalidraw file". Supports flowcharts, relationship diagrams, mind maps, and system architecture diagrams. Outputs .excalidraw JSON files that can be opened directly in Excalidraw.
Build and distribute Expo development clients locally or via TestFlight
Use when you have a written implementation plan to execute in a separate session with review checkpoints
Data structure for annotated matrices in single-cell analysis. Use when working with .h5ad files or integrating with the scverse ecosystem. This is the data format skill—for analysis workflows use scanpy; for probabilistic models use scvi-tools; for population-scale queries use cellxgene-census.
Benchling R&D platform integration. Access registry (DNA, proteins), inventory, ELN entries, workflows via API, build Benchling Apps, query Data Warehouse, for lab data management automation.
Comprehensive molecular biology toolkit. Use for sequence manipulation, file parsing (FASTA/GenBank/PDB), phylogenetics, and programmatic NCBI/PubMed access (Bio.Entrez). Best for batch processing, custom bioinformatics pipelines, BLAST automation. For quick lookups use gget; for multi-service integration use bioservices.
Take borghei/contract-review from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.