fix(fork): 修正工具与技能提示词文本的遗漏、错误与重复 - #4
Open
asto18089 wants to merge 2 commits into
Open
Conversation
对全部 LLM-facing 提示词文本做四类问题(遗漏/错误/重复/啰嗦) 审查并修复约 50 处,覆盖工具 description 与 JSON schema 参数 描述、prompts/*.md 工具用法章节、内置 SKILL.md。纯文本变更, 零代码行为变化,fork 指纹锚点全部保留。 代表性修复: - 错误:grep_files 虚假的 .gitignore 声明;agents/message 与 agents/followup 虚构的 natural resume/idle 语义;code_execution 与 js_execution 的 sandboxed 不实声明;rlm_eval 示例引用不存在 的 SOURCE 变量;delegate 技能错误的 model_strength 默认值; terminal/send 引导发裸 ETX 破坏会话状态跟踪;三处审批文档 提及无实现支撑的 CSV batch;内置技能中 deepseek 时代的命令 名与路径(codewhale mcp、~/.codewhale) - 遗漏:read_file 行号前缀与字节截断无 next_start_line; fetch_url 的 SSRF 拦截与重定向上限;web.run 的 screenshot 实为 PDF 文本提取、recency 不生效;automation 的漏跑不补/不重叠 与完整 RRULE 表单;start_mcp_server 命令白名单;exec_shell interactive 互斥;git_* 补 prefer-over-exec_shell 边界引导; github_* 补 gh CLI 前提与脏工作区拒绝;多处 schema 参数 补默认值与互斥约束 - 重复:workflow script 参数描述与工具级描述逐字重复的 parallel() 规则删一份;edit_file 移除对 pinvou3 工具面不可达 的 apply_patch 引用(同步更新 prompts.rs 锚定测试) 验证:cargo check -p codewhale-tui;cargo test -p codewhale-tui forkguard_ --lib(34 过);tools::/prompts::/skills:: 模块测试 (仅 1 个与本次无关的环境性既有失败);父仓 fork-guard --fast 指纹层全过。 Signed-off-by: asto <asto18089@126.com>
|
Thanks @asto18089 for taking the time to contribute. This repository is observing a maintainer-managed PR intake gate in dry-run mode, so this pull request is staying open. This note helps maintainers prepare the allowlist before any enforcement is considered. Please read |
fetch_url 是进程内 HTTP 客户端,并非沙箱执行;真正的对比点是 exec_shell 的沙箱策略可能拒绝出站网络。与本 PR 对 code_execution/js_execution 的 同类修正保持一致口径。 Signed-off-by: asto <asto18089@126.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
背景
对 fork 全部面向大模型(LLM-facing)的提示词文本做系统性审查,覆盖约 100 个工具的
description与 JSON schema 参数描述、prompts/*.md工具用法章节、13 个内置 SKILL.md,按四类问题(遗漏/错误/重复/啰嗦)修复约 50 处。纯提示词文本变更,零代码行为变化。变更
错误(描述与实现矛盾)
grep_files虚假声称 respects.gitignore(实现是硬编码排除清单)agents/message/agents/followup虚构 "natural resume"、"resume an idle or interrupted child" 能力code_execution/js_execution/SHELL_POLICY_DISABLED三处 "sandboxed" 不实声明(裸子进程无沙箱)fetch_url残留的 "sandboxed" 措辞(实为进程内 HTTP 客户端;真正的对比点是exec_shell的沙箱策略可能拒绝出站网络)rlm_eval示例引用不存在的SOURCE变量(实为content,原示例必 NameError)delegate技能错误的model_strength默认值描述(所有角色默认继承父模型)terminal/send引导发裸 ETX 字节(会破坏会话完成状态跟踪,正解terminal/cancel)codewhale mcp、~/.codewhale等)遗漏(实现支持但描述未提的关键约束)
read_file行号前缀格式、字节截断时无next_start_line;edit_file第二级标点 fuzzy 回退与 staleness 条件、CRLF 警示fetch_urlSSRF 拦截 / 5 次重定向 / 非 2xx 仍返回 bodyweb.runscreenshot 实为 PDF 单页文本提取;recency参数不生效(已标注)automation_create漏跑不补 / 不重叠语义与完整 RRULE 表单、本地时区start_mcp_server命令白名单;exec_shellinteractive 互斥约束git_*补 prefer-over-exec_shell边界引导;github_*补 gh CLI 前提与脏工作区拒绝task_create等十余处 schema 参数补默认值、互斥与安全默认语义重复
workflowscript 参数描述与工具级描述逐字重复的parallel()规则删去一份edit_file移除对 pinvou3 工具面不可达的apply_patch引用(同步更新prompts.rs锚定测试)验证
cargo check -p codewhale-tui通过cargo test -p codewhale-tui forkguard_ --lib34 项全过tools::/prompts::/skills::模块测试全过(仅git_repo_root_reports_attempted_paths_when_no_repo_found1 个失败,为 CodeWhale 作为 submodule 时临时目录落在父仓 git 仓库内的环境性既有失败,与本次改动无关)./scripts/fork-guard.sh --fast指纹层全过,指纹锚点全部保留已知风险
Signed-off-by: asto asto18089@126.com