Compiles a code quality report based on progress.md frontmatter and repository baseline analysis.

Install

mkdir -p .claude/skills/quality && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/12043" && unzip -o skill.zip -d .claude/skills/quality && rm skill.zip

Installs to .claude/skills/quality

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

Generate a code quality report for a pipeline project by reading quality frontmatter from progress.md and optionally running fresh analysis.
140 charsno explicit “when” trigger
Intermediate

Key capabilities

  • Read quality frontmatter from `progress.md`
  • Run fresh complexity analysis against the repository baseline
  • Perform fresh per-file analysis if the project branch exists
  • Generate a code quality report in markdown format
  • Attach the quality report to the work item

How it works

The skill extracts quality metrics from `progress.md`, optionally runs fresh code analysis, and compiles the data into a markdown report that is then attached to the work item.

Inputs & outputs

You give it
Quality frontmatter from `progress.md` and the current repository
You get back
A markdown quality report attached to the work item

When to use quality

  • Generate quality report for pipeline
  • Review milestone complexity metrics
  • Verify code quality against project baseline

About this skill

Quality

You generate a code quality report for a pipeline project by reading the pipeline_quality_* frontmatter from progress.md, optionally running fresh analysis against the repo baseline, and attaching a quality report to the work item.

Inputs

  • wcp_get_artifact($ARGUMENTS, "progress.md") — quality frontmatter from Stage 5 implementation milestones
  • The current repository — for running fresh baseline and per-file analysis
  • The conventions file — for Complexity Analysis tool configuration

Before You Start

  1. Locate the conventions file in the current repo root — look for CLAUDE.md, AGENTS.md, or CONVENTIONS.md (use the first one found). Read it in full. From the ## Pipeline Configuration section, extract Repository Details (default branch, branch prefix, etc.), and look for a Complexity Analysis section.
  2. Read progress.md: wcp_get_artifact($ARGUMENTS, "progress.md")

If progress.md does not exist, STOP:

"No progress artifact found for $ARGUMENTS. Run Stage 5 implementation first."

Step-by-Step Procedure

1. Read Quality Frontmatter

wcp_get_artifact($ARGUMENTS, "progress.md") — extract YAML frontmatter. Parse all pipeline_quality_* fields:

Per-milestone fields (pattern: pipeline_quality_mN_*):

  • pipeline_quality_mN_flog_avg
  • pipeline_quality_mN_flog_max
  • pipeline_quality_mN_flog_max_method
  • pipeline_quality_mN_files_analyzed

Project summary fields (written by /create-pr):

  • pipeline_quality_flog_avg
  • pipeline_quality_repo_baseline_flog_avg
  • pipeline_quality_delta
  • pipeline_quality_verdict
  • pipeline_quality_files_analyzed

If no pipeline_quality_* fields exist in the frontmatter, STOP with a helpful message:

"No quality data found in progress.md for $ARGUMENTS. Quality metrics are captured during Stage 5 implementation when the conventions file has a Complexity Analysis section.

To add quality data to an existing project, a future /backfill-quality skill (ROAD-20 v2) will support checking out old branches and running analysis retroactively."

2. Run Current Repo Baseline

If the conventions file has a Complexity Analysis section, run the repo baseline command for a fresh comparison:

<repo-baseline-command>

Parse the output to extract the current repo-wide flog/method average. Store as current_baseline.

If the command fails or the section doesn't exist, use the stored pipeline_quality_repo_baseline_flog_avg from frontmatter (if available) or .

3. Fresh Per-File Analysis (Optional)

Check if the project branch still exists:

git branch --list '<branch-prefix>$ARGUMENTS'

If the branch exists:

  1. Check out the branch: git checkout <branch-prefix>$ARGUMENTS
  2. Get all pipeline-touched files: git diff --name-only origin/<default-branch>...<branch-prefix>$ARGUMENTS -- '<file-glob>' (exclude spec/)
  3. Run the score command on each file to get fresh per-file scores
  4. Run the per-file command on files with the highest scores to identify current hotspot methods
  5. Check out the previous branch: git checkout -

If the branch does not exist (already merged/deleted), note this in the report and rely solely on frontmatter data.

Failure handling: If any command fails, log a warning and continue with frontmatter data only. Never fail the report because of a stale branch.

4. Write Quality Report

Attach the quality report to the work item:

wcp_attach(
  id=$ARGUMENTS,
  type="quality",
  title="Quality Report",
  filename="quality.md",
  content="[quality report]"
)

Use the following template for the report content:

# Code Quality Report — $ARGUMENTS

> Generated: <current date/time>
> Tool: [tool name from Pipeline Configuration, or from frontmatter context]
> Hotspot threshold: [threshold from Pipeline Configuration, or "unknown"]

## Quality Scorecard

| Metric | Value |
|--------|-------|
| **Project flog avg** | [from frontmatter or fresh analysis] |
| **Repo baseline avg** | [current_baseline or stored baseline] |
| **Delta** | [delta] |
| **Verdict** | [verdict] |
| **Total files analyzed** | [files_analyzed] |

## Per-Milestone Breakdown

| Milestone | Flog Avg | Flog Max | Max Method | Files |
|-----------|----------|----------|------------|-------|
| M1 | [m1_flog_avg] | [m1_flog_max] | [m1_flog_max_method] | [m1_files_analyzed] |
| M2 | ... | ... | ... | ... |
[One row per milestone with quality data]

## Hotspots

[Top 5 methods above the hotspot threshold, from fresh analysis if available, otherwise from per-milestone flog_max data]

| Score | Method | Source |
|-------|--------|--------|
| [score] | [ClassName#method_name] | [file path or milestone] |

[If no methods above threshold: "No methods above the hotspot threshold of [threshold]."]

## Baseline Context

| Metric | Value |
|--------|-------|
| **Stored baseline** (at PR time) | [pipeline_quality_repo_baseline_flog_avg] |
| **Current baseline** | [current_baseline or "—"] |
| **Baseline drift** | [current - stored, or "—"] |

> Baseline drift shows how the repo average has changed since the PR was created. A rising baseline means overall repo complexity is increasing.

## Data Quality Notes

- [Note whether data is from frontmatter only or includes fresh analysis]
- [Note if project branch was available for fresh analysis]
- [Note any milestones missing quality data]
- [Note if baseline was live or stored]

5. Handle Missing Data

  • If a per-milestone field is missing, display in the table
  • If project summary fields are missing (no /create-pr run yet), compute from per-milestone data if possible
  • If the branch is gone, note "Fresh analysis unavailable — branch merged/deleted" and use frontmatter only
  • Use for any metric that cannot be computed

6. Post Completion Comment

Add a comment to the work item summarizing the quality report:

wcp_comment(
  id=$ARGUMENTS,
  author="pipeline/quality",
  body="Quality report attached as quality.md — [verdict summary]"
)

What NOT To Do

  • Do not modify any project documents. Only attach quality.md to the WCP work item.
  • Do not modify source code. This is a read-only analysis tool.
  • Do not fabricate scores. Use for missing data.
  • Do not run pipeline stages. This is a standalone reporting tool.
  • Do not leave the repo on a different branch. Always git checkout - after analysis.

When You're Done

Tell the user:

  1. The quality report has been attached to $ARGUMENTS as quality.md
  2. Summarize key metrics: project flog avg, delta from baseline, verdict
  3. Highlight any hotspots above threshold
  4. Note data quality limitations (frontmatter vs fresh, branch availability)

When not to use it

  • If `progress.md` does not exist
  • If no `pipeline_quality_*` fields exist in the frontmatter

Limitations

  • Does not modify any project documents or source code
  • Does not fabricate scores, uses `,` for missing data
  • Does not run pipeline stages, acts as a standalone reporting tool

How it compares

This skill generates a structured quality report by combining stored metrics with fresh analysis, providing a consolidated view of code quality, unlike manually collecting and presenting metrics.

Compared to similar skills

quality side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
quality (this skill)05moReviewIntermediate
optimize-report03moReviewBeginner
github-code-review132moReviewAdvanced
reviewing-nextjs-16-patterns118moReviewIntermediate

Try saying

Example prompts that trigger this skill in your AI assistant.

Search skills

Search the agent skills registry