From 044749e2ce5a76122ea40a677ede6dc37582a2c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=B1=E6=BD=AE?= Date: Sat, 4 Apr 2026 23:24:07 +0800 Subject: [PATCH] =?UTF-8?q?=E5=9C=A8=20"Skill=20Execution=20Workflow"=20?= =?UTF-8?q?=E4=B9=8B=E5=89=8D=E6=96=B0=E5=A2=9E=E4=BA=86=20"Skills=20vs=20?= =?UTF-8?q?Tools=20-=20CRITICAL=20DISTINCTION"=20=20=20=E6=AE=B5=E8=90=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- prompt/system_prompt.md | 18 +++++++++++++++--- prompt/system_prompt_deep_agent.md | 12 ++++++++++++ 2 files changed, 27 insertions(+), 3 deletions(-) diff --git a/prompt/system_prompt.md b/prompt/system_prompt.md index 32439de..d740313 100644 --- a/prompt/system_prompt.md +++ b/prompt/system_prompt.md @@ -14,7 +14,19 @@ The filesystem backend is currently operating in: `{agent_dir_path}` - Never use relative paths in bash commands - always construct full absolute paths - Use the working directory from to construct absolute paths -**2. Skill Script Path Conversion** +**2. Skills vs Tools - CRITICAL DISTINCTION** + +**Skills are NOT tools.** Do NOT attempt to call a skill as a tool_call/function_call. + +- **Tools** (e.g., `rag_retrieve`, `read_file`, `bash`): Directly callable via tool_call interface with structured parameters. +- **Skills** (e.g., `baidu-search`, `pdf`, `xlsx`): Multi-step workflows executed by: (1) reading SKILL.md, (2) extracting the command, (3) running it via the `bash` tool. + +❌ WRONG: Generating a tool_call with `{"name": "baidu-search", "arguments": {...}}` +✅ CORRECT: Using `read_file` to read SKILL.md, then using `bash` to execute the script + +If you see a skill name in the "Available Skills" list, it is NEVER a tool you can call directly. + +**3. Skill Script Path Conversion** When executing scripts from SKILL.md files, you MUST convert relative paths to absolute paths: @@ -29,14 +41,14 @@ When executing scripts from SKILL.md files, you MUST convert relative paths to a └── scriptB.py # Actual script B file ``` -**3. Workspace Directory Structure** +**4. Workspace Directory Structure** - **`{agent_dir_path}/skills/`** - Skill packages with embedded scripts - **`{agent_dir_path}/dataset/`** - Store file datasets and document data - **`{agent_dir_path}/executable_code/`** - Place generated executable scripts here (not skill scripts) - **`{agent_dir_path}/download/`** - Store downloaded files and content -**4. Executable Code Organization** +**5. Executable Code Organization** When creating scripts in `executable_code/`, follow these organization rules: diff --git a/prompt/system_prompt_deep_agent.md b/prompt/system_prompt_deep_agent.md index 336a265..ecca407 100644 --- a/prompt/system_prompt_deep_agent.md +++ b/prompt/system_prompt_deep_agent.md @@ -83,6 +83,18 @@ When using the write_todos tool: The todo list is a planning tool - use it judiciously to avoid overwhelming the user with excessive task tracking. +### Skills vs Tools - CRITICAL DISTINCTION + +**Skills are NOT tools.** Do NOT attempt to call a skill as a tool_call/function_call. + +- **Tools** (e.g., `rag_retrieve`, `read_file`, `bash`): Directly callable via tool_call interface with structured parameters. +- **Skills** (e.g., `baidu-search`, `pdf`, `xlsx`): Multi-step workflows executed by: (1) reading SKILL.md, (2) extracting the command, (3) running it via the `bash` tool. + +❌ WRONG: Generating a tool_call with `{"name": "baidu-search", "arguments": {...}}` +✅ CORRECT: Using `read_file` to read SKILL.md, then using `bash` to execute the script + +If you see a skill name in the "Available Skills" list, it is NEVER a tool you can call directly. + ### Skill Execution Workflow **CRITICAL**: When you need to use a skill, follow this exact workflow: