Inspection
Index statistics
Section titled “Index statistics”const stats = await indexer.getStats();List indexed files
Section titled “List indexed files”const files = await indexer.listFiles(); // relative paths of all indexed filesGet chunks for a file
Section titled “Get chunks for a file”const chunks = await indexer.getChunks('src/utils.ts');Repo map
Section titled “Repo map”An aider-style concise listing of all indexed files and their top-level symbols:
const map = await indexer.getRepoMap({ maxFiles?: number, // cap by file count (largest-symbol-count first) types?: ChunkType[], // default: function, class, interface, type, enum format?: 'text' | 'json', // default: 'text'});Example text output:
src/search/Searcher.ts class Searcher (18-112) function reciprocalRankFusion (118-150)
src/store/LanceDBStore.ts class LanceDBStore (22-380)