Create scenario files for testing migrated Output SDK workflows. Use to set up test inputs in the scenarios/ subfolder.
Creates JSON scenario files in the `scenarios/` subfolder for testing migrated Output SDK workflows. Use this after migration to set up test inputs that match your workflow's schema, enabling consistent validation with the Output CLI.
/plugin marketplace add growthxai/output-claude-plugins/plugin install growthxai-outputai-flow-migrator-plugins-outputai-flow-migrator@growthxai/output-claude-pluginsThis skill is limited to using the following tools:
This skill helps create scenario files - JSON files containing test inputs for Output SDK workflows. Scenario files enable consistent testing and validation of migrated workflows.
After Migration:
During Development:
Scenario files live in a scenarios/ subfolder within the workflow directory:
src/workflows/my_workflow/
├── workflow.ts
├── steps.ts
├── types.ts
├── analyze@v1.prompt
└── scenarios/
├── basic_input.json
├── edge_case_empty.json
└── full_options.json
Scenario files are JSON files that match the workflow's input schema:
{
"userId": "user-123",
"options": {
"includeDetails": true,
"maxResults": 10
}
}
Use descriptive names that indicate the test case:
basic_input.json # Standard happy path
edge_case_empty.json # Empty or minimal input
edge_case_large.json # Large data input
error_missing_field.json # Missing required field (for error testing)
full_options.json # All optional fields included
question_ada_lovelace.json # Specific test scenario description
Use the Output CLI to run a workflow with a scenario file:
# Basic usage
npx output workflow run <workflow_name> --input src/<workflow>/scenarios/<scenario>.json
# Examples
npx output workflow run simple --input src/simple/scenarios/question_ada_lovelace.json
npx output workflow run userReport --input src/workflows/user_report/scenarios/basic_input.json
Review the workflow's input schema in types.ts or workflow.ts:
// types.ts
export const WorkflowInputSchema = z.object( {
userId: z.string(),
reportType: z.enum( [ 'daily', 'weekly', 'monthly' ] ),
options: z.object( {
includeCharts: z.boolean().optional(),
maxPages: z.number().optional()
} ).optional()
} );
mkdir -p src/workflows/my_workflow/scenarios
Start with a minimal valid input:
{
"userId": "test-user-001",
"reportType": "daily"
}
Full Options Scenario:
{
"userId": "test-user-001",
"reportType": "weekly",
"options": {
"includeCharts": true,
"maxPages": 5
}
}
Edge Case - Empty Optional:
{
"userId": "test-user-002",
"reportType": "monthly",
"options": {}
}
If the Flow SDK workflow had test files, convert them to scenarios:
// Original test
describe('UserReportWorkflow', () => {
it('generates daily report', async () => {
const input = {
userId: 'test-123',
reportType: 'daily'
};
const result = await workflow.execute(input);
expect(result.success).toBe(true);
});
});
// scenarios/daily_report.json
{
"userId": "test-123",
"reportType": "daily"
}
Run with:
npx output workflow run userReport --input src/workflows/user_report/scenarios/daily_report.json
Test normal, expected usage:
// scenarios/basic_user.json
{
"userId": "user-12345",
"action": "process"
}
Test boundary conditions:
// scenarios/edge_empty_string.json
{
"userId": "",
"action": "validate"
}
// scenarios/edge_long_input.json
{
"userId": "user-12345",
"content": "Very long content string repeated many times..."
}
Test error handling (may cause expected failures):
// scenarios/error_invalid_type.json
{
"userId": 12345,
"action": "process"
}
Test complex inputs:
// scenarios/complex_nested.json
{
"userId": "user-001",
"documents": [
{
"id": "doc-1",
"title": "First Document",
"content": "Content of first document"
},
{
"id": "doc-2",
"title": "Second Document",
"content": "Content of second document"
}
],
"options": {
"processAll": true,
"outputFormat": "json"
}
}
// types.ts
import { z } from '@output.ai/core';
export const AnalyzeDocumentInputSchema = z.object( {
documentId: z.string(),
documentText: z.string(),
analysisType: z.enum( [ 'summary', 'entities', 'sentiment', 'full' ] ),
options: z.object( {
language: z.string().optional(),
maxLength: z.number().optional(),
includeConfidence: z.boolean().optional()
} ).optional()
} );
scenarios/basic_summary.json:
{
"documentId": "doc-001",
"documentText": "This is a sample document about artificial intelligence and its applications in modern business.",
"analysisType": "summary"
}
scenarios/full_analysis_with_options.json:
{
"documentId": "doc-002",
"documentText": "Detailed technical document content here...",
"analysisType": "full",
"options": {
"language": "en",
"maxLength": 500,
"includeConfidence": true
}
}
scenarios/edge_minimal.json:
{
"documentId": "doc-min",
"documentText": "Short.",
"analysisType": "summary"
}
scenarios/edge_empty_options.json:
{
"documentId": "doc-003",
"documentText": "Document with empty options object.",
"analysisType": "entities",
"options": {}
}
# Test basic scenario
npx output workflow run analyzeDocument --input src/workflows/analyze_document/scenarios/basic_summary.json
# Test full options
npx output workflow run analyzeDocument --input src/workflows/analyze_document/scenarios/full_analysis_with_options.json
# Test edge cases
npx output workflow run analyzeDocument --input src/workflows/analyze_document/scenarios/edge_minimal.json
Use this template to create new scenarios:
{
"_scenario": {
"name": "Descriptive scenario name",
"description": "What this scenario tests",
"expectedOutcome": "success|error|specific behavior"
},
"field1": "value1",
"field2": "value2",
"optionalField": "optional value"
}
Note: The _scenario metadata field is optional and ignored by the workflow. It's useful for documentation.
After creating scenarios, verify they work:
# List all scenarios
ls src/workflows/my_workflow/scenarios/
# Run each scenario
for f in src/workflows/my_workflow/scenarios/*.json; do
echo "Testing: $f"
npx output workflow run my_workflow --input "$f"
done
flow-validation-checklist - Complete migration validationflow-analyze-workflow-structure - Understanding workflow inputsflow-conventions-folder-structure - Folder structure conventionsCreating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.
Create beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.