def redaction_density(text: str) -> float: if not text: return 0.0 blocks = text.count("████") + text.count("[REDACTED]") return round(blocks / max(len(text.split()), 1), 4)