Embed on write, retrieve on read

  • Build
  • Agent 10

Difficulty 4 of 5

A help bot answers 25 questions/s from 600,000 article chunks. Editors change 20 articles/s, and a bulk import at 0:30 raises that to 300/s for 30 s. Keep answer p99 under 1.6 s. A changed article must be searchable within 15 s. You have two L4 GPU hosts.

Play level

GPU server (L4)520 USD/moGPU server (L4)520 USD/moUsers25 req/sUsers20 req/sAPI server1 vCPU · 1 GBPostgres1 vCPU · 2 GBSearch index2 vCPU · 4 GBLLM API1 vCPU · 1 GB
520 USD/mo520 USD/moUsers25 req/sUsers20 req/sAPI serv…PostgresSearch i…LLM API
The board at the start of the level
An index against a full scanTap to add or remove the index

Index · 4 pages read per query · disk writes per insert: 2

Goals and limits

p99 latency (Ask)
under 1.6 s
Data age
under 15 s
Error rate (*)
under 1%
Monthly cost
under 1,100 USD/mo
Parts you can add
Embedding model
Part limit
2
Hosts
2 × 1 vCPU · 24 GB
Traffic
25 req/s

Concepts

How players did

Player results load from the server.