import fs from "node:fs/promises"; import path from "node:path"; import { logVerbose } from "../../globals.js"; import { createInternalHookEvent, triggerInternalHook } from "../../hooks/internal-hooks.js"; import { getGlobalHookRunner } from "../../plugins/hook-runner-global.js"; import { resolveAgentIdFromSessionKey } from "../../routing/session-key.js"; import type { HandleCommandsParams } from "./commands-types.js";
let routeReplyRuntimePromise: Promise<typeofimport("./route-reply.runtime.js")> | null= null;
function loadRouteReplyRuntime() {
routeReplyRuntimePromise ??= import("./route-reply.runtime.js"); return routeReplyRuntimePromise;
}
export type ResetCommandAction = "new" | "reset";
function parseTranscriptMessages(content: string): unknown[] { const messages: unknown[] = []; for (const line of content.split("\n")) { if (!line.trim()) { continue;
} try { const entry = JSON.parse(line); if (entry.type === "message" && entry.message) {
messages.push(entry.message);
}
} catch { // Skip malformed lines from partially-written transcripts.
}
} return messages;
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.