pr-reference

pr-reference is a skill for Claude Code from microsoft/hve-core. It costs 52 tokens per session (1,412 once invoked), scanned A, original, MIT.

A tool that collects Git commit history and branch differences into a structured XML file. It can filter the changes by file path or extension.

In plain words
What is it for?
It is for preparing review materials, summarising branch changes, and examining modified files.
Why use it?
It gathers the context needed for pull request descriptions, code reviews, security checks, and finding work items from changes.

Skill for Claude Code ✓ vendor

Written for Claude Code: user-invocable in frontmatter.

Good fit It is for preparing review materials, summarising branch changes, and examining modified…

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/microsoft/hve-core/pr-reference
About the project

HVE Core is a collection of agents, prompts, coding instructions, and skills for building repeatable software-development workflows with GitHub Copilot. It is intended for individuals and teams that want structured AI-assisted research, planning, implementation, and review, while the catalogue entries provide many of its reusable workflow components.

microsoft/hve-core · 1,436 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add microsoft/hve-core --skill pr-reference
Clone the repo
git clone --depth 1 https://github.com/microsoft/hve-core

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pr-reference

README.md
[![agentmods](https://agentmods.dev/badge/skills/microsoft/hve-core/pr-reference.svg)](https://agentmods.dev/skills/microsoft/hve-core/pr-reference)
Your own site
<a href="https://agentmods.dev/skills/microsoft/hve-core/pr-reference"><img src="https://agentmods.dev/badge/skills/microsoft/hve-core/pr-reference.svg" alt="Measured on agentmods" height="20"></a>
Per session 52 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,412 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00052 $0.01412
Opus 5 $0.00026 $0.00706
Sonnet 5 $0.00010 $0.00282
Haiku 4.5 $0.00005 $0.00141

Measured 3d ago against content hash cc5939a82009, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

pr-reference scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

The scan reads SKILL.md. This mod also ships 10 executable files (scripts/generate.ps1, scripts/generate.sh, scripts/list-changed-files.ps1, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.github/skills/shared/pr-reference/SKILL.md · 125 lines

How it starts

The opening of the file, as written. The whole thing — 125 lines — stays where its author put it; the contents beside it link to each section on GitHub.

PR Reference Generation Skill

Overview

Queries git for commit metadata and diff output, then produces a structured XML document. Both bash and PowerShell implementations are provided.

Use cases:

  • PR description generation from commit history
  • Code review preparation with structured diff context
  • Work item discovery by analyzing branch changes
  • Security analysis of modified files

After successful generation, include a file link to the absolute path of the XML output in the response.

Prerequisites

The repository must have at least one commit diverging from the base branch.

Platform Runtime
macOS / Linux Bash (pre-installed)
Windows PowerShell 7+ (pwsh)
Cross-platform PowerShell 7+ (pwsh)

Quick Start

Run the following command to generate a PR reference with default settings (compares against origin/main):

scripts/generate.sh
scripts/generate.sh --base-branch auto --merge-base --exclude-ext yml,json
scripts/generate.ps1
scripts/generate.ps1 -BaseBranch auto -MergeBase -ExcludeExt yml,json

Output saves to .copilot-tracking/pr/pr-reference.xml by default.

Parameters Reference

Parameter Flag (bash) Flag (PowerShell) Default Description
Base branch --base-branch -BaseBranch origin/main (bash) / main (PowerShell) Target branch for comparison. Use auto to detect remote default.
Merge base --merge-base -MergeBase false Use git merge-base for three-way comparison
Exclude markdown --no-md-diff -ExcludeMarkdownDiff false Exclude markdown files (*.md) from the diff
Exclude extensions --exclude-ext -ExcludeExt (none) Comma-separated extensions to exclude (e.g., yml,yaml,json,png)
Exclude paths --exclude-path -ExcludePath (none) Comma-separated path prefixes to exclude (e.g., docs/,.github/)
Output path --output -OutputPath .copilot-tracking/pr/pr-reference.xml Custom output file path

Read the full file on GitHub · 125 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 125 lines · 52 tokens per session scan A cc5939a82009

Subscribe to this mod's changes

pr-reference is a skill published in the GitHub repository microsoft/hve-core (1,436 stars, last pushed today), licensed MIT. It adds 52 tokens to every session and 1,412 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

review-implement-phase

Implements triaged review actions, commits focused fixes, and posts Done plus resolves threads. Use when the user wants only the implementation phase of the review-framework workflow.

prisma/orm · 38 tokens

github-pr-workflow

Prepare a GitHub pull request from a feature branch — branch hygiene, commit shape, title/body, verification notes, screenshots for UI work, and replies to review comments.

paperclipai/paperclip · 39 tokens

github-automation

GitHub workflow automation, PR management, issue tracking, and code review coordination. Integrates with GitHub Actions and repository management. Use when: PR creation, code review, issue management, release automation, workflow setup. Skip when: local-only changes, non-GitHub repositories.

ruvnet/ruflo · 61 tokens

review-delta

Review only changes since last commit using impact analysis. Token-efficient delta review with automatic blast-radius detection.

tirth8205/code-review-graph · 24 tokens

work-unit-commits

Plan commits as reviewable work units. Trigger: implementation, commit splitting, chained PRs, or keeping tests and docs with code.

Gentleman-Programming/gentle-ai · 33 tokens

github-contributor

End-to-end playbook for shipping high-quality pull requests to open-source projects you don't maintain — discovery, CONTRIBUTING compliance, PR-size check, minimal-diff implementation, PR description with AI-assisted disclosure, conflict resolution, and post-submission maintainer interaction. Use whenever creating…

daymade/claude-code-skills · 133 tokens