Add OhMyPerf to Timeline, Tracing & Profiling#186
Open
hoainho wants to merge 1 commit into
Open
Conversation
OhMyPerf drives Chromium through the DevTools Protocol via Playwright +
raw CDP, specifically:
- Target.setAutoAttach({flatten: true}) for cross-origin OOPIF
inspection with per-frame CDPSession (~99% coverage). The motivating
pattern is the same as awesome-puppeteer's nested-frame chapter but
generalized to any cross-origin iframe — including the practical
mdnplay.dev / openstreetmap.org / example.org cases.
- Performance.getMetrics + Input.dispatchMouseEvent + 'web-vitals'
PerformanceObserver pipeline for honest LCP/INP/CLS measurement on
real hardware (not synthetic Lighthouse-CI in a datacenter).
- long-task attribution via 'longtask' PerformanceObserver +
Network.requestWillBeSent capture, joined back to the script URL.
- Mann-Whitney U statistical regression detection against a baseline
report (alpha=0.05 default), with per-metric noise floors so noisy
measurements stop reporting false-positive regressions.
Plus an MCP server (Model Context Protocol) so LLM agents can call
the full 'measure -> propose_patch -> verify_fix' fix loop directly.
Apache-2.0, runs both locally (npx -y @ohmyperf/cli) and as a hosted
service. Tested with Claude Desktop, OpenCode, Cursor, Cline.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds OhMyPerf under
DevTools tooling and ecosystem → Timeline, Tracing & Profiling— a real-Chromium Core Web Vitals measurement tool that drives Chromium through the DevTools Protocol via Playwright + raw CDP.Why this list fits
OhMyPerf's value comes from using CDP correctly, not from being yet another performance dashboard:
Target.setAutoAttach({flatten: true})for cross-origin OOPIF inspection. Each cross-origin iframe gets its ownCDPSessionvia Playwright'scontext.newCDPSession(frame). We hit ~99% iframe coverage and verified it against real-world embedded surfaces (mdnplay.dev, openstreetmap.org, example.org).Performance.getMetrics+Input.dispatchMouseEvent+web-vitals/attributionfor honest LCP/INP/CLS measurement on user hardware. INP is measurable in CI because we synthesize a trusted-event interaction via CDP rather than relying on a human click.longtaskPerformanceObserver +Network.requestWillBeSentjoined back to script URL for long-task attribution down to the file path.What's distinct from existing entries
The closest existing entry under Timeline/Tracing/Profiling is DevTools Timeline Viewer (chromedevtools.github.io/timeline-viewer/), which is read-only and viewer-focused. OhMyPerf is on the production side: it actually drives the browser, records the trace, computes CWV + diagnostics, and produces a structured report consumable by both humans and LLM agents.
Most CDP-driver entries in the list (Puppeteer, Playwright, the high-level libraries section) are primitives — OhMyPerf is an application of those primitives specifically for CWV measurement, and exposes them through an MCP server so LLM agents can call
measure → propose_patch → verify_fixend-to-end.Status
@ohmyperf/cliand@ohmyperf/mcp-serverpublished on npmThanks for maintaining this list — the CDP ecosystem has been hard to navigate for years and this is the canonical entry point.