Skip to content

Commit 8fabaea

Browse files
Copilotalexr00
andcommitted
Initial analysis: Add Crystal to ignored completion trigger languages
Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
1 parent b7e4672 commit 8fabaea

File tree

3 files changed

+17
-3
lines changed

3 files changed

+17
-3
lines changed

src/@types/vscode.proposed.chatParticipantAdditions.d.ts

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ declare module 'vscode' {
103103
isConfirmed?: boolean;
104104
isComplete?: boolean;
105105
toolSpecificData?: ChatTerminalToolInvocationData;
106+
fromSubAgent?: boolean;
106107

107108
constructor(toolName: string, toolCallId: string, isError?: boolean);
108109
}
@@ -646,7 +647,13 @@ declare module 'vscode' {
646647
}
647648

648649
export interface ChatRequest {
649-
modeInstructions?: string;
650-
modeInstructionsToolReferences?: readonly ChatLanguageModelToolReference[];
650+
readonly modeInstructions?: string;
651+
readonly modeInstructions2?: ChatRequestModeInstructions;
652+
}
653+
654+
export interface ChatRequestModeInstructions {
655+
readonly content: string;
656+
readonly toolReferences?: readonly ChatLanguageModelToolReference[];
657+
readonly metadata?: Record<string, boolean | string | number>;
651658
}
652659
}

src/@types/vscode.proposed.chatParticipantPrivate.d.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,8 @@ declare module 'vscode' {
187187

188188
isQuotaExceeded?: boolean;
189189

190+
isRateLimited?: boolean;
191+
190192
level?: ChatErrorLevel;
191193

192194
code?: string;
@@ -219,6 +221,10 @@ declare module 'vscode' {
219221
chatSessionId?: string;
220222
chatInteractionId?: string;
221223
terminalCommand?: string;
224+
/**
225+
* Lets us add some nicer UI to toolcalls that came from a sub-agent, but in the long run, this should probably just be rendered in a similar way to thinking text + tool call groups
226+
*/
227+
fromSubAgent?: boolean;
222228
}
223229

224230
export interface LanguageModelToolInvocationPrepareOptions<T> {
@@ -239,6 +245,7 @@ declare module 'vscode' {
239245
export class ExtendedLanguageModelToolResult extends LanguageModelToolResult {
240246
toolResultMessage?: string | MarkdownString;
241247
toolResultDetails?: Array<Uri | Location>;
248+
toolMetadata?: unknown;
242249
}
243250

244251
// #region Chat participant detection

src/github/copilotRemoteAgentUtils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ export function extractTitle(prompt: string, context: string | undefined): strin
5050
return prompt;
5151
}
5252
return prompt.substring(0, 20) + '...';
53-
}
53+
};
5454
const titleMatch = context?.match(/TITLE: \s*(.*)/i);
5555
if (titleMatch && titleMatch[1]) {
5656
return titleMatch[1].trim();

0 commit comments

Comments
 (0)