Section 7

Skill Builder and Prompt Library

Skills and prompts sit at the same level of abstraction in AgentSwarms: both are small, reusable building blocks that you define once and attach to many agents. The difference between them is mostly about scope. A skill is a complete capability — a callable function with inputs and outputs — that an agent can decide to use at runtime. A prompt is a piece of text — a starter system prompt or persona — that an agent uses to define its behaviour. The two screens covered on this page are the places you create, browse, compare, and curate these reusable pieces.

Skill Builder

The Skill Builder at /skillsmanages the library of skills available to your agents. A skill, from the agent's perspective, is a callable tool with a name, a description, an input schema, and an output schema. From your perspective as the builder, a skill is one of two things: a parameterised prompt that runs against a small model to produce a structured output, or a small piece of TypeScript code that runs in a sandboxed runtime. Both flavours feel identical once attached to an agent — the agent does not know or care which kind of skill it just called.

Prompt skills

A prompt skill is the right choice when the capability you are trying to encapsulate is fundamentally about language — taking a free-form input, asking a small model to do something specific with it, and returning a structured result. Common examples include "summarise this text in three bullet points", "extract the named entities and return them as JSON", "rewrite this email in a formal tone", and "classify this support ticket into one of these five categories with a confidence score". The Skill Builder walks you through defining a name, a description (which the parent agent uses to decide when to call the skill), the system prompt that does the work, an input JSON schema, and an output JSON schema validated using Zod-style rules.

Code skills

A code skill is the right choice when the capability is fundamentally deterministic and does not need a model. Common examples include parsing a date string, computing a checksum, normalising a phone number, or calling a small internal API. Code skills run inside a sandboxed JavaScript runtime with no network access by default and a small memory and time budget, so a buggy skill can never compromise the rest of the platform. The editor has syntax highlighting and inline type-checking and the skill is automatically wrapped as a callable tool with the input and output schemas you define.

Generated skills

For both prompt and code skills, the Skill Builder offers a "Generate from description" path. You describe what you want the skill to do in plain English, and the platform drafts the prompt or code, along with input and output schemas and a test case, that you can then review and edit before saving. This is the fastest way to bootstrap a new skill when you know what you want it to do but would rather not write the boilerplate yourself.

Attaching skills to agents

Once a skill exists in your library, attaching it to an agent is a matter of opening the agent in the Agent Builder, going to the Skills tab, and selecting the skill from the picker. From that point on the skill shows up in the agent's tool catalogue and the model can decide when to call it, like any other tool. Skills are versioned: updating a skill propagates to every agent using it on the next run, but you can pin an agent to a specific version of a skill if you need stability.

Prompt Library

The Prompt Library at /prompts is a curated and user-extendable collection of system prompts organised by what they do. It is meant to be the first place you look when you are starting a new agent and have not yet decided what its system prompt should be. Every prompt in the library has been written or reviewed by a human, ships with a clear name and description, and is tagged by category so you can find the right starting point quickly.

  • Browsing by category covers all the major archetypes that appear repeatedly in production agentic systems: retrieval-augmented-generation responders, text-to- SQL agents, structured-output extractors, classifiers, planners, executors, critics, personas, summarisers, and translators. Each category page lists the prompts in that category with a short summary and a preview.
  • Previewing with example inputs renders the prompt against a sample input and shows what a model would actually produce, so you are not guessing at quality before you commit. Previews are run against a small fast model by default to keep latency low.
  • Inserting into an agent with one click drops the chosen prompt straight into the Agent Builder's system prompt editor. The editor remembers which library entry the prompt came from so you can see at a glance when an agent has drifted from its starter prompt.
  • Saving your own prompts to the library is a one-click action from the Agent Builder's system prompt editor. You can keep your saved prompts private or share them publicly; public prompts show up on the library page alongside the curated ones with your display name as the author.

Prompt Compare

The Prompt Compare screen at /prompt-compare is a dedicated environment for the most common practical question in prompt engineering: given the same input, which of these two prompts produces a better output? The screen lays out two prompts side by side, takes the same input on both, runs each through your chosen model (or two different models), and renders the outputs next to each other for direct comparison. A judging agent can also be enabled to score the outputs against a rubric you define, which is the closest the platform gets to a built-in evaluation harness for prompts. Iterating on a prompt with this screen open in a second tab is the single most useful prompt-engineering workflow we have found.