Document Ingestion Rules Chinese RAG Vendors Should Follow

Ingestion is the layer that decides whether a rag bot can answer correctly, yet it is often the part of a RAG project described in one line of the proposal. A Chinese vendor should follow a documented pipeline that covers source formats, cleanup and conflict resolution, metadata and versioning, structure-aware chunking, the embeddings and vector index, hybrid search configuration, and the rules for refreshing, superseding, and deleting sources. Each rule below is a checkpoint the buyer can verify in the staged trial, rather than a promise about how the platform handles documents in general. This article lists the rules in pipeline order and the evidence that proves each one is in place.

Rule 1: validate source formats before indexing

Before any document enters the index, the pipeline should identify its format and confirm it can be parsed reliably. Text-layer PDFs, Word files, web pages, spreadsheets, and presentations each extract through a different path; scanned PDFs need OCR with a confidence flag, and poor scans should be routed to review rather than indexed automatically. The vendor should report which formats are supported, how tables, lists, and numbered steps survive extraction, and which documents failed parsing in the trial sample.

Format validation should also catch encoding issues, broken character mapping, and flattened tables that lose row-column structure. A spreadsheet where columns merged into free text cannot support specification lookups, and a manual where headings lost their hierarchy cannot be chunked by structure. The buyer should inspect a sample extraction for each document type before accepting the ingestion pass, rather than trusting the platform’s format list on its marketing page.

Multi-document corpora need a document register before ingestion. Each source should be listed with its owner, review status, intended audience, and current version, so the pipeline knows which documents are approved for indexing. Drafts, review copies, and internal working notes should stay out of the register until approved; indexing unreviewed material is a common source of answers that contradict the published policy. The register also gives the content owner a checklist for future refreshes, so a policy update has a clear owner to confirm the new version before it enters the live index.

Rule 2: clean, deduplicate, and resolve conflicts

Ingestion should remove duplicates and resolve contradictions before chunks are embedded. Duplicate copies of the same manual, internal drafts sitting beside public versions, and expired promotions left in the corpus each create wrong-answer risk. The pipeline should flag near-duplicate documents and overlapping versions for the buyer’s content owner to resolve, rather than indexing both as neutral alternatives.

Conflicting content needs explicit handling: two documents stating different return windows, warranty terms, or pricing tiers should be marked as conflicts, with the current approved version confirmed before indexing. Controlled terminology should be normalized across documents: product names, model numbers, and service labels written several ways should map to one approved term. The vendor should show how cleanup conflicts are surfaced and who approves the resolution, because indexing unreconciled contradictions lets the bot cite either version as authoritative. Cleanup findings should be reported back to the buyer’s content owner, not resolved silently by the ingestion system.

Rule 3: attach metadata and version tags

Every source and derived chunk should carry structured metadata: document title, product or product line, version, effective date, audience or role, region where applicable, document type, and supersession relation to earlier versions. Metadata lets retrieval filter by segment, prefer current versions, and exclude restricted material, and it lets reviewers trace an answer to the correct source revision. Tags should be reviewable before documents enter the live index.

Version metadata drives supersession: when a new manual replaces an older one, the older chunks should be marked inactive rather than left searchable beside the replacement. Legacy versions retained for older products should be tagged as legacy support, not confused with current documentation. The vendor should explain how metadata is stored, edited, exported, and maintained after launch, and whether the buyer’s own administrators can update tags without vendor intervention.

Metadata also supports access control. Where documents serve different roles, departments, or regions, the audience tag becomes the retrieval filter that keeps restricted material out of unrelated sessions. Tags should be applied at ingestion and verified before a document goes live, since a broad tag over-permits and a narrow tag blocks legitimate access. The access-control design that builds on these tags takes effect at the ingestion step itself, since tags set the permission filters retrieval will apply.

Rule 4: chunk to document structure

Chunk boundaries should follow the document’s own heading hierarchy rather than a fixed token window. Procedures keep their steps together, warnings and notes stay attached to the action they qualify, and specification tables keep rows intact with their model identifier. Short sections merge with related material; long sections split at subheading or step boundaries, never mid-procedure. Each derived chunk carries its section path and inherited metadata.

Chunk size and overlap are tuned to the document type, with small structure-aware overlap preventing a step from being stranded at a boundary. The vendor should show actual chunk output for a sample manual or policy section, not only a description of the chunking method, because boundary quality is visible only in the derived chunks. The decisions behind manual chunking are detailed in product-manual chunking decisions.

Rule 5: choose embeddings and build the vector index

Embeddings turn chunks and queries into vectors that can be compared by similarity. The vendor should state which embedding model is used, whether it matches the languages in the corpus, and how embedding dimensions and index configuration were chosen. Embedding and generation may use different model providers, and the buyer should know which service processes documents and whether retained material is used for service improvement.

Language coverage of the embedding model matters especially for mixed-language or non-English corpora. An embedding model weak in a given language produces poor similarity matches even when chunking and metadata are correct, so the trial should test retrieval in each target language before the index is treated as production-ready. Where the corpus spans several languages, the vendor should explain whether one embedding model covers all of them or separate models are used per language, and how mixed-language queries are encoded. Embedding choice is hard to swap later because of the re-encoding requirement, so it should be settled against the actual corpus rather than inherited from a default setting.

The vector index should be built from the cleaned, tagged chunks, with a documented schema that maps vectors to chunks and metadata. Re-indexing requirements matter: changing the embedding model usually means re-encoding the whole store, because vectors from different models are not comparable. The vendor should explain how index rebuilds run, what they cost, and how the live bot stays available during rebuild, including whether a second index is built before switching over.

Rule 6: configure hybrid search and retrieval filters

Hybrid search combines semantic similarity from the embeddings with keyword matching for exact terms, model numbers, part codes, and policy labels, then reranks the combined results. Pure vector search often misses exact identifiers; pure keyword search misses conceptual rephrasing, so the retrieval layer should use both signals where the corpus contains manual and policy material. The vendor should describe how the two signals are combined, how reranking works, and where metadata filters apply in the pipeline.

Retrieval filters should apply mandatory segment, audience, and version constraints before results reach the model, so restricted or superseded material never enters the candidate pool. Thresholds for weak retrieval should be configurable, so low-confidence matches route to escalation instead of answering. The hybrid-search tradeoffs are outlined in hybrid search when keyword matching still wins, and the configuration should be verified against a fixed retrieval test set before launch.

Rule 7: refresh, supersede, and delete sources

Ingestion is not a one-time load. The pipeline should support scheduled and on-demand refreshes: a revised document re-chunks and re-embeds, old chunks are deactivated, and the supersession link updates in metadata. Withdrawn documents and their chunks should be removed from the searchable index, with derived indexes and cached copies handled under the same retention rule. A deletion should leave no orphaned vector or stale passage that still answers a question.

The refresh workflow should record what changed, when, and who approved the update, and the bot’s freshness should be visible in session records so an answer can be tied to a source version. Retention and deletion commitments should cover production documents, backups, and derived artifacts, with a confirmation path after cancellation. The ongoing freshness procedures are detailed in knowledge bot freshness and update workflows.

Format handling deserves a specific check during ingestion. Scanned PDFs, image-heavy manuals, tables, spreadsheets, and structured lists each demand a different extraction path; a pipeline that flattens everything to plain text can lose table values, step order, and column relationships that the answer depends on. The trial should run one representative document of each source format the buyer maintains, and inspect the extracted text and chunk boundaries before accepting the pipeline. Documents that fail extraction should be flagged to an owner with the reason, rather than entering the index as incomplete passages that later produce vague answers.

Batch and incremental ingestion should both be defined. The initial load indexes the approved corpus in one pass; later updates run incrementally as documents change, so a single revised manual does not require re-embedding the whole library. The pipeline should report ingestion counts per document, any parse or chunk failures, and the documents that entered the index in each refresh batch. Buyers should ask whether failed documents block the whole batch or are held aside for review, because a blocked batch delays every other pending update. A vendor that demonstrates these seven rules in the trial, with sample extraction, chunk output, metadata records, and a documented refresh and deletion path, has an ingestion pipeline the buyer can audit and maintain after launch.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *