Implement deterministic conservative text normalization #61
No reviewers
Labels
No labels
area/deployment
area/governance
area/metadata
area/pipeline
area/search
type/data
type/design
type/implementation
type/testing
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Arkive/arkive!61
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feature/issue-14-text-normalization"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
ProcessingResultoutput without rerunning source verification, plaintext decoding, or PDF extraction.U+000Cpage separator.pages=None).Normalization contract
Normalizer:
arkive.text_normalization0.1.0Rules, in order:
CRLFand bareCRline endings toLF.The v0.1 contract deliberately does not:
Page and lineage behavior
For page-aware PDF processing results:
U+000C.For plaintext processing results:
pages=Noneremains unchanged;Existing adapter transformation metadata is retained separately from the normalization transformation.
No source originals, metadata records, schemas, policies, adapters, extraction behavior, or dependencies are changed.
Pilot-corpus review
All five approved pilot documents were processed using the existing Issue #11/#12/#13 pipeline and manually reviewed before and after normalization.
Results:
The pilot corpus also demonstrates why broader cleanup is intentionally excluded: current PDF extraction contains potentially meaningful spacing, line-break hyphenation, split URLs, page material, and layout artifacts that cannot safely be removed generically.
Verification
python -m unittest discover -s tests -v— 164 passedpython pipeline/validate/validate_records.pypython -m ruff check src pipeline testspython -m ruff format --check src pipeline testsgit diff --checkpython -m pip checkScope confirmation
Linked issue
Closes #14