Knowledge Base Retrieval and Recall for Cosmetics Marketing Content

Data sources for this category include official brand filing documents (including ingredient lists, filing numbers, compliance statements), product

What Data for This Category Looks Like

Data sources for this category include official brand filing documents (including ingredient lists, filing numbers, compliance statements), product manuals, marketing promotional content, user reviews, and regulatory compliance documents. Update cadence varies with new product launches, regulatory policy adjustments, and marketing campaign changes, with no fixed cycle. Documents are centered around individual SKUs. Each document includes fields such as ingredient content, specifications, applicable skin types, efficacy descriptions, price ranges, and filing numbers, with units mostly mg/g, ml, g, CNY, and others.

Constraints These Characteristics Impose on Knowledge Base Retrieval and Recall

The mixed authority of multi-source data requires the retrieval link to distinguish the weights between official filing documents and UGC content, to avoid low-quality content interfering with matching results. The structured field design at the SKU level requires precise field matching during retrieval. Relying solely on full-text retrieval can easily lead to false recalls of unrelated products. The non-fixed update cycle requires support for incremental synchronization mechanisms, to prevent knowledge base content from lagging behind new product launch schedules. The presence of compliance fields requires built-in filtering rules in the retrieval link to eliminate non-compliant promotional content, ensuring recalled content meets regulatory requirements.

Configuration Settings

Configuration ItemRecommended ValueRationale
UPLOAD_FILE_MAX_SIZE200 MBCosmetic product manuals and ingredient list PDFs often contain multi-page tables and detailed ingredient descriptions; single files should not be too large
maxContext800–1200 charactersThe typical length of cosmetic efficacy descriptions and ingredient instructions is moderate; excessive length introduces redundant information that reduces retrieval precision
Recall countTop 4–6 resultsA single category has a large number of SKUs; too many recall results distract users, while too few fail to cover matching needs
Similarity threshold0.75–0.85Similar efficacy products in the same category must be distinguished; a threshold that is too low introduces unrelated products, while a threshold that is too high may fail to retrieve accurate results
PARSE_FILE_TIMEOUT_SECONDS120 secondsCompliance filing documents may contain large numbers of structured tables, leading to long parsing times; sufficient processing time must be reserved
Incremental sync interval2:00 AM dailyNew product launches mostly occur outside working hours; daily synchronization ensures timely updates of knowledge base content

The parameter values provided on this page are common starting points for configuration. Actual values are affected by material form, data volume and business rules. Specific issues require specific analysis, and it is recommended to test on your own samples before finalizing.

Three Common Mistakes

  • Phenomenon: Empty results are returned after retrieval, with no matching documents. Cause: Official brand filing materials and compliance verification rules are not included in the knowledge base source. Only scattered promotional content is imported, leading to insufficient matching accuracy.
  • Phenomenon: When calling the retrieval API and setting top_k=6, the number of returned results remains the default value. Cause: The upper limit parameter of the Recall count configuration item is not adjusted, and the default limit is not lifted.
  • Phenomenon: When uploading a product ingredient list document larger than 1 MB, a 413 Request Entity Too Large error is returned. Cause: The default value of the UPLOAD_FILE_MAX_SIZE configuration item is not modified, and the default limit is 1 MB.

How to Confirm Configuration Is Complete

  • Upload one product document exceeding the default limit, check if the corresponding upload limit error is triggered, to confirm that the UPLOAD_FILE_MAX_SIZE configuration takes effect.
  • Call the retrieval API and set different top_k values, check if the number of returned results matches the configured value, to confirm that the Recall count parameter takes effect.
  • Conduct a retrieval query containing compliance keywords such as "treat acne", check if the returned results filter out non-compliant promotional content, to confirm that the compliance verification rules have been configured.
  • Conduct a retrieval query targeting a specific SKU such as "hyaluronic acid serum suitable for dry skin", check if the returned results include matching product documents, to confirm that the field retrieval configuration takes effect.

Question material comes from public community discussions. Configuration values are common starting points and should be measured against your own samples. Verified on 2026-09-14.