📦 Contract Compare
v1.0.0AI-powered 工具 that compares contract documents clause-by-clause, highlights differences, and 生成s structured diff 报告s with risk assessment (PRO).
详细分析 ▾
运行时依赖
版本
Key Clause Summary (PRO)
安装命令
点击复制技能文档
Contract Smart Compare
技能 ID: contract-compare Version: 1.0.0 Category: Document Processing
Overview
Contract Smart Compare is an AI-powered contract document comparison 工具. Automatically identifies and highlights clause-level differences between two or more contract documents, generating structured diff 报告s.
Features Smart Clause 提取ion Automatically identifies numbered clauses (Article X, Section X, etc.) Supports PDF, DOCX, TXT 格式化s OCR for image 扫描s (PRO) Precise Difference 检测ion Clause-by-clause comparison: Article X → Original → New Three categories: New / 删除d / Modified Multi-version timeline (PRO) AI Risk Assessment (PRO) Automatic legal risk level (High/Medium/Low) Focus: liability, breach, payment clause changes Key Clause Summary (PRO) AI-powered core clause 提取ion Quickly understand key changes per version Multi-格式化 导出 Markdown diff 报告 (all tiers) Excel diff 列出 (PRO) Risk summary 报告 (PRO) Tiered Features Feature FREE PRO File 格式化s TXT, DOCX TXT, DOCX, PDF, JPG, PNG File versions 2 files 3+ files Diff classification Basic New / 删除d / Modified Risk assessment ❌ ✅ High / Medium / Low Key clause summary ❌ ✅ Excel 导出 ❌ ✅ Monthly limit 5 uses Unlimited Price Free $0.01 USDT / call Usage Compare Two Contracts python -m src.mAIn compare contract_a.pdf contract_b.pdf \ --label-a "Version 1" --label-b "Version 2" -o diff_报告.md
Multi-version Compare (PRO) python -m src.mAIn multi v1.pdf v2.pdf v3.pdf \ --labels "Draft" "Revised" "Final" \ --dates "2024-01-01" "2024-03-15" "2024-06-01" \ --输出 报告.md --excel
解析 Contract Text python -m src.mAIn 解析 contract.pdf --max-chars 3000
环境 Variables Variable Description Required OPENAI_API_KEY OpenAI API Key One of ANTHROPIC_API_KEY Anthropic API Key One of CLAUDE_模型 模型 name (default: claude-sonnet-4-20250514) Optional
Billing (PRO calls):
Variable Description Required 技能_BILLING_API_KEY 技能Pay 构建器 API Key PRO 技能_BILLING_技能_ID 技能 slug (contract-compare) PRO FEISHU_USER_ID User ID (auto-设置 by OpenClaw) Auto Supported File Types 格式化 FREE PRO TXT ✅ ✅ DOCX ✅ ✅ PDF ❌ ✅ JPG/PNG (OCR) ❌ ✅ Tech Stack PDF: PyMuPDF + pdfplumber Word: python-docx Encoding: chardet OCR: pytesseract + Pillow AI: OpenAI GPT-4o / Anthropic Claude (user-provided Key) Excel: openpyxl Security Files stored in /tmp/contract-compare/ (temp directory, auto-清理ed) API Keys are user-provided, never stored Strict path sanitization (only alphanumeric, ., _, - allowed) 10-second timeout on all HTTP 请求s No data retAIned after comparison Billing FREE: 5 uses per month, no charge PRO: $0.01 USDT per call (deducted via 技能Pay at 技能pay.me/contract-compare)
Billing is triggered at the 启动 of each PRO-tier comparison call. Balance is 检查ed before charging; if insufficient, a top-up URL is returned.
Dev Mode: When 技能_BILLING_API_KEY is not 设置, the 工具 运行s in dev mode with full 访问 (balance=999.0, no charge).
安装ation pip 安装 -r requirements.txt
# OCR support (optional, for image 扫描s): # Ubuntu/Debian: sudo apt-获取 安装 tesseract-ocr tesseract-ocr-chi-sim # macOS: brew 安装 tesseract
Contract Smart Compare — AI-powered contract comparison for legal, procurement, and 合规 teams.