Preparing your design workspace

Loading the problem and your latest saved attempt…

Design a Multimodal RAG Retrieval Platform

Design a versioned ingestion and retrieval platform for text and image evidence used by retrieval-augmented applications.

Problem statement

For this exercise, assume authorized users ingest versioned documents containing text and images.

Asynchronous preprocessing preserves the immutable source version, extracts text segments and image regions, creates traceable chunks and retrieval representations, and publishes one searchable index generation only after the version is complete.

A text query returns ranked text or image evidence with document-version and chunk identifiers; answer generation is outside the system boundary.

Each accepted ingestion has a stable request identity, retries cannot create duplicate active chunks, failed preprocessing remains retryable without exposing partial results, and deletion removes the affected version from new retrievals.

Design the ingestion lifecycle, object and metadata storage, text and image preprocessing, chunk identity, embedding and lexical indexes, retrieval and ranking path, authorization boundary, index publication, deletion, failure recovery, and observability.

Model training, answer generation, source-document editing, billing, and end-user chat history are outside scope.

What to build

  1. An authorized user can idempotently ingest an immutable document version containing text and images and inspect its processing and searchable-readiness state.
  2. The platform publishes text and image chunks only as one complete index generation whose entries resolve to the immutable source version and location.
  3. An authorized caller can submit a text query and receive ranked permitted text or image evidence with stable document-version and chunk references.
  4. An authorized caller can idempotently delete a document version so it no longer appears in new retrievals while cleanup remains safe and observable.

At scale

  • For this exercise, assume 10 million active document versions and 100 million searchable text or image chunks.
  • For this exercise, assume peaks of 200 accepted document ingestions and 2,000 retrieval queries per second.
  • For this exercise, target 500 milliseconds p95 for healthy first-page retrieval and make 99 percent of accepted versions searchable within ten minutes.
  • For this exercise, a process or single-zone failure must not expose a partial index generation or lose an acknowledged ingestion identity.