What problem does it solve? Optimizing JavaScript functions without measurement often wastes effort on cold paths or produces unverified speedups. This Skill enforces a disciplined workflow: analyze the function's real usage, benchmark the baseline, propose a behavior-preserving rewrite, and validate the improvement with A/B benchmarks. ## Core Features & Use Cases - Impact Analysis: Reads the target function, its references, call sites, and tests to assess algorithmic complexity, blast radius, and whether optimization is actually worthwhile. - Baseline Benchmarking: Delegates to the ns-benchmark-run skill to measure the current implementation using real inputs derived from call sites and tests. - Validated Rewrites: Proposes a single behavior-preserving optimization, requires user approval, then hands off to ns-validate-optimization for A/B comparison with up to 3 retry attempts. - Use Case: A developer notices a slow request handler in their Node.js API. They point at the function, and the Skill confirms it is a hot path, benchmarks it, rewrites the dominant allocation cost, and verifies a measurable throughput improvement. ## Quick Start Optimize this Node.js function to make it faster and validate the improvement with a benchmark.