feat(config): enable Gemma 4 models by default via Gemini API (#26307)

This commit is contained in:
Abhijit Balaji
2026-04-30 21:14:57 -07:00
committed by GitHub
parent b3e6c28933
commit d9f273e440
9 changed files with 15 additions and 16 deletions
+2 -2
View File
@@ -3673,7 +3673,7 @@ describe('Config JIT Initialization', () => {
expect(config.getExperimentalGemma()).toBe(false);
});
it('should return false when experimentalGemma is not provided', () => {
it('should return true when experimentalGemma is not provided', () => {
const params: ConfigParameters = {
sessionId: 'test-session',
targetDir: '/tmp/test',
@@ -3683,7 +3683,7 @@ describe('Config JIT Initialization', () => {
};
config = new Config(params);
expect(config.getExperimentalGemma()).toBe(false);
expect(config.getExperimentalGemma()).toBe(true);
});
it('should be independent of experimentalMemoryV2', () => {
+1 -1
View File
@@ -1179,7 +1179,7 @@ export class Config implements McpContext, AgentLoopContext {
this.experimentalJitContext = params.experimentalJitContext ?? true;
this.experimentalMemoryV2 = params.experimentalMemoryV2 ?? true;
this.experimentalAutoMemory = params.experimentalAutoMemory ?? false;
this.experimentalGemma = params.experimentalGemma ?? false;
this.experimentalGemma = params.experimentalGemma ?? true;
this.experimentalContextManagementConfig =
params.experimentalContextManagementConfig;
this.memoryBoundaryMarkers = params.memoryBoundaryMarkers ?? ['.git'];
+3 -3
View File
@@ -595,9 +595,9 @@ describe('isActiveModel', () => {
expect(isActiveModel(DEFAULT_GEMINI_FLASH_MODEL)).toBe(true);
});
it('should return true for Gemma 4 models only when experimentalGemma is true', () => {
expect(isActiveModel(GEMMA_4_31B_IT_MODEL)).toBe(false);
expect(isActiveModel(GEMMA_4_26B_A4B_IT_MODEL)).toBe(false);
it('should return true for Gemma 4 models when experimentalGemma is not provided (defaults to true)', () => {
expect(isActiveModel(GEMMA_4_31B_IT_MODEL)).toBe(true);
expect(isActiveModel(GEMMA_4_26B_A4B_IT_MODEL)).toBe(true);
expect(isActiveModel(GEMMA_4_31B_IT_MODEL, false, false, false, true)).toBe(
true,
);
+1 -1
View File
@@ -455,7 +455,7 @@ export function isActiveModel(
useGemini3_1: boolean = false,
useGemini3_1FlashLite: boolean = false,
useCustomToolModel: boolean = false,
experimentalGemma: boolean = false,
experimentalGemma: boolean = true,
): boolean {
if (!VALID_GEMINI_MODELS.has(model)) {
return false;