Skip to main content
Glama

Assess change fit

assess-change-fit-tool

Pre-flight fit check for a change you are about to open as a pull request. Pass the numstat of your working diff (or, failing that, its additions, deletions, and changed-file counts) and Coderbuds answers whether the change fits how this team ships: a verdict with reasons, the team's own merged-PR size norms (median/p75) and merge time by size category, and the current review-queue pressure. Pass repository and that queue is scoped to it — human-authored open pull requests on the repo you are working in, not every repo the team owns, because "review one of these first" is only actionable if you are near them.

Four verdicts, and only two of them ask anything of you. fits — go. fits_at_edge — over the standard but inside its tolerance, which is stated for the record and needs no action, because changes this close to the line merge like changes under it. caution — meaningfully over; weigh the guidance. split_required — effectively unreviewable; split it.

Coderbuds applies its own opinionated standard (on by default, teams can opt out): changes well above the standard size get at least a caution regardless of what the team's historical norms would allow — reported as team_norms.target_total_changes.

Also pass review_goals: the distinct outcomes a reviewer must approve in this change. Describe outcomes, not implementation layers — an API, UI, migration, tests, and docs that deliver one behavior are one review goal. One goal fits. Two prompt a caution to confirm they really must ship atomically. Three or more require a split. This is the scope-coherence standard: a small diff can still be hard to review when it bundles unrelated decisions. If multiple goals truly cannot ship separately, use scope_rationale to preserve that context and record the decision after the check.

Best results: pass numstat, the raw output of git diff --numstat <base>.... Coderbuds then works out the split from the file paths itself — tests, documentation, generated files (lockfiles, snapshots, minified bundles) and binary assets are identified and discounted, so the verdict judges the CODE a reviewer actually has to read. 400 lines of blog post and 400 lines of business logic are not the same review, and without the paths there is no way to tell them apart.

When the team has a review policy, the numstat also predicts the review tier the pull request will get (review_tier, with its reasons) and which files a reviewer should read first (where_to_look). The tier is often set by one file — splitting off a migration or a sensitive file into its own pull request can lower what reviewers face on the rest.

Failing that, declare the split yourself: test_lines (changed lines living in test files, e.g. from git diff --shortstat -- tests/) and moved_lines (code relocated without behavioral change, e.g. an extraction refactor) are subtracted from the verdict, because a raw count punishes test coverage and double-counts refactors. Report these honestly; they are recorded with the check and visible to the team.

Do the same for files with test_files and moved_files. A rename sweep, codemod, or file-move refactor touches a lot of files with almost nothing to read in each, and the file count is judged separately from the line count — so without these a mechanical change is called oversized on file count alone. git diff --shortstat -M and git diff --summary will tell you how many of the changed files were renames.

When the verdict is not "fits", say what you did about it with record-change-fit-decision-tool — including when you proceed anyway. Overriding is allowed; overriding silently is what leaves the standard unable to learn it is in the wrong place.

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": "assess-change-fit-tool"
  }
}

Input Schema

NameRequiredDescriptionDefault
numstatNoStrongly recommended: raw `git diff --numstat <base>...` output (tab-separated "added deleted path" rows, `-` for binary). Coderbuds counts the lines and files from it and classifies the paths itself, discounting tests, docs, generated files and binary assets, so the verdict judges the code a reviewer must read. Supersedes test_lines/test_files when given.
additionsNoLines added in the proposed change (e.g. from `git diff --shortstat`). Required unless numstat is given; worked out from the numstat when omitted.
deletionsNoLines deleted in the proposed change. Required unless numstat is given; worked out from the numstat when omitted.
repositoryNoOptional "owner/name" repository slug the change targets (e.g. patchstack/hub).
test_filesNoOptional: how many of the changed files are test files. Discounted from the file count the same way test_lines is discounted from the line count.
test_linesNoOptional: changed lines that live in test files (e.g. from `git diff --shortstat -- tests/`). Discounted from the verdict — test coverage is not review burden. Ignored when numstat is given.
moved_filesNoOptional: how many of the changed files were renamed or moved rather than edited (see `git diff --summary`). Discounted from the file count — without this a rename sweep is judged oversized on file count alone.
moved_linesNoOptional: lines that are relocated code, not new logic (e.g. an extraction refactor). Discounted from the verdict — a raw diff double-counts moves. Estimate honestly; recorded with the check.
review_goalsNoStrongly recommended: the distinct outcomes a reviewer must approve. Describe user or system outcomes, not implementation layers; supporting code, tests, docs, and migrations for one behavior are one goal. One fits, two get a caution, and three or more require a split.
changed_filesNoNumber of files changed. Optional but improves the size categorization.
scope_rationaleNoOptional: why multiple review goals must ship atomically. This preserves the reasoning for the team but does not silently waive the scope standard.

Output Schema

NameRequiredDescriptionDefault
teamYesTeam name.
reasonsYesWhy the verdict is what it is, in plain language.
verdictYesThe strongest result across active standards: fits | fits_at_edge (over the size standard but inside tolerance — stated, no action expected) | caution | split_required.
check_idYesId of the recorded check — pass it to record-change-fit-decision-tool to say what you did about this verdict.
guidanceYesConcrete next steps when the change does not cleanly fit.
proposedYesThe proposed change: additions, deletions, changed_files, total_changes, the discounted surfaces (test_lines, moved_lines, docs_lines, generated_lines, test_files, moved_files, docs_files, generated_files, binary_files), reviewable_changes and reviewable_files (what the verdict judges), size_category (tiny|small|medium|large|oversized, of the reviewable surface).
standardsYesPer-standard results. `size` reports its own verdict and threshold; `scope_coherence` reports assessed|not_assessed|disabled, the normalized review goals, rationale, reason, and guidance.
repositoryNoMatched team repository slug, or null if none given/matched.
team_normsYesThe box: merged PRs analyzed, median/p75 total changes, the Coderbuds standard size ceiling when active (target_total_changes), and average merge-time hours by size category.
review_tierNoOnly when the team has a review policy and numstat was given: the predicted review tier (none | ai_review | standard | careful), its headline, the reason that decided it, and all reasons strictest first — judged on the change itself, so it is what splitting or trimming can lower. `until_read` is set when a coding agent's unread change needs more than that until a person reads it; `assumptions` lists what the prediction could not know. Independent of the verdict.
review_queueYesCurrent open PR count, how many are awaiting review by a person (not those the review policy lets through on an AI review or none), and how many have waited past the Coderbuds review-turnaround standard. Scoped to the repository when one was given. PRs left unreviewed for over a month are reported separately as `abandoned` and excluded from the awaiting/stale pressure counts — they call for closing, not reviewing.
where_to_lookNoOnly alongside review_tier: the files a reviewer should read first and why, or null when the reasons already name them or no person needs to review.
show_it_workingNoOnly alongside review_tier, when the change touches what people see: put a screenshot or short recording in the pull request description. Do it.
lower_the_reviewNoOnly alongside review_tier, when a few files are what make the change need a person: which to split into their own pull request (`split_out`), what the rest would then need (`rest`), and a `note` to act on. Splitting is worth it when the rest is substantial; otherwise ignore it.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / properties / check_id / description
      Previous value: -"Id of the recorded check — pass it to record-change-fit-decision to say what you did about this verdict."New value: +"Id of the recorded check — pass it to record-change-fit-decision-tool to say what you did about this verdict."
  2. Changed5 schema fields changed
    • changedOutput schema / properties / lower_the_review / type
      Previous value: -"object"New value: +[
      +  "object",
      +  "null"
      +]
    • changedOutput schema / properties / repository / type
      Previous value: -"string"New value: +[
      +  "string",
      +  "null"
      +]
    • changedOutput schema / properties / review_queue / description
      Previous value: -"Current open PR count, how many are awaiting a reviewer, and how many have waited past the Coderbuds review-turnaround standard. Scoped to the repository when one was given. PRs left unreviewed for over a month are reported separately as `abandoned` and excluded from the awaiting/stale pressure counts — they call for closing, not reviewing."New value: +"Current open PR count, how many are awaiting review by a person (not those the review policy lets through on an AI review or none), and how many have waited past the Coderbuds review-turnaround standard. Scoped to the repository when one was given. PRs left unreviewed for over a month are reported separately as `abandoned` and excluded from the awaiting/stale pressure counts — they call for closing, not reviewing."
    • changedOutput schema / properties / show_it_working / type
      Previous value: -"string"New value: +[
      +  "string",
      +  "null"
      +]
    • changedOutput schema / properties / where_to_look / type
      Previous value: -"string"New value: +[
      +  "string",
      +  "null"
      +]
  3. Changed1 schema field changed
    • addedOutput schema / properties / show_it_working
      Added value: +{
      +  "description": "Only alongside review_tier, when the change touches what people see: put a screenshot or short recording in the pull request description. Do it.",
      +  "type": "string"
      +}
  4. Changed1 schema field changed
    • addedOutput schema / properties / lower_the_review
      Added value: +{
      +  "description": "Only alongside review_tier, when a few files are what make the change need a person: which to split into their own pull request (`split_out`), what the rest would then need (`rest`), and a `note` to act on. Splitting is worth it when the rest is substantial; otherwise ignore it.",
      +  "type": "object"
      +}
  5. Changed2 schema fields changed
    • addedOutput schema / properties / review_tier
      Added value: +{
      +  "description": "Only when the team has a review policy and numstat was given: the predicted review tier (none | ai_review | standard | careful), its headline, the reason that decided it, and all reasons strictest first — judged on the change itself, so it is what splitting or trimming can lower. `until_read` is set when a coding agent's unread change needs more than that until a person reads it; `assumptions` lists what the prediction could not know. Independent of the verdict.",
      +  "type": "object"
      +}
    • addedOutput schema / properties / where_to_look
      Added value: +{
      +  "description": "Only alongside review_tier: the files a reviewer should read first and why, or null when the reasons already name them or no person needs to review.",
      +  "type": "string"
      +}
  6. Changed4 schema fields changed
    • changedInput schema / properties / additions / description
      Previous value: -"Lines added in the proposed change (e.g. from `git diff --shortstat`)."New value: +"Lines added in the proposed change (e.g. from `git diff --shortstat`). Required unless numstat is given; worked out from the numstat when omitted."
    • changedInput schema / properties / deletions / description
      Previous value: -"Lines deleted in the proposed change."New value: +"Lines deleted in the proposed change. Required unless numstat is given; worked out from the numstat when omitted."
    • changedInput schema / properties / numstat / description
      Previous value: -"Strongly recommended: raw `git diff --numstat <base>...` output (tab-separated \"added deleted path\" rows, `-` for binary). Coderbuds classifies the paths itself and discounts tests, docs, generated files and binary assets, so the verdict judges the code a reviewer must read. Supersedes test_lines/test_files when given."New value: +"Strongly recommended: raw `git diff --numstat <base>...` output (tab-separated \"added deleted path\" rows, `-` for binary). Coderbuds counts the lines and files from it and classifies the paths itself, discounting tests, docs, generated files and binary assets, so the verdict judges the code a reviewer must read. Supersedes test_lines/test_files when given."
    • removedInput schema / required
      Removed value: -[
      -  "additions",
      -  "deletions"
      -]
  7. First observed

TDQS

A4.3/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Only destructiveHint=false is supplied, so the description carries the burden and largely meets it: it explains the four verdicts and their thresholds, the default-on opinionated standard teams can opt out of, path-based discounting of tests/docs/generated/binary, and that supplied counts are 'recorded with the check and visible to the team.' The main gap is that it never states the read-only/no-side-effect nature of the check itself or what happens when inputs are inconsistent (e.g. numstat plus test_lines), leaving the safety profile to inference from a single hint.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well front-loaded — the verdict vocabulary and the numstat-first guidance arrive early — but the discounting rationale is restated three times (numstat, test_lines, moved_files/moved_lines), and the sentence 'Do the same for files with test_files and moved_files' is grammatically broken and refers back ambiguously. For an 11-parameter tool some length is warranted, yet roughly a third of the text re-explains what the schema already says.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers everything an agent needs: triggers, preferred and fallback inputs, meaning of each verdict, the scope-coherence rule for review_goals, the opt-out-able house standard, path-based discounting, and the follow-up action when the verdict isn't 'fits.' An output schema exists, so the description is not obliged to detail return values, and it doesn't need to.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3; the description still adds cross-parameter meaning the schema only partially captures: numstat supersedes the manual split, review_goals threshold behavior (one fits / two caution / three split) is tied to concrete outcomes rather than schema typing, and scope_rationale is framed as 'preserves the reasoning' without 'silently waiving the scope standard.' It duplicates some schema text (moved_lines, test_lines discounting) rather than adding to it, which keeps it from a 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb+resource: 'Pre-flight fit check for a change you are about to open as a pull request.' It clearly separates itself from the two related siblings (set-change-fit-standard-tool, record-change-fit-decision-tool) by being a read-only evaluation of a diff, and it enumerates exactly what comes back: verdict with reasons, team size norms, merge time, review-queue pressure.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

States the precondition (before opening the PR), names the preferred input ('Best results: pass numstat'), the fallback path (declare test_lines/moved_lines yourself), and routes explicitly to record-change-fit-decision-tool when the verdict is not 'fits' — including the case of overriding. Alternatives and their selection conditions are spelled out rather than implied.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources