mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-20 16:57:46 +00:00
Refactor: Remove GEMINI.md memory and refactor system prompt
- Updates CONTRIBUTING.md and Tips.tsx to remove references to GEMINI.md and the /init command, and renumbers tips.
- Fixes a typo in Tips.tsx ("information.s" -> "information.").
- Refactors the core system prompt in prompts.ts from a constant string to a function .
- Updates client.ts to call the function.
- Updates tool name references within the system prompt to use template literals for dynamic naming.
Fixes bug: https://buganizer.corp.google.com/issues/413061073
---
Generated by yours truly __Gemini Code__
This commit is contained in:
committed by
N. Taylor Mullen
parent
94c04955c8
commit
095163bbed
@@ -14,11 +14,11 @@ import {
|
||||
Content,
|
||||
Tool,
|
||||
} from '@google/genai';
|
||||
import { CoreSystemPrompt } from './prompts.js';
|
||||
import process from 'node:process';
|
||||
import { getFolderStructure } from '../utils/getFolderStructure.js';
|
||||
import { Turn, ServerGeminiStreamEvent } from './turn.js';
|
||||
import { Config } from '../config/config.js';
|
||||
import { getCoreSystemPrompt } from './prompts.js';
|
||||
|
||||
export class GeminiClient {
|
||||
private config: Config;
|
||||
@@ -66,7 +66,7 @@ export class GeminiClient {
|
||||
return this.client.chats.create({
|
||||
model: this.model,
|
||||
config: {
|
||||
systemInstruction: CoreSystemPrompt,
|
||||
systemInstruction: getCoreSystemPrompt(),
|
||||
...this.generateContentConfig,
|
||||
tools: tools,
|
||||
},
|
||||
@@ -140,7 +140,7 @@ export class GeminiClient {
|
||||
model: this.model,
|
||||
config: {
|
||||
...this.generateContentConfig,
|
||||
systemInstruction: CoreSystemPrompt,
|
||||
systemInstruction: getCoreSystemPrompt(),
|
||||
responseSchema: schema,
|
||||
responseMimeType: 'application/json',
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user