xml-standards

XML tag structure patterns for Claude Code agents and commands. Use when designing or implementing agents to ensure proper XML structure following Anthropic best practices.

248 stars

Best use case

xml-standards is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

XML tag structure patterns for Claude Code agents and commands. Use when designing or implementing agents to ensure proper XML structure following Anthropic best practices.

Teams using xml-standards should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/xml-standards/SKILL.md --create-dirs "https://raw.githubusercontent.com/MadAppGang/claude-code/main/plugins/agentdev/skills/xml-standards/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/xml-standards/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How xml-standards Compares

Feature / Agentxml-standardsStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

XML tag structure patterns for Claude Code agents and commands. Use when designing or implementing agents to ensure proper XML structure following Anthropic best practices.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

plugin: agentdev
updated: 2026-01-20

# XML Tag Standards

## Core Tags (Required for ALL Agents/Commands)

### `<role>`
Defines agent identity and purpose.

```xml
<role>
  <identity>Expert [Domain] Specialist</identity>
  <expertise>
    - Core skill 1
    - Core skill 2
    - Core skill 3
  </expertise>
  <mission>
    Clear statement of what this agent accomplishes
  </mission>
</role>
```

### `<instructions>`
Defines behavior constraints and workflow.

```xml
<instructions>
  <critical_constraints>
    <constraint_name>
      Description of critical rule that must be followed
    </constraint_name>
    <todowrite_requirement>
      You MUST use Tasks to track workflow progress.
    </todowrite_requirement>
  </critical_constraints>

  <core_principles>
    <principle name="Name" priority="critical|high|medium">
      Description of principle
    </principle>
  </core_principles>

  <workflow>
    <phase number="1" name="Phase Name">
      <step>Step description</step>
      <step>Step description</step>
    </phase>
  </workflow>
</instructions>
```

### `<knowledge>`
Domain-specific best practices and templates.

```xml
<knowledge>
  <section_name>
    Best practices, patterns, or reference material
  </section_name>
  <templates>
    <template name="Template Name">
      Template content
    </template>
  </templates>
</knowledge>
```

### `<examples>`
Concrete usage scenarios (2-4 required).

```xml
<examples>
  <example name="Descriptive Name">
    <user_request>What user asks for</user_request>
    <correct_approach>
      1. Step one
      2. Step two
      3. Step three
    </correct_approach>
  </example>
</examples>
```

### `<formatting>`
Communication style and output format.

```xml
<formatting>
  <communication_style>
    - Style guideline 1
    - Style guideline 2
  </communication_style>
  <completion_message_template>
    Template for completion messages
  </completion_message_template>
</formatting>
```

---

## Specialized Tags by Agent Type

### Orchestrators (Commands)

```xml
<orchestration>
  <allowed_tools>Task, Bash, Read, TaskCreate, TaskUpdate, TaskList, TaskGet, AskUserQuestion</allowed_tools>
  <forbidden_tools>Write, Edit</forbidden_tools>

  <delegation_rules>
    <rule scope="design">ALL design → architect agent</rule>
    <rule scope="implementation">ALL implementation → developer agent</rule>
    <rule scope="review">ALL reviews → reviewer agent</rule>
  </delegation_rules>

  <phases>
    <phase number="1" name="Phase Name">
      <objective>What this phase achieves</objective>
      <steps>
        <step>Step description</step>
      </steps>
      <quality_gate>Exit criteria for this phase</quality_gate>
    </phase>
  </phases>
</orchestration>

<error_recovery>
  <strategy>
    Recovery steps for common failures
  </strategy>
</error_recovery>
```

### Planners (Architects)

```xml
<planning_methodology>
  <approach>How planning is performed</approach>
  <deliverables>What planning produces</deliverables>
</planning_methodology>

<gap_analysis>
  <checklist>Items to verify during planning</checklist>
</gap_analysis>

<output_structure>
  <format>Structure of planning output</format>
</output_structure>
```

### Implementers (Developers)

```xml
<implementation_standards>
  <file_writing_standards>
    <standard name="Standard Name">Description</standard>
  </file_writing_standards>

  <quality_checks mandatory="true">
    <check name="check_name" order="1">
      <tool>Tool name</tool>
      <command>Command to run</command>
      <requirement>What must pass</requirement>
      <on_failure>Recovery action</on_failure>
    </check>
  </quality_checks>

  <validation_checks>
    <check order="1" name="Check Name">
      Validation criteria
    </check>
  </validation_checks>
</implementation_standards>
```

### Reviewers

```xml
<review_criteria>
  <focus_areas>
    <area name="Area Name" priority="critical|high|medium" weight="20%">
      **Check:**
      - Item to verify
      - Item to verify

      **Common Issues:**
      - Issue description

      **Critical if**: Condition for critical severity
      **High if**: Condition for high severity
    </area>
  </focus_areas>

  <feedback_format>
    Template for review feedback
  </feedback_format>
</review_criteria>

<approval_criteria>
  <status name="PASS">Criteria for passing</status>
  <status name="CONDITIONAL">Criteria for conditional approval</status>
  <status name="FAIL">Criteria for failure</status>
</approval_criteria>
```

### Testers

```xml
<testing_strategy>
  <approach>Testing methodology</approach>
  <test_types>
    <type name="Type Name">Description</type>
  </test_types>
</testing_strategy>

<coverage_requirements>
  <requirement>Coverage criteria</requirement>
</coverage_requirements>
```

---

## Nesting Rules

1. **Proper Hierarchy** - Tags must be properly nested
2. **Closing Tags** - All opening tags must have closing tags
3. **Semantic Attributes** - Use `name`, `priority`, `order` attributes
4. **Consistent Naming** - Use lowercase-with-hyphens for tag names

## Code Blocks in XML

```xml
<template name="Example">
```language
// code here - note: opening ``` directly under tag
```
</template>
```

## Character Escaping

Only in XML attribute values and text nodes (NOT in code blocks):
- `&lt;` for `<`
- `&gt;` for `>`
- `&amp;` for `&`

Related Skills

mcp-standards

248
from MadAppGang/claude-code

MCP server standardization patterns for Claude Code plugins. Use when implementing MCP servers, designing tool interfaces, configuring MCP transports, or standardizing MCP naming conventions. Trigger keywords - "MCP", "MCP server", "MCP tools", "MCP transport", "tool naming", "MCP configuration".

documentation-standards

248
from MadAppGang/claude-code

Use when writing README files, API documentation, user guides, or technical documentation following industry standards from Google, Microsoft, and GitLab style guides.

test-skill

248
from MadAppGang/claude-code

A test skill for validation testing. Use when testing skill parsing and validation logic.

bad-skill

248
from MadAppGang/claude-code

This skill has invalid YAML in frontmatter

release

248
from MadAppGang/claude-code

Plugin release process for MAG Claude Plugins marketplace. Covers version bumping, marketplace.json updates, git tagging, and common mistakes. Use when releasing new plugin versions or troubleshooting update issues.

openrouter-trending-models

248
from MadAppGang/claude-code

Fetch trending programming models from OpenRouter rankings. Use when selecting models for multi-model review, updating model recommendations, or researching current AI coding trends. Provides model IDs, context windows, pricing, and usage statistics from the most recent week.

Claudish Integration Skill

248
from MadAppGang/claude-code

**Version:** 1.0.0

transcription

248
from MadAppGang/claude-code

Audio/video transcription using OpenAI Whisper. Covers installation, model selection, transcript formats (SRT, VTT, JSON), timing synchronization, and speaker diarization. Use when transcribing media or generating subtitles.

final-cut-pro

248
from MadAppGang/claude-code

Apple Final Cut Pro FCPXML format reference. Covers project structure, timeline creation, clip references, effects, and transitions. Use when generating FCP projects or understanding FCPXML structure.

ffmpeg-core

248
from MadAppGang/claude-code

FFmpeg fundamentals for video/audio manipulation. Covers common operations (trim, concat, convert, extract), codec selection, filter chains, and performance optimization. Use when planning or executing video processing tasks.

statusline-customization

248
from MadAppGang/claude-code

Configuration reference and troubleshooting for the statusline plugin — sections, themes, bar widths, and script architecture

technical-audit

248
from MadAppGang/claude-code

Technical SEO audit methodology including crawlability, indexability, and Core Web Vitals analysis. Use when auditing pages or sites for technical SEO issues.