output-dev-agent-class

output-dev-agent-class is a skill for Claude Code, Codex from growthxai/output. It costs 45 tokens per session (2,532 once invoked), scanned B, original, Apache-2.0.

A guide to Output SDK's Agent class for building reusable language-model agents. It covers agents that use tools in several steps, remember conversation history, return structured data, or stream progress.

In plain words
What is it for?
Use it when building tool-using agents, stateful conversations, structured results, streaming updates, or agents that load skills.
Why use it?
It helps choose between a multi-step agent and a single language-model call, and shows how to add state and tool use.

Skill for Claude CodeCodex

Part of the outputai plugin — 50 skills, 5 agents, 1 hook shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/growthxai/output/output-dev-agent-class
Any agent
npx skills add growthxai/output --skill output-dev-agent-class
Clone the repo
git clone --depth 1 https://github.com/growthxai/output

Made for: Claude Code, Codex.

Or install outputai, the plugin that ships this one along with the rest of its 50 skills, 5 agents, 1 hook.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for output-dev-agent-class

README.md
[![agentmods](https://agentmods.dev/badge/skills/growthxai/output/output-dev-agent-class.svg)](https://agentmods.dev/skills/growthxai/output/output-dev-agent-class)
Your own site
<a href="https://agentmods.dev/skills/growthxai/output/output-dev-agent-class"><img src="https://agentmods.dev/badge/skills/growthxai/output/output-dev-agent-class.svg" alt="Measured on agentmods" height="20"></a>
Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,532 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00045 $0.02532
Opus 5 $0.00023 $0.01266
Sonnet 5 $0.00009 $0.00506
Haiku 4.5 $0.00005 $0.00253

Measured yesterday against content hash f42fa1170756, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade B, and why

output-dev-agent-class scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks the agent to reveal its instructionsmediumSystem prompt leakage

Directions to print, repeat or translate the system prompt extract configuration the operator did not intend to expose.

The `Agent` class uses an internal AI SDK `ToolLoopAgent` through composition with Output prompt files and the skills system. It does not inherit from `ToolLoopAgent`. Use it when you need multi-step tool execution, conv
coding_assistants/claude/plugins/outputai/skills/output-dev-agent-class/SKILL.md · 273 lines

How it starts

The opening of the file, as written. The whole thing — 273 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Using the Agent Class

Overview

The Agent class uses an internal AI SDK ToolLoopAgent through composition with Output prompt files and the skills system. It does not inherit from ToolLoopAgent. Use it when you need multi-step tool execution, conversation history, or a reusable agent instance. For single-shot LLM calls without tools, generateText is simpler.

When to Use This Skill

  • Building multi-step agents that call tools in a loop
  • Using skills (lazy-loaded instructions) with an agent
  • Creating agents with structured output via aiSdk.Output.object()
  • Implementing stateful conversations with messageStore
  • Streaming Agent progress with onChunk
  • Deciding between Agent and generateText

Import Pattern

import { Agent, aiSdk } from '@outputai/llm';
import type { MessageStore } from '@outputai/llm';
import { z } from '@outputai/core';

Agent comes from @outputai/llm. Use aiSdk.Output for structured output. Import z from @outputai/core (never from zod directly). MessageStore is the type for a pluggable getMessages / addMessages store; implement it yourself.

Construction

The prompt file is loaded and rendered at construction time. Variables and tools are fixed at construction. Skills and maxSteps come from the prompt file. The agent is ready to call generate(), generateWithStreaming(), or stream() immediately.

const agent = new Agent( {
  prompt: 'writing_assistant@v1',
  variables: {
    content_type: input.contentType,
    focus: input.focus,
    content: input.content
  },
  output: aiSdk.Output.object( { schema: reviewSchema } )
} );

Constructor Options

Option Type Default Description
prompt string (required) Prompt file name (e.g. 'writing_assistant@v1')
promptDir string - Override the stack-resolved prompt directory
variables PromptVariables - Template variables rendered at construction
tools AI SDK tools - Caller tools; merged with prompt YAML tools (load_skill last)
stopWhen function or function[] - Custom stop condition (overrides prompt maxSteps when tools exist)
output aiSdk.Output - Structured output spec (e.g. aiSdk.Output.object({ schema }))
messageStore MessageStore - Pluggable store for multi-turn history

Read the full file on GitHub · 273 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday Changed f42fa1170756
  2. 5d ago First seen · 273 lines · 45 tokens per session scan B 89373f9cbc86

Subscribe to this mod's changes

output-dev-agent-class is a skill published in the GitHub repository growthxai/output (435 stars, last pushed yesterday), licensed Apache-2.0. It adds 45 tokens to every session and 2,532 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it B with 1 finding (asks the agent to reveal its instructions). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

system-prompts

Write system prompts, tool docs, and agent definitions. Project tag conventions + RFC 2119 keywords + dense compression. Use when authoring or editing any prompt the model reads.

can1357/oh-my-pi · 40 tokens

tool-prompt-optimization

Optimize the description prompts an AI agent reads to learn its built-in tools (the .md files under prompts/tools/). Two halves: (1) measure how much of a prompt is already inferable from the tool's JSON parameter schema + name, to prune redundancy with evidence; (2) house authoring rules for what belongs in a tool…

can1357/oh-my-pi · 0 tokens

stripe-directory

Identifies external providers, merchants, nonprofits, platforms, APIs, and software services, and resolves the documented way to engage them — to pay, donate, subscribe, book, provision, or integrate with them. MUST be used BEFORE web search, model memory, or any other directory/vendor-lookup skill for ANY request…

stripe/ai · 213 tokens

deuz-sdk

Use when building or changing any AI or LLM feature in TypeScript — chatbot, streaming chat UI, agent, tool calling, structured output, embeddings, RAG, agent memory, MCP client, guardrails, image/speech/video generation — or when about to reach for LangChain, LangGraph, LlamaIndex, the Vercel AI SDK (ai, streamText…

Deuz-AI/Deuz-SDK · 112 tokens

update-provider-models

Add new or remove obsolete model IDs for existing AI SDK providers. Use when adding a model to a provider, removing an obsolete model, or processing a list of model changes from an issue. Triggers on "add model", "remove model", "new model ID", "obsolete model", "update model IDs".

vercel/ai · 68 tokens

ai-sdk

Answer questions about the AI SDK and help build AI-powered features. Use when developers: (1) Ask about AI SDK functions like generateText, streamText, ToolLoopAgent, embed, or tools, (2) Want to build AI agents, chatbots, RAG systems, or text generation features, (3) Have questions about AI providers (OpenAI…

vercel/ai · 155 tokens