vinta/hal-9000/tree/main/plugins/hal-grammar-check

vinta/hal-9000/tree/main/plugins/hal-grammar-check

输入提示时即时进行语法检查,并用繁体中文解释。修正内容会在按 Enter 前显示在提示框上方。
这个外掛需要本地 Ollama 和 gemma4:31b-mlx 模型:
ollama pull gemma4:31b-mlx
这是一个 mod,因此还需要 Claude Code 2.1.287 或更高版本。
claude plugin marketplace add vinta/hal-9000
claude plugin install hal-grammar-check@hal-9000
然后重启 Claude Code。
直接输入即可。停止输入约 250ms 后,草稿会发送到 Ollama,结果显示在提示框上方。较旧草稿的结果会被丢弃。
hal-statusline 会在提交后检查每个提示。为了避免同时看到两份结果,可以在环境变量中设置 HAL_STATUSLINE_GRAMMAR_CHECK_DISABLED=1 关闭它。
它会将草稿的前 500 个字符发送到本地 Ollama 的 localhost:11434。完全离线,不会有任何内容离开你的机器。

请先查看作者 README 确认 marketplace 和插件名称;命令可能随仓库结构改变。
claude plugin marketplace add vinta/hal-9000 claude plugin install hal-grammar-check
A grammar check on your prompt while you type, with explanations in Traditional Chinese. The corrections show up above the prompt box, before you hit Enter.
This plugin needs a local Ollama with the gemma4:31b-mlx model:
ollama pull gemma4:31b-mlx
It's a mod, so it also needs Claude Code 2.1.287 or later.
claude plugin marketplace add vinta/hal-9000
claude plugin install hal-grammar-check@hal-9000
Then restart Claude Code.
Just type. About 250ms after you stop, the draft goes to Ollama and the result shows up above the prompt box. A result for an older draft is dropped.
hal-statusline checks each prompt after you submit it. To avoid seeing both, turn that one off with HAL_STATUSLINE_GRAMMAR_CHECK_DISABLED=1 in your environment variables.
It sends the first 500 characters of your draft to your local Ollama at localhost:11434. Fully offline, nothing leaves your machine.
