Live data from Hacker News

Ask HN: I still don't understand why AI agents need "skills"

news.ycombinator.com

31–33 of 33 posts

Re: Ask HN: I still don't understand why AI agents need "skills"

#31
If you add all those .md files to your AGENTS.md, your harness will likely load all those files into context. This will create context pollution for you.

Context, similar to your computer's memory, is limited.

Additionally, the more things the AI has in context, the worse it performs.

Skills helps you to quickly add more context for doing things, without polluting your context window.

I think you need to learn about AI, there isn't anything hype there. It's just an easier way of giving more context to the AI.

This can be helpful, for example, if you have an internal API that does XYZ, and you want the AI to know that API, you can save that API, its endpoints and authenticaiton methods to a skill, and invoke it when you want your harness (CC, Codex) to know about the existance of that API, to make requests, make tests etc.

Re: Ask HN: I still don't understand why AI agents need "skills"

#32

A skill is more like a packaging convention around instructions, with the difference that the runtime knows it's a reusable unit. That lets it expose only the skill's name/description initially and load the full instructions (and sometimes bundled scripts or other resources) only when needed. Truth is that if you implemented the same lazy behavior with AGENTS.md and a bunch of Markdown files you'd end up with somethi…

Something like instructions in Projects? Or how? Could you please describe the pros and cons of each and when to use each? That'd be truly helpful!

The goal is more or less the same, to give the agent the ability to do things it doesn’t know by default. The difference when explaining this new thing to the agent using a skill is that it will only learn how to do it when it needs to, not all the time in all conversations (as the AGENTS.md file is read at the start of every new conversation). Furthermore, giving a model a new capability might require more than just a couple of Markdown files, and that’s where skills come in since they’re only read when needed, rather than at the start of every conversation, so they don’t waste tokens unnecessarily on something that could be very resource-intensive. Plus, decoupling them from an AGENTS.md file makes them easier to deploy.

An example of a skill I use a lot is draw-io skill (https://github.com/Agents365-ai/drawio-skill), it enables the agent to generate Draw.io diagrams. As you can see, there are a lot of Markdown files, but also Python scripts that the model must run to gather what it needs. If this was defined in an AGENTS.md file for a single project it wouldn’t be so bad, but if you have to maintain five skills of this size in your agent (or simply want to share them), you can’t include them in the AGENTS.md file, because they’ll consume all the context, even in a conversation where the agent won’t use any of them. It's like writing reusable and callable functions instead of writing all code in the main() method.

Post reply on HN