Code Assist backend telemetry for user accept/reject of suggestions (#15206)

This commit is contained in:
Christian Gunderman
2025-12-17 15:12:59 -08:00
committed by GitHub
parent c28ff3d5a5
commit 5d13145995
8 changed files with 508 additions and 74 deletions

View File

@@ -27,6 +27,7 @@ import {
coreEvents,
CoreEvent,
createWorkingStdio,
recordToolCallInteractions,
} from '@google/gemini-cli-core';
import type { Content, Part } from '@google/genai';
@@ -407,6 +408,8 @@ export async function runNonInteractive({
geminiClient
.getChat()
.recordCompletedToolCalls(currentModel, completedToolCalls);
await recordToolCallInteractions(config, completedToolCalls);
} catch (error) {
debugLogger.error(
`Error recording completed tool call information: ${error}`,

View File

@@ -38,6 +38,7 @@ import {
runInDevTraceSpan,
EDIT_TOOL_NAMES,
processRestorableToolCalls,
recordToolCallInteractions,
} from '@google/gemini-cli-core';
import { type Part, type PartListUnion, FinishReason } from '@google/genai';
import type {
@@ -163,6 +164,11 @@ export const useGeminiStream = (
currentModel,
completedToolCallsFromScheduler,
);
await recordToolCallInteractions(
config,
completedToolCallsFromScheduler,
);
} catch (error) {
debugLogger.warn(
`Error recording completed tool call information: ${error}`,