Ship an explain-codebase skill that answers natural-language questions like "how does the share-session skill work" by reading source files, synthesizing a structured developer-friendly explanation of fundamental principles, and delivering it with platform-aware social copy and a dark-mode card image — following the same pipeline as all other share-* skills.
Read and implement all steps in the plan at docs/plans/add-codebase-explain-skill.md — Add explain-codebase skill to social-media-tools. Verify against the plan's Tests, Verification, and Acceptance Criteria before reporting done. If everything passed, mark completion in docs/plans/add-codebase-explain-skill.md — tick each step's [x] marker and each criterion's - [x], set status: completed — and re-render the HTML from the spec. If any check failed, leave status: in-progress and say which.
More ways to run this plan — goal & workflow prompts, file path
Achieve this goal: Add explain-codebase skill to social-media-tools. The plan at docs/plans/add-codebase-explain-skill.md describes one approach — use it as reference, but optimize for the outcome. Verify against the plan's Tests, Verification, and Acceptance Criteria before reporting done. If everything passed, mark completion in docs/plans/add-codebase-explain-skill.md — tick each step's [x] marker and each criterion's - [x], set status: completed — and re-render the HTML from the spec. If any check failed, leave status: in-progress and say which.
add-codebase-explain-skill.html
docs/plans/add-codebase-explain-skill.html
docs/plans/add-codebase-explain-skill.md
Context
The story behind this plan — what prompted the work and why it matters now.
The social-media-tools plugin ships twelve skills across share-*, social-share, and media-library workflows. When a developer wants to understand how a specific skill operates — its phases, patterns, invocation syntax, and file layout — they have to read raw SKILL.md files directly. There is no conversational entry point that reads those files and explains the underlying principles.
An explain-codebase skill fills that gap: parse the question, locate the relevant files (SKILL.md, reference docs, scripts), read them, synthesize a structured developer-friendly answer, and then deliver the output the same way every other share-* skill does — security scrub the content, draft platform-aware social copy, populate a card template ( feature-card.html for skill/component explanations, quote-card.html for concept/pattern explanations), screenshot via the rendering pipeline, save persistently to docs/media/social/ , and deliver copy + image in the same turn.
This also closes a routing gap in social-share : "how does X work" queries currently fall through to the share-code fallback, which is wrong. A new classification rule fixes the routing.
Steps
The step-by-step work, in order — each step says what to do, why it matters, and how to check it worked.
Definition of done
The plan counts as done when every statement below is true — check each one off as you verify it.
Final check
One last pass to confirm the whole change works end to end.
Invoke /social-media-tools:explain-codebase how does the share-session skill work and confirm: (1) locates and reads skills/share-session/SKILL.md plus referenced files; (2) returns structured explanation with Core Purpose, Workflow Phases (Phase 0–6), Key Patterns (ExitPlanMode bootstrap, session_usage.py, security scrub gate, reuse check), Important Files, and Invocation; (3) passes the security scrub gate without blocking; (4) produces platform-aware social copy; (5) populates feature-card.html with skill name, one-line purpose, and key phases as bullets; (6) saves a PNG to docs/media/social/ ; (7) delivers explanation + copy + image in the same response turn.
Then verify routing: send "how does share-scan work" via social-share and confirm dispatch to explain-codebase rather than share-code or share-project .
Wrapping up
Three gates that must all pass before this plan is marked completed.
Completion Report
No items to report — all requirements met.