/** * `openlore status` — what this repository's index IS, right now * (change: make-index-self-state-honest). * * The product could already answer "can I reach the embedding endpoint" (`doctor`) and * "what is in the graph" (`orient`), but not the question an agent asks constantly and a * human asks after every upgrade: what mode am I actually being served, how old is the * index, and is it behind what I just edited. On 2026-09-20 answering it meant opening * `.openlore/analysis/vector-index-meta.json` by hand in two repositories. * * Read-only by construction: it opens no lock, writes no artifact, and starts no build. */ import { Command } from 'commander'; import { type RetrievalMode } from '../../core/analyzer/embedder.js'; import { type IndexEmbedFailure } from '../../core/analyzer/analysis-indexes.js'; /** * Why keyword retrieval is being served. The distinction the config spec draws: an * unconfigured keyword index is the first-class default, a configured-but-unrealized one * is a finding. */ export type KeywordCause = 'no-provider-configured' | 'configured-provider-unrealized' | null; export interface IndexStatus { indexPresent: boolean; /** The mode a query would actually be served right now. */ retrievalMode: RetrievalMode | null; /** Set only when the served mode is a keyword one. */ keywordCause: KeywordCause; /** Provider named by configuration, if any. */ configuredProvider: string | null; builtAt: string | null; /** Files changed in the working tree since the index was built. */ staleFiles: string[]; /** True when the count was capped rather than complete. */ staleFilesTruncated: boolean; /** Git or the index build time was unavailable, so freshness cannot be asserted. */ staleFilesUnknown?: true; /** A failure recorded outside a full build (the watcher's incremental embed). */ embedFailure?: IndexEmbedFailure; /** Degradations recorded by the last build. */ degraded: Array<{ index: string; reason: string; }>; /** Present when the configuration could not be read at all. */ configUnreadable?: true; } /** Collect the index's self-state without mutating anything. */ export declare function collectIndexStatus(rootPath: string): Promise; export declare const statusCommand: Command; //# sourceMappingURL=status.d.ts.map