AgentStack
MCP unreviewed MIT Self-run

Frigg

mcp-bnomei-frigg · by bnomei

Fast local code intelligence for AI agents powered by AST Treesitter, SCIP, semantic search and a reranker

No reviews yet
0 installs
2 views
0.0% view→install

Install

$ agentstack add mcp-bnomei-frigg

Open-source listing — not yet scanned by AgentStack. Follow the source repository for install instructions.

Security review

⚠ Flagged

1 finding(s); flagged for manual review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures
  • high Pipes remote content directly into a shell (remote code execution).

What it can access

  • Network access Used
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

Are you the author of Frigg? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

frigg

[](https://crates.io/crates/frigg) [](https://github.com/bnomei/frigg/actions/workflows/ci.yml) [](#license) [](https://discordapp.com/users/bnomei) [](https://www.buymeacoffee.com/bnomei)

Frigg gives AI agents local, source-backed code search and navigation without sending whole repositories through every prompt.

It turns each repository into searchable, navigable context for Codex, Claude, Cursor, and other MCP clients: lexical and hybrid search, symbols, structural queries, definitions, references, bounded reads, and runtime health through one local MCP service.

Frigg is local-first OSS. It builds a repository model under .frigg/, serves it over MCP, and keeps the useful parts plain: a CLI, a local SQLite store, explicit client adoption, cacheable runtime state, and source-backed answers.

[](https://asciinema.org/a/1260121)

Why Frigg

AI coding agents need retrieval as much as generation: the right answer starts with the right repository evidence. Code Context Engine shows the local-index pattern for AI coding agents, where the agent searches through MCP instead of rereading whole files. Sourcegraph Code Search documents production code-intelligence primitives such as full-text search, regular expressions, symbol search, repository scoping, ranking, and code navigation. turbopuffer Hybrid Search shows why lexical/BM25 and vector signals are often combined with rank fusion and re-ranking. Frigg brings that shape to a local OSS MCP service for source-backed agent context.

For individuals, Frigg keeps coding agents grounded in local source instead of broad scans, whole-file dumps, and model-memory guesses. It helps an agent find the right files, read only the source windows it needs, follow symbols, and answer with concrete repository evidence.

For teams, Frigg standardizes how agents inspect a repository. frigg adopt, shared MCP config, CI-cacheable .frigg/ state, local safety boundaries, and repeatable search/navigation tools give every agent session the same evidence layer and vocabulary across large or unfamiliar codebases.

Use Frigg when shell scans stop being enough: broad discovery, exact source windows, symbol and call navigation, structural queries, optional semantic recall, and optional SCIP-backed precision.

What Frigg is not

Frigg is not an AI pair programmer, hosted code intelligence platform, IDE replacement, Copilot alternative, or generic semantic search product. MCP is the delivery channel, not the category; SQLite, Tree-sitter, semantic recall, and SCIP are implementation proof points, not the reason to adopt Frigg.

The narrow promise is source-backed context for AI agents: repository-aware search, navigation, and bounded reads that make agent work easier to verify.

What Frigg provides

  • One local MCP service that can serve multiple adopted repositories.
  • Local state in .frigg/storage.sqlite3.
  • Tree-sitter-backed document symbols and structural search for Rust, PHP, Blade, TypeScript / TSX, Python, Go, Kotlin / KTS, Java, Lua, Roc, and Nim.
  • Direct literal, safe-regex, and rg-shaped code scans with search_text.
  • Broad discovery with search_hybrid, blending lexical, path, graph, witness, optional semantic, and code-aware ranking signals.
  • Known-identifier lookup with search_symbol.
  • Bounded source reads with read_file and read_match.
  • Definitions, declarations, references, implementations, incoming calls, and outgoing calls.
  • Optional semantic indexing with local, OpenAI, or Google embedding providers.
  • Optional SCIP artifact ingestion and generator assistance for more precise navigation.
  • Built-in watch refreshes behind frigg serve.

Quickstart

1. Install Frigg

Fast path on macOS or GNU/glibc Linux:

curl -fsSL https://raw.githubusercontent.com/bnomei/frigg/main/scripts/install.sh | FRIGG_VERSION=0.6.3 sh

The installer downloads the matching GitHub Release archive, verifies its .sha256, and installs the frigg binary to $HOME/.local/bin unless FRIGG_INSTALL_DIR is set. When FRIGG_VERSION is unset, it resolves the latest GitHub Release.

Other install surfaces:

| Channel | Command | | --- | --- | | GitHub Release installer | curl -fsSL https://raw.githubusercontent.com/bnomei/frigg/main/scripts/install.sh \| sh | | Cargo prebuilt binary | cargo binstall frigg | | Cargo source fallback | cargo install frigg | | npm wrapper | npx @bnomei/frigg --version | | Docker image | docker run --rm ghcr.io/bnomei/frigg:0.6.3 --version | | Scoop | scoop bucket add frigg https://github.com/bnomei/scoop-frigg && scoop install frigg |

The prebuilt paths are the point: one local binary, no Python 3.11+ runtime, no local C compiler, and no ONNX model download unless you explicitly enable the local semantic runtime.

Build from a local checkout:

git clone https://github.com/bnomei/frigg.git
cd frigg
cargo build --release -p frigg
target/release/frigg --version

Expected output:

frigg 0.6.3

Frigg's source currently requires Rust 1.88 or newer.

2. Index a repository

Run these commands from the repository you want Frigg to index:

frigg init
frigg index

Expected successful output includes:

ok init: complete status=ok
ok index: complete status=ok

From outside the repository, pass an explicit root:

frigg init --workspace-root /absolute/path/to/repo
frigg index --workspace-root /absolute/path/to/repo

3. Choose and start the MCP transport

Frigg supports stdio and HTTP MCP transports. Use this rule before choosing a client config:

| Workflow | Transport | | --- | --- | | One local MCP client, no subagents, and the client should own the Frigg process | Stdio | | More than one client, subagents, shared workflows, or long-running use | HTTP |

Stdio works, but it is a convenience transport for one local client. It is not the best match for Frigg once work becomes shared, long-running, or agentic. A stdio config makes the MCP client spawn and own a Frigg process. Another client or subagent usually means another Frigg process with its own lifecycle, session state, in-memory caches, and access to .frigg/storage.sqlite3.

HTTP gives Frigg a shared runtime:

  • One endpoint for all clients and subagents. Codex, Claude, Cursor, and worker agents can connect to the same 127.0.0.1:37444/mcp service instead of each spawning their own Frigg process.
  • Warm process state. Repository registry state, runtime task tracking, search/navigation caches, compiled safe-regex caches, and precise graph caches can live in one service process across client sessions.
  • Better freshness behavior. frigg serve is the long-lived service path, and built-in watch refreshes are designed around that shape. Stdio defaults to an ephemeral profile with watch disabled unless you explicitly opt in.
  • Lower local contention. One service coordinates access to .frigg/storage.sqlite3; several stdio processes can duplicate work and make SQLite lock contention harder to understand.
  • Clearer operations. A single HTTP service has one lifecycle, one log stream, one endpoint, loopback-by-default binding, and optional bearer auth for non-loopback use.

Use stdio only when one local MCP client should launch Frigg directly and no subagent or second client will share the same repository. Use HTTP for normal Frigg use.

For HTTP shared-service mode, run:

frigg serve

By default, frigg serve listens on loopback HTTP:

http://127.0.0.1:37444/mcp

Keep this process running while clients use Frigg. A server can start without startup roots, and MCP clients can attach repositories later. To preload known repositories at startup:

frigg serve \
  --workspace-root /absolute/path/to/repo-a \
  --workspace-root /absolute/path/to/repo-b

frigg serve is the HTTP service path. Do not use it in a stdio MCP config.

4. Add client configuration

Use frigg adopt to add managed Frigg instructions and MCP config entries to a project:

frigg adopt --target agents-md --target mcp-project --dry-run
frigg adopt --target agents-md --target mcp-project

Useful targets include agents-md, claude-md, gemini-md, copilot, cursor, mcp-project, mcp-cursor, and hook. Use --all to update every supported non-hook target, --check for a CI drift check, --uninstall to remove Frigg-managed entries, and --force to replace a diverged Frigg MCP JSON entry.

The managed MCP JSON entries use loopback HTTP, so keep frigg serve running while clients use Frigg.

Manual HTTP configuration for clients that accept JSON:

{
  "mcpServers": {
    "frigg": {
      "transport": "streamable_http",
      "url": "http://127.0.0.1:37444/mcp"
    }
  }
}

Manual CLI examples:

claude mcp add --transport http frigg http://127.0.0.1:37444/mcp
codex mcp add frigg --url http://127.0.0.1:37444/mcp

Manual stdio configuration for a single local client:

{
  "mcpServers": {
    "frigg": {
      "command": "frigg",
      "args": ["--workspace-root", "/absolute/path/to/repo"]
    }
  }
}

This uses stdio because there is no serve subcommand and no --mcp-http-port. The MCP client owns the Frigg process lifetime. Use this only for one local client with no subagents; switch to HTTP as soon as another client or subagent needs the same Frigg runtime.

5. Use Frigg from an MCP client

The normal MCP loop is:

  1. Omit repository_id in normal single-repo work. Frigg uses the session default, adopted repositories, or auto-adopts a sensible default when possible.
  2. Call workspace only when you want compact workspace status or need to adopt a specific path or repository_id.
  3. Use list_files when you would otherwise run rg --files, find, or fd.
  4. Use workspace when you need the session default, known repositories, or runtime task state.
  5. Use search_hybrid for broad discovery when you do not have an exact string, symbol, or path anchor.
  6. Use search_text for literal, safe-regex, and rg-shaped matches.
  7. Use search_symbol for known identifiers.
  8. Use read_match when a search or navigation result returned result_handle plus match_id.
  9. Use read_file when you already know the canonical repository-relative path.
  10. Use navigation and structure tools for definitions, references, implementations, calls, outlines, syntax trees, and structural queries.

Shell replacement map:

| Shell habit | Frigg tool | | --- | --- | | rg --files | list_files | | rg -n "text" | search_text | | rg -n "foo\|bar" | search_text with pattern_type=regex | | rg -n "text" path/ | search_text with path_regex | | identifier/API/type/class/function lookup | search_symbol | | cat path | read_file | | sed -n '10,80p' path | read_file with start_line, end_line, or line_count | | follow definitions/references/calls | navigation tools |

search_text is the Frigg surface for the same class of code scans agents often run with rg: known literals, safe regexes, grouped alternation, path_regex narrowing, context windows, per-file limits (max_count_per_file), and "which files contain this?" probes with files_with_matches. Frigg may execute the lexical work with its native scanner or with its ripgrep accelerator; either path still returns repository-scoped matches, canonical paths, result_handle, and per-row match_id values.

For example, this rg scan:

rg -n 'PathBuf::from\(&.*path\)|Path::new\(&.*path\)|current_dir\(' crates

maps to:

{
  "query": "PathBuf::from\\(&.*path\\)|Path::new\\(&.*path\\)|current_dir\\(",
  "pattern_type": "regex",
  "path_regex": "^crates/.*\\.rs$",
  "context_lines": 1,
  "limit": 100
}

Use shell only for git state and diffs, non-code files, build/test output, generated or unindexed files, explicit live-disk verification, ripgrep-specific flags outside search_text, or unavailable Frigg results. When shell finds relevant code, return to Frigg for read_match, read_file, symbols, or navigation when possible.

Example prompts:

  • "Where is authentication bootstrapped?"
  • "Show me implementations of ProviderInterface."
  • "Who calls handleWebhook?"
  • "Which files are relevant to the checkout flow?"

For agent-facing usage guidance, use [skills/frigg-first-code-search](skills/frigg-first-code-search/). For runtime diagnosis, use the [Frigg Operator Runbook](docs/operator-runbook.md).

CLI reference

| Command | Purpose | | --- | --- | | frigg | Start the MCP server over stdio when no subcommand and no HTTP port are provided. | | frigg serve | Start the shared MCP service over loopback HTTP by default. | | frigg adopt | Add or remove managed Frigg entries in agent docs and MCP configs. | | frigg init | Create or repair .frigg/storage.sqlite3 without scanning source files. | | frigg index | Scan files, refresh the local search index, and refresh semantic rows when semantic runtime is enabled. | | frigg index --changed | Recheck files changed since the last index. | | frigg hash | Print the stable CI cache fingerprint as frigg-hash=. | | frigg context | Summarize context-efficiency JSONL logs when logging is enabled. |

frigg reindex remains a compatibility alias for frigg index.

MCP tool surface

Frigg exposes the extended MCP tool surface by default. Set FRIGG_MCP_TOOL_SURFACE_PROFILE=core to restrict the server to the stable core set.

Core tool groups:

  • Workspace status and adoption: workspace.
  • File listing: list_files.
  • Source reads: read_file, read_match.
  • Discovery: search_text, search_hybrid, search_symbol.
  • Navigation: find_references, go_to_definition, find_declarations, find_implementations, incoming_calls, outgoing_calls.
  • Structure: document_symbols, inspect_syntax_tree, search_structural.

Extended-only tools in default builds:

  • explore

Feature-gated extended-only playbook tools are available only when Frigg is compiled with --features playbook:

  • playbook_run
  • playbook_replay
  • playbook_compose_citations

Read tools default to text-first output. Request presentation_mode=json only when the caller needs structured fields such as path, byte ranges, or context-efficiency metadata. Search and navigation tools default to compact responses; request response_mode=full when diagnostics or selection notes matter.

Configuration

Precedence is CLI flag > environment variable > default.

| Flag / environment variable | Default | Meaning | | --- | --- | --- | | --workspace-root | Utility commands use the current directory; serve can start empty | Repository root Frigg may read and index. Repeatable. | | --max-file-bytes / FRIGG_MAX_FILE_BYTES | 2097152 | Maximum file size Frigg reads. | | --full-scip-ingest / FRIGG_FULL_SCIP_INGEST | true | Ingest full SCIP artifacts when present. | | --mcp-http-port | 37444 for frigg serve | HTTP port. | | --mcp-http-host | 127.0.0.1 when HTTP is enabled | HTTP bind host. | | --allow-remote-http | false | Required for non-loopback HTTP binds. | | --mcp-http-auth-token / FRIGG_MCP_HTTP_AUTH_TOKEN | unset | Bearer token for HTTP MCP requests. Required for non-loopback binds. | | --watch-mode / FRIGG_WATCH_MODE | auto | Watch mode: auto, on, or off. | | --watch-debounce-ms / FRIGG_WATCH_DEBOUNCE_MS | 2000 | Delay before a watch-triggered refresh starts. | | --watch-retry-ms / FRIGG_WATCH_RETRY_MS | 5000 | Retry delay after a failed watch refresh. | | --watch-manifest-fast-concurrency / FRIGG_WATCH_MANIFEST_FAST_CONCURRENCY | 1 | Maximum concurrent manifest-fast watch refreshes. | | --watch-semantic-followup-concurrency / FRIGG_WATCH_SEMANTIC_FOLLOWUP_CONCURRENCY | 1 | Maximum conc

Source & license

This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet — be the first.

Versions

  • v0.1.0 Imported from the upstream source.