/** * `astramem-local memory health [--json] [--deep]` * * FEAT-444 AC-3: human-readable per-store health report, read-only (opens * the production DB directly, same key-aware/config-aware resolution as * doctor/budget/queue via openRuntimeDb() — no daemon needs to be running). * Exits 0 unconditionally; never mutates memories, memory_events, or * consolidation_proposals. * * `--deep` additionally runs the heavy CLI-only metrics (near-duplicate * estimate, junk heuristic, optional LLM-judged sample) from * server/queries/memory-health-deep.ts — these are NEVER run without the * flag, and NEVER wired into `doctor`'s default pass or `GET /health` (see * that module's file header for why). The LLM-judged sample additionally * requires `memoryHealth.llmJudgedJunkSample.enabled: true` in config.yaml * (AC-5) — `--deep` alone only runs the heuristic (no LLM call). */ import { type MemoryHealthReport } from '../server/queries/memory-health.js'; import { type NearDuplicateEstimate, type JunkHeuristicEstimate, type LlmJudgedJunkResult } from '../server/queries/memory-health-deep.js'; export interface MemoryHealthDeepSection { nearDuplicate: NearDuplicateEstimate; junk: JunkHeuristicEstimate; llmJudged: LlmJudgedJunkResult; } export interface MemoryHealthCliReport { report: MemoryHealthReport; deep?: MemoryHealthDeepSection; } export declare function memoryHealthCommand(args: string[]): Promise;