Skip to main content
Glama

Scythe Context MCP

No longer maintained — 2026-10-19. Development and releases have ended. This public archive preserves the source, historical usage instructions and evaluation results. The evaluations did not establish a general speed or token-saving advantage over rg. See the final larger TypeScript evaluation. Existing npm versions remain available for reference; the installation instructions below describe the historical setup.

CI npm version License: Apache-2.0 Node.js >=24.11

English | 繁體中文 | 简体中文

Scythe Context MCP helps coding agents find relevant code and trace symbols, imports, and reverse imports. It returns file paths, line ranges, and selected snippets through CLI + Skill or MCP. Local keyword search works without an API key; semantic search is optional.

When to use it

What you need

Start with

A known file, exact identifier, error message, or regular expression

Direct file reads or rg.

Ranked matches and related-file context in an unfamiliar repository

Scythe keyword search and navigation.

Relevant code may use different wording from your description

Optional hybrid search with embeddings.

Keyword search depends on matching terms. Scythe's additional value is ranking and cross-file context; it is not a replacement for every rg lookup.

Related MCP server: ragbox-mcp

Choose an interface

Both interfaces ship in the same scythe-context-mcp npm package. Choose either, or use both.

Interface

Use it when

Search default

CLI + Skill

Your agent runs shell commands and loads skills, or you search from a terminal.

Local keyword.

MCP

Your client uses MCP tools.

hybrid; set mode="keyword" for local-only lookup.

Scythe requires Node.js >=24.11.0 <27; Node.js 24 is the tested baseline. Your target repository does not need Node.js. Install and run Scythe in the same environment as its files; see Windows, WSL, Linux, and macOS setup.

Quick start

CLI + Skill

1. Install the CLI and search your repository. Replace the path and query with your own repository and relevant terms:

cd /absolute/path/to/your/repo
npm install -g scythe-context-mcp@0.1.24
scythe-context index
scythe-context context "auth token" --format compact --max-results 1

The example limits results to one with --max-results 1 for display; remove that option to return more matches.

index writes local metadata to .scythe-context/; it does not request embeddings. Refresh it after source changes. The terminal commands work without installing a Skill.

2. Install the Skill for your agent. Locate the global npm package directory:

npm root -g

Inside that directory, install the entire scythe-context-mcp/skills/scythe-context/ folder using your agent's skill installer, or copy it into the agent's configured skill directory. It teaches the agent when to use rg, Scythe, and embeddings. npm installation or upgrades do not install or refresh this separate copy. See client-specific Skill locations and invocation.

MCP

Codex configuration example. For Claude Code and Antigravity CLI, see client-specific MCP registration.

For Codex on Linux, macOS, or WSL, add the following to ~/.codex/config.toml (or your configured Codex home), then restart the client. For native Windows or Windows App + WSL, use the platform setup guide.

[mcp_servers.scythe_context]
command = "npx"
args = ["-y", "scythe-context-mcp"]

Ask the agent to execute these MCP tool calls, not shell commands. Replace the path; reindex only when metadata is missing/stale:

repo_index_status({ "project_path": "/absolute/path/to/your/repo" })
repo_reindex({ "project_path": "/absolute/path/to/your/repo", "dry_run": false, "index_embeddings": false })
repo_context_pack({ "project_path": "/absolute/path/to/your/repo", "query": "auth token", "mode": "keyword" })

This example stays local by explicitly selecting keyword. If setup fails, use repo_doctor and troubleshooting.

What a result looks like

Actual CLI output from a two-file src/auth.ts / src/app.ts example, using the command above; the project path is normalized. Results depend on your repository:

Project: /absolute/path/to/your/repo
Mode: keyword
src/auth.ts:1-3
  keyword/path match
export function validateToken(token: string) {
  return token.length > 0;
}
Related: src/auth.ts (source)
Related: src/app.ts (source)
Suggested: src/auth.ts
Suggested: src/app.ts

The agent can read the returned ranges and follow related files. See the command and output reference for search, related, status, doctor, JSON, budgets, and saved results.

Language support

Text search works on supported text files. Structure and local navigation cover:

Language

Navigation coverage

JS / TS

Declarations, relative imports, config aliases/inheritance, explicit project references, declared workspace source exports.

Python

Declarations, flat/src packages, relative imports.

Go

Declarations and packages in the nearest go.mod module.

Rust

Declarations, Cargo file modules, anchored paths, literal library/binary target roots.

C#

Namespace/type/common method declarations and literal .csproj project references; using remains a hint.

C++

Namespace/type/common function declarations and exact file-relative quoted includes.

No target-language compiler or SDK is required. Navigation uses conservative source parsing, with language-specific limits; see language support and config-driven navigation. Older installs should read index upgrade notes.

Optional: embeddings

Use keyword first when likely source terms are known. When wording differences make local results insufficient, hybrid combines keyword and vector retrieval; semantic uses vectors alone. The Skill guides initial vector creation and updates when useful and within the task's authorized scope.

Embeddings require a Gemini-compatible endpoint. Vector indexing sends code chunks; hybrid/semantic queries send query text when matching code vectors exist. Provider charges may apply. Without matching vectors, hybrid falls back locally and semantic errors before sending a query. CLI defaults to keyword; MCP defaults to hybrid.

See semantic search, credentials, updates, and privacy. An API key alone neither creates vectors nor enables automatic CLI mode switching.

Limits and privacy

  • Indexes need refreshing after edits; there is no automatic watcher. Related files are navigation hints, not compiler binding or a complete runtime call graph.

  • Exclude private files with the root .gitignore. Keep .scythe-context/, legacy .repo-beacon/, .env, and local/ out of version control.

  • Retrieval benchmarks do not establish faster agent task completion or lower total token use. See the benchmark and task A/B protocol (Traditional Chinese).

More information

Available Tools

7 tools
gemini_embedding_probeGemini Embedding ProbeB

Send one embedding request and return diagnostics for official Gemini or proxy compatibility.

Inputs: text (required), project_path, response_mode.

repo_context_packRepo Context PackB

Preferred task-oriented code lookup for unknown file locations. Defaults to paths_only; use compact for short snippets and snippets for ranking/debug detail. Set mode=keyword for local lookup without embedding requests.

Inputs: query (required), mode, max_results, project_path, +11 more.

repo_doctorRepo DoctorB

Run local diagnostics for runtime, native modules, config, WSL interop, and index health without calling embedding APIs.

Inputs: project_path, response_mode.

repo_index_statusRepo Index StatusC

Show Scythe Context configuration and current index status.

Inputs: project_path, response_mode.

repo_reindexRepo ReindexC

Scan a project, write metadata, and optionally index embeddings.

Inputs: dry_run, project_path, response_mode, max_file_bytes, +6 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.2/5.0

    Scored across 7 tools

    Disambiguation4/5

    Most tools have clearly distinct purposes, with explicit guidance that repo_context_pack is preferred for normal lookup and repo_semantic_search is for debugging rankings. The main possible confusion is between the two lookup tools, and secondarily between repo_doctor and gemini_embedding_probe, but descriptions mitigate this well.

    Naming Consistency4/5

    All names use snake_case, and six of seven share a repo_ prefix, creating a mostly predictable pattern. The exception is gemini_embedding_probe, and the names mix noun phrases with action-oriented labels, preventing a perfect score.

    Tool Count5/5

    With 7 tools, the set is well-scoped for a context/indexing MCP server. Each tool has a clear role spanning diagnostics, indexing, status, search, and related-file lookup without obvious redundancy.

    Completeness4/5

    The server covers diagnostics, indexing lifecycle, status, semantic search, context packing, and related-file inspection, which addresses the core workflows. Minor gaps exist, such as no explicit index deletion/reset or project listing tool, but agents can likely work around them.

    Maintenance

    ActivityMaintained
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      B
      maintenance
      Enables semantic and keyword search over a local codebase by chunking source files along function and class boundaries, embedding them offline, and fusing vector and BM25 results. Runs entirely on your machine in a single SQLite file, so AI coding agents can find relevant code with no API keys, telemetry, or cloud calls.
      7
      11 npm
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables coding agents to search a locally indexed codebase with hybrid dense, lexical, and symbol-graph retrieval, returning ranked passages with exact file:line-line citations plus graph context and index status. It keeps its index in sync via a file watcher and runs as a local sidecar with no hosted service to deploy.
      25 PyPI
      1
      MIT
    • A
      license
      Not graded
      quality
      A
      maintenance
      Enables AI coding agents to pull focused, token-bounded context from a local structural code graph stored in SQLite, so they can locate relevant code, traverse relationships between entities, and carry recorded mistakes into later sessions instead of reading whole files. It also supports serving that context over an authenticated local HTTP dashboard.
      28 npm
      MIT
    • A
      license
      Not graded
      quality
      A
      maintenance
      Serves AI coding agents focused context from a project-local SQLite graph of source entities and Git relationships, so they can retrieve relevant code, trace callers/callees and impact, and carry recorded mistakes into later sessions without reading whole files. Queries render bounded, token-estimated packets while all indexing stays on the local machine.
      28 npm
      MIT