mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-29 14:34:55 -07:00
Co-authored-by: Yuna Seol <yunaseol@google.com>
This commit is contained in:
@@ -20,6 +20,7 @@ import {
|
||||
isFunctionResponse,
|
||||
} from '../../utils/messageInspectors.js';
|
||||
import { debugLogger } from '../../utils/debugLogger.js';
|
||||
import { LlmRole } from '../../telemetry/types.js';
|
||||
|
||||
// The number of recent history turns to provide to the router for context.
|
||||
const HISTORY_TURNS_FOR_CONTEXT = 4;
|
||||
@@ -161,6 +162,7 @@ export class ClassifierStrategy implements RoutingStrategy {
|
||||
systemInstruction: CLASSIFIER_SYSTEM_PROMPT,
|
||||
abortSignal: context.signal,
|
||||
promptId,
|
||||
role: LlmRole.UTILITY_ROUTER,
|
||||
});
|
||||
|
||||
const routerResponse = ClassifierResponseSchema.parse(jsonResponse);
|
||||
|
||||
@@ -16,6 +16,7 @@ import { resolveClassifierModel, isGemini3Model } from '../../config/models.js';
|
||||
import { createUserContent, Type } from '@google/genai';
|
||||
import type { Config } from '../../config/config.js';
|
||||
import { debugLogger } from '../../utils/debugLogger.js';
|
||||
import { LlmRole } from '../../telemetry/types.js';
|
||||
|
||||
// The number of recent history turns to provide to the router for context.
|
||||
const HISTORY_TURNS_FOR_CONTEXT = 8;
|
||||
@@ -169,6 +170,7 @@ export class NumericalClassifierStrategy implements RoutingStrategy {
|
||||
systemInstruction: CLASSIFIER_SYSTEM_PROMPT,
|
||||
abortSignal: context.signal,
|
||||
promptId,
|
||||
role: LlmRole.UTILITY_ROUTER,
|
||||
});
|
||||
|
||||
const routerResponse = ClassifierResponseSchema.parse(jsonResponse);
|
||||
|
||||
Reference in New Issue
Block a user