Initial commit
This commit is contained in:
46
commands/explain.md
Normal file
46
commands/explain.md
Normal file
@@ -0,0 +1,46 @@
|
||||
---
|
||||
description: Get detailed explanations of code, concepts, or architectures
|
||||
argument-hint: "[file_path or concept]"
|
||||
---
|
||||
|
||||
Provide a clear, comprehensive explanation of the code, concept, or system architecture.
|
||||
|
||||
## Explanation Style:
|
||||
|
||||
1. **Start with the Big Picture**
|
||||
- What is this code/system for?
|
||||
- What problem does it solve?
|
||||
- How does it fit into the larger project?
|
||||
|
||||
2. **Break Down the Details**
|
||||
- Explain each major component
|
||||
- Describe how components interact
|
||||
- Highlight key algorithms or patterns
|
||||
|
||||
3. **Walk Through the Flow**
|
||||
- Trace execution paths
|
||||
- Show data transformations
|
||||
- Explain control flow
|
||||
|
||||
4. **Highlight Important Concepts**
|
||||
- Design patterns used
|
||||
- Best practices applied
|
||||
- Trade-offs and decisions made
|
||||
|
||||
5. **Provide Examples**
|
||||
- Show usage scenarios
|
||||
- Give concrete examples
|
||||
- Demonstrate edge cases
|
||||
|
||||
6. **Connect to Fundamentals**
|
||||
- Link to underlying principles
|
||||
- Reference related concepts
|
||||
- Suggest further learning resources
|
||||
|
||||
## Explanation Levels:
|
||||
|
||||
- **Beginner**: Simple terms, lots of context
|
||||
- **Intermediate**: Technical details, common patterns
|
||||
- **Expert**: Advanced concepts, trade-offs, alternatives
|
||||
|
||||
Adjust explanation depth based on your needs. What would you like me to explain?
|
||||
42
commands/fix.md
Normal file
42
commands/fix.md
Normal file
@@ -0,0 +1,42 @@
|
||||
---
|
||||
description: Automatically detect and fix bugs with AI assistance
|
||||
argument-hint: "[error_message or file_path]"
|
||||
---
|
||||
|
||||
Engage the @bug-hunter agent to systematically find and fix bugs.
|
||||
|
||||
## Bug Detection Process:
|
||||
|
||||
1. **Identify the Problem**
|
||||
- Analyze error messages and stack traces
|
||||
- Review recent code changes
|
||||
- Check logs and runtime behavior
|
||||
|
||||
2. **Root Cause Analysis**
|
||||
- Trace the bug to its source
|
||||
- Understand why it occurs
|
||||
- Identify related issues
|
||||
|
||||
3. **Solution Strategy**
|
||||
- Propose multiple fix approaches
|
||||
- Evaluate trade-offs
|
||||
- Choose the best solution
|
||||
|
||||
4. **Implementation**
|
||||
- Fix the bug with minimal changes
|
||||
- Add error handling if needed
|
||||
- Ensure backwards compatibility
|
||||
|
||||
5. **Validation**
|
||||
- Verify the fix resolves the issue
|
||||
- Check for side effects
|
||||
- Suggest test cases to prevent regression
|
||||
|
||||
## What to provide:
|
||||
|
||||
- Error messages or logs (if available)
|
||||
- File path or code snippet where the bug occurs
|
||||
- Expected vs actual behavior
|
||||
- Steps to reproduce (if known)
|
||||
|
||||
Let's squash this bug! What's the issue?
|
||||
24
commands/pair.md
Normal file
24
commands/pair.md
Normal file
@@ -0,0 +1,24 @@
|
||||
---
|
||||
description: Start an AI pair programming session with intelligent assistance
|
||||
---
|
||||
|
||||
You are now in **AI Pair Programming Mode**.
|
||||
|
||||
Your role is to act as an experienced pair programming partner who:
|
||||
|
||||
1. **Collaborates actively**: Ask clarifying questions before implementing solutions
|
||||
2. **Thinks out loud**: Explain your reasoning and design decisions
|
||||
3. **Suggests alternatives**: Propose different approaches and their trade-offs
|
||||
4. **Catches mistakes**: Point out potential issues before they become bugs
|
||||
5. **Shares knowledge**: Explain concepts and best practices as you code
|
||||
|
||||
## Guidelines:
|
||||
|
||||
- Before writing code, discuss the approach with me
|
||||
- Break down complex tasks into smaller, manageable steps
|
||||
- Use the @code-reviewer agent for quality checks on important changes
|
||||
- Use the @architect agent for architectural decisions
|
||||
- Consider edge cases and error handling
|
||||
- Write clean, maintainable, and well-documented code
|
||||
|
||||
Let's build something great together! What would you like to work on?
|
||||
39
commands/review.md
Normal file
39
commands/review.md
Normal file
@@ -0,0 +1,39 @@
|
||||
---
|
||||
description: Request a comprehensive code review from AI experts
|
||||
argument-hint: "[file_path or 'recent' for latest changes]"
|
||||
---
|
||||
|
||||
Perform a comprehensive code review by invoking the @code-reviewer agent.
|
||||
|
||||
Focus on:
|
||||
|
||||
1. **Code Quality**
|
||||
- Readability and maintainability
|
||||
- Naming conventions
|
||||
- Code organization and structure
|
||||
|
||||
2. **Security**
|
||||
- Authentication and authorization
|
||||
- Input validation
|
||||
- Sensitive data handling
|
||||
- SQL injection, XSS vulnerabilities
|
||||
|
||||
3. **Performance**
|
||||
- Algorithm efficiency
|
||||
- Memory usage
|
||||
- Database query optimization
|
||||
- Unnecessary computations
|
||||
|
||||
4. **Best Practices**
|
||||
- Design patterns
|
||||
- Error handling
|
||||
- Testing coverage
|
||||
- Documentation
|
||||
|
||||
5. **Potential Bugs**
|
||||
- Null pointer exceptions
|
||||
- Race conditions
|
||||
- Edge cases
|
||||
- Logic errors
|
||||
|
||||
Provide specific, actionable feedback with code examples where appropriate.
|
||||
44
commands/suggest.md
Normal file
44
commands/suggest.md
Normal file
@@ -0,0 +1,44 @@
|
||||
---
|
||||
description: Get intelligent suggestions for code improvements
|
||||
argument-hint: "[file_path or feature description]"
|
||||
---
|
||||
|
||||
Analyze the code and provide intelligent improvement suggestions.
|
||||
|
||||
## Analysis Areas:
|
||||
|
||||
1. **Refactoring Opportunities**
|
||||
- Extract repeated code into functions
|
||||
- Simplify complex logic
|
||||
- Remove dead code
|
||||
- Improve naming
|
||||
|
||||
2. **Design Improvements**
|
||||
- Better separation of concerns
|
||||
- More appropriate design patterns
|
||||
- Cleaner interfaces
|
||||
- Reduced coupling
|
||||
|
||||
3. **Performance Optimizations**
|
||||
- Algorithm improvements
|
||||
- Caching strategies
|
||||
- Lazy loading
|
||||
- Database query optimization
|
||||
|
||||
4. **Code Modernization**
|
||||
- Use newer language features
|
||||
- Update deprecated APIs
|
||||
- Modern best practices
|
||||
|
||||
5. **Maintainability**
|
||||
- Better error handling
|
||||
- Improved logging
|
||||
- More comprehensive tests
|
||||
- Enhanced documentation
|
||||
|
||||
For each suggestion:
|
||||
- Explain WHY it's better
|
||||
- Show BEFORE/AFTER code examples
|
||||
- Estimate the impact and effort
|
||||
|
||||
Prioritize suggestions by importance and ease of implementation.
|
||||
Reference in New Issue
Block a user