search

search is a command for Claude Code from skymanbp/rag-your-code. It costs 29 tokens per session (618 once invoked), scanned A, original, MIT.

A command that searches a code repository using a plain-language question and reports the declarations that answer it. It includes each result's file, line range, matching words, and surrounding code context.

In plain words
What is it for?
Use it to find functions, classes, or other declarations related to a question, optionally including their callers, callees, or containing code.
Why use it?
It shortens the path from a coding question to the relevant implementation. It also makes results easier to verify by showing exactly where the supporting code is located.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter.

Part of the rag-your-code plugin — 1 skill, 4 commands shipped together

Good fit Use it to find functions, classes, or other declarations related to a question, optionally including their callers, callees, or containing code.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/skymanbp/rag-your-code/search
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.

Clone the repo
git clone --depth 1 https://github.com/skymanbp/rag-your-code

Made for: Claude Code.

Or install rag-your-code, the plugin that ships this one along with the rest of its 1 skill, 4 commands.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for search

README.md
[![agentmods](https://agentmods.dev/badge/commands/skymanbp/rag-your-code/search/github.svg)](https://agentmods.dev/commands/skymanbp/rag-your-code/search)
Your own site
<a href="https://agentmods.dev/commands/skymanbp/rag-your-code/search"><img src="https://agentmods.dev/badge/commands/skymanbp/rag-your-code/search/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for search

Your own site · 80×15
<a href="https://agentmods.dev/commands/skymanbp/rag-your-code/search"><img src="https://agentmods.dev/badge/commands/skymanbp/rag-your-code/search.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 29 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 618 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00029 $0.00618
Opus 5.5 $0.00012 $0.00247
Sonnet 5.5 $0.00006 $0.00124
Haiku 4.5 $0.00003 $0.00062

Measured 2mo ago against content hash 04f3324b3ac8, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

search 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 2mo ago.

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.

commands/search.md · 57 lines

How it starts

The opening of the file, as written. The whole thing — 57 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Retrieve focused context for: $ARGUMENTS

What to do

python -m ragyourcode.cli search "$ARGUMENTS" --json --limit 8

Add --graph --hops 1 when callers, callees or containment are relevant. Prefer one hop; use two only when the first produced concrete edge evidence.

Then read the returned files and line ranges directly before saying anything about the code. Results are navigation, not the file: results carries the identifier, path, line range, signature, description, score and matched terms, and the code arrives once in context, trimmed to a budget. omitted_for_budget says how many results the context did not reach — read those from the path and line range each result reports, or raise --max-chars. (open is an action of the JSON-lines agent protocol, not a subcommand.)

Cite every claim as path:line, taken from the result rather than remembered.

Matching is lexical by default

The default embedder is a feature hash, so a query sharing no word with a unit scores zero against it — synonyms do not match. Ask in the vocabulary the code uses: prefer retry charge gateway timeout over "重试扣款失败", and try two or three wordings before concluding something is absent.

An empty result is an answer, not a failure

Retrieval returns nothing rather than the unit that ranked least badly. Read diagnosis.reason:

reason what it means what to do
no_query_term_in_index no word of the question is here re-ask in the code's vocabulary, or check the index root
only_ubiquitous_terms_matched only words used throughout matched add a term specific to what you want
too_little_of_the_query_matched most of the question is absent ask something narrower, or write descriptions
matched_terms_are_scattered the words are here, never together the subject is probably not in this repository — say so and stop

Never respond by lowering search.min_coverage or search.min_concentration. That restores the guessing this exists to prevent. If two or three rephrasings all come back empty, report that the repository does not appear to contain it — do not keep going until something is returned.

Read the full file on GitHub · 57 lines

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. 2mo ago First seen · 57 lines · 29 tokens per session scan A 04f3324b3ac8

Subscribe to this mod's changes

search is a command published in the GitHub repository skymanbp/rag-your-code (1 stars, last pushed 2mo ago), licensed MIT. It adds 29 tokens to every session and 618 once invoked, about $0.0001 per session on Opus 5.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

search compared with commands from other repositories

search next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
searchskymanbp/rag-your-codeCommand12mo agoMITA29Claude Code
carryover5dive-ai/5dive-pluginsCommand2yesterdayApache-2.0A14Claude Code
gov-code-searchtractorjuice/arckit-claudeCommand64d agononeA13Claude Code
ccc-reindexiliaal/ccc-pluginCommand16mo agoMITA27Claude Code
memorygreppable/greppable-cc-pluginCommand36mo agoMITB19Claude Code
goalNova-Violet-Role/RoT-DTD-GOALCommand22mo agononeA30Claude Code
goal-swarmNova-Violet-Role/RoT-DTD-GOALCommand22mo agononeA0Claude Code