witchcraft  by dropbox

Local semantic search engine

Created 1 month ago
433 stars

Top 68.4% on SourcePulse

GitHubView on GitHub
Project Summary

Summary

Witchcraft provides a high-performance, client-side semantic search engine reimplemented in safe Rust. It targets developers and power users needing fast, standalone search without external APIs or vector databases. Its core benefit is lightning-fast, self-contained search, demonstrated for recalling AI coding sessions.

How It Works

This project is a Rust reimplementation of Stanford's XTR-Warp, using a single-file SQLite database for persistence. It employs an embedding and indexing pipeline for semantic search, prioritizing standalone deployment. It supports T5 backends (GGUF via Candle, OpenVINO) and hardware acceleration (Apple Metal, x86 fbgemm).

Quick Start & Requirements

  • Build: Use make warp-cli for the CLI, make pickbrain for the example.
  • Prerequisites: Requires XTR weights (downloadable via Python scripts from Huggingface) and GGUF quantization. Python environment implied.
  • Setup: Involves downloading weights, compiling Rust, then using warp-cli for data ingestion (readcsv), embedding (embed), and index creation (index). State persists in mydb.sqlite.
  • Links: Original XTR-Warp: https://github.com/jlscheerer/xtr-warp.

Highlighted Details

  • Claims 21ms p95 search latency on NFCorpus (33% NDCG@10) on Apple M2 Max, reportedly faster than original XTR-WARP on server hardware.
  • Features pickbrain, a CLI for indexing and semantically searching AI coding transcripts (Claude Code, OpenAI Codex) to recall specific conversations.
  • Supports hybrid search, combining semantic search with SQLite's native BM25 functionality.

Maintenance & Community

The provided README does not detail notable contributors, sponsorships, partnerships, or community channels (e.g., Discord, Slack).

Licensing & Compatibility

Licensed under the Apache License, Version 2.0. This permissive license is compatible with commercial use and closed-source projects.

Limitations & Caveats

Adoption requires downloading external XTR weights. The project notes nextest is necessary for reliable unit testing due to potential "history effects" with standard cargo test.

Health Check
Last Commit

3 days ago

Responsiveness

Inactive

Pull Requests (30d)
17
Issues (30d)
1
Star History
433 stars in the last 30 days

Explore Similar Projects

Starred by Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems") and Simon Willison Simon Willison(Coauthor of Django).

semantra by freedmand

0.0%
3k
CLI tool for semantic document search
Created 3 years ago
Updated 1 year ago
Starred by John Resig John Resig(Author of jQuery; Chief Software Architect at Khan Academy), Simon Horup Eskildsen Simon Horup Eskildsen(Cofounder of Turbopuffer), and
21 more.

meilisearch by meilisearch

0.1%
57k
Search engine API for integrating AI-powered hybrid search
Created 8 years ago
Updated 2 days ago
Feedback? Help us improve.