Skip to content

kuroi.core.findings

findings

The Finding data type — what every detector emits and the redactor consumes.

Finding dataclass

A single proposed redaction.

page is 1-indexed. start and end are inclusive word indices into the per-page word list produced by extract_word_index. kind is the rule category (e.g. "email", "person_name"). source records who proposed it ("rules:pii-en", "llm", "instruction:1").

span_length property

span_length: int

Number of words covered by this finding (inclusive).

bbox_union

bbox_union(boxes: Iterable[Bbox]) -> Bbox

Return the smallest axis-aligned rectangle containing all input boxes.