Skip to content

Commit a8a46bd

Browse files
committed
Merge private-agent-modal with web-app
2 parents d5def36 + 5f766ab commit a8a46bd

File tree

9 files changed

+1414
-537
lines changed

9 files changed

+1414
-537
lines changed

vscode/media/command-deck/command-deck.js

-1
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,6 @@ class CommandDeck {
133133
this.ref.innerHTML = textContent.substring(0, atIndex) + textContent.substring(atIndex + 1);
134134
}
135135
if (option?.name.startsWith('@')) {
136-
console.log('agents options', option?.metadata);
137136
activeAgentAttach.style = "color: #497BEF; !important";
138137

139138
agentName = option?.metadata.display_name;

vscode/media/onboarding/onboarding.js

-1
Original file line numberDiff line numberDiff line change
@@ -1047,7 +1047,6 @@ function handleSubmit(event) {
10471047
} else {
10481048

10491049
matchingItems = getAgents().filter(item => {
1050-
console.log('name', item);
10511050
return item.search?.toLowerCase().startsWith(query.toLowerCase());
10521051
});
10531052
}

vscode/src/providers/chat_view_provider.ts

+19-27
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,6 @@ export class FlutterGPTViewProvider implements vscode.WebviewViewProvider {
174174
// StorageManager.instance.deleteAgents();
175175

176176
webviewView.onDidChangeVisibility(() => {
177-
console.log("webview", webviewView.visible);
178177
if (webviewView.visible && this._view) {
179178
this._view?.webview.postMessage({ type: "focusChatInput" });
180179
}
@@ -454,6 +453,7 @@ export class FlutterGPTViewProvider implements vscode.WebviewViewProvider {
454453
private: false,
455454
};
456455
try {
456+
console.log(JSON.stringify(data));
457457
const modelResponse = await makeHttpRequest<{ response: string, references: Array<string> }>({
458458
url: "https://api.commanddash.dev/v2/ai/agent/answer",
459459
method: "post",
@@ -468,19 +468,15 @@ export class FlutterGPTViewProvider implements vscode.WebviewViewProvider {
468468
value: this._publicConversationHistory,
469469
});
470470
} catch (error) {
471-
this._publicConversationHistory.push({
472-
[this._activeAgent]: {
473-
role: "error",
474-
text:
475-
error instanceof Error
476-
? (error as Error).message
477-
: (error as any).toString(),
478-
},
479-
});
480-
this._view?.webview.postMessage({
481-
type: "displayMessages",
482-
value: this._publicConversationHistory,
483-
});
471+
// this._publicConversationHistory.push({
472+
// [this._activeAgent]: {
473+
// role: "error",
474+
// text:
475+
// error instanceof Error
476+
// ? (error as Error).message
477+
// : (error as any).toString(),
478+
// },
479+
// });
484480
} finally {
485481
this?._view?.webview?.postMessage({ type: "hideLoadingIndicator" });
486482
}
@@ -730,19 +726,15 @@ export class FlutterGPTViewProvider implements vscode.WebviewViewProvider {
730726
} catch (error) {
731727
console.error(error);
732728
logError("command-deck-conversation-error", error);
733-
this._publicConversationHistory.push({
734-
[this._activeAgent]: {
735-
role: "error",
736-
text:
737-
error instanceof Error
738-
? (error as Error).message
739-
: (error as any).toString(),
740-
},
741-
});
742-
this._view?.webview.postMessage({
743-
type: "displayMessages",
744-
value: this._publicConversationHistory,
745-
});
729+
// this._publicConversationHistory.push({
730+
// [this._activeAgent]: {
731+
// role: "error",
732+
// text:
733+
// error instanceof Error
734+
// ? (error as Error).message
735+
// : (error as any).toString(),
736+
// },
737+
// });
746738
} finally {
747739
this._view?.webview.postMessage({ type: "hideLoadingIndicator" });
748740
this._view?.webview.postMessage({

0 commit comments

Comments
 (0)