Skip to content

ollama_corpus_health

Corpus health. Health summary for indexed corpora. No Ollama call. Superset of ollama_corpus_list: staleness_days, embed_model_resolved, within-refresh :latest drift, failed_paths_count, write_complete, and per-corpus warnings[]. Optional name narrows to a single corpus (typos fail loud). Optional detailed: true adds a per-file list with mtime + stale_days. Use this as your go-to ‘is anything broken?’ check before search or refresh.

Parameter Type Required Default Description
name string no Single corpus to report on. When omitted, reports health for every corpus on disk.
detailed boolean no When true, each entry gets a per-file list with mtime + staleness days. Default false — cheaper.

The JSON Schema below is generated from the same zod schema the server validates against at the wire — it cannot drift from runtime behavior.

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"name": {
"description": "Single corpus to report on. When omitted, reports health for every corpus on disk.",
"type": "string",
"minLength": 1,
"pattern": "^[a-zA-Z0-9_-]+$"
},
"detailed": {
"description": "When true, each entry gets a per-file list with mtime + staleness days. Default false — cheaper.",
"type": "boolean"
}
}
}

Every tool returns the standard envelope — tier_used, model, tokens_in/tokens_out, elapsed_ms, backend provenance, warnings. See Envelope & tiers.

Schema + handler: src/tools/corpusHealth.ts · registration: src/index.ts


Back to the Tool Reference.