/explain-plan
Generate and interpret a SQL query execution plan in plain language.
$ npx -y skills add rohitg00/awesome-claude-code-toolkit --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
/explain-plan
Context preview
What this command does when you run it.
Generate and interpret a SQL query execution plan in plain language.
Command definition
explain-plan.md/explain-plan - Explain Query Execution Plan
Generate and interpret a SQL query execution plan in plain language.
Steps
1. Take the SQL query from the user input 2. Determine the database engine (PostgreSQL, MySQL, SQLite, SQL Server) 3. Run EXPLAIN or EXPLAIN ANALYZE with the appropriate syntax for the engine 4. Parse the execution plan output into structured components 5. Identify each operation: Sequential Scan, Index Scan, Nested Loop, Hash Join, Sort 6. Explain each step in plain language: what table is read, how it is filtered 7. Highlight expensive operations: full table scans, large sort operations, hash joins 8. Calculate the cost percentage of each step relative to total query cost 9. Identify the critical path (most expensive sequence of operations) 10. Suggest specific improvements for the most costly operations 11. Estimate memory usage and temporary disk usage from the plan 12. Present the explanation as a step-by-step narrative
Rules
- Translate database-specific terminology into plain English
- Highlight operations that scan more than 1000 rows without an index
- Show estimated vs actual rows to identify cardinality estimation errors
- Explain the difference between estimated cost and actual execution time
- Identify parallel query opportunities if the database supports them
- Note when the planner chose a suboptimal plan due to stale statistics
- Recommend ANALYZE/VACUUM if statistics appear outdated
Read more
/explain-plan - Explain Query Execution Plan
Generate and interpret a SQL query execution plan in plain language.
Steps
1. Take the SQL query from the user input 2. Determine the database engine (PostgreSQL, MySQL, SQLite, SQL Server) 3. Run EXPLAIN or EXPLAIN ANALYZE with the appropriate syntax for the engine 4. Parse the execution plan output into structured components 5. Identify each operation: Sequential Scan, Index Scan, Nested Loop, Hash Join, Sort 6. Explain each step in plain language: what table is read, how it is filtered 7. Highlight expensive operations: full table scans, large sort operations, hash joins 8. Calculate the cost percentage of each step relative to total query cost 9. Identify the critical path (most expensive sequence of operations) 10. Suggest specific improvements for the most costly operations 11. Estimate memory usage and temporary disk usage from the plan 12. Present the explanation as a step-by-step narrative
Rules
- Translate database-specific terminology into plain English
- Highlight operations that scan more than 1000 rows without an index
- Show estimated vs actual rows to identify cardinality estimation errors
- Explain the difference between estimated cost and actual execution time
- Identify parallel query opportunities if the database supports them
- Note when the planner chose a suboptimal plan due to stale statistics
- Recommend ANALYZE/VACUUM if statistics appear outdated
The most comprehensive toolkit for Claude Code -- 135 agents, 35 curated skills (+400,000 via SkillKit), 42 commands, 176+ plugins, 20 hooks, 15 rules, 7 templates, 15 MCP configs, 26 companion apps, 53 ecosystem entries, and more.
Repo: rohitg00/awesome-claude-code-toolkit
Other commands on rohitg00-claude-code-toolkit.
- /adr
Write an Architecture Decision Record documenting a significant technical decision.
Open command - /design-review
Conduct a structured design review of a module, feature, or system component.
Open command - /diagram
Generate Mermaid diagrams from codebase analysis or description.
Open command - /migrate
Plan and execute a framework or library migration incrementally.
Open command - /plan
Create a structured implementation plan for the requested feature or change.
Open command - /refactor
Perform a systematic refactoring of the specified code area.
Open command

