본문으로 건너뛰기
cccskills
무료GitHub에 공개

statistics-infographic

Generate an eight-panel repository statistics infographic with individual-PR diff histograms and human/agent comment and commit comparisons.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(11)

  • SKILL.md8.8 KB
  • examples/example.json4.3 KB
  • references/data-contract.md12.9 KB
  • requirements-dev.txt55 B
  • requirements.txt17 B
  • scripts/audit_sources.py16.6 KB
  • scripts/compute_pr_activity.py2.5 KB
  • scripts/compute_pr_changes.py3.2 KB
  • scripts/render_infographic.py20.7 KB
  • scripts/statistics_data.py22.8 KB
  • tests/test_statistics.py31.1 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Repository statistics infographic

Use when asked to consolidate repository-statistics slides into one image, regenerate the infographic with updated data, or verify its calculations. This is a reusable eight-panel statistical template, not an arbitrary PowerPoint screenshot collage.

The panels cover inferred PR initiation, merge/closed outcomes, start-to-merge durations, community issue outcomes, Go/JavaScript code composition, and weekly first-parent code changes, plus overlapping histograms of lines added and removed for individual PRs, and mean comments/commits per PR for human versus agent/bot comment-writer and primary-commit-author accounts. Repository names, dates, counts, proportions, and weeks come from the input, never from this skill's original dataset.

Generate

Prefer already collected source evidence. Do not fetch repository data, trigger workflows, or invent missing statistics. Keep raw data and generated images out of the repository. Use a temporary or session artifact directory.

Create a Python 3.9+ virtual environment and install the runtime manifest:

python3 -m venv /tmp/statistics-infographic-venv
/tmp/statistics-infographic-venv/bin/python -m pip install \
  -r .github/skills/statistics-infographic/requirements.txt

Supply either one JSON object following examples/example.json, or a directory of existing summaries:

/tmp/statistics-infographic-venv/bin/python \
  .github/skills/statistics-infographic/scripts/render_infographic.py \
  --input .github/skills/statistics-infographic/examples/example.json \
  --output /tmp/statistics-infographic.png

For real data, replace --input with --data-dir /path/to/summaries. See references/data-contract.md for schemas and statistical definitions. The example is explicitly synthetic, not a gh-aw report.

Optional arguments: --title, --font-regular, and --font-bold. Supply both font paths together. Automatic discovery supports Arial on macOS/Windows and Liberation Sans or DejaVu Sans on Linux. Missing fonts fail explicitly; no bitmap fallback is used.

The output is a static, RGB, 2560 x 5040 PNG with 300-DPI metadata. A successful render atomically replaces the explicit output path. Invalid data, unreadable layout, or invalid fonts leave an existing output intact. Counts too large for their slots, more than 10 duration bands, or more than 260 weeks require a different layout; do not silently truncate, rescale text to illegibility, or aggregate data.

Recompute individual PR change sizes

The seventh panel counts individual PRs, never weeks, commits, or files. Each census PR contributes its GitHub additions value to one bin of the added series and its deletions value to one bin of the removed series, including zeros. The x-axis is lines per PR; the y-axis is number of PRs. Both series use the same equal-width integer bins; bars overlap with transparency, not stacking or mirroring. The population includes merged, closed-unmerged, and open census PRs across all files, unlike the Go/JS-only weekly history panel.

To recompute pr-change-histogram.json and a standalone image from cached raw records containing individual PR number, additions, deletions, state, and createdAt fields:

/tmp/statistics-infographic-venv/bin/python \
  .github/skills/statistics-infographic/scripts/compute_pr_changes.py \
  --raw-dir /path/to/raw-records \
  --census /path/to/summaries/pr-initiation-assumption-summary.json \
  --output-dir /path/to/summaries

This writes pr-change-histogram.json and pr-change-histogram.png (2560 x 1180). The summary is the required pr_changes section in the combined input, or the sixth canonical file for --data-dir. Re-render the complete image with all seven summaries. Missing per-PR additions/deletions fail explicitly; never substitute weekly Git totals, merge-commit churn, or missing values as zero. The command never fetches or refreshes API snapshots. If raw PR diff statistics are unavailable, disclose that real-data recomputation is blocked. Keep any rendered synthetic example clearly labelled and separate.

Compare human and agent PR activity

Panel 08 counts who wrote each comment and authored each commit, never who created the PR. Each PR can contain both human and agent/bot contributions. For each author group, divide its total comments and primary-authored commits by the same entire PR census, including PRs with no contributions in that group. Use exact-rational means rounded half up to one decimal. No human contributions means zero, not an undefined or excluded PR population.

/tmp/statistics-infographic-venv/bin/python \
  .github/skills/statistics-infographic/scripts/compute_pr_activity.py \
  --raw-dir /path/to/raw-records \
  --census /path/to/summaries/pr-initiation-assumption-summary.json \
  --output-dir /path/to/summaries

Raw PRs need fully paginated comments { totalCount nodes { id author { login __typename } } } and commits { totalCount nodes { commit { oid author { user { login __typename } } } } } alongside number, state, and creation date. Counts-only records are insufficient. Every connection total must match its complete, distinct node inventory. The command writes pr-activity-summary.json (the required pr_activity section) and standalone pr-activity.png (2560 x 1180). Classify each comment's author and each commit's linked primary author.user. User accounts without bot/machine-user naming are human proxies; Bot actors, [bot] logins, and known Copilot accounts are agent/bot accounts. Unknown/deleted comment authors, unlinked commit authors, and other machine-user accounts stay unattributed. Disclose unknown comment and commit counts separately. Do not use the PR creator, committer, coauthor trailer, name, or email as a fallback. Agent/bot includes non-AI automation; account attribution is not proof of AI use. Comments exclude inline review comments and review submissions. Count each commit once per PR by its primary author, not once per coauthor or globally across PRs. The summary declares group_by: contribution-author; legacy PR-creator summaries must fail rather than being silently reused.

Verify accuracy

Input validation proves internal reconciliation, not correctness of the evidence. When cached raw API records are available, independently recompute the displayed statistics before delivery:

/tmp/statistics-infographic-venv/bin/python \
  .github/skills/statistics-infographic/scripts/audit_sources.py \
  --data-dir /path/to/summaries \
  --raw-dir /path/to/raw-records \
  --repo /path/to/local-checkout

The auditor also accepts --input instead of --data-dir. Omit --repo only if local Git evidence is unavailable, and disclose that code/history were not audited. For a repository migration, explicitly supply a repeatable --repository-alias previous-owner/previous-name only when issue numbering is known to be shared.

The Git audit reads immutable objects at the full input commit, not the worktree. It requires complete local history, disables lazy object fetching, and never requests credentials or performs network operations. Missing objects or shallow history fail explicitly. Large repositories may require substantial memory for the batched blob inventory.

Open the resulting image and inspect all eight panels at normal viewing size: titles, axes, labels, footnotes, chart proportions, and snapshot metadata. Automated text-bound and overlap checks complement but do not replace visual inspection.

Deliver the image with its path and disclose missing independent checks or evidence limitations. In particular, inferred source issues do not prove who initiated an agent session or which device they used. The no-issue human assumption must be explicitly authorized for the dataset.

Maintain

Install the development manifest only for validation work:

/tmp/statistics-infographic-venv/bin/python -m pip install \
  -r .github/skills/statistics-infographic/requirements-dev.txt
HYPOTHESIS_STORAGE_DIRECTORY=/tmp/statistics-infographic-hypothesis \
  /tmp/statistics-infographic-venv/bin/python -m unittest discover \
  -s .github/skills/statistics-infographic/tests -v
/tmp/statistics-infographic-venv/bin/python -m mypy --strict \
  .github/skills/statistics-infographic/scripts

The implementation uses immutable typed records, explicit invariants, exact rational count ratios with half-up rounding, Decimal-oracle property tests, source-mutation regressions, deterministic rendering, safe CLI output tests, and pinned-object Git fixtures. These are rigorous software checks, not a mathematical proof of the whole program or of causal attribution.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Standard collaboration patterns for all squad agents — worktree awareness, decisions, cross-agent communication

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

github/gh-aw5.4천2026년 10월 19일 업데이트

Shared hard rules enforced across all squad agents

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

github/gh-aw5.4천2026년 10월 19일 업데이트

Route gh-aw design, creation, diagnosis, patching, active debugging, and upgrade requests to the right strategies.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

github/gh-aw5.4천2026년 10월 19일 업데이트

How to write comprehensive architectural proposals that drive alignment before code is written

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

github/gh-aw5.4천2026년 10월 19일 업데이트

Upgrade gh-aw to latest gh-aw-firewall release and identify follow-up spec tasks.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

github/gh-aw5.4천2026년 10월 19일 업데이트

Review code that performs git or gh operations against repository checkouts in gh-aw, checking that the right credentials are available at the right time and that sparseness, shallowness and credential-free factors are properly considered.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

github/gh-aw5.4천2026년 10월 19일 업데이트

github의 스킬 모두 보기

이 스킬의 문제 신고