Introduction

Documentation

PolicyDiff is a rule-based utility for monitoring structural changes in legal documents. It provides a structured signal for change analysis, without the variability of probabilistic models.

Engine Logic

The system provides auditable results through a multi-stage processing pipeline:

  • Structural Hashing: Normalizes tables and lists into canonical text before diffing.
  • Isolation Layer: Identifies primary content containers while stripping headers, footers, and navigation noise.
  • Rule Engine: Employs Proximity Clustering(scanning verbs within a 5-word window of sensitive nouns) andNegation Shift Detection to detect intent changes.

System Guarantees

FeatureGuarantee
DeterminismIdentical HTML input always yields identical JSON output.
Risk CoverageRule-based detection of data sharing, arbitration, and numeric overrides.
SecuritySHA-256 hashing for all API keys. Raw credentials are never stored.
AuditabilityFull snapshot history preserved for every meaningful change detected.