bm25

Solid

Ranked content search over any text corpus using BM25 (via xhluca/bm25s). Corpus-agnostic: works on cloned repos, project knowledge stores, uploaded files/archives, and any local directory. Stateless — builds an in-memory index each invocation, no cache, no persistence. Use when you need ranked multi-word content search beyond grep, or when picking the "most relevant files for these terms" across a corpus. Triggers on "rank these documents", "search this corpus", "find content about X", "which files are most about Y", or multi-word concept queries against a known body of text.

Data & Documents 134 stars 7 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 84/100

Stars 20%
71
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# bm25 Ranked content search over any text corpus. One CLI, in-memory BM25 index per process, with a session-local disk cache so repeat invocations against the same corpus load in tens of milliseconds instead of rebuilding. ## Setup ```bash uv pip install --system --break-system-packages bm25s ``` Install is sub-second on a warm uv cache. That's the entire dependency. ## Usage ```bash BM25=/mnt/skills/user/bm25/scripts/bm25.py # Local directory python3 $BM25 ./repo 'csrf middleware' # Multiple queries against the same in-memory index (build once, query many) python3 $BM25 ./repo 'csrf middleware' 'session backend' 'queryset filter' # Cloned GitHub repo via tarball (one HTTP call) python3 $BM25 'github.com/django/django' 'atomic transaction' python3 $BM25 'github.com/django/django@stable/5.0.x' 'atomic transaction' # Project knowledge or uploads python3 $BM25 project 'RAG scaling laws' python3 $BM25 uploads 'tax loss harvesting' # Filters python3 $BM25 ./repo 'auth flow' --exclude 'tests/*' --exclude '*/tests/*' python3 $BM25 ./repo 'config' --include '*.py' --include '*.toml' # Interactive (REPL — single corpus, many queries) python3 $BM25 ./repo --interactive # JSON output for piping python3 $BM25 ./repo 'auth flow' --json ``` ## Corpus types | Spec | Meaning | |------|---------| | `./path` or `/abs/path` | Local directory | | `uploads` | `/mnt/user-data/uploads/` | | `project` | `/mnt/project/` | | `github.com/owner/repo[@ref]` | Tarball fetch via GitHub API ...

Details

Author
oaustegard
Repository
oaustegard/claude-skills
Created
9 months ago
Last Updated
yesterday
Language
Python
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category

AI & Automation Solid

algo-ecom-bm25

"Implement BM25 ranking function for e-commerce product search relevance scoring. Use this skill when the user needs to build a text-based product search engine, improve search result relevance, or replace basic TF-IDF with a more robust ranking function — even if they say 'product search ranking', 'search relevance', or 'BM25 implementation'.".

22 Updated 1 weeks ago
charlieviettq
AI & Automation Solid

using-brainpalace

Expert BrainPalace skill for document search with BM25 keyword, semantic vector, hybrid, graph, multi, compute, scan, absence, and timeline retrieval modes. Use when asked to "search documentation", "query domain", "find in docs", "bm25 search", "hybrid search", "semantic search", "graph search", "multi search", "compute query", "scan sessions", "absence query", "timeline query", "find dependencies", "code relationships", "searching knowledge base", "querying indexed documents", "finding code references", "exploring codebase", "what calls this function", "find imports", "trace dependencies", "brain search", "brain query", "knowledge base search", "cache management", "clear embedding cache", "cache hit rate", or "cache status". Supports multi-instance architecture with automatic server discovery. GraphRAG mode enables relationship-aware queries for code dependencies and entity connections. Pluggable providers for embeddings (OpenAI, Cohere, Ollama) and summarization (Anthropic, OpenAI, Gemini, Grok, Ollama). S

2 Updated 4 days ago
bxw91
AI & Automation Solid

basemind

Navigate large or unfamiliar codebases via the basemind MCP server — outlines, symbol search, reference/caller lookups, commit history, blame, and diffs without reading source files. Reach for it whenever the user asks "where is X defined", "what calls Y", "what changed recently in Z", or whenever you're about to grep or open many files to find structural information.

69 Updated yesterday
Goldziher