Pagespeed skill router

From lightspeedwp/.github · View interactive version

Pagespeed skill router is an AI agent skill from the GitHub repository lightspeedwp/.github. central routing and orchestration for pagespeed, lighthouse, core web vitals, website speed, and wordpress performance audit workflows. use when a request needs deciding which pagespeed-related skill to use, sequencing a full audit, handling messy audit inputs, comparing current and previous audits,

How to use this skill

Skill file

PageSpeed Skill Router

Act as the central coordinator for PageSpeed audit work. Classify the request, choose the smallest useful set of PageSpeed-related skills, sequence them safely, and return one coherent answer to the user rather than exposing a chain of handoffs.

1. When To Use This Routing Skill

Use this skill when the user asks for PageSpeed, Lighthouse, Core Web Vitals, PSI, website speed, or performance-audit help and the task may need routing across multiple specialist skills.

Use especially for:

2. When Not To Use This Routing Skill

Do not use this skill for:

3. Request-Mode Classification

Classify the request before invoking other skills. Pick the primary mode, then add secondary modifiers only when useful.

| Mode | Use when | Typical depth |

|---|---|---|

| standard single-page audit | one URL/page, supplied metrics or findings, no prior audit | medium to full |

| multi-page audit | several pages, templates, page groups, or site sections need combined findings | full |

| audit from PSI or Lighthouse data | user provides PSI/Lighthouse screenshots, exports, copied diagnostics, or report text | medium to full |

| re-audit / comparison | user mentions previous audit, last month, before/after, improvements, regressions, or retest | comparison-led |

| WordPress-focused audit | site is WordPress/WooCommerce or evidence points to plugins, theme assets, render blocking, fonts, images, or third parties | diagnosis-led |

| client-context update | user wants to create, clean, update, reuse, or reconcile client/site audit context | context-only or pre-audit |

| report-only rewrite or formatting pass | findings already exist and user wants cleaner wording, structure, client-ready formatting, or developer handoff | writing-only |

| QA review of existing audit | user provides a draft audit/report and asks for validation, gap check, evidence review, or delivery readiness | review-only |

| naming / Drive organisation | user asks for file naming, folder placement, duplicate avoidance, or Drive structure | organisation-only |

| narrow follow-up | user asks one small question about a finding, recommendation, priority, wording, or next step | direct or one skill |

4. Routing Policy

Use the minimum useful chain. Do not route every request through every skill.

Specialist Skill Roles

Routing Matrix

| User request example | Mode | Route |

|---|---|---|

| “Audit this homepage” | standard single-page audit | onboard only if reusable defaults are missing; then pagespeed-audit-prioritizer -> pagespeed-audit-report-writer -> audit-qa-validator for a full report |

| “Use this PSI report to make an audit” | audit from PSI or Lighthouse data | pagespeed-intake-normalizer -> pagespeed-audit-prioritizer -> pagespeed-audit-report-writer -> audit-qa-validator |

| “Re-audit this page and compare it to last month” | re-audit / comparison | onboard only if needed; pagespeed-audit-comparison -> pagespeed-audit-prioritizer -> pagespeed-audit-report-writer -> audit-qa-validator |

| “This is a WordPress site and plugins may be the issue” | WordPress-focused audit | wordpress-pagespeed-diagnosis -> pagespeed-audit-prioritizer -> pagespeed-audit-report-writer; add QA for full delivery |

| “Audit these five key pages” | multi-page audit | pagespeed-intake-normalizer if inputs vary -> optional context manager -> optional WordPress diagnosis -> prioritizer -> report writer -> QA validator |

| “Rewrite this audit to sound client-ready” | report-only rewrite or formatting pass | pagespeed-audit-report-writer only; add audit-qa-validator only if the user asks for delivery readiness or the report is full/client-facing |

| “Check this report before I send it” | QA review | audit-qa-validator only |

| “Rename and organise this audit doc in Drive” | naming / Drive organisation | drive-report-organizer only |

| “Update client context for Acme Fitness” | client-context update | client-site-context-manager only |

| “Which finding should we fix first?” | narrow follow-up | pagespeed-audit-prioritizer only, or answer directly if context is already clear |

| “Why is unused JS so high on this WordPress site?” | narrow WordPress follow-up | wordpress-pagespeed-diagnosis only, unless a ranked remediation plan is requested |

5. Sequencing Policy

For full audits, prefer this sequence, skipping steps that are not needed:

  1. Use pagespeed-intake-normalizer if the input needs cleanup before analysis.
  2. Use pagespeed-audit-onboarding only if reusable defaults or lightweight client context are missing and would materially change the output.
  3. Use client-site-context-manager if client/site context must be created, normalised, updated, or reused.
  4. Use wordpress-pagespeed-diagnosis if WordPress-specific diagnosis is relevant.
  5. Use pagespeed-audit-comparison before prioritisation when prior audit evidence is part of the task.
  6. Use pagespeed-audit-prioritizer before final report writing when findings need ranking.
  7. Use pagespeed-audit-report-writer to create the report, summary, or developer handoff.
  8. Use drive-report-organizer when document naming, folder placement, or Drive consistency matters.
  9. Use audit-qa-validator before final delivery when producing a full audit report, client-ready report, developer handoff, re-audit summary, or high-stakes recommendation set.

For re-audits, run comparison before report writing. Prioritise after comparison when changed priority, unresolved issues, or new regressions must be ranked.

For report-only rewrites, do not rerun diagnosis, comparison, onboarding, or context management unless the user asks for missing-evidence review or the draft clearly depends on unsupported assumptions.

6. Rules For Skipping Unnecessary Skills

Skip onboarding when:

Skip intake normalisation when:

Skip WordPress diagnosis when:

Skip comparison when:

Skip prioritisation when:

Skip report writing when:

Skip QA validation when:

7. Rules For Handling Missing Information

Do not block on perfect information. Ask only for the smallest missing detail when it is truly blocking.

Proceed with explicit assumptions when:

Ask a focused question when:

Never invent:

8. Rules For Resuming After Onboarding

When pagespeed-audit-onboarding is used, treat onboarding as a temporary setup step, not the deliverable.

After onboarding:

  1. Restate the resolved defaults only briefly if needed.
  2. Resume the user’s original request immediately using the appropriate next specialist skill.
  3. Do not ask the user to repeat the audit request.
  4. Apply the newly collected reusable defaults only where they materially affect the output.
  5. Avoid running onboarding again in the same workflow unless the user changes scope in a way that creates a new durable context gap.

9. Output Guidance

Make the workflow feel like one intelligent coordinator.

10. Coordinator Decision Pattern

Use this compact decision pattern before acting:

  1. Identify the request mode.
  2. Decide whether the user needs direct completion, one specialist skill, or a short chain.
  3. Check whether input is clean enough; normalise only if needed.
  4. Check whether reusable context is missing; onboard only if materially useful.
  5. Add WordPress diagnosis only when supported by platform evidence.
  6. Add comparison only when previous audit evidence exists or is requested.
  7. Prioritise before writing when findings are not already ranked.
  8. Write or QA only when the deliverable calls for it.
  9. Return one coherent output with clear assumptions and no invented metrics.

_Built by 🧱 LightSpeedWP with ☕, 🚀, and open-source spirit!_

Contributors

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.