Skip to content

Quickstart

After installing, index a repository and ask it questions. Most answers come back in under a millisecond — queries are answered from RAM, not disk.

  1. Index the repository

    From the repository root:

    Terminal window
    basemind scan

    This walks the tree, parses with tree-sitter, and writes a content-addressed blob store + inverted index under .basemind/. Takes a few seconds for small repos, around 18 seconds for an 81k-file TypeScript monorepo.

  2. Find where a symbol is defined

    Terminal window
    basemind query symbol "parseQuery"

    Output:

    src/parser.rs:142:1 parseQuery (function)
    src/utils.rs:89:1 parseQuery (type alias)

    Now you know exactly where to read — no grep noise, no manual parsing.

  3. See what calls a function

    Terminal window
    basemind query references "processFile"

    Output:

    src/scanner.rs:142:9 processFile
    src/scanner.rs:201:13 processFile
    src/extract.rs:57:20 processFile

    Every place it’s called, with line and column numbers.

  4. Find who last touched a line

    Terminal window
    basemind git blame-file src/main.rs

    Or drill down to a single symbol:

    Terminal window
    basemind git blame-symbol src/main.rs "processFile"

    Shows the last commit, author, and timestamp for each line or symbol.

  5. Keep the index fresh

    As you edit, update the index with:

    Terminal window
    basemind watch

    This runs in the foreground and re-indexes on file changes. Or use basemind serve if you’re querying via the MCP server or plugin.

  • Index build: Seconds for small repos; the largest test case (81k TypeScript files) scans in around 18 seconds. Re-scans are much faster — only changed files are re-indexed.

  • Query latency: Under a millisecond for symbol and reference lookups. Call-graph searches in a few milliseconds. Git history lookups in tens of microseconds.

  • Outline before you read: Use outline to see a file’s structure (symbols, signatures, line numbers, imports) without opening it.

    Terminal window
    basemind query outline src/parser.rs

    Output shows every symbol and its line number, so you know exactly what to read.

If you’re using the plugin or MCP server instead of the CLI, you’re already indexed once you run /bm-scan or call the rescan MCP tool. From there, use the tools in the chat:

  • Find a definition: Call search_symbols with a name.
  • Find references: Call find_references with a name.
  • Browse before reading: Call outline on a file path.
  • Check git history: Call blame_symbol, recent_changes, or commits_touching.

All the same queries, just over the MCP surface instead of the CLI.