Witchcraft, fast local semantic search on top of SQLite [P]

· Source: Machine Learning · Field: Technology & Digital — Artificial Intelligence & Machine Learning, Software Development & Engineering, Data Science & Analytics · Depth: Intermediate, quick

Summary

Dropbox has released Witchcraft, an open-source, Rust-based re-implementation of Stanford's XTR-Warp semantic search engine. Designed for client-side deployment, Witchcraft utilizes a single-file SQLite database for storage, eliminating the need for API keys, external vector databases, or complex chunking strategies. It achieves a p.95 end-to-end search latency of 20ms on the NFCorpus dataset with 33% NDCG@10 on an Apple Macbook Pro M2 Max, demonstrating over twice the speed of the original XTR-WARP on server-class hardware while maintaining similar accuracy. The project also includes Pickbrain, a CLI tool for indexing Claude Code and OpenAI Codex session transcripts, memory files, and documents, enabling fast semantic search and session resumption.

Key takeaway

For NLP Engineers and AI Architects building local-first applications or seeking to enhance developer productivity, Witchcraft offers a compelling solution for fast, client-side semantic search. You can integrate Pickbrain to index and retrieve past AI agent interactions, significantly improving context management and session continuity without relying on external APIs or vector databases. Consider adopting this for projects requiring high-performance, privacy-preserving local search capabilities.

Key insights

Witchcraft provides fast, local, and self-contained semantic search using SQLite, ideal for client-side applications.

Principles

Method

Witchcraft re-implements XTR-Warp in Rust, using SQLite for backing storage to enable client-side, stand-alone semantic search without external dependencies.

In practice

Topics

Code references

Best for: NLP Engineer, AI Architect, AI Engineer, Machine Learning Engineer, Prompt Engineer

Related on AIssential

Open in AIssential →

Editorial summary, takeaway, and curation by AIssential. Original article published by Machine Learning.