Client Conduct Auditor
Automated bulk assessment of client behavior for law firm termination decisions.

Overview
This tool processes client activity PDFs exported from case management systems (like MyCase) and:
- Extracts timeline events, communications, and case metadata
- Analyzes client behavior using Claude AI and SOP classifications
- Generates a formatted Excel spreadsheet with termination recommendations
Features
- ✅ Batch PDF Processing - Handle dozens of client cases at once
- ✅ SOP-Compliant Classification - Normal / Special / E-Special / Delinquent
- ✅ Automated Recommendations - Continue / Cure / Terminate / Executive Review
- ✅ Firm Fault Detection - Identifies potential malpractice or ethics issues
- ✅ Formatted Spreadsheet - Color-coded, professional deliverable
- ✅ Summary Dashboard - Statistics and breakdown by category
Installation
Requirements
- Python 3.8+
- Anthropic API key
Option 1: Install as Claude Code Plugin (Recommended)
In Claude Code, run:
/plugin marketplace add WeipengZhuo/arvin-client_audit
/plugin install client-conduct-auditor
/setup-auditor
Then use with:
/audit-clients ~/Downloads/client_pdfs
Option 2: Standalone Installation
# Clone the repository
git clone https://github.com/WeipengZhuo/arvin-client_audit.git
cd arvin-client_audit
# Run installation script
bash install.sh
# Set your API key
export ANTHROPIC_API_KEY="sk-ant-..."
Or install manually:
pip install -r requirements.txt
Usage
Basic Usage
python auditor.py /path/to/pdf_folder
This will:
- Process all PDFs in the folder
- Generate
client_assessment.xlsx in current directory
Custom Output Path
python auditor.py /path/to/pdf_folder -o ~/Desktop/assessment.xlsx
With Custom SOP File
python auditor.py /path/to/pdf_folder --sop /path/to/custom_sop.md
Full Example
# Set API key
export ANTHROPIC_API_KEY="sk-ant-api03-..."
# Process PDFs
python auditor.py ~/Downloads/delinquent_clients -o ~/Desktop/february_audit.xlsx
# Output:
# ✅ Successfully extracted data from 15 PDFs
# 🤖 Analyzing 15 cases...
# ✅ Spreadsheet saved: ~/Desktop/february_audit.xlsx
Input Format
Expected PDF Structure
PDFs should be MyCase exports containing:
- Items/Info section - Case metadata (client name, case #, attorney)
- Activities & Timeline - Full chronological history
Supported export types:
Activities & Timeline (full export, NOT filtered by date)
Items / Info
- Combined exports
Naming Convention (Optional)
PDFs can be named anything, but descriptive names help:
01_doe_john_asylum.pdf
02_smith_maria_green_card.pdf
03_garcia_family_deportation.pdf
Output Format
Spreadsheet Columns
| Column | Description |
|---|
| Case Name | Client name extracted from PDF |
| PDF Source | Original filename for reference |
| Client Classification | Normal / Special / E-Special / Delinquent / Delinquent + Special |
| Type of Notice Sent | Notice to Cure / Notice of Termination / None sent |
| Firm Fault | Yes / No / Unclear from records |
| Firm Fault Explanation | Brief explanation if firm made error |
| Current Status | Active / Pending Cure / Terminated / Recommended for Termination |
| Recommendation | Continue / Cure / Terminate / Executive Review |
| Reasoning | 2-3 sentence explanation with evidence |
| Key Evidence | Specific quotes from timeline supporting classification |
Color Coding
- 🟢 Green - Continue representation
- 🟡 Yellow - Send Notice to Cure
- 🔴 Red - Proceed with Termination
- 🔵 Blue - Executive Review Required
Summary Sheet
Includes:
- Total cases analyzed
- Classification breakdown (Special vs E-Special vs Delinquent)
- Recommendation statistics
- Firm fault analysis
SOP Classifications
Normal Client
✅ Pays on time, communicates respectfully, stays within scope
Special Client
⚠️ Difficult but salvageable:
- Excessive contact seeking reassurance
- Expressions of dissatisfaction
- Scope expansion attempts
- Key: Still respectful, no abuse
E-Special Client (Excessively Special)
🚫 Shocks the conscience - automatic termination track:
- Yelling, screaming, profanity
- Threats (lawsuit, State Bar, physical harm)
- Accusations of fraud/theft
- Hostile office conduct
- Review blackmail
Delinquent
💰 Any past-due balance per MyCase
Delinquent + Special
⚠️💰 Combination requiring dual assessment
How It Works
Phase 1: PDF Extraction (pdf_extractor.py)