sop-structure
Use when structuring Standard Operating Procedures with proper sections, organization, and markdown formatting. Covers SOP anatomy and section organization.
What this skill does
# SOP Structure
Well-structured SOPs follow consistent patterns that make them easy to understand, maintain, and execute. This skill covers the anatomy of effective SOPs and how to organize sections.
## Key Concepts
### Standard SOP Anatomy
Every SOP should include these core sections:
1. **Title**: Clear, action-oriented description
2. **Overview**: Brief summary of purpose and use cases
3. **Parameters**: Configurable inputs for reusability
4. **Prerequisites**: Required tools, knowledge, or setup
5. **Steps**: Sequential instructions for execution
6. **Success Criteria**: How to verify completion
7. **Error Handling**: What to do when things go wrong
8. **Related SOPs**: Links to related workflows
### File Naming Convention
SOP files MUST use the `.sop.md` extension:
```
✅ deployment-checklist.sop.md
✅ code-review-security.sop.md
✅ database-migration.sop.md
❌ deployment.md (missing .sop)
❌ checklist.sop.txt (wrong file type)
❌ SOP-Deployment.md (incorrect format)
```
## Best Practices
### Title Section
```markdown
# {Action Verb} {Specific Outcome}
Short form: Use kebab-case filename
Long form: Use Title Case heading
```
**Examples:**
```markdown
# Generate API Documentation
# Implement Feature Using TDD
# Review Pull Request for Security
```
### Overview Section
The overview should answer three questions:
1. **What**: What does this SOP accomplish?
2. **When**: When should you use this SOP?
3. **Why**: Why use this approach?
```markdown
## Overview
This SOP guides you through implementing new features using Test-Driven
Development (TDD). Use this when adding functionality that requires high
confidence in correctness. TDD ensures comprehensive test coverage and
reduces regression risk.
```
### Parameters Section
Define all configurable inputs at the beginning:
```markdown
## Parameters
- **Input Variable**: {variable_name} - Description and example values
- **Configuration**: {config_option} - Available options (option1, option2, option3)
- **Path**: {file_path} - Expected format and constraints
```
**Example:**
```markdown
## Parameters
- **Repository Path**: {repository_path} - Absolute path to git repository
- **Output Format**: {output_format} - Documentation format (markdown, html, pdf)
- **Verbosity**: {verbosity} - Detail level (concise, standard, comprehensive)
- **Include Tests**: {include_tests} - Whether to include test examples (yes, no)
```
### Prerequisites Section
List required tools, knowledge, and setup:
```markdown
## Prerequisites
### Required Tools
- Tool name (version X.X or higher)
- Another tool (version Y.Y or higher)
### Required Knowledge
- Understanding of concept A
- Familiarity with technology B
### Required Setup
- Environment variable {VAR_NAME} must be set
- Configuration file {config.json} must exist
```
**Example:**
```markdown
## Prerequisites
### Required Tools
- Node.js (v18 or higher)
- npm (v8 or higher)
- Git (v2.30 or higher)
### Required Knowledge
- Understanding of JavaScript/TypeScript
- Familiarity with testing frameworks
- Git workflow basics
### Required Setup
- Package.json exists in project root
- Test framework is installed (Jest, Vitest, or Mocha)
- Git repository is initialized
```
### Steps Section
Structure steps hierarchically:
```markdown
## Steps
1. First major step
- Sub-step or detail
- Another sub-step
- Additional context
2. Second major step
- Implementation detail
- Expected outcome
3. Third major step
- Specific action
- Validation step
```
**With Validation:**
```markdown
## Steps
1. Analyze codebase structure
- Identify main entry points
- Map directory organization
- List dependencies
- **Validation**: Confirm all entry points are documented
2. Extract patterns
- Identify design patterns
- Document data flow
- Note architectural decisions
- **Validation**: Verify patterns are correctly identified
3. Generate documentation
- Create overview section
- Document public APIs
- Add usage examples
- **Validation**: Ensure documentation builds without errors
```
### Success Criteria Section
Define measurable outcomes:
```markdown
## Success Criteria
- [ ] Specific measurable outcome 1
- [ ] Specific measurable outcome 2
- [ ] Specific measurable outcome 3
- [ ] All tests pass
- [ ] Documentation is complete
```
**Example:**
```markdown
## Success Criteria
- [ ] All new code has test coverage ≥ 90%
- [ ] All tests pass without warnings
- [ ] Code passes linter with zero errors
- [ ] Documentation includes usage examples
- [ ] Changes follow existing code patterns
```
### Error Handling Section
Provide guidance for common failures:
```markdown
## Error Handling
### Error: {Error Name or Code}
**Symptoms**: How this error manifests
**Cause**: Why this error occurs
**Resolution**:
1. First troubleshooting step
2. Second troubleshooting step
3. Alternative approach if steps fail
```
**Example:**
```markdown
## Error Handling
### Error: Tests Fail to Run
**Symptoms**: Test runner exits with error code, tests don't execute
**Cause**: Missing dependencies, incorrect test framework configuration, or environment issues
**Resolution**:
1. Verify test framework is installed: `npm list {test-framework}`
2. Check test configuration file exists and is valid
3. Ensure NODE_ENV is set correctly
4. If issue persists, reinstall dependencies: `rm -rf node_modules && npm install`
### Error: Type Errors During Build
**Symptoms**: TypeScript compiler reports type mismatches
**Cause**: Incorrect type annotations or missing type definitions
**Resolution**:
1. Run type checker: `npx -y --package typescript tsc`
2. Review error messages for specific type issues
3. Add necessary type annotations
4. Install missing @types packages if needed
```
### Related SOPs Section
Link to related workflows:
```markdown
## Related SOPs
- **{sop-name}**: Brief description of when to use this instead
- **{another-sop}**: How this complements the current SOP
```
**Example:**
```markdown
## Related SOPs
- **code-review**: Use after completing feature implementation to get peer review
- **deployment-checklist**: Use after code review passes to deploy changes
- **rollback-procedure**: Use if deployment fails or issues are discovered
```
## Examples
### Complete SOP Structure Example
```markdown
# Deploy Application to Production
## Overview
This SOP guides you through deploying application changes to production
environment safely. Use this after code review approval and successful
staging deployment. This ensures consistent deployment process and reduces
production incidents.
## Parameters
- **Environment**: {environment} - Target environment (staging, production)
- **Version**: {version} - Semantic version number (e.g., 1.2.3)
- **Rollback Plan**: {rollback_plan} - Strategy if deployment fails (automatic, manual)
## Prerequisites
### Required Tools
- kubectl (v1.24 or higher)
- Docker (v20.10 or higher)
- AWS CLI (v2.0 or higher)
### Required Knowledge
- Understanding of Kubernetes deployments
- Familiarity with application architecture
- Access to production monitoring dashboards
### Required Setup
- Production credentials configured in ~/.kube/config
- Docker registry authentication set up
- Monitoring alerts configured
## Steps
1. Pre-deployment verification
- Verify {version} passed all staging tests
- Confirm database migrations are ready
- Check rollback procedures are documented
- **Validation**: All tests passed, migrations reviewed
2. Build and push container image
- Build Docker image with tag {version}
- Run security scan on image
- Push to container registry
- **Validation**: Image pushed successfully, no critical vulnerabilities
3. Apply database migrations
- Backup production database
- Test migrations on backup
- Apply migrations to production
- **Validation**: Migrations applied, database accessible
4. Deploy application
- UpdRelated in Writing & Docs
jax-development
IncludedUse this skill when the user is writing, debugging, profiling, refactoring, reviewing, benchmarking, parallelising, exporting, or explaining JAX code, or when they mention JAX, jax.numpy, jit, grad, value_and_grad, vmap, scan, lax, random keys, pytrees, jax.Array, sharding, Mesh, PartitionSpec, NamedSharding, pmap, shard_map, Pallas, XLA, StableHLO, checkify, profiler, or the JAX repo. It helps turn NumPy or PyTorch-style code into pure functional JAX, fix tracer/control-flow/shape/PRNG bugs, remove recompiles and host-device syncs, choose transforms and sharding strategies, inspect jaxpr/lowering/IR, and benchmark compiled code correctly.
nature-article-writer
IncludedDrafts, rewrites, diagnostically critiques, and style-calibrates primary research manuscripts for Nature and Nature Portfolio journals. Use when the user wants a Nature-style title, summary paragraph or abstract, introduction, results, discussion, methods, figure legends, presubmission enquiry, cover letter, reviewer response, or when a scientific draft sounds generic, jargon-heavy, structurally weak, or AI-ish and needs precise, broad-reader-friendly prose without inventing data, analyses, or references. Best for primary research articles and letters rather than reviews or press releases unless explicitly adapting one.
deckrd
IncludedDocument-driven framework that derives requirements, specifications, implementation plans, and executable tasks from goals through structured AI dialogue. Use when user says "write requirements", "create spec", "plan implementation", "derive tasks", "structure this feature", "break down into tasks", or "document this module". Also use for reverse engineering existing code into docs (/deckrd rev). Do NOT use for direct code writing — use /deckrd-coder after tasks are generated. Do NOT use when the user only wants to run or fix existing code without planning.
clinical-decision-support
IncludedGenerate professional clinical decision support (CDS) documents for pharmaceutical and clinical research settings, including patient cohort analyses (biomarker-stratified with outcomes) and treatment recommendation reports (evidence-based guidelines with decision algorithms). Supports GRADE evidence grading, statistical analysis (hazard ratios, survival curves, waterfall plots), biomarker integration, and regulatory compliance. Outputs publication-ready LaTeX/PDF format optimized for drug development, clinical research, and evidence synthesis.
handling-sf-data
IncludedSalesforce data operations with 130-point scoring. Use this skill to create, update, delete, bulk import/export, generate test data, and clean up org records using sf CLI and anonymous Apex. TRIGGER when: user creates test data, performs bulk import/export, uses sf data CLI commands, needs data factory patterns for Apex tests, or needs to seed/clean records in a Salesforce org. DO NOT TRIGGER when: SOQL query writing only (use querying-soql), Apex test execution (use running-apex-tests), or metadata deployment (use deploying-metadata).
accelint-ac-to-playwright
IncludedConvert and validate acceptance criteria for Playwright test automation. Use when user asks to (1) review/evaluate/check if AC are ready for automation, (2) assess if AC can be converted as-is, (3) validate AC quality for Playwright, (4) turn AC into tests, (5) generate tests from acceptance criteria, (6) convert .md bullets or .feature Gherkin files to Playwright specs, (7) create test automation from requirements. Handles both bullet-style markdown and Gherkin syntax with JSON test plan generation and validation.