chops-search

Semantic search for static sites. No server, no SaaS, no megabyte model download.

Quick Start

Getting Started From `cargo install` to a working search box on a Zola site. Site-wide search Two template lines give every page a Cmd-K overlay. Deploy with caching The headers file, the CSP directives, and the three gotchas. Evaluate your search Turn ranking quality into a number and gate it in CI.

chops-search is hybrid keyword + semantic search for static sites, running entirely in the browser. The "model" is a model2vec/potion int8 lookup table streamed over HTTP range requests, so a query costs about 0.2 KB on average rather than the tens of megabytes a transformer would. Try it right now: the search on this site is chops-search, indexing these docs. Press Cmd-K (or /) and phrase a question in words the pages don't use.

Hybrid ranking

BM25 keyword scores fused with semantic cosine similarity. The two engines fail differently, which is the whole point.

Range-fetched model

The embedding model is a static file. The browser fetches individual rows out of it, a kilobyte at a time.

One tokenizer

One Rust core compiled to native and wasm, so the tokenizer that indexed your content is bit-for-bit the one that reads queries.

Measured, not vibed

A labelled-query eval harness turns every ranking change into a recall number, and --fail-under makes CI enforce it.

Key Features