Identifies which repositories are indexed in Sourcerer before querying content, and helps expand scope to dependencies or upstream repos during investigation.
Ships in sourcerer. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
sourcerer.repos.list lists all indexed repos by git host. Each result is an org/repo that has at least one ref indexed. Start here. Avoid filters; it's cheap to run.sourcerer.repos.search ranks repos whose code best matches a free-text query. You can improve recall by adding search terms and using snake_case or PascalCase (e.g. "elastic es|ql disk_bbq" matches any hits for "elastic", "disk_bbq", "disk", "bbq"; "DiskBBQ" matches any hits for "diskbbq", "disk", "bbq"; "es|ql" matches any hits for "es|ql", "es", "ql"). Prefer repos with higher scores. Helps with deciding which repo(s) are most relevant to your work, not for finding specific files or code. Run this in parallel with (or right after) sourcerer.repos.list and cross-reference to handle false matches or missed matches.sourcerer.refs.list lists all indexed refs by repo. Each result row is one indexed ref; the distinct git.repo values in the results are the repos available to query. Prefer filtering only by git_org and git_repo, using * wildcards as needed.Start with the most specific pattern likely to match the question. Broaden only if the result is empty or you need more coverage.
| Scenario | Example call |
|---|---|
| Specific repo, confident | git_org: elastic, git_repo: elasticsearch |
| Repo family in one org | git_org: elastic, git_repo: elasticsearch* |
| All repos in one org | git_org: elastic, git_repo: * |
| Different org or upstream | git_org: apache, git_repo: lucene* |
| Cross-org fallback (expensive) | git_repo: * (no org filter) |
Avoid git_repo: * without an org filter unless you genuinely need all orgs - it returns every indexed ref and consumes many tokens.
From the result rows:
git.repo values - the repos available to query.git.ref_type - whether each repo has branches, tags, or both. Useful for knowing whether ref-resolution will find tags or needs to fall back to a branch.status - complete means fully indexed; indexing means an in-progress snapshot (content may be incomplete — prefer complete refs).A question about Elasticsearch's query parsing leads into how Lucene's QueryParser works underneath:
sourcerer.repos.list and sourcerer.refs.list(git_org: elastic, git_repo: elasticsearch) - confirm the repo and plan the search.refs.list(git_org: apache, git_repo: lucene*) - discover which Lucene repos are indexed.ref-resolution on the relevant Lucene repo to pin a commit, then query content.Each discovery call should be targeted - retrieve only what you need to plan the next step.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
/sourcerer:repo-discoveryfrom sourcerer
npx claudepluginhub elastic/sourcerer --plugin sourcerer5 skills in this plugin
/code-citationsUse whenever an answer names a code symbol, class, function, config key, endpoint, file, directory, or file extension - or makes any checkable claim about repository behavior (a default value, a version, a recall/latency figure, a behavioral guarantee). This is nearly every substantive answer this agent produces, so treat it as the default path, not an edge case reserved for explicit "cite your sources" requests./code-searchUse when you need to find where something is defined, understand how a feature is implemented, or explore an unfamiliar repo. Guides which tools to use and in what order./subagent-orchestrationUse when a request decomposes into multiple independent subtasks that can be worked on separately and combined afterward./ref-resolutionUse any time a branch, tag, or version in the user's question is ambiguous or unspecified - whether at the start of a question or mid-conversation (e.g. when comparing behavior across versions).Other plugins' skills for the same job