Create .prompt files for LLM operations in Output SDK workflows. Use when designing prompts, configuring LLM providers, or using Liquid.js templating.
Creates `.prompt` files for LLM operations in Output SDK workflows. Use when designing prompts, configuring LLM providers (Anthropic, OpenAI, Google), or using Liquid.js templating for dynamic content.
/plugin marketplace add growthxai/output-claude-plugins/plugin install growthxai-outputai-plugins-outputai@growthxai/output-claude-pluginsThis skill is limited to using the following tools:
This skill documents how to create .prompt files for LLM operations in Output SDK workflows. Prompt files use YAML frontmatter for configuration and Liquid.js templating for dynamic content.
Prompt files are stored INSIDE the workflow folder:
src/workflows/{workflow-name}/
├── workflow.ts
├── steps.ts
├── types.ts
└── prompts/
├── analyzeContent@v1.prompt
├── generateSummary@v1.prompt
└── extractData@v2.prompt
Important: Prompts are workflow-specific and live inside the workflow folder, NOT in a shared location.
{promptName}@v{version}.prompt
Examples:
generateImageIdeas@v1.promptanalyzeContent@v1.promptsummarizeText@v2.promptThe version suffix (@v1, @v2) allows for prompt versioning without breaking existing code.
---
provider: anthropic
model: claude-sonnet-4-20250514
temperature: 0.7
maxTokens: 4096
---
<system>
System instructions go here.
</system>
<user>
User message with {{ variable }} placeholders.
</user>
---
provider: anthropic # LLM provider: anthropic, openai, google
model: claude-sonnet-4-20250514 # Model identifier
---
---
provider: anthropic
model: claude-sonnet-4-20250514
temperature: 0.7 # 0.0 to 1.0, default varies by provider
maxTokens: 4096 # Maximum output tokens
providerOptions: # Provider-specific options
thinking:
type: enabled
budgetTokens: 2000
---
---
provider: anthropic
model: claude-sonnet-4-20250514
temperature: 0.7
maxTokens: 8192
---
---
provider: anthropic
model: claude-sonnet-4-20250514
temperature: 0.7
maxTokens: 32000
providerOptions:
thinking:
type: enabled
budgetTokens: 2000
---
---
provider: openai
model: gpt-4o
temperature: 0.7
maxTokens: 4096
---
---
provider: google
model: gemini-1.5-pro
temperature: 0.7
maxTokens: 8192
---
Use XML-style tags to define message roles:
<system>
You are an expert at analyzing technical content.
Your responses should be clear and structured.
</system>
<user>
Please analyze the following content:
{{ content }}
</user>
<assistant>
I'll analyze this content step by step...
</assistant>
<user>
Analyze this content about {{ topic }}:
{{ content }}
Generate {{ numberOfIdeas }} ideas.
</user>
<system>
You are an expert content analyzer.
{% if colorPalette %}
**Color Palette Constraints:** {{ colorPalette }}
{% endif %}
{% if artDirection %}
**Art Direction Constraints:** {{ artDirection }}
{% endif %}
</system>
<user>
Analyze each of these items:
{% for item in items %}
- {{ item.name }}: {{ item.description }}
{% endfor %}
</user>
<user>
Generate {{ numberOfIdeas | default: 3 }} ideas for {{ topic }}.
</user>
Based on a real prompt file (generateImageIdeas@v1.prompt):
---
provider: anthropic
model: claude-sonnet-4-20250514
temperature: 0.7
maxTokens: 32000
providerOptions:
thinking:
type: enabled
budgetTokens: 2000
---
<system>
You are an expert at creating structured, precise infographic prompts optimized for Gemini's image generation model.
Your task is to generate prompts for informational infographics that illustrate key concepts from the provided content.
CRITICAL RULES you MUST follow:
- Use Markdown dashed lists to specify constraints
- Use ALL CAPS for "MUST" requirements to ensure strict adherence
- Include specific compositional constraints (e.g., rule of thirds, lighting)
- Always include negative constraints to prevent unwanted elements
- Keep each infographic focused on ONE clear concept
{% if colorPalette %}
**Color Palette Constraints:** {{ colorPalette }}
{% endif %}
{% if artDirection %}
**Art Direction Constraints:** {{ artDirection }}
{% endif %}
</system>
<user>
Generate {{ numberOfIdeas }} structured infographic prompts based on key topics from this content.
<content>
{{ content }}
</content>
Each prompt MUST follow this structure:
Create an infographic about [specific topic]. The infographic MUST follow ALL of these constraints:
- The infographic MUST use the reference images as a visual style guide
- The composition MUST follow the rule of thirds for visual balance
- The infographic MUST use clean, minimal design with simple lines and shapes
{% if colorPalette %}- The color palette MUST strictly follow: {{ colorPalette }}{% endif %}
{% if artDirection %}- The art direction MUST strictly follow: {{ artDirection }}{% endif %}
- NEVER include any watermarks, logos, or decorative overlays
- NEVER use generic AI art buzzwords like "hyperrealistic"
Focus on the most important concepts that would benefit from visual explanation.
</user>
import { generateObject } from '@output.ai/llm';
import { z } from '@output.ai/core';
const response = await generateObject({
prompt: 'generateImageIdeas@v1', // References prompts/generateImageIdeas@v1.prompt
variables: {
content: 'Solar panel technology explained...',
numberOfIdeas: 3,
colorPalette: 'blue and green tones',
artDirection: 'minimalist style'
},
schema: z.object({
ideas: z.array(z.string())
})
});
import { generateText } from '@output.ai/llm';
const response = await generateText({
prompt: 'summarize@v1',
variables: {
content: 'Long article text...',
maxLength: 200
}
});
<system>
CRITICAL RULES you MUST follow:
- Rule 1
- Rule 2
- NEVER do X
- ALWAYS do Y
</system>
<user>
Analyze the following:
<content>
{{ content }}
</content>
<requirements>
{{ requirements }}
</requirements>
</user>
<system>
You analyze sentiment. Return: positive, negative, or neutral.
</system>
<user>
"I love this product!"
</user>
<assistant>
positive
</assistant>
<user>
"{{ text }}"
</user>
When making significant changes, create a new version:
analyzeContent@v1.prompt - OriginalanalyzeContent@v2.prompt - Improved with better examplesUpdate the step to use the new version:
prompt: 'analyzeContent@v2' // Changed from v1
{% if optionalField %}
Additional context: {{ optionalField }}
{% endif %}
---
provider: anthropic
model: claude-sonnet-4-20250514
temperature: 0.3
---
<system>
You are a content classifier. Categorize content into exactly one category.
Available categories: {{ categories | join: ", " }}
</system>
<user>
Classify this content:
{{ content }}
</user>
---
provider: anthropic
model: claude-sonnet-4-20250514
temperature: 0.2
---
<system>
You extract structured data from text. Be precise and only include information explicitly stated.
</system>
<user>
Extract the following fields from this text:
{% for field in fields %}
- {{ field }}
{% endfor %}
Text:
{{ text }}
</user>
---
provider: anthropic
model: claude-sonnet-4-20250514
temperature: 0.8
---
<system>
You are a creative writer. Generate engaging content based on the given parameters.
</system>
<user>
Generate {{ count }} {{ type }} about {{ topic }}.
Requirements:
{{ requirements }}
</user>
prompts/ folder inside workflow directory{promptName}@v{version}.promptprovider and model<system>, <user>, <assistant>){{ variableName }} syntax{% if %}...{% endif %} syntaxoutput-dev-step-function - Using prompts in step functionsoutput-dev-folder-structure - Understanding prompts folder locationoutput-dev-workflow-function - Orchestrating LLM-powered stepsThis skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.
This skill should be used when the user asks to "create a slash command", "add a command", "write a custom command", "define command arguments", "use command frontmatter", "organize commands", "create command with file references", "interactive command", "use AskUserQuestion in command", or needs guidance on slash command structure, YAML frontmatter fields, dynamic arguments, bash execution in commands, user interaction patterns, or command development best practices for Claude Code.
This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.