Code Search

2026-03-19

Search your codebase by keywords, by meaning, or both. Vast finds exact function names and conceptual matches in a single query.

Quick start

# Build the search index
8v search index .

# Search your code
8v search find "authentication"

The first command indexes all files in the current directory. The second searches them. By default, Vast searches by both keywords and meaning — so searching "login" also finds files about "authentication" and "credentials."

Search modes

# Default — finds by keywords AND meaning
8v search find "error handling patterns"

# Keywords only — fast, finds exact identifiers
8v search find "resolve_index_dir" --mode bm25

# Meaning only — finds conceptual matches
8v search find "deployment strategy" --mode semantic
ModeGood forExample
Default (hybrid)Most searches"how does auth work"
Keywords (--mode bm25)Function names, error codes, exact strings"resolve_index_dir"
Meaning (--mode semantic)Conceptual questions"how to handle user sessions"

Indexing

Before you can search, build an index:

8v search index .
8v search index /path/to/project

The index is stored in ~/.8v/index/ — it never touches your project directory. Vast respects .gitignore and skips target/, node_modules/, and similar directories.

Indexed file types: .rs, .ts, .tsx, .js, .jsx, .toml, .yaml, .yml, .md, .json

Everything runs locally. No API calls, no cloud. The embedding model runs on your CPU.

Find symbols

Extract functions, structs, enums, and traits from your code:

# All public symbols
8v search symbols .

# Filter by kind
8v search symbols . --kind function

# Include private symbols
8v search symbols . --private

# Single file
8v search symbols src/main.rs

Options

8v search find

FlagDefaultDescription
--modehybridhybrid, bm25, or semantic
--path.Directory to search
--limit10Maximum results
--formattexttext or json

8v search symbols

FlagDefaultDescription
--kindallfunction, struct, enum, trait, const, module, impl
--privatefalseInclude private symbols
--formattexttext or json

Performance

OperationTime
Index 825 files~30s
Keyword search<1ms
Meaning search~100ms
Combined search~100ms

Without an index

If you haven't built an index, search still works — it falls back to regex search (like ripgrep). You get keyword matching but not meaning-based results. Run 8v search index . to unlock the full experience.