Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .claude/commands/doc-concept.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
Create conceptual documentation following DITA-style concept topic structure.

Generate comprehensive conceptual documentation that includes:

1. **Overview**: High-level explanation of what this concept is
2. **Context**: When and why this concept is relevant
3. **Key Components**: Break down the main elements or aspects
4. **Relationships**: How this concept relates to other concepts in the system
5. **Use Cases**: Common scenarios where this concept applies
6. **Benefits/Considerations**: Advantages and important considerations

Structure the content with:
- Clear headings and subheadings
- Logical flow from general to specific
- Cross-references to related task and reference documentation
- Examples where helpful for understanding

Focus on the "what" and "why" rather than step-by-step procedures.
25 changes: 25 additions & 0 deletions .claude/commands/doc-map.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
Create a documentation map or content organization structure following DITA-style map principles.

Generate a hierarchical content organization that includes:

1. **Content Inventory**: Survey existing documentation and identify gaps
2. **Topic Hierarchy**: Organize content into logical groups:
- Getting Started / Introduction
- Concepts (understanding)
- Tasks (procedures)
- Reference (lookup)
- Troubleshooting
- Advanced Topics
3. **Content Relationships**: Define how topics relate to each other
4. **Navigation Structure**: Logical flow and pathways through content
5. **Metadata Strategy**: Consistent tagging and categorization
6. **Content Reuse Plan**: Identify reusable components and snippets

Create:
- Table of contents with hierarchical structure
- Content matrix showing topic types and audiences
- Cross-reference map showing relationships between topics
- Templates and style guide recommendations
- Content maintenance and update procedures

Focus on creating a cohesive, navigable documentation ecosystem that serves different user needs and experience levels.
27 changes: 27 additions & 0 deletions .claude/commands/doc-reference.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
Create reference documentation following DITA-style reference topic structure.

Generate comprehensive reference material that includes:

1. **Purpose**: Brief description of what this reference covers
2. **Syntax/Structure**: Formal syntax, schema, or structure definition
3. **Parameters/Properties**: Detailed list with:
- Name and type
- Description and purpose
- Required vs optional
- Default values
- Valid values or constraints
- Examples
4. **Return Values/Outputs**: What the API/function/command returns
5. **Examples**: Multiple practical examples showing usage
6. **Error Conditions**: Possible errors and their meanings
7. **Related Items**: Links to related APIs, functions, or concepts

Structure with:
- Consistent formatting for technical elements
- Tables for parameter lists and comparisons
- Code blocks with proper syntax highlighting
- Clear categorization and grouping
- Alphabetical or logical ordering where appropriate
- Cross-references to concept and task documentation

Focus on precise, factual information for quick lookup and integration.
27 changes: 27 additions & 0 deletions .claude/commands/doc-reuse.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
Create reusable content components and manage content reuse following DITA principles.

Identify and create reusable documentation elements including:

1. **Content Analysis**: Review existing content for reuse opportunities:
- Common procedures or explanations
- Repeated warnings or notes
- Standard definitions or concepts
- Boilerplate text or disclaimers
2. **Reusable Components**: Create modular content pieces:
- Snippets for common procedures
- Template structures for consistent formatting
- Standard definitions and glossary terms
- Common troubleshooting steps
- Boilerplate sections (prerequisites, legal notices)
3. **Content Variables**: Define dynamic content elements:
- Product names and versions
- URLs and links
- Contact information
- Configuration values
4. **Conditional Content**: Plan content variations for:
- Different audiences (admin, developer, end-user)
- Different products or versions
- Different platforms or environments
5. **Reuse Strategy**: Document how to maintain and update shared content

Focus on creating a sustainable content ecosystem that reduces duplication while maintaining consistency and accuracy across all documentation.
35 changes: 35 additions & 0 deletions .claude/commands/doc-review.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
Perform a comprehensive documentation review using New Relic standards.

Review the current documentation and provide feedback on:

1. **Content Quality**:
- Accuracy and technical correctness
- Completeness of information
- Logical flow and organization
- Clear problem-solution alignment

2. **New Relic Style Compliance**:
- Voice and tone consistency
- Terminology usage (check against style guide)
- Code example formatting
- Heading structure and hierarchy

3. **User Experience**:
- Scannability and readability
- Appropriate use of lists, tables, and callouts
- Cross-references and navigation
- Mobile-friendly formatting

4. **Technical Standards**:
- MDX syntax correctness
- Frontmatter completeness
- Component usage consistency
- SEO optimization (titles, descriptions)

5. **Accessibility**:
- Alt text for images
- Descriptive link text
- Proper heading hierarchy
- Color contrast considerations

Provide specific, actionable feedback with line numbers and suggested improvements.
23 changes: 23 additions & 0 deletions .claude/commands/doc-task.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
Create task-oriented documentation following DITA-style task topic structure.

Generate step-by-step procedural documentation that includes:

1. **Purpose**: Brief statement of what the task accomplishes
2. **Prerequisites**: Required knowledge, permissions, or setup needed
3. **Context**: When you would perform this task
4. **Procedure**: Clear, numbered steps with:
- Action verbs starting each step
- Expected results or confirmations
- Code examples, commands, or UI interactions
- Screenshots or diagrams where helpful
5. **Verification**: How to confirm the task was completed successfully
6. **Troubleshooting**: Common issues and solutions
7. **Next Steps**: What to do after completing this task

Structure with:
- Scannable numbered or bulleted lists
- Clear action-oriented language
- Consistent formatting for code, UI elements, and file paths
- Cross-references to related concept and reference documentation

Focus on the "how" with clear, actionable instructions.
193 changes: 193 additions & 0 deletions .claude/json-prompt-guide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,193 @@
# JSON Prompt Engineering Guide for Technical Writers

## Template Structure

```json
{
"context": {
"project": "New Relic Documentation",
"audience": "developers|administrators|end-users",
"doc_type": "concept|task|reference|tutorial",
"existing_content": "file_path or description",
"related_docs": ["list", "of", "related", "files"]
},
"task": {
"primary_goal": "clear, specific objective",
"deliverable": "what you want created/updated",
"scope": "boundaries and limitations",
"success_criteria": ["measurable", "outcomes"]
},
"requirements": {
"style_guide": "New Relic voice and tone",
"format": "MDX with specific components",
"structure": "headings, sections, flow",
"examples": "code samples, screenshots, etc.",
"cross_references": "links to maintain"
},
"constraints": {
"length": "word count or section limits",
"technical_level": "beginner|intermediate|advanced",
"compliance": "security, legal, brand requirements",
"deadline": "time constraints if relevant"
},
"output_format": {
"structure": "specific markdown/MDX format",
"components": "New Relic doc components to use",
"frontmatter": "required metadata fields",
"review_checklist": "what to verify before completion"
}
}
```

## Example Templates by Documentation Type

### 1. New Feature Documentation
```json
{
"context": {
"project": "New Relic Documentation",
"audience": "developers",
"doc_type": "concept + task",
"existing_content": "none - new feature",
"related_docs": ["src/content/docs/apis/", "src/content/docs/integrations/"]
},
"task": {
"primary_goal": "Introduce new Security RX feature",
"deliverable": "Complete feature documentation with overview and setup",
"scope": "Cover core functionality, exclude advanced configurations",
"success_criteria": ["User can understand the feature", "User can complete basic setup", "SEO optimized"]
},
"requirements": {
"style_guide": "New Relic conversational but authoritative tone",
"format": "MDX with code blocks and callouts",
"structure": "Overview → Prerequisites → Setup → Verification → Next Steps",
"examples": "Working code samples, API calls, configuration files",
"cross_references": "Link to related security and API docs"
},
"constraints": {
"length": "1500-2500 words maximum",
"technical_level": "intermediate developers",
"compliance": "Include security best practices warnings",
"deadline": "none specified"
},
"output_format": {
"structure": "Standard New Relic doc template",
"components": "Use Callout, CodeBlock, InlineCode components",
"frontmatter": "Include title, description, redirects, freshnessValidatedDate",
"review_checklist": ["Accuracy", "Completeness", "Style compliance", "Link validation"]
}
}
```

### 2. Documentation Update/Revision
```json
{
"context": {
"project": "New Relic Documentation",
"audience": "security engineers",
"doc_type": "reference update",
"existing_content": "src/content/docs/vulnerability-management/overview.mdx",
"related_docs": ["aws.mdx", "security NRQL examples"]
},
"task": {
"primary_goal": "Update Security RX overview with latest features",
"deliverable": "Revised overview page with current capabilities",
"scope": "Update existing sections, add 2-3 new sections",
"success_criteria": ["Reflects current product state", "Maintains existing structure", "Improves user onboarding"]
},
"requirements": {
"style_guide": "Match existing doc voice, update outdated terms",
"format": "Maintain current MDX structure and components",
"structure": "Keep existing headings, expand content within",
"examples": "Update code samples to current API versions",
"cross_references": "Verify all internal links still work"
},
"constraints": {
"length": "Don't exceed current length by more than 30%",
"technical_level": "Match current intermediate level",
"compliance": "Ensure security recommendations are current",
"deadline": "none specified"
},
"output_format": {
"structure": "Preserve existing heading structure",
"components": "Use same components as original",
"frontmatter": "Update freshnessValidatedDate, keep other metadata",
"review_checklist": ["No broken functionality", "Backward compatibility", "Updated examples work"]
}
}
```

### 3. API Documentation Generation
```json
{
"context": {
"project": "New Relic Documentation",
"audience": "API developers",
"doc_type": "reference",
"existing_content": "OpenAPI spec or code comments",
"related_docs": ["authentication guides", "SDK documentation"]
},
"task": {
"primary_goal": "Generate comprehensive API reference from code",
"deliverable": "Complete API endpoint documentation",
"scope": "All public endpoints, exclude internal/deprecated ones",
"success_criteria": ["All endpoints documented", "Working code examples", "Clear error handling"]
},
"requirements": {
"style_guide": "Technical but accessible, New Relic API doc standards",
"format": "MDX with consistent parameter tables and code blocks",
"structure": "Endpoint → Parameters → Examples → Responses → Errors",
"examples": "cURL and JavaScript/Python examples for each endpoint",
"cross_references": "Link to authentication, rate limiting, SDK docs"
},
"constraints": {
"length": "Comprehensive but scannable",
"technical_level": "Intermediate to advanced developers",
"compliance": "Include rate limiting and security considerations",
"deadline": "none specified"
},
"output_format": {
"structure": "New Relic API reference template",
"components": "Use Table, CodeBlock, Callout for warnings",
"frontmatter": "Include API version, last updated, related endpoints",
"review_checklist": ["All examples tested", "Parameter types correct", "Error codes accurate"]
}
}
```

## Quick Reference Prompts

### Documentation Review
```json
{
"context": {"existing_content": "file_path", "audience": "target_user"},
"task": {"primary_goal": "comprehensive review", "deliverable": "actionable feedback"},
"requirements": {"style_guide": "New Relic standards", "format": "current MDX"},
"output_format": {"structure": "line-by-line feedback with suggestions"}
}
```

### Content Gap Analysis
```json
{
"context": {"existing_content": "doc_section", "related_docs": ["comparative_files"]},
"task": {"primary_goal": "identify missing content", "deliverable": "gap analysis + recommendations"},
"requirements": {"style_guide": "match existing", "format": "structured analysis"},
"output_format": {"structure": "gaps → impact → priority → solutions"}
}
```

## Best Practices for JSON Prompts

1. **Be Specific**: Use exact file paths, not generic descriptions
2. **Set Clear Boundaries**: Define what's in/out of scope
3. **Include Success Criteria**: How will you know it's done well?
4. **Reference Standards**: Always specify New Relic style requirements
5. **Plan for Review**: Include what should be checked before publishing

## Integration with Claude Code MCP

- Use GitHub MCP to reference actual files and PRs
- Leverage exploration agents for understanding doc relationships
- Use task agents for complex multi-step documentation projects
- Include file paths that Claude Code can directly access and analyze
Loading
Loading