Track attachment versions across email replies
3 November 2026
To track PDF attachment versions across email replies without mistaking legitimate updates for duplicate messages, an intake system must decouple message transport metadata from document payload identity. When an email reply attaches an amended PDF under an original filename, the workflow evaluates composite processing keys—mailbox ID, message ID, attachment ID, and case purpose—alongside cryptographic payload checksums (SHA-256). Keep every distinct delivery, even where a processing result is eligible for reuse. A changed payload is a candidate revision until an authorised reviewer accepts it. Attachment manifest · Intake results
Establishing identity across email reply threads
Email reply threads frequently carry revised PDF attachments under original filenames. Suppressing a reply thread because the filename matches an earlier submission risks discarding critical revisions. Conversely, treating every transmission as a new processing job creates redundant computational work when identical files are resent. Intake results
An effective intake architecture distinguishes four operational states:
- Exact transport duplicate: An identical message and attachment arrive again due to network or server retries.
- Thread reply with identical attachment: A reply message carries an unchanged copy of a previously parsed PDF.
- Thread reply with amended attachment: A reply message carries a modified PDF under the original filename, creating a candidate revision whose intention and content still require checking.
- Malformed or corrupted attachment: An incoming file cannot be parsed or validated due to structural errors.
Attachment manifest · Intake results
A thread groups messages for navigation. It is neither a file identity nor an acceptance decision. Keep the original receipt and the reply as separate message/attachment pairs, with their respective payload digests and authorised business purpose. Attachment manifest · Intake results
Worked decision record: synthetic intake test findings
To illustrate version tracking in practice, consider five synthetic delivery records processed by a local intake script. This synthetic experiment categorises inbound deliveries into job creation, context reuse, duplicate suppression, and quarantine handling. Intake results
The test environment was executed locally using Python 3.12.14 and pypdf 6.10.0 with zero network calls. Mail API integration (mail_api_test) and security scanning (security_scan) remained in unexecuted NOT_RUN template states. The test processed a source file (synthetic-tables.pdf) with a recorded SHA-256 hash of beee40fa0bfd1f3c5819f6fb919a0c3791100856cc1626d3db0f510d60f58905. Across 5 total deliveries and 4 unique source contexts, the test generated 2 processing jobs. Attachment manifest · Intake results
The table below records the full decision ledger for this synthetic test set: Attachment manifest · Intake results
| Delivery | Mailbox & Message | Attachment & Purpose | SHA-256 Checksum | Processing Outcome | Retained Context / Action |
|---|---|---|---|---|---|
| D01 | SYN-MB01 / M01 | A01 (SYN-CASE-A) | beee40fa... | CREATED_JOB (Job SYN-J01) | Parsed 3 pages; no human version acceptance was measured. |
| D02 | SYN-MB01 / M01 | A01 (SYN-CASE-A) | beee40fa... | DUPLICATE_DELIVERY | Suppressed exact transport duplicate. |
| D03 | SYN-MB01 / M02 | A02 (SYN-CASE-A) | beee40fa... | REUSED_JOB_NEW_CONTEXT | Reused Job SYN-J01; recorded context [SYN-MB01, M02, A02]. |
| D04 | SYN-MB01 / M03 | A03 (SYN-CASE-B) | beee40fa... | CREATED_JOB (Job SYN-J02) | Parsed 3 pages for separate case purpose. |
| D05 | SYN-MB01 / M04 | A04 (SYN-CASE-A) | cd81e669... | QUARANTINED_PARSE_FAILURE | Exception PdfReadError. |
Intake results · Attachment manifest
Decide which attachment the receiving team should use
The malformed D05 payload had a different digest and raised PdfReadError. Different bytes and a parser error do not identify the sender’s intent or establish acceptance. The other local cases reused identical bytes. The source does not demonstrate a real mail thread, an accepted amended PDF, mailbox movement, live mail authentication or a security scan. Keep that measured result separate from this proposed version decision. Attachment manifest · Intake results
| Evidence in a hypothetical reply | Intake action | What the reviewer records |
|---|---|---|
| Same name, different message and attachment IDs, same bytes and purpose | Retain the new receipt. A compatible result may be reused without treating the message itself as a duplicate. | Link the new context to the existing payload and note any new instructions in the reply. |
| Same name, different bytes; sender says the document is corrected | Retain both versions. Compare the changed content, requested purpose and sender authority. | Proposed predecessor/successor relationship, reason for change and actual reviewer decision. |
| Distinct bytes but unreadable or unclear purpose | Hold the candidate separately and keep the previously accepted version available under existing access rules. | Observed error, assigned owner and what clarification or replacement is required. |
| Reviewer accepts the new version | Update the active version for that specific use, preserving the prior issue and delivery history. | Version IDs, effective time, evidence and any downstream recipient who needs to be told. |
Do not mark an earlier version superseded simply because a later email arrived. If the correction changes a document already sent to another team, record whether that handoff must be repeated and which version the receiving team acknowledges. If the two attachments serve different cases, preserve separate purpose bindings even where their bytes match. Attachment manifest · Intake results
Before enabling deduplication, test an amended file under the original filename as well as an exact transport replay. Verify that the legitimate reply remains visible, the reviewer can retrieve both versions and downstream processing follows the version actually authorised for that case. Intake results
Part of the Deduplicate PDF email attachments without losing their case guide.
Published by Arke Technologies (Pty) Ltd, Johannesburg. Drafted with NotebookLM. Source checks and editing by Kairos (Codex).
