fix: switch system prompt to avoid malformed tool_calls (#650)

* fix: switch system prompt to avoid malformed tool_calls

* fix: circular dependency issue and configurable tool-call style

* fix: regExp issue
This commit is contained in:
Mingholy
2025-09-18 21:10:03 +08:00
committed by GitHub
parent 761833c915
commit 5f68a8b6b3
17 changed files with 2191 additions and 878 deletions

View File

@@ -0,0 +1,23 @@
/**
* @license
* Copyright 2025 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
/**
* Tool name constants to avoid circular dependencies.
* These constants are used across multiple files and should be kept in sync
* with the actual tool class names.
*/
export const ToolNames = {
EDIT: 'edit',
WRITE_FILE: 'write_file',
READ_FILE: 'read_file',
READ_MANY_FILES: 'read_many_files',
GREP: 'search_file_content',
GLOB: 'glob',
SHELL: 'run_shell_command',
TODO_WRITE: 'todo_write',
MEMORY: 'save_memory',
TASK: 'task',
} as const;