import { registerStatusCommand } from "./commands/status.js";
import { registerViewCommand } from "./commands/view.js";
import { registerCompactionHook } from "./hooks/compaction-hook.js";
import { registerCompactionTrigger } from "./hooks/compaction-trigger.js";
import { registerObserverTrigger } from "./hooks/observer-trigger.js";
import { Runtime } from "./runtime.js";
import { registerRecallTool } from "./tools/recall-observation.js";
import { registerReadProjectObservationsTool } from "./tools/read-project-observations.js";
import { registerWriteProjectObservationTool } from "./tools/write-project-observation.js";
export default function observationalMemory(ext) {
    const runtime = new Runtime();
    // Log extension load so we can confirm it's running in serve mode.
    process.stderr.write("[obs-mem] extension loaded\n");
    registerObserverTrigger(ext, runtime);
    registerCompactionTrigger(ext, runtime);
    registerCompactionHook(ext, runtime);
    registerStatusCommand(ext, runtime);
    registerViewCommand(ext, runtime);
    registerRecallTool(ext);
    registerReadProjectObservationsTool(ext);
    registerWriteProjectObservationTool(ext);
}
