diff --git a/src/auto-reply/reply/agent-runner-helpers.test.ts b/src/auto-reply/reply/agent-runner-helpers.test.ts index 5aaab51fec33..4c4df30434c6 100644 --- a/src/auto-reply/reply/agent-runner-helpers.test.ts +++ b/src/auto-reply/reply/agent-runner-helpers.test.ts @@ -1,3 +1,4 @@ +// Tests agent runner helper decisions for payload and runtime preparation. import { beforeEach, describe, expect, it, vi } from "vitest"; import type { ReplyPayload } from "../types.js"; import type { TypingSignaler } from "./typing-mode.js"; diff --git a/src/auto-reply/reply/agent-runner-memory.test.ts b/src/auto-reply/reply/agent-runner-memory.test.ts index d97621c87dcc..e0e4179988a0 100644 --- a/src/auto-reply/reply/agent-runner-memory.test.ts +++ b/src/auto-reply/reply/agent-runner-memory.test.ts @@ -1,3 +1,4 @@ +// Tests agent runner memory flush and persisted memory context handling. import fsCore from "node:fs"; import fs from "node:fs/promises"; import os from "node:os"; diff --git a/src/auto-reply/reply/commands-abort-trigger.test.ts b/src/auto-reply/reply/commands-abort-trigger.test.ts index 03bb39d989cb..adf7b4505973 100644 --- a/src/auto-reply/reply/commands-abort-trigger.test.ts +++ b/src/auto-reply/reply/commands-abort-trigger.test.ts @@ -1,3 +1,4 @@ +// Tests abort trigger command parsing and cancellation requests. import { beforeEach, describe, expect, it, vi } from "vitest"; import type { OpenClawConfig } from "../../config/config.js"; import { handleAbortTrigger } from "./commands-session-abort.js"; diff --git a/src/auto-reply/reply/commands-approve.ts b/src/auto-reply/reply/commands-approve.ts index fb67d79deb7b..409cece08a07 100644 --- a/src/auto-reply/reply/commands-approve.ts +++ b/src/auto-reply/reply/commands-approve.ts @@ -1,3 +1,4 @@ +// Implements approval commands for pending tool and execution requests. import { normalizeLowercaseStringOrEmpty } from "@openclaw/normalization-core/string-coerce"; import { getChannelPlugin, diff --git a/src/auto-reply/reply/commands-core.runtime.ts b/src/auto-reply/reply/commands-core.runtime.ts index a95f4e6e028b..5b58c9411572 100644 --- a/src/auto-reply/reply/commands-core.runtime.ts +++ b/src/auto-reply/reply/commands-core.runtime.ts @@ -1 +1,2 @@ +// Runtime barrel for command handlers that need lazy production imports. export { emitResetCommandHooks } from "./commands-reset-hooks.js"; diff --git a/src/auto-reply/reply/commands-export-trajectory.ts b/src/auto-reply/reply/commands-export-trajectory.ts index 2da58c3f623c..17dd6eccaa4b 100644 --- a/src/auto-reply/reply/commands-export-trajectory.ts +++ b/src/auto-reply/reply/commands-export-trajectory.ts @@ -1,3 +1,4 @@ +// Implements trajectory export command packaging for the active session agent. import { resolveSessionAgentId } from "../../agents/agent-scope.js"; import { createExecTool } from "../../agents/bash-tools.js"; import type { ExecToolDetails } from "../../agents/bash-tools.js"; diff --git a/src/auto-reply/reply/commands-openclaw-cli.ts b/src/auto-reply/reply/commands-openclaw-cli.ts index 4eb0f91a53c6..d4b0c203e28c 100644 --- a/src/auto-reply/reply/commands-openclaw-cli.ts +++ b/src/auto-reply/reply/commands-openclaw-cli.ts @@ -1,3 +1,4 @@ +// Formats OpenClaw CLI command snippets for chat-facing command responses. function quoteShellArg(value: string): string { if (process.platform === "win32") { return `'${value.replaceAll("'", "''")}'`; diff --git a/src/auto-reply/reply/commands-plugin.test.ts b/src/auto-reply/reply/commands-plugin.test.ts index a66b31cd2fe5..6250d217a3ab 100644 --- a/src/auto-reply/reply/commands-plugin.test.ts +++ b/src/auto-reply/reply/commands-plugin.test.ts @@ -1,3 +1,4 @@ +// Tests plugin command dispatch and plugin-scoped command aliases. import { beforeEach, describe, expect, it, vi } from "vitest"; import type { OpenClawConfig } from "../../config/config.js"; import { handlePluginCommand } from "./commands-plugin.js"; diff --git a/src/auto-reply/reply/commands-session-restart.test.ts b/src/auto-reply/reply/commands-session-restart.test.ts index 990854790a6f..7d281046ed8c 100644 --- a/src/auto-reply/reply/commands-session-restart.test.ts +++ b/src/auto-reply/reply/commands-session-restart.test.ts @@ -1,3 +1,4 @@ +// Tests session restart command behavior and runtime reset handoff. import { beforeEach, describe, expect, it, vi } from "vitest"; import type { RestartSentinelPayload } from "../../infra/restart-sentinel.js"; import type { scheduleGatewaySigusr1Restart } from "../../infra/restart.js"; diff --git a/src/auto-reply/reply/commands-session-store.ts b/src/auto-reply/reply/commands-session-store.ts index 96de4f53a70f..7388c45a86fe 100644 --- a/src/auto-reply/reply/commands-session-store.ts +++ b/src/auto-reply/reply/commands-session-store.ts @@ -1,3 +1,4 @@ +// Shared session-store helpers for command handlers that mutate sessions. import type { SessionEntry } from "../../config/sessions.js"; import { updateSessionStore } from "../../config/sessions.js"; import { applyAbortCutoffToSessionEntry, type AbortCutoff } from "./abort-cutoff.js"; diff --git a/src/auto-reply/reply/commands-status-subagents.ts b/src/auto-reply/reply/commands-status-subagents.ts index ee51a0ad36ca..bb293d1f524c 100644 --- a/src/auto-reply/reply/commands-status-subagents.ts +++ b/src/auto-reply/reply/commands-status-subagents.ts @@ -1,3 +1,4 @@ +// Formats subagent status rows for the status command response. import type { SubagentRunRecord } from "../../agents/subagent-registry.types.js"; import { formatDurationCompact } from "../../infra/format-time/format-duration.ts"; import { formatRunLabel, sortSubagentRuns } from "./subagents-utils.js"; diff --git a/src/auto-reply/reply/commands-status.runtime.ts b/src/auto-reply/reply/commands-status.runtime.ts index f272eba9f9bf..f12c76c485e4 100644 --- a/src/auto-reply/reply/commands-status.runtime.ts +++ b/src/auto-reply/reply/commands-status.runtime.ts @@ -1,2 +1,3 @@ +// Runtime barrel for status command helpers loaded outside core command setup. export { buildStatusReply } from "./commands-status.js"; export { buildStatusText } from "../../status/status-text.js"; diff --git a/src/auto-reply/reply/commands-steer.test.ts b/src/auto-reply/reply/commands-steer.test.ts index 761c34ca1e07..eec6c039d7c9 100644 --- a/src/auto-reply/reply/commands-steer.test.ts +++ b/src/auto-reply/reply/commands-steer.test.ts @@ -1,3 +1,4 @@ +// Tests steer command persistence and retrieval for session guidance. import { beforeEach, describe, expect, it, vi } from "vitest"; import type { OpenClawConfig } from "../../config/types.openclaw.js"; import { buildCommandTestParams } from "./commands.test-harness.js"; diff --git a/src/auto-reply/reply/commands-tasks.test.ts b/src/auto-reply/reply/commands-tasks.test.ts index 134b188e00a7..6886b5ab7fb7 100644 --- a/src/auto-reply/reply/commands-tasks.test.ts +++ b/src/auto-reply/reply/commands-tasks.test.ts @@ -1,3 +1,4 @@ +// Tests task command routing and persisted task state replies. import { afterEach, beforeEach, describe, expect, it, vi } from "vitest"; import { resolveSessionAgentId } from "../../agents/agent-scope.js"; import { diff --git a/src/auto-reply/reply/completion-delivery-policy.ts b/src/auto-reply/reply/completion-delivery-policy.ts index 33377b42fc06..c9c20c21db5b 100644 --- a/src/auto-reply/reply/completion-delivery-policy.ts +++ b/src/auto-reply/reply/completion-delivery-policy.ts @@ -1,3 +1,4 @@ +// Resolves whether completed replies should send visibly or stay tool-only. import { normalizeChatType, type ChatType } from "../../channels/chat-type.js"; import type { OpenClawConfig } from "../../config/types.openclaw.js"; import { deriveSessionChatTypeFromKey } from "../../sessions/session-chat-type-shared.js"; diff --git a/src/auto-reply/reply/dispatch-acp-delivery.test.ts b/src/auto-reply/reply/dispatch-acp-delivery.test.ts index 92181e52a604..7b3079e4d30d 100644 --- a/src/auto-reply/reply/dispatch-acp-delivery.test.ts +++ b/src/auto-reply/reply/dispatch-acp-delivery.test.ts @@ -1,3 +1,4 @@ +// Tests ACP dispatch delivery routing and visible reply handoff. import { beforeEach, describe, expect, it, vi } from "vitest"; import type { OpenClawConfig } from "../../config/config.js"; import { createAcpDispatchDeliveryCoordinator } from "./dispatch-acp-delivery.js"; diff --git a/src/auto-reply/reply/get-reply-directives-apply.test.ts b/src/auto-reply/reply/get-reply-directives-apply.test.ts index abf6875fde03..89ab8324e868 100644 --- a/src/auto-reply/reply/get-reply-directives-apply.test.ts +++ b/src/auto-reply/reply/get-reply-directives-apply.test.ts @@ -1,3 +1,4 @@ +// Tests applying parsed directives to get-reply execution options. import { describe, expect, it } from "vitest"; import { formatModelOverrideResetEvent } from "./get-reply-directives-apply.js"; diff --git a/src/auto-reply/reply/get-reply-run.exec-hint.test.ts b/src/auto-reply/reply/get-reply-run.exec-hint.test.ts index efcfcea62762..ac8afa1bc66d 100644 --- a/src/auto-reply/reply/get-reply-run.exec-hint.test.ts +++ b/src/auto-reply/reply/get-reply-run.exec-hint.test.ts @@ -1,3 +1,4 @@ +// Tests execution hint propagation through get-reply run setup. import { describe, expect, it } from "vitest"; import type { SessionEntry } from "../../config/sessions.js"; import type { TemplateContext } from "../templating.js"; diff --git a/src/auto-reply/reply/get-reply.config-override.test.ts b/src/auto-reply/reply/get-reply.config-override.test.ts index 0bfd74c428b9..384b3cb7be81 100644 --- a/src/auto-reply/reply/get-reply.config-override.test.ts +++ b/src/auto-reply/reply/get-reply.config-override.test.ts @@ -1,3 +1,4 @@ +// Tests get-reply config override handling for a single inbound turn. import { afterEach, beforeEach, describe, expect, it, vi } from "vitest"; import type { OpenClawConfig } from "../../config/config.js"; import { diff --git a/src/auto-reply/reply/mcp-commands.ts b/src/auto-reply/reply/mcp-commands.ts index 506efe015df5..b50ed56499e0 100644 --- a/src/auto-reply/reply/mcp-commands.ts +++ b/src/auto-reply/reply/mcp-commands.ts @@ -1,3 +1,4 @@ +// Implements MCP server command parsing and persisted enablement settings. import { parseStandardSetUnsetSlashCommand } from "./commands-setunset-standard.js"; export type McpCommand = diff --git a/src/auto-reply/reply/reply-dispatcher.ts b/src/auto-reply/reply/reply-dispatcher.ts index 3e1e443e8786..123888534dcd 100644 --- a/src/auto-reply/reply/reply-dispatcher.ts +++ b/src/auto-reply/reply/reply-dispatcher.ts @@ -1,3 +1,4 @@ +// Dispatches final reply payloads through visible senders and message tools. import type { TypingCallbacks } from "../../channels/typing.js"; import type { HumanDelayConfig } from "../../config/types.js"; import type { OpenClawConfig } from "../../config/types.openclaw.js"; diff --git a/src/auto-reply/reply/route-reply.test.ts b/src/auto-reply/reply/route-reply.test.ts index 6830e568bca5..3499e6af603a 100644 --- a/src/auto-reply/reply/route-reply.test.ts +++ b/src/auto-reply/reply/route-reply.test.ts @@ -1,3 +1,4 @@ +// Tests routeReply delivery decisions across channels and fallback paths. import { afterEach, beforeEach, describe, expect, it, vi } from "vitest"; import type { ChannelMessagingAdapter, diff --git a/src/auto-reply/reply/routing-policy.test.ts b/src/auto-reply/reply/routing-policy.test.ts index cd25209876c9..274a91666c65 100644 --- a/src/auto-reply/reply/routing-policy.test.ts +++ b/src/auto-reply/reply/routing-policy.test.ts @@ -1,3 +1,4 @@ +// Tests reply routing policy decisions for direct, group, and private routes. import { describe, expect, it } from "vitest"; import { resolveReplyRoutingDecision } from "./routing-policy.js"; diff --git a/src/auto-reply/reply/session-run-accounting.ts b/src/auto-reply/reply/session-run-accounting.ts index c67590652523..2fe4118f3448 100644 --- a/src/auto-reply/reply/session-run-accounting.ts +++ b/src/auto-reply/reply/session-run-accounting.ts @@ -1,3 +1,4 @@ +// Tracks per-session run usage totals and last-run accounting facts. import { deriveSessionTotalTokens, type NormalizedUsage } from "../../agents/usage.js"; import type { OpenClawConfig } from "../../config/types.openclaw.js"; import { incrementCompactionCount } from "./session-updates.js";