Inside Claude Skills: Anthropic’s new pattern for customizing LLMs

Agent Skills

Anthropic has introduced Claude Skills, a new method for enabling large language models (LLMs) to adapt to specific tasks and tools at inference. The feature provides a simple yet powerful way to transform generalist models like Claude into expert agents. 

Claude Skills are very intuitive, organized as folders containing instructions, scripts, and other resources that an agent can discover and load dynamically. This approach allows anyone to package procedural knowledge and organizational context, equipping a general model with specific, composable capabilities.

How it works: progressive disclosure and token efficiency

The design of Claude Skills is centered on progressive disclosure, where the model is gradually given information about skills to maintain token efficiency. At the start of a session, the agent scans available skills and populates the LLM’s system prompt with a brief name and description about each skill, compiled as YAML metadata that is around 100 tokens. This initial step provides just enough information for the model to know when a skill might be relevant without consuming a large part of the context window.

If a user’s task matches a skill’s description, the agent then loads the full description, which is formatted as markdown, into a file named SKILL.md. For more complex tasks, this file can reference additional documents or scripts bundled within the skill’s directory. The agent can choose to access these linked files as needed to avoid loading unneeded information into its context window.

Agent Skills structure
Agent Skills structure (source: Anthropic blog)

The SKILL.md file contains the full instructions for the model to accomplish the specific task. Agent Skills is integrated across Claude apps for Pro, Max, and Team users, as well as the Claude Developer Platform and Claude Code.

Real-world applications and portability of Agent Skills

Anthropic’s own document creation abilities, which allow Claude to generate formatted .docx, .xlsx, and .pdf files, are implemented entirely using Skills. In a hands-on test of an example skill, software engineer Simon Willison created a GIF creator for Slack. When prompted, the model uses a pre-written Python script included in the skill to generate a GIF. The skill also provides a validation function to check if the generated file meets Slack’s size constraints, allowing the model to retry if the initial attempt is too large. 

Furthermore, the creation process itself is streamlined through AI. Anthropic offers a “skill-creator” skill where Claude interactively guides a user, asking about their workflow to automatically generate the folder structure and format the necessary SKILL.md file without manual editing.

Agent Skills in action
How Anthropic Agent Skills works at runtime (source: Anthropic blog)

Because Skills are fundamentally just folders of text files and scripts, they are not inherently tied to Anthropic’s models. Another model with access to a code interpreter could be instructed to read a SKILL.md file and follow its instructions. This simplicity suggests the potential for a portable, cross-platform ecosystem of skills that could work with a variety of agents and models.

Security considerations

The Skills mechanism requires the model to have access to a filesystem and the ability to execute code. This dependency is what makes the feature so powerful, effectively turning a tool like Claude Code into a general agent for computer automation.

However, this capability also introduces security risks. Malicious skills could execute harmful code, exfiltrate data, or direct the model to take unintended actions. Anthropic recommends that users install skills only “from trusted sources” and audit their contents, paying close attention to code dependencies and any instructions that connect to external networks.

Basically, like any setting where you provide LLMs with access to coding and external tools, you should be very careful on the kinds of privileges and functions that you put at the model’s disposal.

Agent Skills versus MCP

Last year, Anthropic introduced Model Context Protocol (MCP), an open-source protocol that provided LLMs access to external tools and data sources. It was touted as a USB for LLMs. 

While MCP generated significant interest, a key limitation has emerged in its token usage. Some MCP implementations can consume tens of thousands of tokens, leaving little context window space for the model to perform its actual work. 

Agent Skills provide an alternative that avoids the extra overhead by loading information on demand. Their design, based on Markdown with YAML metadata, outsources complexity to the LLM and its computing environment, which is a sensible strategy given the demonstrated ability of models to run tools.

However, Anthropic has hinted that they are considering exploring “how Skills can complement Model Context Protocol (MCP) servers by teaching agents more complex workflows that involve external tools and software.”

Anthropic’s long-term vision is to enable agents to create, edit, and evaluate skills on their own, allowing them to codify their successful behaviors into reusable capabilities. Agent Skills provide a simple and expandable foundational pattern that can make that vision a reality.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.