compose-email
The compose-email command generates professional emails using the What-Why-How framework, which structures messages with an opening statement of purpose, contextual background, and clear calls-to-action. Use this tool when drafting communications to colleagues, stakeholders, or leadership, as it gathers recipient type and email purpose to tailor tone and technical jargon appropriately, then applies best practices for subject lines, paragraph length, and formatting before delivering a complete draft.
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/softaworks/agent-toolkit/HEAD/commands/compose-email.md -o ~/.claude/commands/compose-email.mdcompose-email.md
# Draft Professional Email
Generate a professional, well-structured email using communication best practices for software developers.
## Arguments
`$ARGUMENTS` - Optional context, topic, or existing draft to refine
## Workflow
### Step 1: Gather Context
If `$ARGUMENTS` is empty or insufficient, use AskUserQuestion to gather:
**Question 1: Recipient Type** (header: "Audience")
- Technical peer (developer, engineer)
- Non-technical stakeholder (PM, executive, customer)
- Cross-functional team (mixed audience)
- Manager or leadership
**Question 2: Email Purpose** (header: "Purpose")
- Status update or progress report
- Request (review, approval, resources)
- Information sharing (FYI, announcement)
- Escalation or raising concern
- Following up on prior conversation
**Question 3: Urgency** (header: "Urgency")
- Urgent - needs response today
- Standard - within 1-2 days
- Low priority - for awareness only
### Step 2: Apply Communication Framework
Use the **What-Why-How** structure:
1. **WHAT** (Opening - 1-2 sentences)
- Lead with the key message or request
- State the purpose immediately
- No throat-clearing ("I hope this email finds you well...")
2. **WHY** (Context - 2-3 sentences)
- Provide necessary background
- Explain relevance to the recipient
- Include only essential context
3. **HOW** (Action - clear next steps)
- Specific call-to-action
- Clear deadline if applicable
- Who needs to do what
### Step 3: Apply Email Best Practices
**Subject Line:**
- Specific and scannable (5-8 words ideal)
- Include action needed: "[Action Required]", "[FYI]", "[Decision Needed]"
- Include deadline if urgent: "[Due Friday]"
**Body Structure:**
- Bullets for multiple points (3-5 max)
- Bold key information
- One topic per email
- Short paragraphs (2-3 sentences max)
**Tone Calibration by Audience:**
| Audience | Tone | Jargon Level |
| --- | --- | --- |
| Technical peer | Direct, precise | High (use technical terms) |
| Non-technical | Business-focused | Low (translate jargon) |
| Cross-functional | Balanced | Medium (explain as needed) |
| Leadership | Concise, impact-focused | Low (focus on outcomes) |
### Step 4: Generate Draft
Produce a complete email with:
```markdown
## Email Draft
**Subject:** [Clear, specific subject line]
---
[Opening - WHAT: Key message/request]
[Context - WHY: Background and relevance]
[Body - Details as needed, use bullets for lists]
[Closing - HOW: Clear call-to-action]
[Sign-off]
```
### Step 5: Offer Refinements
After presenting the draft, offer:
1. **Tone adjustment** - Make more/less formal
2. **Length adjustment** - Expand or condense
3. **Jargon translation** - Adjust technical language level
4. **Format change** - Different structure for different medium (Slack, Teams)
## Example Usage
```bash
# With context
/soft-skills:draft-email Need to ask team lead for deadline extension on API migration
# Refine existing draft
/soft-skills:draft-email "Hi team, wanted to let you know about the deployment..."
# Start fresh
/soft-skills:draft-email
```
## Output
Present the draft in a clear format showing:
1. **Subject line** with rationale
2. **Email body** with WHAT/WHY/HOW sections labeled
3. **Refinement options** for iteration
## Anti-Patterns to Avoid
- Generic subjects ("Quick question", "Update", "FYI")
- Burying the request at the end
- Wall of text without structure
- Missing clear call-to-action
- Over-apologizing or excessive hedging
- CC'ing unnecessarilyRefactor bloated AGENTS.md, CLAUDE.md, or similar agent instruction files to follow progressive disclosure principles. Splits monolithic files into organized, linked documentation.
Use this agent when you need to visualize UI concepts through ASCII mockups before implementation. Examples: <example>Context: User has an idea for a dashboard layout with data tables and charts. user: 'I want to create a dashboard that shows user analytics with a sidebar navigation, main content area with charts, and a data table below' assistant: 'I'll use the ascii-ui-mockup-generator agent to create multiple ASCII mockup variations for your dashboard concept.' <commentary>The user wants to visualize a UI concept, so use the ascii-ui-mockup-generator to create multiple ASCII representations they can choose from.</commentary></example> <example>Context: User is designing a form layout with multiple input fields. user: 'I need a contact form with name, email, message fields and a submit button' assistant: 'Let me use the ascii-ui-mockup-generator to create several ASCII mockup options for your contact form layout.' <commentary>Since the user needs to visualize form layouts, use the ascii-ui-mockup-generator to provide multiple ASCII design options.</commentary></example>
Create API handoff documentation for frontend developers. Use when backend work is complete and needs to be documented for frontend integration, or user says 'create handoff', 'document API', 'frontend handoff', or 'API documentation'.
Generate architecture documentation using C4 model Mermaid diagrams. Use when asked to create architecture diagrams, document system architecture, visualize software structure, create C4 diagrams, or generate context/container/component/deployment diagrams. Triggers include "architecture diagram", "C4 diagram", "system context", "container diagram", "component diagram", "deployment diagram", "document architecture", "visualize architecture".
codebase-pattern-finder is a useful subagent_type for finding similar implementations, usage examples, or existing patterns that can be modeled after. It will give you concrete code examples based on what you're looking for! It's sorta like codebase-locator, but it will not only tell you the location of files, it will also give you code details!
Use when the user asks to run Codex CLI (codex exec, codex resume) or references OpenAI Codex for code analysis, refactoring, or automated editing. Uses GPT-5.2 by default for state-of-the-art software engineering.
Create a detailed implementation plan using Codex 5.2 with high reasoning
This skill should be used when creating a Claude Code slash command. Use when users ask to "create a command", "make a slash command", "add a command", or want to document a workflow as a reusable command. Essential for creating optimized, agent-executable slash commands with proper structure and best practices.