Skip to content

Cross-repo engagement radar -- star/fork/issue deltas across all repos #69

@djdarcy

Description

@djdarcy

Cross-repo engagement radar -- star/fork/issue deltas across all repos

Milestone: v0.5.0
Type: Epic -- new capability layer for ghtraf

Problem

GitHub provides no built-in way to see engagement changes across all your repos and orgs. The notifications feed covers PRs, issue comments, and CI failures -- but not stars, forks, or newly opened issues on repos you don't actively watch. Devs maintaining many repos across multiple orgs have no "what should I pay attention to?" signal.

The GitHub Traffic API (what ghtraf uses today) is per-repo and covers views/clones/referrers. Cross-repo engagement data (stars, forks, issues, community health) lives in the GraphQL API and requires a different collection approach.

Vision

Extend ghtraf with a portfolio subcommand family that:

  1. Collects star/fork/issue counts across all user and org repos via gh api graphql
  2. Stores daily snapshots (same snapshot-then-diff pattern ghtraf already uses for traffic)
  3. Computes deltas -- "which repos gained/lost stars since last check?"
  4. Displays a cross-repo feed/timeline on the dashboard (new tab or standalone page)
  5. Surfaces engagement signals that GitHub notifications miss

Approach: Prototype-then-graduate

This follows the same proven path as setup-gists.py -> ghtraf create:

  1. Prototype (scripts/star_radar.py) -- standalone script using gh api graphql, local JSON storage
  2. Graduate to ghtraf portfolio collect / ghtraf portfolio show subcommands
  3. Dashboard integration -- portfolio tab on the existing dashboard, or a linked portfolio page

Execution model

The per-repo Actions workflow collects traffic data per-repo. The portfolio collector runs centrally -- once, for all repos -- as either:

  • A scheduled Action in a single "portfolio repo" (e.g., the user's .github profile repo)
  • Local cron / manual invocation via ghtraf portfolio collect

Both use gh api graphql (subprocess call to gh, same pattern as existing gh.py). Zero new Python dependencies.

Data sources (GraphQL)

Signal GraphQL field Notes
Stars stargazerCount, stargazers(orderBy: STARRED_AT) Count + who/when
Forks forkCount Count only (fork list requires separate query)
Open issues issues(states: OPEN) { totalCount } Delta = new issues opened
Open PRs pullRequests(states: OPEN) { totalCount } Delta = new PRs
Watchers watchers { totalCount } Engagement signal
Releases releases(first: 1) { nodes { publishedAt } } Last release date

Related existing issues

Sub-issues

Non-goals (for now)

  • Replacing GitHub's per-repo Insights tab (ghtraf already does this better for traffic)
  • User activity tracking (commits, PRs authored) -- this is about inbound engagement
  • Social features (followers, profile views) -- focused on repo engagement

Analysis

See 2026-03-21__17-57-11__dev-workflow-process_cross-repo-analytics-extend-vs-separate.md for the full architectural analysis and decision rationale.

Metadata

Metadata

Assignees

No one assigned

    Labels

    analyticsDerived metrics, insights, and conversion ratiosdashboardDashboard UI and visualizationenhancementNew feature or requestepicLarge multi-phase initiativeportfolioCross-repo/org-level analytics and engagement tracking

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions