# Semantic Search at the Edge, <10ms Globally

> Store, index, and query vector embeddings across 300+ edge locations. Built-in similarity search, automatic clustering, and native OpenAI/Claude integration. Scale from prototype to billions of vectors with zero configuration.

Canonical: https://vectors.do/

## In code

```ts
import { Vectors } from 'vectors.do'

// Edge-native vector store with HNSW indexing
const store = Vectors({ dimensions: 1536, metric: 'cosine', index: 'hnsw' })

on.Document.created(async $ => {
  const embedding = await $.OpenAI.embed.text($.content)
  store.insert({ id: $.id, vector: embedding, metadata: $.metadata })
})

// Semantic search with <10ms latency
on.Search.submitted($ => store.query({ vector: $.embed(), topK: 10 }))
```

## Frequently asked questions

### How does vectors.do compare to Pinecone or Weaviate?

Vectors.do runs at the edge with <10ms query latency globally versus 50-200ms for traditional vector databases. No separate infrastructure to manage—embeddings are stored across Cloudflare's 300+ locations automatically. Built-in integration with OpenAI, Claude, and local models eliminates embedding pipeline complexity. Scale to billions of vectors with automatic sharding, no capacity planning required. First 1M queries daily are free.

### What about indexing performance and accuracy?

HNSW (Hierarchical Navigable Small World) indexing provides 95%+ recall with <10ms query times. IVF (Inverted File Index) available for trillion-scale datasets. Automatic index optimization based on query patterns—no manual tuning required. Support for approximate and exact nearest neighbor search with configurable accuracy/speed tradeoffs.

### Can I use custom embedding models or fine-tuned embeddings?

Yes. Bring your own embeddings from any model: OpenAI, Cohere, sentence-transformers, custom PyTorch/TensorFlow models, or domain-specific fine-tuned models. Any vector dimensionality from 128 to 4096 supported. Automatic normalization, quantization, and compression for optimal storage and query performance.

### How do I implement hybrid search with text and vectors?

Store full-text metadata alongside vectors for powerful hybrid search. Combine semantic similarity with keyword filters, date ranges, categorical facets, and geo-location bounds. Use re-ranking algorithms to optimize result relevance. Full SQL-like query language with vector similarity operators built-in.

### What are the scaling limits and costs?

Scale to billions of vectors with automatic horizontal sharding across edge locations. No connection limits, no cold starts, sub-millisecond billing precision. Storage: $0.25/GB/month, queries: <$0.0001 each with volume discounts. Enterprise plans support dedicated capacity, private deployments, and custom SLAs.

## Part of Platform.do

vectors.do is one of the primitives of Platform.do. Every .do shares one grammar, Business-as-Code, and one SDK.

- What is Business-as-Code? https://platform.do/business-as-code
- Platform.do: https://platform.do/
- Docs: https://docs.platform.do
