summaryrefslogtreecommitdiff
path: root/packages/core/src/code_assist/server.ts
diff options
context:
space:
mode:
authorowenofbrien <[email protected]>2025-08-01 14:37:56 -0500
committerGitHub <[email protected]>2025-08-01 19:37:56 +0000
commita6a386f72aee3c5509a7c9fe7482060cf7d5884e (patch)
tree6a3a25a2ed7097e907bd3e60f8168744d5bc0d84 /packages/core/src/code_assist/server.ts
parent67d16992cfc6b18f1d242865e0fbd8f5f40cf25f (diff)
Propagate prompt (#5033)
Diffstat (limited to 'packages/core/src/code_assist/server.ts')
-rw-r--r--packages/core/src/code_assist/server.ts16
1 files changed, 14 insertions, 2 deletions
diff --git a/packages/core/src/code_assist/server.ts b/packages/core/src/code_assist/server.ts
index 7af643f7..08339bdc 100644
--- a/packages/core/src/code_assist/server.ts
+++ b/packages/core/src/code_assist/server.ts
@@ -53,10 +53,16 @@ export class CodeAssistServer implements ContentGenerator {
async generateContentStream(
req: GenerateContentParameters,
+ userPromptId: string,
): Promise<AsyncGenerator<GenerateContentResponse>> {
const resps = await this.requestStreamingPost<CaGenerateContentResponse>(
'streamGenerateContent',
- toGenerateContentRequest(req, this.projectId, this.sessionId),
+ toGenerateContentRequest(
+ req,
+ userPromptId,
+ this.projectId,
+ this.sessionId,
+ ),
req.config?.abortSignal,
);
return (async function* (): AsyncGenerator<GenerateContentResponse> {
@@ -68,10 +74,16 @@ export class CodeAssistServer implements ContentGenerator {
async generateContent(
req: GenerateContentParameters,
+ userPromptId: string,
): Promise<GenerateContentResponse> {
const resp = await this.requestPost<CaGenerateContentResponse>(
'generateContent',
- toGenerateContentRequest(req, this.projectId, this.sessionId),
+ toGenerateContentRequest(
+ req,
+ userPromptId,
+ this.projectId,
+ this.sessionId,
+ ),
req.config?.abortSignal,
);
return fromGenerateContentResponse(resp);