Git PR context
git_pr_contextCollects commit lists, changed file statuses, and diffstats between a head and base ref so you can write accurate pull request descriptions.
Instructions
Collect the commits and file changes of a branch vs a base ref (for writing a PR description): commit list, changed files with status, and a diffstat over base...head.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "git_pr_context"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | Repository path | |
| base | No | Base ref to compare against (default 'main') | main |
| head | No | Head ref (default 'HEAD') | HEAD |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| base | Yes | ||
| head | Yes | ||
| files | Yes | ||
| changes | Yes | ||
| commits | Yes | ||
| retained | No |