mirror of
https://github.com/google-gemini/gemini-cli
synced 2026-04-21 13:37:17 +00:00
fix: revert snippets.ts fallback to DEFAULT_CONTEXT_FILENAME
The prompt rendering fallback should use the singular default (GEMINI.md) to avoid changing system prompt text, which caused an eval regression. The actual multi-filename discovery still works via getAllGeminiMdFilenames() passed from promptProvider.
This commit is contained in:
parent
e738708aed
commit
e0a102eaeb
1 changed files with 3 additions and 3 deletions
|
|
@ -35,7 +35,7 @@ import {
|
|||
TRACKER_UPDATE_TASK_TOOL_NAME,
|
||||
} from '../tools/tool-names.js';
|
||||
import type { HierarchicalMemory } from '../config/memory.js';
|
||||
import { DEFAULT_CONTEXT_FILENAMES } from '../tools/memoryTool.js';
|
||||
import { DEFAULT_CONTEXT_FILENAME } from '../tools/memoryTool.js';
|
||||
|
||||
// --- Options Structs ---
|
||||
|
||||
|
|
@ -178,7 +178,7 @@ export function renderCoreMandates(options?: CoreMandatesOptions): string {
|
|||
if (!options) return '';
|
||||
const filenames = options.contextFilenames?.length
|
||||
? options.contextFilenames
|
||||
: DEFAULT_CONTEXT_FILENAMES;
|
||||
: [DEFAULT_CONTEXT_FILENAME];
|
||||
const formattedFilenames =
|
||||
filenames.length > 1
|
||||
? filenames
|
||||
|
|
@ -495,7 +495,7 @@ export function renderUserMemory(
|
|||
if (trimmed.length === 0) return '';
|
||||
const filenames = contextFilenames?.length
|
||||
? contextFilenames
|
||||
: DEFAULT_CONTEXT_FILENAMES;
|
||||
: [DEFAULT_CONTEXT_FILENAME];
|
||||
const formattedHeader = filenames.join(', ');
|
||||
return `
|
||||
# Contextual Instructions (${formattedHeader})
|
||||
|
|
|
|||
Loading…
Reference in a new issue