You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
body: "{\"contents\":[{\"parts\":[{\"text\":\"You are a knowledgeable assistant that helps users with various tasks.\\nBe helpful, accurate, and concise in your responses.\\n\"}],\"role\":\"user\"},{\"parts\":[{\"text\":\"## Filesystem Tool Instructions\\n\\nThis toolset provides comprehensive filesystem operations with built-in security restrictions.\\n\\n### Security Model\\n- All operations are restricted to allowed directories only\\n- Use list_allowed_directories to see available paths\\n- Subdirectories within allowed directories are accessible\\n- Use add_allowed_directory to request access to new directories (requires user consent)\\n\\n### Directory Access Management\\n- If you need access to a directory outside the allowed list, use add_allowed_directory\\n- This will request user consent before expanding filesystem access\\n- Always provide a clear reason when requesting new directory access\\n\\n### Common Patterns\\n- Always check if directories exist before creating files\\n- Prefer read_multiple_files for batch operations\\n- Use search_files_content for finding specific code or text\\n\\n### Performance Tips\\n- Use read_multiple_files instead of multiple read_file calls\\n- Use directory_tree with max_depth to limit large traversals\\n- Use appropriate exclude patterns in search operations\"}],\"role\":\"user\"},{\"parts\":[{\"text\":\"How many files in testdata/working_dir? Only output the number.\"}],\"role\":\"user\"},{\"parts\":[{\"functionCall\":{\"args\":{\"path\":\"testdata/working_dir\"},\"name\":\"list_directory\"}}],\"role\":\"model\"},{\"parts\":[{\"functionResponse\":{\"name\":\"call_8d644b69-7ee9-4f53-b375-9a99945a25dc\",\"response\":{\"result\":\"FILE README.me\\n\"}}}],\"role\":\"user\"}],\"generationConfig\":{},\"toolConfig\":{\"functionCallingConfig\":{\"mode\":\"AUTO\"}},\"tools\":[{\"functionDeclarations\":[{\"description\":\"Create a new directory or ensure a directory exists. Can create multiple nested directories in one operation.\",\"name\":\"create_directory\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory path to create\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Get a recursive tree view of files and directories as a JSON structure.\",\"name\":\"directory_tree\",\"parameters\":{\"properties\":{\"max_depth\":{\"description\":\"Maximum depth to traverse (optional)\",\"type\":\"integer\"},\"path\":{\"description\":\"The directory path to traverse\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Make line-based edits to a text file. Each edit replaces exact line sequences with new content.\",\"name\":\"edit_file\",\"parameters\":{\"properties\":{\"edits\":{\"description\":\"Array of edit operations\",\"items\":{\"properties\":{\"newText\":{\"description\":\"The replacement text\",\"type\":\"string\"},\"oldText\":{\"description\":\"The exact text to replace\",\"type\":\"string\"}},\"required\":[\"oldText\",\"newText\"],\"type\":\"object\"},\"type\":\"array\"},\"path\":{\"description\":\"The file path to edit\",\"type\":\"string\"}},\"required\":[\"path\",\"edits\"],\"type\":\"object\"}},{\"description\":\"Retrieve detailed metadata about a file or directory.\",\"name\":\"get_file_info\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The file or directory path to inspect\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Returns a list of directories that the server has permission to access. Don't call if you access only the current working directory. It's always allowed.\",\"name\":\"list_allowed_directories\",\"parameters\":{\"type\":\"object\"}},{\"description\":\"Request to add a new directory to the allowed directories list. This requires explicit user consent for security reasons.\",\"name\":\"add_allowed_directory\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory path to add to allowed directories\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Get a detailed listing of all files and directories in a specified path.\",\"name\":\"list_directory\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory path to list\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Get a detailed listing of all files and directories in a specified path, including sizes.\",\"name\":\"list_directory_with_sizes\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory path to list\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Move or rename files and directories.\",\"name\":\"move_file\",\"parameters\":{\"properties\":{\"destination\":{\"description\":\"The destination path\",\"type\":\"string\"},\"source\":{\"description\":\"The source path\",\"type\":\"string\"}},\"required\":[\"source\",\"destination\"],\"type\":\"object\"}},{\"description\":\"Read the complete contents of a file from the file system.\",\"name\":\"read_file\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The file path to read\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Read the contents of multiple files simultaneously.\",\"name\":\"read_multiple_files\",\"parameters\":{\"properties\":{\"json\":{\"description\":\"Whether to return the result as JSON\",\"type\":\"boolean\"},\"paths\":{\"description\":\"Array of file paths to read\",\"items\":{\"type\":\"string\"},\"type\":\"array\"}},\"required\":[\"paths\"],\"type\":\"object\"}},{\"description\":\"Recursively search for files and directories matching a pattern. Prints the full paths of matching files and the total number of files found.\",\"name\":\"search_files\",\"parameters\":{\"properties\":{\"excludePatterns\":{\"description\":\"Patterns to exclude from search\",\"items\":{\"type\":\"string\"},\"type\":\"array\"},\"path\":{\"description\":\"The starting directory path\",\"type\":\"string\"},\"pattern\":{\"description\":\"The search pattern\",\"type\":\"string\"}},\"required\":[\"path\",\"pattern\"],\"type\":\"object\"}},{\"description\":\"Searches for text or regex patterns in the content of files matching a GLOB pattern.\",\"name\":\"search_files_content\",\"parameters\":{\"properties\":{\"excludePatterns\":{\"description\":\"Patterns to exclude from search\",\"items\":{\"type\":\"string\"},\"type\":\"array\"},\"is_regex\":{\"description\":\"If true, treat query as regex; otherwise literal text\",\"type\":\"boolean\"},\"path\":{\"description\":\"The starting directory path\",\"type\":\"string\"},\"query\":{\"description\":\"The text or regex pattern to search for\",\"type\":\"string\"}},\"required\":[\"path\",\"query\"],\"type\":\"object\"}},{\"description\":\"Create a new file or completely overwrite an existing file with new content.\",\"name\":\"write_file\",\"parameters\":{\"properties\":{\"content\":{\"description\":\"The content to write to the file\",\"type\":\"string\"},\"path\":{\"description\":\"The file path to write\",\"type\":\"string\"}},\"required\":[\"path\",\"content\"],\"type\":\"object\"}}]}]}\n"
34
+
body: "{\"contents\":[{\"parts\":[{\"text\":\"You are a knowledgeable assistant that helps users with various tasks.\\nBe helpful, accurate, and concise in your responses.\\n\"}],\"role\":\"user\"},{\"parts\":[{\"text\":\"## Filesystem Tool Instructions\\n\\nThis toolset provides comprehensive filesystem operations with built-in security restrictions.\\n\\n### Security Model\\n- All operations are restricted to allowed directories only\\n- Use list_allowed_directories to see available paths\\n- Subdirectories within allowed directories are accessible\\n- Use add_allowed_directory to request access to new directories (requires user consent)\\n\\n### Directory Access Management\\n- If you need access to a directory outside the allowed list, use add_allowed_directory\\n- This will request user consent before expanding filesystem access\\n- Always provide a clear reason when requesting new directory access\\n\\n### Common Patterns\\n- Always check if directories exist before creating files\\n- Prefer read_multiple_files for batch operations\\n- Use search_files_content for finding specific code or text\\n\\n### Performance Tips\\n- Use read_multiple_files instead of multiple read_file calls\\n- Use directory_tree with max_depth to limit large traversals\\n- Use appropriate exclude patterns in search operations\"}],\"role\":\"user\"},{\"parts\":[{\"text\":\"How many files in testdata/working_dir? Only output the number.\"}],\"role\":\"user\"},{\"parts\":[{\"functionCall\":{\"args\":{\"path\":\"testdata/working_dir\"},\"name\":\"list_directory\"},\"thoughtSignature\":\"CiQB0e2Kb8f55SOYzHzh/VoESz0UqNZk0m2s+yiiWKfUEKIQ1nEKZgHR7YpvEobm0Mf3tP07MuK/fwYBk9GcW3aZdUiSDZbGWOJgWAhZ0IXZmpNVOlL5gEBRX9le7ej0zokjdkHv8cExdGd1O58CjB8tKJFbqb8dRaBOmPoqx0UoZAruFr6KsYleL2z5rQrUAQHR7Ypvk6sBdUg6OPTJeHJJ1N5uOPZYAyLUyp66e93CCQ7GCcms8AW/okDM42XJia6UCAjySJpEkzAlgPVRrPN4b6BiH7LMNHnP8PTvASeelDIHu29jflUyNS4imM1dg/ocTCTZOs8/fvVHpU28BAc7WgmtdSymGSx1DrlcesGo2yRMZv41EvK9lhsy332LSf0oTdCQXvYbL7TPdis2v6kde8mkM1K1KfYc/H3lqwOBYLojiETjwtTxZxfAiJn5MWOiPZI7EQ8mYJJOkZepC9QEK/8x\"}],\"role\":\"model\"},{\"parts\":[{\"functionResponse\":{\"name\":\"call_831be108-7307-4e54-9a9d-66906dfab974\",\"response\":{\"result\":\"FILE README.me\\n\"}}}],\"role\":\"user\"}],\"generationConfig\":{},\"toolConfig\":{\"functionCallingConfig\":{\"mode\":\"AUTO\"}},\"tools\":[{\"functionDeclarations\":[{\"description\":\"Create a new directory or ensure a directory exists. Can create multiple nested directories in one operation.\",\"name\":\"create_directory\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory path to create\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Get a recursive tree view of files and directories as a JSON structure.\",\"name\":\"directory_tree\",\"parameters\":{\"properties\":{\"max_depth\":{\"description\":\"Maximum depth to traverse (optional)\",\"type\":\"integer\"},\"path\":{\"description\":\"The directory path to traverse\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Make line-based edits to a text file. Each edit replaces exact line sequences with new content.\",\"name\":\"edit_file\",\"parameters\":{\"properties\":{\"edits\":{\"description\":\"Array of edit operations\",\"items\":{\"properties\":{\"newText\":{\"description\":\"The replacement text\",\"type\":\"string\"},\"oldText\":{\"description\":\"The exact text to replace\",\"type\":\"string\"}},\"required\":[\"oldText\",\"newText\"],\"type\":\"object\"},\"type\":\"array\"},\"path\":{\"description\":\"The file path to edit\",\"type\":\"string\"}},\"required\":[\"path\",\"edits\"],\"type\":\"object\"}},{\"description\":\"Retrieve detailed metadata about a file or directory.\",\"name\":\"get_file_info\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The file or directory path to inspect\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Returns a list of directories that the server has permission to access. Don't call if you access only the current working directory. It's always allowed.\",\"name\":\"list_allowed_directories\",\"parameters\":{\"type\":\"object\"}},{\"description\":\"Request to add a new directory to the allowed directories list. This requires explicit user consent for security reasons.\",\"name\":\"add_allowed_directory\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory path to add to allowed directories\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Get a detailed listing of all files and directories in a specified path.\",\"name\":\"list_directory\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory path to list\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Get a detailed listing of all files and directories in a specified path, including sizes.\",\"name\":\"list_directory_with_sizes\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory path to list\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Move or rename files and directories.\",\"name\":\"move_file\",\"parameters\":{\"properties\":{\"destination\":{\"description\":\"The destination path\",\"type\":\"string\"},\"source\":{\"description\":\"The source path\",\"type\":\"string\"}},\"required\":[\"source\",\"destination\"],\"type\":\"object\"}},{\"description\":\"Read the complete contents of a file from the file system.\",\"name\":\"read_file\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The file path to read\",\"type\":\"string\"}},\"required\":[\"path\"],\"type\":\"object\"}},{\"description\":\"Read the contents of multiple files simultaneously.\",\"name\":\"read_multiple_files\",\"parameters\":{\"properties\":{\"json\":{\"description\":\"Whether to return the result as JSON\",\"type\":\"boolean\"},\"paths\":{\"description\":\"Array of file paths to read\",\"items\":{\"type\":\"string\"},\"type\":\"array\"}},\"required\":[\"paths\"],\"type\":\"object\"}},{\"description\":\"Recursively search for files and directories matching a pattern. Prints the full paths of matching files and the total number of files found.\",\"name\":\"search_files\",\"parameters\":{\"properties\":{\"excludePatterns\":{\"description\":\"Patterns to exclude from search\",\"items\":{\"type\":\"string\"},\"type\":\"array\"},\"path\":{\"description\":\"The starting directory path\",\"type\":\"string\"},\"pattern\":{\"description\":\"The search pattern\",\"type\":\"string\"}},\"required\":[\"path\",\"pattern\"],\"type\":\"object\"}},{\"description\":\"Searches for text or regex patterns in the content of files matching a GLOB pattern.\",\"name\":\"search_files_content\",\"parameters\":{\"properties\":{\"excludePatterns\":{\"description\":\"Patterns to exclude from search\",\"items\":{\"type\":\"string\"},\"type\":\"array\"},\"is_regex\":{\"description\":\"If true, treat query as regex; otherwise literal text\",\"type\":\"boolean\"},\"path\":{\"description\":\"The starting directory path\",\"type\":\"string\"},\"query\":{\"description\":\"The text or regex pattern to search for\",\"type\":\"string\"}},\"required\":[\"path\",\"query\"],\"type\":\"object\"}},{\"description\":\"Create a new file or completely overwrite an existing file with new content.\",\"name\":\"write_file\",\"parameters\":{\"properties\":{\"content\":{\"description\":\"The content to write to the file\",\"type\":\"string\"},\"path\":{\"description\":\"The file path to write\",\"type\":\"string\"}},\"required\":[\"path\",\"content\"],\"type\":\"object\"}}]}]}\n"
0 commit comments