"""ELA Course Audit System
Centralized phonetic validation for all English Language Arts content.
Usage:
python3 audit/run_audit.py # audit all weeks
python3 audit/run_audit.py Week_02 # audit specific week
python3 audit/run_audit.py --quick # fast check, skip deep analysis
Pre-generation hook (auto-integrated into validate_week):
The phonetic audit now runs automatically when you call validate_week()
from the shared validate.py module. Every week generator validates against
the verified word database before generating PDFs.
For explicit use in a generator:
from audit.run_audit import validate_before_generate
def main():
validate_before_generate(__file__) # blocks on errors
Architecture:
word_db.py - Verified word patterns (source of truth)
validators/ - Pattern-specific rule engines
scanner.py - Extracts words/claims from week generators
run_audit.py - Main entry point, generates reports
- Includes validate_before_generate() hook
"""