Optimize application stack using specialized optimization agents:
[Extended thinking: This tool coordinates database, performance, and frontend optimization agents to improve application performance holistically. Each agent focuses on their domain while ensuring optimizations work together.]
Use Task tool with subagent_type="database-optimizer" to:
- Analyze query performance and execution plans
- Optimize indexes and table structures
- Implement caching strategies
- Review connection pooling and configurations
- Suggest schema improvements
Prompt: "Optimize database layer for: $ARGUMENTS. Analyze and improve:
- Slow query identification and optimization
- Index analysis and recommendations
- Schema optimization for performance
- Connection pool tuning
- Caching strategy implementation"
Use Task tool with subagent_type="performance-engineer" to:
- Profile application code
- Identify CPU and memory bottlenecks
- Optimize algorithms and data structures
- Implement caching at application level
- Improve async/concurrent operations
Prompt: "Optimize application performance for: $ARGUMENTS. Focus on:
- Code profiling and bottleneck identification
- Algorithm optimization
- Memory usage optimization
- Concurrency improvements
- Application-level caching"
Use Task tool with subagent_type="frontend-developer" to:
- Reduce bundle sizes
- Implement lazy loading
- Optimize rendering performance
- Improve Core Web Vitals
- Implement efficient state management
Prompt: "Optimize frontend performance for: $ARGUMENTS. Improve:
- Bundle size reduction strategies
- Lazy loading implementation
- Rendering optimization
- Core Web Vitals (LCP, FID, CLS)
- Network request optimization"
- Current performance metrics
- Identified bottlenecks
- User experience impact
-
Quick Wins (< 1 day)
- Simple query optimizations
- Basic caching implementation
- Bundle splitting
-
Medium Improvements (1-3 days)
- Index optimization
- Algorithm improvements
- Lazy loading implementation
-
Major Optimizations (3+ days)
- Schema redesign
- Architecture changes
- Full caching layer
- Database query time reduction: X%
- API response time improvement: X%
- Frontend load time reduction: X%
- Overall user experience impact
- Ordered list of optimizations by impact/effort ratio
- Dependencies between optimizations
- Risk assessment for each change
Target for optimization: $ARGUMENTS