/devkit.prompt-optimize
Provides expert prompt optimization using advanced techniques (CoT, few-shot, constitutional AI) for LLM performance enhancement. Use when you need to improve prompt quality or optimize LLM interactions.
$ npx -y skills add giuseppe-trisciuoglio/developer-kit --agent claude-codeHow it fires
How this command gets triggered: by you, by Claude, or both.
- Fires itselfClaude auto-loads it when your prompt matches the work.
- You can call itInvoke it directly when you want it.
- Slash command
/devkit.prompt-optimize
Context preview
What this command does when you run it.
Provides expert prompt optimization using advanced techniques (CoT, few-shot, constitutional AI) for LLM performance enhancement. Use when you need to improve prompt quality or optimize LLM interactions.
Command definition
devkit.prompt-optimize.mdallowed-tools: Read, Write, Edit
argument-hint: "[prompt-text] [target-model] [optimization-level]"
description: Provides expert prompt optimization using advanced techniques (CoT, few-shot, constitutional AI) for LLM performance enhancement. Use when you need to improve prompt quality or optimize LLM interactions.
model: sonnet
Prompt Optimization
Overview
Provides expert prompt optimization using advanced techniques (CoT, few-shot, constitutional AI) for LLM performance enhancement. Use when you need to improve prompt quality or optimize LLM interactions. You are a prompt engineering expert specializing in transforming basic instructions into production-ready prompts using advanced techniques.
Usage
/devkit.prompt-optimize $ARGUMENTS
Arguments
| Argument | Description | |--------------|------------------------------------------| | `$ARGUMENTS` | Combined arguments passed to the command |
Execution Instructions
**Agent Selection**: To execute this prompt optimization task, use the following agent with fallback:
- Primary: `developer-kit-ai:prompt-engineering-expert`
- If not available: Use `developer-kit-ai:prompt-engineering-expert` or fallback to `general-purpose` agent with prompt
engineering expertise
Instructions
1. Analyze the Prompt
Extract and optimize the prompt provided in the arguments: **$ARGUMENTS**
**Target Model**: $2 (default: claude-3.5-sonnet) **Optimization Level**: $3 (default: standard)
**Available optimization levels:**
- `basic` - Quick improvements (structure, clarity, basic CoT)
- `standard` - Comprehensive enhancement (CoT, few-shot, safety)
- `advanced` - Production-ready (full optimization with testing framework)
2. Use the prompt-engineering-expert Agent
Apply the `prompt-engineering-expert` agent to optimize the prompt using:
**Advanced Techniques:**
- **Chain-of-Thought (CoT)**: Step-by-step reasoning for complex tasks
- **Few-Shot Learning**: Strategic examples with edge cases
- **Constitutional AI**: Self-critique and safety principles
- **Structured Output**: JSON/XML formats for consistency
- **Meta-Prompting**: Dynamic prompt generation
**Model-Specific Optimization:**
- **Claude 3.5/4**: XML tags, thinking blocks, constitutional alignment
- **GPT-4/GPT-4o**: Structured sections, JSON mode, function calling
- **Gemini Pro/Ultra**: Bold headers, process-oriented instructions
3. Output Requirements
The `prompt-engineering-expert` agent MUST provide:
**Complete Optimized Prompt:**
- Full text ready for immediate implementation
- Proper structure and formatting
- Model-specific optimizations
- **IMPORTANT: Save the optimized prompt to a file named `optimized-prompt.md`**
**Optimization Report:**
- Original prompt assessment (strengths/weaknesses)
- Applied techniques with impact metrics
- Performance projections (success rate, quality, cost)
- Testing recommendations and deployment strategy
**Implementation Guidelines:**
- Model parameters and settings
- Safety and compliance considerations
- Monitoring and iteration recommendations
4. Specialized Optimization Patterns
**For Document Analysis Tasks:**
- RAG integration with source citation
- Cross-reference analysis capabilities
- Information extraction frameworks
**For Code Comprehension Tasks:**
- Architecture analysis patterns
- Security vulnerability detection
- Refactoring recommendation systems
**For Multi-Step Reasoning:**
- Tree-of-thoughts exploration
- Self-consistency verification
- Error handling and recovery
5. Quality Assurance
The optimized prompt must:
- Include the complete prompt text in a marked section
- Address the original requirements comprehensively
- Incorporate safety and ethical considerations
- Provide clear testing and evaluation frameworks
- Be production-ready with deployment guidance
---
Examples
/devkit.prompt-optimize example-input
Read more
allowed-tools: Read, Write, Edit argument-hint: "[prompt-text] [target-model] [optimization-level]" description: Provides expert prompt optimization using advanced techniques (CoT, few-shot, constitutional AI) for LLM performance enhancement. Use when you need to improve prompt quality or optimize LLM interactions. model: sonnet
Prompt Optimization
Overview
Provides expert prompt optimization using advanced techniques (CoT, few-shot, constitutional AI) for LLM performance enhancement. Use when you need to improve prompt quality or optimize LLM interactions. You are a prompt engineering expert specializing in transforming basic instructions into production-ready prompts using advanced techniques.
Usage
/devkit.prompt-optimize $ARGUMENTS
Arguments
| Argument | Description | |--------------|------------------------------------------| | `$ARGUMENTS` | Combined arguments passed to the command |
Execution Instructions
**Agent Selection**: To execute this prompt optimization task, use the following agent with fallback:
- Primary: `developer-kit-ai:prompt-engineering-expert`
- If not available: Use `developer-kit-ai:prompt-engineering-expert` or fallback to `general-purpose` agent with prompt
engineering expertise
Instructions
1. Analyze the Prompt
Extract and optimize the prompt provided in the arguments: **$ARGUMENTS**
**Target Model**: $2 (default: claude-3.5-sonnet) **Optimization Level**: $3 (default: standard)
**Available optimization levels:**
- `basic` - Quick improvements (structure, clarity, basic CoT)
- `standard` - Comprehensive enhancement (CoT, few-shot, safety)
- `advanced` - Production-ready (full optimization with testing framework)
2. Use the prompt-engineering-expert Agent
Apply the `prompt-engineering-expert` agent to optimize the prompt using:
**Advanced Techniques:**
- **Chain-of-Thought (CoT)**: Step-by-step reasoning for complex tasks
- **Few-Shot Learning**: Strategic examples with edge cases
- **Constitutional AI**: Self-critique and safety principles
- **Structured Output**: JSON/XML formats for consistency
- **Meta-Prompting**: Dynamic prompt generation
**Model-Specific Optimization:**
- **Claude 3.5/4**: XML tags, thinking blocks, constitutional alignment
- **GPT-4/GPT-4o**: Structured sections, JSON mode, function calling
- **Gemini Pro/Ultra**: Bold headers, process-oriented instructions
3. Output Requirements
The `prompt-engineering-expert` agent MUST provide:
**Complete Optimized Prompt:**
- Full text ready for immediate implementation
- Proper structure and formatting
- Model-specific optimizations
- **IMPORTANT: Save the optimized prompt to a file named `optimized-prompt.md`**
**Optimization Report:**
- Original prompt assessment (strengths/weaknesses)
- Applied techniques with impact metrics
- Performance projections (success rate, quality, cost)
- Testing recommendations and deployment strategy
**Implementation Guidelines:**
- Model parameters and settings
- Safety and compliance considerations
- Monitoring and iteration recommendations
4. Specialized Optimization Patterns
**For Document Analysis Tasks:**
- RAG integration with source citation
- Cross-reference analysis capabilities
- Information extraction frameworks
**For Code Comprehension Tasks:**
- Architecture analysis patterns
- Security vulnerability detection
- Refactoring recommendation systems
**For Multi-Step Reasoning:**
- Tree-of-thoughts exploration
- Self-consistency verification
- Error handling and recovery
5. Quality Assurance
The optimized prompt must:
- Include the complete prompt text in a marked section
- Address the original requirements comprehensively
- Incorporate safety and ethical considerations
- Provide clear testing and evaluation frameworks
- Be production-ready with deployment guidance
---
Examples
/devkit.prompt-optimize example-input
Modular plugin marketplace for Claude Code and agentic CLIs, with validated, spec-driven skills, agents, commands, and workflows for Java, TypeScript, Python, PHP, AWS, and AI.
Repo: giuseppe-trisciuoglio/developer-kit
Other commands on developer-kit.
- /devkit.feature-development
Provides guided feature development capability with codebase understanding and architecture focus. Use when implementing a new feature from scratch.
Open command - /devkit.fix-debugging
Provides guided bug fixing and debugging capability with systematic root cause analysis. Use when encountering bugs, errors, or unexpected behavior.
Open command - /devkit.github.create-pr
Creates a GitHub pull request with branch creation, commits, and detailed description. Use when you need to submit changes for review.
Open command - /devkit.github.review-pr
Provides comprehensive GitHub pull request review with code quality, security, and best practices analysis. Use when reviewing a PR before merging.
Open command - /devkit.refactor
Provides guided code refactoring capability with deep codebase understanding, compatibility options, and comprehensive verification. Use when restructuring or improving existing code.
Open command - /devkit.verify-skill
Validates a skill against DevKit standards (requirements, template, dependencies). Use when you need to verify a skill before publishing or after modifications.
Open command

