sample-scout

Analyzes Skia GM samples to identify demos worth porting to the SkiaSharp Gallery.

5.6k|645|Updated Feb 22, 2016
One-click install
npx skills add https://github.com/mono/SkiaSharp --skill sample-scout
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: sample-scout
Source: https://github.com/mono/SkiaSharp/tree/main/.agents/skills/sample-scout
Command: npx skills add https://github.com/mono/SkiaSharp --skill sample-scout

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires jsonschema, and includes scripts (resource) and references (resource) components.

What problem does it solve?

Manually reviewing 400+ C++ GM sample files in the upstream Skia repository to find demos worth porting to the SkiaSharp Gallery is impractical. This Skill automates the discovery, classification, and gap analysis so maintainers know exactly which samples to build next.

Core Features & Use Cases

  • Automated GM Analysis: Reads .cpp files from the externals/skia submodule, classifies each by interest level (high/medium/low), and extracts the key Skia APIs used.
  • API Availability Checking: Greps the SkiaSharp binding directory to determine whether each sample's required APIs exist in C#, listing any missing APIs.
  • Gallery Gap Cross-Referencing: Tags each finding as none/similar/existing against current Gallery samples and produces validated JSON plus a GitHub-ready Markdown report.
  • Use Case: After adding new SkiaSharp APIs, run a full scout to find high-interest samples that are now buildable and have no existing Gallery coverage.

Quick Start

Scout the upstream Skia GM samples and find interesting demos we should port to the SkiaSharp Gallery with a full scan.

Frequently Asked Questions about sample-scout

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I find Skia GM samples to port to SkiaSharp?

Run a full scout scan, which reads every .cpp file in externals/skia/gm/, classifies each by interest level, checks API availability in the SkiaSharp bindings, and outputs a prioritized report of porting opportunities.

How does the skill check if Skia APIs exist in SkiaSharp?

It greps the binding/SkiaSharp/ directory for C# equivalents of each C++ API, such as SKCanvas.DrawRect for SkCanvas::drawRect. APIs like SkMesh and SkShadowUtils are known to be unavailable and flagged as missing.

What output formats does the sample scout report produce?

It produces a JSON report validated against sample-scout-schema.json using validate-sample-scout.py, plus a GitHub-flavored Markdown report rendered by render-sample-scout.py with collapsible sections and summary tables.

Does the Skia submodule need to be initialized before scouting?

Yes, the GM files live in externals/skia/gm/, so the submodule must be checked out first with git submodule update --init --depth=1 externals/skia. The skill's setup phase handles this if it is not already initialized.

Which GM samples are excluded from high-interest classification?

Bug regression tests (crbug_*, skbug_* files), GPU backend internals like GrFragmentProcessor tests, Graphite-specific tests, and stress tests are classified as low interest since they do not make useful Gallery demos.