fix(core): improve chat history merging and switch to stable preview flash model

- Refactor GeminiChat history merging to handle consecutive turns of any role.
- Implement part-level filtering to remove empty text segments while preserving tool calls.
- Switch integration tests to 'gemini-3.1-flash-lite-preview' for improved stability.
- Ensure crash report context follows alternating role rules.
This commit is contained in:
Sehoon Shon
2026-03-31 21:35:13 -04:00
parent 4bb389efb7
commit 428a4808db
2 changed files with 41 additions and 30 deletions
+2 -2
View File
@@ -12,7 +12,7 @@ import { fileURLToPath } from 'node:url';
import { env } from 'node:process';
import { setTimeout as sleep } from 'node:timers/promises';
import {
DEFAULT_GEMINI_FLASH_MODEL,
PREVIEW_GEMINI_3_1_FLASH_LITE_MODEL,
GEMINI_DIR,
} from '@google/gemini-cli-core';
export { GEMINI_DIR };
@@ -460,7 +460,7 @@ export class TestRig {
...(env['GEMINI_TEST_TYPE'] === 'integration'
? {
model: {
name: DEFAULT_GEMINI_FLASH_MODEL,
name: PREVIEW_GEMINI_3_1_FLASH_LITE_MODEL,
},
}
: {}),