Load, validate, and populate templates consistently across frameworks.
Instantiates templates by locating them across project, framework, and system paths, parsing placeholders and conditions, gathering required inputs from context or prompts, and generating validated artifacts with metadata.
/plugin marketplace add jmagly/ai-writing-guide/plugin install utils@aiwgThis skill inherits all available tools. When active, it can use any tool Claude has access to.
scripts/template_engine.pyLoad, validate, and populate templates consistently across frameworks.
This skill provides a unified template instantiation engine that:
When triggered, this skill:
Locates template:
.aiwg/templates/)Parses template:
{{variable}}, {variable})Gathers inputs:
Instantiates template:
Validates output:
Saves artifact:
1. .aiwg/templates/{template-name}.md
2. .aiwg/templates/{category}/{template-name}.md
3. {framework}/templates/{category}/{template-name}.md
4. ~/.local/share/ai-writing-guide/.../{template-name}.md
# {{project_name}} Architecture Document
**Author**: {{author}}
**Date**: {{date}}
**Version**: {{version|default:0.1.0}}
{{#if has_database}}
## Database Design
{{database_description}}
{{/if}}
## Components
{{#each components}}
### {{name}}
{{description}}
- **Owner**: {{owner}}
- **Dependencies**: {{dependencies}}
{{/each}}
{{> common/header.md}}
## Content
{{> partials/component-table.md}}
**Generated**: {{now|format:YYYY-MM-DD}}
**ID**: {{artifact_type}}-{{sequence|pad:3}}
Each template can have a .meta.yaml file:
name: software-architecture-document
description: Template for Software Architecture Documents
category: architecture
version: 1.0.0
variables:
- name: project_name
required: true
description: Name of the project
- name: author
required: true
description: Document author
- name: version
required: false
default: "0.1.0"
description: Document version
- name: components
required: false
type: array
description: List of system components
sections:
- name: overview
required: true
- name: database
required: false
condition: has_database
output:
location: .aiwg/architecture/
filename: "{{project_name|kebab}}-sad.md"
User: "Create SAD from template"
Skill executes:
1. Find: sdlc-complete/templates/analysis-design/software-architecture-doc-template.md
2. Parse: Extract placeholders (project_name, author, etc.)
3. Gather: Prompt for required values
4. Instantiate: Replace placeholders
5. Save: .aiwg/architecture/myproject-sad.md
6. Metadata: Create .aiwg/architecture/myproject-sad.metadata.json
User: "New test plan from template for authentication module"
Context provides:
- project_name: "MyProject"
- module: "authentication"
- author: from git config
Skill uses context values, prompts for remaining.
User: "What templates are available?"
Skill returns:
Architecture:
- software-architecture-doc-template
- adr-template
- api-contract-template
Requirements:
- use-case-spec-template
- user-story-template
- supplementary-spec-template
Testing:
- test-plan-template
- test-case-template
- test-strategy-template
User: "Create component diagram from template with 3 components"
Skill prompts:
- Component 1 name? "API Gateway"
- Component 1 description? "External API interface"
- Component 2 name? "Auth Service"
...
Output includes all components in repeating section.
# Instantiate template
python template_engine.py --template software-architecture-doc-template
# With variables
python template_engine.py --template sad \
--var project_name="MyProject" \
--var author="John Doe"
# Interactive mode
python template_engine.py --template test-plan --interactive
# List templates
python template_engine.py --list
python template_engine.py --list --category architecture
# Validate template
python template_engine.py --validate --template custom-template.md
# Preview without saving
python template_engine.py --template sad --preview
# Specify output location
python template_engine.py --template sad --output .aiwg/architecture/custom-name.md
| Category | Templates |
|---|---|
| requirements | use-case-spec, user-story, supplementary-spec, srs, glossary |
| architecture | sad, adr, api-contract, data-flow, database-design |
| testing | test-strategy, test-plan, test-cases, defect-card |
| security | threat-model, security-requirements, vulnerability-plan |
| deployment | deployment-plan, release-notes, support-runbook |
| management | iteration-plan, risk-list, project-status |
| Category | Templates |
|---|---|
| intake | campaign-intake, audience-profile, brand-brief |
| content | blog-post, case-study, whitepaper, newsletter |
| creative | creative-brief, asset-spec, design-system |
| email-campaign, email-sequence, nurture-workflow | |
| analytics | kpi-dashboard, measurement-plan, campaign-report |
This skill integrates with:
artifact-metadata: Creates metadata for instantiated artifactsartifact-orchestration: Uses templates for artifact generationproject-awareness: Gets context values from project stateTemplate 'nonexistent' not found.
Did you mean:
- test-plan-template (testing)
- deployment-plan-template (deployment)
Available templates: python template_engine.py --list
Missing required variable: project_name
Description: Name of the project
Please provide: --var project_name="value"
Template validation failed:
Line 45: Unclosed conditional block {{#if has_database}}
Line 67: Unknown variable {{unknwon_var}}
sdlc-complete/templates/media-marketing-kit/templates/schemas/template-meta.schema.jsonThis 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.