Published Updated

A corrected invoice scan adds two missing pages. The repository now has four pages, but search and an AI summary still reflect the earlier two-page file. Upload completion has not established that the downstream content is current.
Rebuild the outputs whose source or processing dependencies changed. Replaced source bytes usually require new OCR and affected downstream processing. A mapping, search-schema or prompt change may reuse accepted OCR. First prevent outdated outputs from being presented as current while their replacements are prepared.
Treat source versions, OCR runs, mapped fields, indexes and AI results as related records. An OCR success status answers whether that job completed; it does not by itself establish that every consumer uses the intended source.
| Change | Affected work | Acceptance evidence |
|---|---|---|
| Source bytes, selected pages or input rendition | Process the changed source and rebuild consumers that depend on its text or extracted values. | Pinned source, page coverage, accepted extraction and matching consumer generation. |
| Metadata only; processing inputs unchanged | Update consumers of that metadata; repeat OCR only if the change also affects processing selection or parameters. | Changed field and consumer behaviour, including relevant retrieval filters. |
| Mapping or field-validation rule | Remap accepted OCR if it contains the required data; rerun extraction if an additional output type is needed. | Mapping revision, input result, proposed fields and validation decision. |
| OCR engine, material parameter or known defect | Evaluate representative documents and rebuild the affected population and dependants. | Profile revision, comparison results, affected uses and approved rollout scope. |
| Search schema or analyser | Reindex from accepted content if it remains adequate; extraction need not change. | Index configuration, expected queries and confirmed source-linked results. |
| Prompt, model, chunking or retrieval configuration | Rebuild the affected AI outputs or retrieval collection; reuse OCR when its dependencies remain valid. | AI configuration, accepted source set, evaluation and current retrieval eligibility. |
An engine upgrade alone does not establish the need for an immediate full-repository rebuild. Compare representative inputs against the uses that matter, then agree quality, cost and rollout criteria. A field-mapping change belongs with the schema and consumer review used for other integration changes.
Select immutable input bytes or a supported version-specific artifact. Record the digest, page coverage and processing profile.
Check the returned extraction against that source and the intended use. Preserve failures and reviewer decisions.
Apply the accepted generation through controlled writes. Verify search, fields and AI targets separately.
Start with the FormKiQ siteId and documentId. Where Document Versioning is enabled, GET /documents/{documentId}/versions provides the source's versionKey. Keep that identity, a content digest, the processing configuration, result locations and acceptance decisions in the application's processing history.
For this example, prepare a separate work document containing the corrected four-page invoice and keep its bytes unchanged while OCR runs. In the request below, {documentId} is that work document's FormKiQ identifier and {siteId} is its site. With Textract configured, the documented OCR request asks for text, forms and tables from every page:
POST /documents/{documentId}/ocr?siteId={siteId}
Authorization: {accessToken}
Content-Type: application/json
{
"ocrEngine": "TEXTRACT",
"parseTypes": ["TEXT", "FORMS", "TABLES"],
"ocrNumberOfPages": "-1"
}Retrieve the result with GET /documents/{documentId}/ocr?siteId={siteId} after asynchronous processing completes. Check page coverage and extracted values before mapping invoice attributes or publishing full-text content. Track the search update and summary generation separately in the application so an OCR result cannot stand in for either delivery's success.
The OCR request above selects a document; it does not include a versionKey parameter. The work copy keeps the selected source stable during processing. Before publishing its accepted output back to the invoice's current read paths, compare the recorded source identity with the invoice's intended current version.
Stage candidate results where they cannot directly overwrite production attributes or indexes. Restrict those writes to the publisher that owns the current-generation decision, using the destination's supported conditional or serialised controls. A check before processing starts is insufficient if a later source change or delayed worker can still publish.
If OCR rewrites a PDF into a searchable rendition, record the rewritten file as an output artifact with its source relationship. Configure intake triggers so the processor's own writes do not create an endless rebuild loop.
In this fictional invoice workflow, invoice INV-204 initially has two scanned pages. A corrected four-page file replaces that scan. The application records the replacement's FormKiQ document and version identity and prepares the work copy used above. It requires validated invoice attributes, a matching search result and an accepted summary before presenting reprocessing as complete.
The application records the corrected source and marks outputs from the two-page scan ineligible for current use. Preserve the earlier results as historical where policy requires them. Current search and automation must enforce the eligibility rule while the replacement is pending.
The OCR request processes all four pages of the work document with the configured Textract text, form and table outputs. Retrieve those results through the OCR API and check the invoice fields required by the workflow. Keep the source relationship and mapping revision with the review decision.
A run for the earlier two-page scan finishes late. Its successful OCR status does not make it current. The publication guard detects the source mismatch and keeps that result out of production writes. If the invoice changes again during processing, the four-page result also needs a new current-source decision before publication.
The corrected invoice attributes are accepted, but the search update fails. Search remains pending and the dependent summary remains blocked under this example's policy. Retry the failed delivery using the same accepted result. Exclude or remove the older search record, or gate retrieval, so it cannot silently stand in for the corrected invoice.
After search accepts the update, check a phrase from one of the added pages and verify its source/generation. Check that removed old-only text is no longer returned as current. Build and evaluate the summary from the accepted source, then record each consumer's acknowledgement and the completed processing chain.
The invoice-management and ERP guide explains why extracted values remain proposals until the relevant business checks accept them. Reprocessing should preserve that decision history.
A new processing configuration or source creates a new logical generation. A delivery retry remains tied to the accepted generation it is trying to publish. Agree duplicate handling, partial publication, rollback and recovery for each target; asynchronous services do not provide a single atomic switch across every consumer.
Every production reader must honour the current-source policy, including direct search and AI retrieval paths. If historical output remains available for continuity, label its source version and status clearly. A newer upload must not make an old answer look current. The search and KnowledgeBase propagation guide covers the separate problem of removing ineligible derived content.
For an invoice table, review the relationships between fields as well as whether the source is current. Checking Invoice Rows After OCR follows a repair invoice whose subtotal is correct while its extracted quantity has the wrong unit.
Choose OCR, remapping, reindexing and AI rebuilds from their actual dependencies. Pin the input, retain the processing decision and publish through a controlled current-generation policy. A completed job becomes useful current content when its intended consumers confirm the accepted result.
The open-source foundation — API-first, deployable into your own AWS account, and free to use. Right for architecture validation and early implementation.
Production-ready editions for departments and complex workflows. Start with a Proof-of-Value deployment or go straight to production.
For governance-heavy environments with residency, sovereignty, assurance, and multi-jurisdiction requirements. Talk to us about the right deployment model.