How Airtable Built Semantic Search Across Thousands of Dynamic Bases
How Airtable architected per-base semantic search on Milvus: partition capping, HNSW over DiskANN, and hot-cold offloading for idle enterprise bases.
On this page
Airtable occupies a unique place in enterprise infrastructure: it blends relational database flexibility with spreadsheet usability. When Airtable introduced semantic search and generative AI features across enterprise accounts, its infrastructure faced an unusual reality:
Roughly three-quarters of the hundreds of thousands of embedded enterprise bases sit idle in any given week.
If a database system pinned all embeddings in memory across all customer bases, 75% of high-cost GPU and RAM resources would sit completely idle. Conversely, when an active base receives thousands of concurrent row updates, search indexes must reflect modifications within milliseconds.
To solve this, Airtable designed a specialized search layer on top of Milvus, incorporating partition capping, in-memory HNSW indexing, and automated hot-cold tiering.
Unique Constraints of Enterprise Spreadsheet-Databases
Unlike static search corpora (such as Wikipedia or e-commerce catalogs), enterprise bases exhibit three adversarial characteristics:
- Extreme Dynamic Schema Modification: Users add, rename, and delete columns continuously. A vector search engine cannot rely on rigid table schemas.
- Strict Multi-Tenant Isolation: Base data from Company A must never leak into Company B’s vector space. Cross-tenant retrieval is a catastrophic security violation.
- Severe Skew and Idleness: A small fraction of bases experience millions of row operations daily, while the vast majority sit quiet until a quarterly audit or weekly meeting.
+-----------------------------------------------------------------------+
| Airtable Search System Priorities |
+-----------------------------------------------------------------------+
| 1. Sub-500ms p99 Query Latency |
| 2. High Write Throughput (Support continuous row edits & imports) |
| 3. Self-Hosted for Strict Enterprise Privacy & Security |
| 4. Horizontal Elasticity (Scale resources to match base activity) |
+-----------------------------------------------------------------------+
Architecture: Milvus with Partition Capping and Hot-Cold Tiering
Airtable selected Milvus as its underlying vector engine, structuring index tenancy carefully to avoid coordinator limits.
+-----------------------------------------------------------------------+
| Airtable Semantic Search Flow |
+-----------------------------------------------------------------------+
| |
| [ User Cell Edit / Row Insert ] |
| | |
| v |
| [ Change Data Capture (CDC) Event Stream ] |
| | |
| v |
| [ Embedding Worker Pool (OpenAI / Self-Hosted Encoders) ] |
| | (Generates 1536-dimensional semantic vectors) |
| v |
| [ Airtable Tenancy Router & Partition Allocator ] |
| | |
| +---> Small / Medium Bases (<100k rows): Clustered Partitions |
| +---> Large Enterprise Bases (>1M rows): Dedicated Collections |
| v |
| +-----------------------------------------------------------------+ |
| | Milvus Vector Storage Tiers | |
| | | |
| | [ HOT TIER: Active Bases ] | |
| | - In-Memory HNSW Graphs | |
| | - Sub-50ms Approximate Nearest Neighbor Lookups | |
| | | |
| | [ COLD TIER: Idle Bases (75% of Total Fleet) ] | |
| | - Offloaded from RAM to S3 Object Storage | |
| | - On-Demand Rehydration upon first user query (~300ms) | |
| +-----------------------------------------------------------------+ |
| | |
| v |
| [ Hybrid Reranker: Reciprocal Rank Fusion (BM25 + Semantic Score) ] |
| | |
| v |
| [ Filtered Results Returned to Airtable Client ] |
+-----------------------------------------------------------------------+
1. Partition Capping vs Collection Limits
Milvus imposes hard limits on the number of collections a single cluster can manage (typically a few thousand before metadata coordinator overhead degrades). Because Airtable hosts hundreds of thousands of independent bases, assigning one collection per base was impossible.
Airtable engineered a dynamic tenancy allocator:
- Shared Partition Pools: Small-to-medium bases share large Milvus collections, partitioned logically using Milvus partition keys and tenant ID filters.
- Dedicated Collections: Only mega-bases with millions of records receive dedicated collections to isolate indexing workloads.
2. Choosing HNSW Over DiskANN
When evaluating index algorithms, Airtable evaluated DiskANN (disk-resident graph index) against HNSW (in-memory graph index):
- DiskANN: Optimized for massive single datasets (billions of vectors) where SSD I/O replaces RAM. But write-amplification during rapid updates is high.
- HNSW: Delivers ultra-low latency and superior dynamic update throughput, but requires holding index graphs in memory.
Because enterprise spreadsheet workflows require instant write visibility when users edit cells, Airtable chose HNSW for active bases, but mitigated memory costs through automated hot-cold offloading.
3. Automated Hot-Cold Offloading
To prevent paying RAM costs for idle data, Airtable built a lifecycle manager:
- If a base receives no search queries or write activity for 72 hours, its HNSW index segment is unloaded from Milvus QueryNode memory and persisted directly to Amazon S3.
- When an executive opens an idle base and types a semantic search query, the index segment is pulled back from S3 and loaded into RAM. The first cold query completes in roughly 300 to 400 milliseconds; subsequent searches run in under 30 milliseconds.
Hybrid Search: Blending Lexical Exactness with Semantics
Users searching Airtable expect both semantic discovery and exact string matching:
- A query for “invoices overdue by 30 days” requires semantic intent.
- A query for “INV-2024-0098” requires exact lexical matching.
Airtable combines dense HNSW vector search with an Elastic/BM25 inverted text index using Reciprocal Rank Fusion (RRF). The resulting ranking guarantees that exact invoice numbers rank at the top, while fuzzy contextual concepts appear immediately below.
Key Engineering Takeaways
- Account for the 75% idle rule: Multi-tenant SaaS platforms must tier vector storage. Do not pin all enterprise embeddings in high-cost RAM when the vast majority of workspaces are inactive.
- Match index choice to write frequency: If users update rows frequently, in-memory HNSW handles dynamic mutations with far less write amplification than disk-resident graph alternatives.
- Hybrid search is non-negotiable in business tools: Semantic search alone fails at exact alphanumeric identifiers, serial numbers, and IDs. Always pair vector retrieval with lexical keyword indexes.



/* Comments */
Comments are offline right now — we reconnect automatically, nothing is lost.