跳到正文
原文
Jesse Vincent·· 2025/12/17精选AI 评分66

Claude Code 的 Skill 不触发?可能是它根本没看到

原文标题:Claude Code skills not triggering? It might not see them.

AI 导读

Claude Code 通过把 Skill 名称和描述注入系统提示词来让模型知道有哪些 Skill,当 Skill 太多或描述字段太长时,系统提示词就不会列出它们,模型也就无法使用,而且提示词还要求模型不要使用未列出的 Skill。

推荐理由

作者解释了 Claude Code 不触发已安装 Skill 的原因,并给出可直接使用的环境变量临时解法。

正文

当前语言的正文正在等待翻译,暂时显示原文。

I've heard from a number of folks that they're seeing Claude Code just...not use skills they have installed.

The way Claude knows about skills is that it builds a big list of skill names and descriptions and injects it into in the system prompt.

pasted image 20251217 144948

The problems start when you've got too many skills or their description fields are too long. Then, the system prompt doesn't tell Claude about them. And if it doesn't know about them...it can't use them.

To add insult to injury, the system prompt tells Claude never to use skills that aren't listed.

pasted image 20251217 145126

As of Claude Code 2.0.70, the limit for skill and command descriptions defaults to 15,000 characters (or around 4000 tokens). If you're not making heavy use of skills, that ought to be fine. But, since there's no warning when you go over, you might find yourself with unusable skills.

For now, the best workaround is to set an environment variable:

SLASH_COMMAND_TOOL_CHAR_BUDGET=30000 claude will give you double the headroom for skill descriptions.

I've been working on making Superpowers a little bit more system-prompt token efficient. Superpowers 4.0, which should ship "soon", combines a number of infrequently used skills and rewrites a number of skill descriptions to be a bit shorter. But more on that soon.

来源:Jesse Vincent · blog.fsck.com