list_repos
List all indexed repositories with metadata
How to use it
list_repos is exposed by the Narsil MCP MCP server. Add the server to your MCP client (Claude Desktop, Cursor, Windsurf and others), and the list_repos tool becomes available to the model automatically. See the full listing for setup details and every tool this server provides.
Install Narsil MCP
npx @modelcontextprotocol/inspector ./target/release/narsil-mcp --repos ./path/to/repoOther tools in Narsil MCP (39)
Auto-discover repositories in a directory
Find path between two functions
Find unreachable code blocks
Assignments that are never read
Find all references to a symbol
Find Type-3/4 semantic clones of a function
Find code similar to a snippet (TF-IDF)
Find code similar to a symbol
Cross-file symbol usage with imports
Find structs, classes, functions by type/pattern
Variables used before initialization
Get call graph for repository/function
Find functions called by a function
Find functions that call a function
Statistics about code chunks
Get AST-aware chunks for a file
Get cyclomatic/cognitive complexity
Get CFG showing basic blocks and branches
Variable definitions and uses
Analyze imports and dependents
Embedding index statistics
Extract code around specific lines with context
Get exported symbols from a file/module
Get file contents with optional line range
Find highly connected functions
Show index stats and enabled features
Neural embedding index statistics
Get directory tree with file icons and sizes
Which assignments reach each point
Get symbol source with surrounding context
Combined BM25 + TF-IDF with rank fusion
Infer types for variables in a function without external type checkers
Semantic search using neural embeddings (finds similar code even with different names)
Trigger re-indexing of repositories
Search over AST-aware code chunks
Keyword search with relevance ranking
BM25-ranked semantic search
Check if path is a valid repository
Fuzzy search symbols across workspace