/** * In-memory usage counts mirrored into agent.db's `_usage` tables (see * {@link AgentStorage.recordUsage}), read synchronously on hot UI paths. * * - {@link commandUsage}: keyed by canonical slash-command name (builtin primary * name, `skill:`, custom/file/template name). {@link InputController} * records every submitted known command; `CombinedAutocompleteProvider` uses * the counts to break text-match-score ties. * - {@link hintUsage}: keyed by composer hint id; a hint retires once its * gesture has been used often enough (see `COMPOSER_HINTS`). * * Until {@link UsageCounter.load} resolves, hits stay in memory only — * headless paths and tests that never load a counter never open agent.db. */ import type { ComposerHintId } from "@oh-my-pi/pi-tui/prompt/composer-hints"; import { type UsageKind } from "../session/agent-storage.js"; /** Process-wide use counts for one {@link UsageKind}, keyed by `Name`. */ export declare class UsageCounter { #private; readonly kind: UsageKind; constructor(kind: UsageKind); /** Load persisted counts once per process; concurrent calls share one read. */ load(): Promise; get(name: Name): number; /** Increment a count; persists when the counter is loaded. */ record(name: Name): void; } /** Slash-command invocation counts. */ export declare const commandUsage: UsageCounter; /** Composer hint gesture counts. */ export declare const hintUsage: UsageCounter;