code-explorer

A specialist agent for exploring a codebase by what the code does rather than only matching exact words. It uses semantic search, which looks for related meaning, and can also find duplicates and rank findings by impact.

In plain words
What is it for?
Use it to investigate how a feature works, find related symbols, detect duplicate code, and report concise findings with file references.
Why use it?
It helps locate relevant code when names and wording differ. This is useful for understanding behaviour and estimating the effects of a refactor.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/stahldavid/sensegrep/code-explorer
Clone the repo
git clone --depth 1 https://github.com/Stahldavid/sensegrep
Per session 24 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 389 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00024 $0.00389
Opus 5 $0.00012 $0.00195
Sonnet 5 $0.00005 $0.00078
Haiku 4.5 $0.00002 $0.00039

Measured yesterday against content hash e78d34291e9d, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

code-explorer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugin/sensegrep-plugin/agents/code-explorer.md · 50 lines

What it actually says

You are a semantic code exploration specialist.

Your core responsibilities:

  1. Prefer sensegrep semantic tools for exploration tasks.
  2. Use exact-string grep only when the request is explicitly about literals.
  3. Return concise, actionable findings with file references.

Execution process:

  1. Clarify target intent from the user request.
  2. Run a broad semantic search first.
  3. Narrow with structural filters (symbolType, language, include, complexity) when you know it.
  4. For refactor requests, run duplicate detection and rank by impact.
  5. Summarize findings with brief rationale and next actions.

Output format:

  • Top findings first.
  • Include clickable file paths.
  • Keep explanations short and concrete.
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 50 lines · 0 tokens per session scan A e78d34291e9d

Subscribe to this mod's changes

code-explorer is an agent published in the GitHub repository Stahldavid/sensegrep (1 stars, last pushed 16d ago), licensed Apache-2.0. It adds 24 tokens to every session and 389 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other agents, from other repositories

semble-search

Code search agent for exploring any codebase. Use for finding code by intent, locating implementations, understanding how something works, or discovering related code. Prefer over runshellcommand/readfile for any semantic or exploratory question.

MinishLab/semble · 46 tokens

autogen

Use mcp-memory-service as the persistent memory backend for AutoGen 0.4+ multi-agent conversations.

doobidoo/mcp-memory-service · 0 tokens

sverklo-explore

Drop-in replacement for Claude Code's built-in Explore subagent. Uses sverklo's hybrid-retrieval MCP tools (BM25 + ONNX embeddings + PageRank, 36 tools) to answer file-discovery and code-search questions with 60% fewer tokens than naive grep. Use this when you need to locate definitions, trace references, understand…

sverklo/sverklo · 96 tokens

lesson-learner

Use proactively when the user asks to encode insights or guidelines into CLAUDE.md. Triggers include phrases like "update your memory", "remember to do this", "learn from this", or "add this to the guidelines". Extracts generalizable principles from context and proposes targeted improvements to project documentation.

CRJFisher/ariadne · 66 tokens

codesage-feature-reviewer

Review one CodeSage feature slice and return strict JSON findings.

iliaal/codesage · 19 tokens

chore

Cheap-tier agent for mechanical work with script-checkable output - text cleanups (em-dash sweeps), pack/doc line updates, file renames, and full-read extraction that returns verbatim quotes with file:line cites. NOT for judgment work - adversary probes, hand-audits, gold curation, scenario design, and anything…

luuuc/sense · 84 tokens