Skip to content

Commit 86136d4

Browse files
committed
disable AI summary behavior entirely
1 parent be868ca commit 86136d4

5 files changed

Lines changed: 6 additions & 415 deletions

File tree

package.json

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -131,16 +131,7 @@
131131
"title": "Make Executable",
132132
"icon": "$(unlock)"
133133
},
134-
{
135-
"command": "commandtree.generateSummaries",
136-
"title": "Generate AI Summaries",
137-
"icon": "$(sparkle)"
138-
},
139-
{
140-
"command": "commandtree.selectModel",
141-
"title": "CommandTree: Select AI Model",
142-
"icon": "$(hubot)"
143-
}
134+
144135
],
145136
"menus": {
146137
"view/title": [
@@ -371,7 +362,7 @@
371362
},
372363
"commandtree.enableAiSummaries": {
373364
"type": "boolean",
374-
"default": true,
365+
"default": false,
375366
"description": "Use GitHub Copilot to generate plain-language summaries of scripts, enabling semantic search"
376367
},
377368
"commandtree.aiModel": {

src/extension.ts

Lines changed: 4 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,12 @@ import { TaskRunner } from "./runners/TaskRunner";
1010
import { QuickTasksProvider } from "./QuickTasksProvider";
1111
import { logger } from "./utils/logger";
1212
import { initDb, disposeDb } from "./db/lifecycle";
13-
import { forceSelectModel } from "./semantic/summariser";
1413
import { syncTagsFromConfig } from "./tags/tagSync";
1514
import { setupFileWatchers } from "./watchers";
1615
import { PrivateTaskDecorationProvider } from "./tree/PrivateTaskDecorationProvider";
1716
import { appState } from "./state";
1817
import {
19-
initAiSummaries,
2018
registerDiscoveredCommands,
21-
runSummarisation,
2219
syncAndSummarise,
2320
} from "./summaryOrchestration";
2421
import type { SummaryDeps } from "./summaryOrchestration";
@@ -87,15 +84,11 @@ export async function activate(context: vscode.ExtensionContext): Promise<Extens
8784
}
8885

8986
function runBackgroundStartup(workspaceRoot: string): void {
90-
initialDiscovery(workspaceRoot)
91-
.then(() => {
92-
initAiSummaries(getSummaryDeps(workspaceRoot));
93-
})
94-
.catch((e: unknown) => {
95-
logger.error("Initial discovery failed", {
96-
error: e instanceof Error ? e.message : String(e),
97-
});
87+
initialDiscovery(workspaceRoot).catch((e: unknown) => {
88+
logger.error("Initial discovery failed", {
89+
error: e instanceof Error ? e.message : String(e),
9890
});
91+
});
9992
}
10093

10194
async function initDatabaseSafe(workspaceRoot: string): Promise<void> {
@@ -201,24 +194,6 @@ function registerFilterCommands(context: vscode.ExtensionContext): void {
201194
vscode.commands.registerCommand("commandtree.clearFilter", () => {
202195
getTreeProvider().clearFilters();
203196
updateFilterContext();
204-
}),
205-
vscode.commands.registerCommand("commandtree.generateSummaries", async () => {
206-
const workspaceRoot = vscode.workspace.workspaceFolders?.[0]?.uri.fsPath;
207-
if (workspaceRoot !== undefined) {
208-
await runSummarisation(getSummaryDeps(workspaceRoot));
209-
}
210-
}),
211-
vscode.commands.registerCommand("commandtree.selectModel", async () => {
212-
const result = await forceSelectModel();
213-
if (result.ok) {
214-
vscode.window.showInformationMessage(`CommandTree: AI model set to ${result.value}`);
215-
const workspaceRoot = vscode.workspace.workspaceFolders?.[0]?.uri.fsPath;
216-
if (workspaceRoot !== undefined) {
217-
await runSummarisation(getSummaryDeps(workspaceRoot));
218-
}
219-
} else {
220-
vscode.window.showWarningMessage(`CommandTree: ${result.error}`);
221-
}
222197
})
223198
);
224199
}

src/test/e2e/aisummaries.e2e.test.ts

Lines changed: 0 additions & 176 deletions
This file was deleted.

src/test/e2e/treeview.e2e.test.ts

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import {
1414
getCommandTreeProvider,
1515
getLabelString,
1616
collectLeafItems,
17-
collectLeafTasks,
1817
refreshTasks,
1918
writeFile,
2019
deleteFile,
@@ -232,23 +231,6 @@ suite("TreeView E2E Tests", () => {
232231
});
233232
});
234233

235-
suite("AI Summaries", () => {
236-
test("@exclude-ci Copilot summarisation produces summaries for discovered tasks", async function () {
237-
this.timeout(15000);
238-
const provider = getCommandTreeProvider();
239-
// AI summaries: extension activation triggers summarisation via Copilot.
240-
// If Copilot auth fails (GitHubLoginFailed), tasks will have no summaries.
241-
// This MUST fail if the integration is broken.
242-
const allTasks = await collectLeafTasks(provider);
243-
const withSummary = allTasks.filter((t) => t.summary !== undefined && t.summary !== "");
244-
assert.ok(
245-
withSummary.length > 0,
246-
`Copilot summarisation must produce summaries — got 0 out of ${allTasks.length} tasks. ` +
247-
"Check for GitHubLoginFailed errors above."
248-
);
249-
});
250-
});
251-
252234
suite("Private Make And Mise Tasks", () => {
253235
const makeRelativePath = "private-targets/Makefile";
254236
const miseRelativePath = "private-targets/mise.toml";

0 commit comments

Comments
 (0)