Render template

From maslennikov-ig/claude-code-orchestrator-kit · View interactive version

Render template is an AI agent skill from the GitHub repository maslennikov-ig/claude-code-orchestrator-kit. Render templates with variable substitution using {{variable}} or ${variable} syntax. Use for generating formatted output, reports, commit messages, or any text requiring variable interpolation.

How to use this skill

Skill file

Render Template

Render templates with variable substitution, supporting various syntax formats and helper functions.

When to Use

Instructions

Step 1: Receive Template and Data

Accept template string and variable data.

Expected Input:

Supported Syntax:

Step 2: Parse Template

Identify all placeholders in template.

Placeholder Patterns:

Step 3: Resolve Variables

Replace placeholders with values from variables object.

Resolution Rules:

Step 4: Apply Filters (Optional)

Support simple filters if specified.

Common Filters:

Step 5: Return Rendered Output

Return final rendered string.

Expected Output: String (template with variables replaced)

Error Handling

Examples

Example 1: Simple Variable Substitution

Input:

{
  "template": "Hello {{name}}, your score is {{score}}!",
  "variables": {
    "name": "Alice",
    "score": 95
  },
  "syntax": "mustache"
}

Output:

Hello Alice, your score is 95!

Example 2: Nested Properties

Input:

{
  "template": "User: {{user.name}} ({{user.email}})\nRole: {{user.role}}",
  "variables": {
    "user": {
      "name": "Bob",
      "email": "bob@example.com",
      "role": "admin"
    }
  }
}

Output:

User: Bob (bob@example.com)
Role: admin

Example 3: Shell Syntax

Input:

{
  "template": "Version: ${VERSION}\nDate: ${RELEASE_DATE}",
  "variables": {
    "VERSION": "0.8.0",
    "RELEASE_DATE": "2025-10-17"
  },
  "syntax": "shell"
}

Output:

Version: 0.8.0
Date: 2025-10-17

Example 4: Commit Message Template

Input:

{
  "template": "{{type}}({{scope}}): {{description}}\n\n{{body}}\n\nšŸ¤– Generated with Claude Code\nCo-Authored-By: Claude <noreply@anthropic.com>",
  "variables": {
    "type": "feat",
    "scope": "auth",
    "description": "add OAuth2 support",
    "body": "Implemented OAuth2 flow with token refresh.\nSupports Google and GitHub providers."
  }
}

Output:

feat(auth): add OAuth2 support

Implemented OAuth2 flow with token refresh.
Supports Google and GitHub providers.

šŸ¤– Generated with Claude Code
Co-Authored-By: Claude <noreply@anthropic.com>

Example 5: Missing Variables

Input:

{
  "template": "Name: {{name}}\nAge: {{age}}\nCity: {{city}}",
  "variables": {
    "name": "Alice"
  }
}

Output (with empty string replacement):

Name: Alice
Age:
City:

Output (with keep placeholder):

Name: Alice
Age: {{age}}
City: {{city}}

Example 6: Report Header Template

Input:

{
  "template": "# {{reportType}} Report: {{version}}\n\n**Generated**: {{timestamp}}\n**Status**: {{statusEmoji}} {{status}}\n**Version**: {{version}}",
  "variables": {
    "reportType": "Bug Hunting",
    "version": "2025-10-17",
    "timestamp": "2025-10-17 14:30:00 UTC",
    "statusEmoji": "āœ…",
    "status": "success"
  }
}

Output:

# Bug Hunting Report: 2025-10-17

**Generated**: 2025-10-17 14:30:00 UTC
**Status**: āœ… success
**Version**: 2025-10-17

Validation

Supporting Files

None required - pure template rendering logic.

Integration with Other Skills

This Skill consolidates formatting logic used by:

Example Integration:

Instead of: Hard-coded string formatting in each Skill
Use: render-template Skill with predefined templates
Result: Consistent formatting, easier to maintain
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.