Marketplace promotions: vector indexes for procurement

Review vector indexes for procurement in Marketplace promotions. Check document scope, failure paths and source evidence through controlled tests.

What the documents look like

Platform promotion enrollment and price management revolve around price, stock, and campaign timing. The data comes from campaign backends, ERP stock, and historical transaction prices. This page handles stock procurement and supplier materials: campaign enrollment forms, promotional price approval sheets, stock lock tables, and campaign review tables form the material set to be retrieved. These materials update weekly and per campaign, and one supplier may produce several quotation and lock records within a single campaign period.

The internal structure of the material determines index quality. A stock lock table typically carries a supplier entity, a product object, a locked quantity, a lock date range, and an approval status. A promotional price approval sheet carries a quotation validity period, a signature status, and the applicable campaign session. The vector model and index step needs to preserve entity, object, status, and validity range together so retrieval can return verifiable source data.

Constraints at the vector indexes step

Knowledge bases linked for retrieval must use the same vector model. Check the actual model and input type first. One source data block can be associated with multiple indexes, and the index and the source content are checked separately. Build index content from complete and focused information; retrieval coverage and index length are weighed against the sample. Image retrieval also depends on whether image descriptions or image vectors were generated at ingestion, and the query side alone does not decide this. After a model or index change, compare cited source text using the same question set, and do not promise an effect from a vector score alone.

FastGPT uses the PostgresSQL PG Vector plugin as the vector retriever, with HNSW as the index, while MongoDB stores source data in the dataset.datas table and keeps an indexes field recording vector IDs. Retrieval first recalls vectors, then uses the vector IDs to fetch source data from MongoDB; records mapping to the same source data are merged and the highest score is taken. Semantic retrieval relies on vector distance, full-text retrieval relies on keyword hits, hybrid retrieval merges the two paths with RRF, and Rerank reorders candidate text and returns a 0-1 score. Minimum relevance takes effect only in semantic retrieval or when result reranking is used; it is a filtering threshold and does not perform permission or entity isolation.

Hypothetical exercise sample. Source text for verification: first, "Supplier A, Product A, campaign session S1, locked quantity 500 units, lock period 1 June 2025 to 30 June 2025, status is submitted by operations, procurement approval field blank." Second, "Supplier A, Product A, quotation Q1, quotation validity 20 May 2025 to 20 June 2025, signature field blank." Draft sentence to be judged: "Supplier A Product A has completed stock locking and price approval in session S1."

Configuration and implementation checks

Configuration itemValue or check method on this pageRelation to the sample
Linked knowledge basesCheck the vector model identifier of each base; exclude inconsistent onesEnsures the four material types can be linked together
Index contentKeep entity, object, status, and validity range per blockLock table and approval sheet are indexed this way
Index and source dataOne source data block can link multiple indexesOne lock record can carry several index groups
Search modeUse full-text or hybrid retrieval for codes and sessionsSession S1 and quotation Q1 need exact hits
Minimum relevanceHypothetical trial start 0.3 on this page, compared with 0.5Observe how cited item count changes after filtering
Citation capSet by tokens, not top kControls returned source length

The minimum relevance start of 0.3 is a trial choice for this exercise, because the sample question is short and the entity is clear, and it is compared with 0.5 to observe filtered content. This value is not an official default.

Three common errors

  1. Treating a retrieval hit as authorization. In the sample the procurement approval field is blank; retrieving the lock table only shows the material exists and does not show approval is complete. Comparison action: after fetching the source data, inspect the approval field value. Observable result: if the field is empty, record it as pending verification.
  2. Inferring supply duration from quotation validity. In the sample the quotation validity ends 20 June, and the lock period ends 30 June. Comparison action: check the two date ranges field by field. Observable result: the non-overlapping part cannot be treated as covered.
  3. Linking knowledge bases across vector models. Comparison action: check the vector model identifier of each base. Observable result: exclude those with inconsistent identifiers, record the actual observation, and do not infer missed recall or redundancy from this.

How to verify the setup

  1. Input the two sample source sentences and the draft sentence, then run retrieval. Compare the entity, object, and status fields of the returned cited source text against the sample source text. Condition met: the cited source text contains Supplier A, Product A, and session S1, and the approval status field matches the source text.
  2. Input the session identifier S1 and use full-text or hybrid retrieval. Compare whether the returned result contains that exact identifier. Condition met: the cited content shows the lock record for S1; if it does not appear, record it as a miss and check the index content.
  3. Input the quotation identifier Q1 and compare the returned signature field and validity field. Condition met: the returned source text has a blank signature field and validity ending 20 June. If the returned content lacks that field, record the evidence gap and do not judge approval as completed or not completed.

For an empty result, use a paper input of an empty array to check whether the downstream path runs, without claiming that retrieval under a fictional rule necessarily returns empty.