diff --git a/packages/tui/src/component/dialog-config.tsx b/packages/tui/src/component/dialog-config.tsx index a78f77cfcef..7f65a07856c 100644 --- a/packages/tui/src/component/dialog-config.tsx +++ b/packages/tui/src/component/dialog-config.tsx @@ -117,7 +117,7 @@ export const settings: Setting[] = [ category: "Session", path: ["session", "verbosity"], description: "How much tool activity is shown in the chat", - default: "medium", + default: "low", values: ["low", "medium", "high"], keywords: ["detail", "activity", "summary", "transcript"], }, diff --git a/packages/tui/src/routes/session/grouping/session.ts b/packages/tui/src/routes/session/grouping/session.ts index a5ca9053760..d3d9b187e7a 100644 --- a/packages/tui/src/routes/session/grouping/session.ts +++ b/packages/tui/src/routes/session/grouping/session.ts @@ -29,7 +29,7 @@ export type SessionGroup = { /** Experimental transcript detail; undefined selects the default production rules. */ export type Verbosity = "low" | "medium" | "high" -export const defaultVerbosity: Verbosity = "medium" +export const defaultVerbosity: Verbosity = "low" export type SessionRow = SessionEntry | SessionGroup diff --git a/packages/tui/test/cli/tui/data.test.tsx b/packages/tui/test/cli/tui/data.test.tsx index 133ab498ab8..b0ae5a397ec 100644 --- a/packages/tui/test/cli/tui/data.test.tsx +++ b/packages/tui/test/cli/tui/data.test.tsx @@ -46,7 +46,7 @@ function emitEvent(events: ReturnType, event: OpenCode events.emit({ ...event, location: { directory } }) } -const config = createTuiResolvedConfig() +const config = createTuiResolvedConfig({ session: { verbosity: "medium" } }) function DataProvider(props: ParentProps) { return ( diff --git a/packages/tui/test/cli/tui/session-grouping.test.ts b/packages/tui/test/cli/tui/session-grouping.test.ts index da3ee07032c..50789739ed0 100644 --- a/packages/tui/test/cli/tui/session-grouping.test.ts +++ b/packages/tui/test/cli/tui/session-grouping.test.ts @@ -5,9 +5,9 @@ test("a pending tool does not hide a later tool reusing its call ID in another m const rows: SessionRow[] = [] const blocked = { messageID: "assistant-a", partID: "call-reused" } const later = { messageID: "assistant-b", partID: "call-reused" } - append(rows, blocked, { type: "tool", name: "read" }) + append(rows, blocked, { type: "tool", name: "read" }, rows.length, "medium") partitionPending(rows, new Set([blocked.partID])) - append(rows, later, { type: "tool", name: "read" }) + append(rows, later, { type: "tool", name: "read" }, rows.length, "medium") const group = rows[0] if (group.type !== "group" || group.kind !== "exploration") throw new Error("Expected exploration group") diff --git a/packages/tui/test/cli/tui/session-rows.test.ts b/packages/tui/test/cli/tui/session-rows.test.ts index 74d02136c32..e4a0313f8ff 100644 --- a/packages/tui/test/cli/tui/session-rows.test.ts +++ b/packages/tui/test/cli/tui/session-rows.test.ts @@ -6,11 +6,14 @@ import { SessionTurn } from "@opencode/util/session-turn" import { cacheReuseDrop, messageBoundaryIDs, - reduceSessionRows, + reduceSessionRows as reduceRows, sessionRowID, type SessionRow, } from "../../../src/routes/session/rows" +const reduceSessionRows = (messages: SessionMessageInfo[], inputs = new Set(), turnTokens = false) => + reduceRows(messages, inputs, turnTokens, "medium") + test("indexed tail footer calculations do not subscribe to an unrelated history prefix", () => { createRoot((dispose) => { try { diff --git a/packages/tui/test/config-v2.test.tsx b/packages/tui/test/config-v2.test.tsx index cd8c2096c8d..f97bf049a18 100644 --- a/packages/tui/test/config-v2.test.tsx +++ b/packages/tui/test/config-v2.test.tsx @@ -126,7 +126,7 @@ test("shows the TPS default in session settings", () => { test("shows transcript verbosity in session settings", () => { expect(settings.find((setting) => setting.path.join(".") === "session.verbosity")).toMatchObject({ category: "Session", - default: "medium", + default: "low", values: ["low", "medium", "high"], }) }) diff --git a/packages/tui/test/session-backfill-disclosure.test.tsx b/packages/tui/test/session-backfill-disclosure.test.tsx index 74da56651b9..4df911261e8 100644 --- a/packages/tui/test/session-backfill-disclosure.test.tsx +++ b/packages/tui/test/session-backfill-disclosure.test.tsx @@ -60,7 +60,10 @@ test("clicking a backfilled thought group toggles it", async () => { run({ app: { name: "test", version: "test", channel: "test" }, server: { endpoint: { url: server.url.toString() } }, - config: { get: async () => ({ animations: false, tabs: { enabled: false } }), update: async () => ({}) }, + config: { + get: async () => ({ animations: false, session: { verbosity: "medium" }, tabs: { enabled: false } }), + update: async () => ({}), + }, packages: { prepare: async () => ({ directory: "" }) }, args: { sessionID: session.id }, terminalHandoff: async () => ({ renderer: setup.renderer, mode: "dark", complete: () => {} }), diff --git a/packages/tui/test/session-dialog-resync.test.tsx b/packages/tui/test/session-dialog-resync.test.tsx index 4acbdf8f328..779102ff9b7 100644 --- a/packages/tui/test/session-dialog-resync.test.tsx +++ b/packages/tui/test/session-dialog-resync.test.tsx @@ -52,7 +52,7 @@ async function openDialogThenResync(target: string, dialog: string) { await using setup = await createAppFixture({ width: 112, height: 34, - config: { animations: false, tabs: { enabled: false } }, + config: { animations: false, session: { verbosity: "medium" }, tabs: { enabled: false } }, args: { sessionID: session.id }, fetch: (url) => { if (url.pathname === "/api/session") return json({ data: [session], cursor: {} }) diff --git a/packages/tui/test/session-group-navigation.test.tsx b/packages/tui/test/session-group-navigation.test.tsx index 868ed2b3447..94d3a73f185 100644 --- a/packages/tui/test/session-group-navigation.test.tsx +++ b/packages/tui/test/session-group-navigation.test.tsx @@ -97,6 +97,7 @@ test.each([ config: { get: async () => ({ animations: false, + session: { verbosity: "medium" }, tabs: { enabled: true, scope: "global" }, keybinds: { "session.messages_last_user": "ctrl+shift+u", "session.message.next": "ctrl+shift+n" }, }), diff --git a/packages/tui/test/session-history-interactions.test.tsx b/packages/tui/test/session-history-interactions.test.tsx index 71036ec3a44..217a4e8a29a 100644 --- a/packages/tui/test/session-history-interactions.test.tsx +++ b/packages/tui/test/session-history-interactions.test.tsx @@ -93,7 +93,7 @@ test.each(modes.flatMap((mode) => [100, 48].map((width) => ({ mode, width }))))( height: 30, state: state.path, args: { sessionID: session.id }, - config: { animations: false, tabs: { enabled: true, scope: "global" } }, + config: { animations: false, session: { verbosity: "medium" }, tabs: { enabled: true, scope: "global" } }, fetch: async (url) => { if (url.pathname === "/api/session") return json({ data: [session, other], cursor: {} }) if (url.pathname === `/api/session/${session.id}`) return json({ data: session }) diff --git a/packages/tui/test/session-mount-budget.test.tsx b/packages/tui/test/session-mount-budget.test.tsx index 89bb8d682e1..659b70d68c8 100644 --- a/packages/tui/test/session-mount-budget.test.tsx +++ b/packages/tui/test/session-mount-budget.test.tsx @@ -74,6 +74,7 @@ test("an expanded group spends the mounting budget that older rows used", async config: { get: async () => ({ animations: false, + session: { verbosity: "medium" }, tabs: { enabled: false }, keybinds: { "session.messages_last_user": "ctrl+shift+u", "session.last": "ctrl+shift+l" }, }),