写英文挑出语法、用词、地道度问题。写中文顺手给一段地道英文版。
代码、命令、不需要的输入 — 完全静默。
需要 Python 3.9+ · 已安装 Claude Code · 一行命令完成 hook 注册
演示
✦ Better Phrase · English tip
· "todya" → "today" — 拼写错误,字母顺序颠倒。
· comma splice — 两个独立句子应该用句号。
✍️ Better phrase: "Hey, how's it going today? Also, tell me a joke."
✦ Better Phrase · English
"I'd like to schedule a meeting with the client next Tuesday to go over the contract details."
写代码、敲命令、或者不需要翻译的中文 — 完全静默,0 token,0 干扰。
为什么不用 CLAUDE.md
在 CLAUDE.md 里写"写英文时帮我润色"看似一样,但每条消息都要交一次税。
| 在 CLAUDE.md 里写规则 | Better Phrase | |
|---|---|---|
| Token 成本 | 每条消息都加载完整规则(~400 token) | 只在真正触发时才注入 |
| 触发判定 | 模型自己判断(易遗忘 / 误触发) | 确定性判断,100% 一致 |
| 纯中文 / 代码 | 仍占用 token | 0 token,完全静默 |
全天用下来 token 成本降低 5–10 倍,触发可靠性更高。
特性
语法 / 词汇 / 表达地道度修正,顺手给一段 native rewrite。
写中文时附带一段地道英文版本,可一键开关。
代码、命令、不相关输入完全不触发,不浪费一个 token。
tip 用中文解释,聚焦常见中式英语模式,看一次记一次。
hook 本身只做语言检测,相对 Claude 响应延迟感知不到。
无 API 调用,无遥测,数据永不出本机。
安装
$ curl -fsSL https://betterphrase.roseduan.cn/install.sh | bash
$ git clone https://github.com/roseduan/better-phrase.git ~/.claude/skills/better-phrase $ cd ~/.claude/skills/better-phrase $ ./install.sh
安装脚本做了什么
~/.claude/ 存在,且 python3 / git 可用~/.claude/settings.json 打时间戳备份hooks.UserPromptSubmit 加一条入口✦ Better Phrase · English tip 块出现。