Define the processing-adapter contract and implement UTF-8 plain-text ingestion #12
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.
Blocks
Depends on
#13 Implement born-digital PDF text extraction
Arkive/arkive
#16 Implement the end-to-end pilot processing command
Arkive/arkive
Reference
Arkive/arkive#12
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
Goal
Carry source ID, document ID, original file identity, media type, and transformation metadata through the adapter result.
Implement strict or explicitly documented UTF-8 decoding behavior.
Preserve the input text exactly at this ingestion stage.
Record encoding assumptions and the adapter implementation/version used.
Produce deterministic output and deterministic errors.
Reject unsupported encodings or malformed input according to the documented policy.
Add tests using approved plain-text pilot files and focused invalid fixtures.
Keep the interface small enough that a born-digital PDF adapter can implement it without a plugin framework.
Chunk generation.
PDF extraction.
OCR.
Automatic format conversion or repair.
A dynamic plugin discovery system.
#9 — Align metadata schemas and validation with the intake and processing contracts
#11 — Implement approved-file import and integrity verification
Valid UTF-8 pilot files preserve exact text and identity.
Source and document lineage is present in the adapter output.
Encoding and transformation metadata are explicit.
Unsupported or malformed text fails clearly.
Repeated ingestion produces identical output.
Compare ingested text byte-for-byte or character-for-character with approved UTF-8 inputs as appropriate.
Exercise malformed UTF-8 and unsupported-encoding fixtures.
Repeat ingestion and compare serialized results.
Issue #12 is complete through PR #57.
The processing-adapter boundary is now documented and implemented, with approved originals flowing through the Issue #11 integrity-verification boundary into format-specific processing using the exact verified bytes.
The initial plain-text adapter provides deterministic strict UTF-8 ingestion with exact text preservation, explicit encoding and adapter-version metadata, source/document/original lineage, stable processing errors, UTF-8 BOM preservation, unsupported-encoding handling, and deterministic repeated results.
Both approved UTF-8 pilot originals are covered by integration tests alongside focused malformed UTF-8, unsupported encoding, media-type, whitespace/newline, BOM, immutability, serialization, and verification-failure tests.
Final validation passed with 73 unit tests, metadata validation, Ruff lint/format checks,
git diff --check, andpip check.Issue #12 acceptance criteria are satisfied. Closing as completed.