/basemind:basemind-git-historyfrom basemind
Explores git history without shelling out to git — recent commits, path-based queries, per-line and per-symbol blame, structural diffs, churn ranking, and symbol history over time.
Ships in basemind. 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.
Read when SKILL.md points to them.
basemind indexes git history and resolves blame and diffs at symbol resolution, backed by a
gix history index. Three tools cover it: git_log, git_blame and git_diff. They return
commits, authors, paths, and line/symbol attributions, structured and capped, for a fraction of
the cost of parsing git log / git blame output.
The tools are always loaded: call them directly, no tool search needed. Prefer them over shelling
out to git log, git blame, git status or git diff. Drop to raw git only when no tool covers
the question (staging, rebasing, anything that mutates history).
| Question | MCP call | CLI |
|---|---|---|
| "What changed recently?" | git_log {} | basemind git log |
| "Which commits touched file F?" | git_log {"path":"src/store.rs","limit":5} | basemind git log --path src/store.rs --limit 5 |
| "Which commits touched a directory?" | git_log {"path":"src/mcp/"} | basemind git log --path src/mcp/ |
| "Which commit mentions X?" | git_log {"query":"fix race"} | basemind git log --query "fix race" |
| "What did this author commit?" | git_log {"author":"ada"} | basemind git log --author ada |
| "When did symbol X change?" | git_log {"path":"src/store.rs","symbol":"open"} | basemind git log --path src/store.rs --symbol open |
| "Show one commit in full" | git_log {"rev":"HEAD~1"} | basemind git log --rev HEAD~1 |
| "Who wrote this file's lines?" | git_blame {"path":"src/store.rs"} | basemind git blame src/store.rs |
| "Who wrote these lines?" | git_blame {"path":"src/store.rs","line":120,"end_line":160} | basemind git blame src/store.rs --line 120 --end-line 160 |
| "Who wrote this symbol?" | git_blame {"path":"src/store.rs","symbol":"open"} | basemind git blame src/store.rs --symbol open |
| "What's dirty in the working tree?" | git_diff {} | basemind git diff |
| "What did I change in file F?" | git_diff {"path":"src/store.rs"} | basemind git diff src/store.rs |
| "Diff a file between revisions?" | git_diff {"path":"src/store.rs","from":"HEAD~1","to":"HEAD"} | basemind git diff src/store.rs --from HEAD~1 --to HEAD |
| "What symbols were added or removed?" | git_diff {"path":"src/store.rs","from":"HEAD~5","structural":true} | basemind git diff src/store.rs --from HEAD~5 --structural |
| "What's HEAD / branch?" | index_status {} | basemind status |
| "Where's the churn?" | CLI only | basemind git churn |
| "Commits whose changed paths match a regex?" | CLI only | basemind git by-path <regex> |
The CLI also keeps shorthands: git recent, git touching <path>, git search <query>,
git show <rev>, git symbol-history <path> <name>, git blame-symbol <path> <name>,
git status, git diff-outline <path>.
git_log {"limit":5}
→ {"commits":["612df7e3a1c4 chore(release): v0.15.0",
"1779b9902d5e fix(git-history,serve): address code-review findings", …],
"files":{"612df7e3a1c4":{"Cargo.toml":"modified",…},…}, …}
git_blame {"path":"crates/basemind-engine/src/scanner.rs","symbol":"process_file"}
→ per-line authorship of that function's span
git_diff {"path":"src/mcp/tools.rs","from":"HEAD~5","structural":true}
→ the symbols in `added` and `removed`, and the count of `common` ones
basemind serve to be running inside a git repository. Outside one
they answer with an error result saying so..git.git_log list commit is the string "<sha12> <summary>" (the sha's first 12 hex digits, which
every tool taking a revision resolves), with no author or time. A search by author writes
"<sha12> <author>: <summary>", since author matches part of a name or email and may select
several people. A symbol's history writes [introduced] or [removed] after the sha, and
[modified] only when a changed commit's summary itself starts with [. A list carries no date:
rev gives a commit's time. The recent list (no arguments)
and a directory list put the files in a top-level files: {"<sha>": {"<path>": "<change>"}}, where a merge lists only what it changed
against every parent. rev shows one commit with its full sha, author, author_email, time,
message body and files.git_log with no arguments is a recency window; use query or author to find a commit
arbitrarily far back. symbol needs path. limit defaults to 20 and caps at 100, and
limit: 0 is refused. A path that no commit reachable from HEAD touches and that is not on
disk is an error, for a file and for a directory.git_log with path + symbol reads one window of the commits touching the file per page.
When older commits remain the page returns next_cursor, and says truncated_reason: "span_limit"
when it is short or empty: follow the cursor until it is absent to reach every change back to
the introduction. A symbol the working tree no longer defines still has its history read. A
name no commit inspected so far defines either is named in unmatched (with the names the file
does define) on each empty page, and is an error on the last page.git_log with a directory path (one ending in /) pages the same way, 200 commits per page:
an empty page with truncated_reason: "span_limit" and a next_cursor is not the end of the
history, and unmatched says when nothing has touched the directory so far and it is not on
disk.git_log cursor is refused when the git-history index came up (or stopped answering) since
it was issued: the two order commits differently. Restart without cursor.git_log with rev holds the commit's file list to max_tokens and then sets budgeted, with
omitted counting the files left out.git_blame: line and end_line are 1-based and inclusive, and end_line defaults to line.
rev blames at a revision other than HEAD. A symbol is located in the file as it is at rev,
not in the working tree, so its lines (and a line passed to pick one of several) are that
revision's; a symbol that exists only uncommitted is "no symbol ... at HEAD". limit defaults to 100 hunks, counted after merging,
and the list is trimmed to max_tokens (default 6000), then sets budgeted. hunks is
["<line>[-<end_line>] <sha12>[ <source_path>]", ...], adjacent hunks of one commit merged;
source_path, the rest of the row (it may hold spaces), names the file the lines came from when
they moved there from another; the line they had there is not given (git_log {rev} and
code_read at that path read the old code). commits maps each sha to {author, time, summary}
once (time is unix seconds). A
symbol blame also carries the symbol's line / end_line.git_diff: path alone is that file's working-tree diff against HEAD; from defaults to HEAD
and to to the working tree. The response has from, to (a sha, or "working tree") and
hunks, plus present_at_from: false for a file added since from or present_at_to: false
for one deleted by to. A diff is cut at 200 hunks or 128 KiB of hunk
text and then sets truncated, truncated_reason (hunk_cap or byte_cap) and omitted (the
hunks left out); it has no cursor, so narrow it with a closer from / to. A structural diff
compares from against the indexed working tree, takes no to, and returns added, removed
and common, the count of unchanged symbols.git_diff {} lists at most 200 paths per status list, in path order, and leaves an empty list
out. A cut status sets
truncated, truncated_reason: "path_cap" and omitted; pass a directory path (one ending
in /) for the status under that directory. That narrowed status lists every untracked file on
its own and its is_clean is about the directory only. A directory that is not on disk and has
no changed path under it is an error; so is a directory given without the trailing slash.next_cursor ->
cursor. A cursor continues only the call that returned it (same arguments apart from limit
and max_tokens); on another query, or after HEAD moved, the call is an error: repeat it without
cursor. A shallow clone sets truncated with truncated_reason: "shallow_clone": absence is
then inconclusive. Every cut uses the same words: next_cursor alone when a page ended at
limit, budgeted when the token budget trimmed it, and truncated + truncated_reason for a
cut the caller did not ask for, with omitted counting the items left out where known.query is matched against the commit message and author against the author name and email,
each on its own field: {"query":"review","author":"alice"} is commits by alice that mention a
review. A search answered before the git-history index is ready covers only the subjects and
authors of the newest 10,000 commits and says so: truncated with
truncated_reason: "unindexed_scan"; retry shortly.symbol is an error listing each with its
lines: add line (any line inside the one you mean).binary: true and no hunks, a file over 4 MiB too_large: true. A path
that leaves the repository is refused.For code structure see basemind-code-search; for document search see basemind-documents; for
agent coordination see basemind-comms.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub goldziher/basemind --plugin basemind10 skills in this plugin
/basemindNavigate large or unfamiliar codebases via the basemind MCP server — outlines, symbol search, reference/caller lookups, commit history, blame, and diffs without reading source files. Reach for it whenever the user asks "where is X defined", "what calls Y", "what changed recently in Z", or whenever you're about to grep or open many files to find structural information./basemind-cliNavigate codebases and manage caches via the basemind CLI — outlines, symbol search, reference/caller lookups, git history, blame, and diffs. For headless scripting, CI, or when driving the CLI more efficiently than interactive MCP calls. Shares the same index as the MCP server./basemind-code-searchFind where code is defined and used without reading files — symbol search, file outlines, references, callers, implementations, dependents, and indexed regex over content. Reach for it whenever the user asks "where is X defined", "what calls Y", "what implements Z", "what's the shape of this file", or whenever you're about to grep or open files to learn structure./basemind-commsCoordinate with other agents working the same repo through basemind's agent_post, agent_inbox and agent_threads tools — threads, a per-actor read position, bodies inline. Reach for it whenever you start, finish, or hit a decision while collaborating, or to check whether another agent is already touching the code you're about to change./basemind-doctorDiagnose and recover basemind when it isn't working — MCP tools missing or erroring, "no index" / "no indexed files", empty results that shouldn't be empty, or the MCP server seems dead. Runs CLI checks (no MCP server required) and gives the client-specific way to reconnect the server./basemind-documentsSemantic search over documents via basemind's RAG store — PDFs, Office, HTML, email, Jupyter notebooks, and images (OCR), with cross-encoder reranking, keyword and named-entity (NER) filters, and per-document summaries. Reach for it whenever the user asks to "search the docs / PDFs", "find where a topic is discussed", or "what does the documentation say about X".Other plugins' skills for the same job