/**
 * MAU.3 — session-boundary memory reconcile.
 *
 * Flushes a project's authored auto-memories into the long-term RAG at session
 * end (import + refresh; NO delete — the no-auto-delete axiom
 * [[memory-architecture-dual-surface-sync]]). The SessionEnd hook carries no
 * cwd, so the dir is resolved from the cwd that PreToolUse recorded per session
 * (`readSessionCwd`). Extracted from the hook bin so it's unit-testable with
 * injected deps (the bin file runs `main()` on import).
 *
 * Failure policy: FAIL-LOUD (a silent reconcile failure is the exact drift this
 * track prevents — surface it on stderr) but NEVER throw / block session end
 * (hook fail-open contract). Engine-down → loud stderr, return cleanly.
 *
 * Imports from: node:fs/promises, node:os, node:path, ../../engine/client.js,
 *   ../../setup/migrate/auto_memory_snapshot.js, ../paths.js, ../session_state.js.
 * Imported by: src/runtime/hooks/session-end.ts; memory_reconcile.test.ts.
 */
import { type MemoryStore } from '../../setup/migrate/memory_store_handle.js';
/**
 * Encode a project path the way Claude Code names the auto-memory dir: every
 * `/` → `-`. Mirrors `encodeProjectPath` in `src/setup/cli/memory.ts`; inlined
 * (one line) so this module doesn't pull commander into the hook bundle.
 */
export declare function encodeProjectPath(projectPath: string): string;
export interface ReconcileDeps {
    /** Defaults to `readSessionCwd` (per-session cwd recorded by PreToolUse). */
    readCwd?: (sessionId: string) => Promise<string | null>;
    /** Defaults to `~/.claude/projects`. */
    autoMemoryRoot?: string;
    /** Defaults to a real libSQL-backed `makeMemoryStore`. */
    storeFactory?: () => Promise<MemoryStore>;
    /** Defaults to `OPENSQUID_HOME()`. */
    opensquidHome?: () => string;
    /** Defaults to `process.stderr.write`. */
    stderr?: (s: string) => void;
}
export declare function reconcileMemoryOnSessionEnd(sessionId: string, deps?: ReconcileDeps): Promise<void>;
//# sourceMappingURL=memory_reconcile.d.ts.map