Recently learned what agent skills are. I remember reading about them when they first came out, but I didn’t really understand their purpose, thinking that it’s Anthropic’s analogue of Copilot’s Instructions. They are similar, but thinking now, skills feels superior. More like a superset of copilot instructions.
Skill is a prompt file, which describes what the skill should do. Quick short snippets of information that an agent should know. They can come with references and script files which have more information to not clutter the prompt. Scripts are just code files, which an agent can run from the CLI and they solve some task for the agent (Kinda reminds of SMOL agents).
The main agent, in its system prompt has a TOC of skills, name and description. To use a skill, the agent just has has to read the SKILLS.md file (using the read_file tool or you make a custom tool to like get_skill or smth). This just injects the prompt into the context and the agent uses that to continue what it was doing.
This allows to not clutter the context with too many tools, prompts etc. The agent can pick and choose which ones it needs, when it needs them.