Skip to main content
Glama
N0moreher0
by N0moreher0

Comment on PR

project_pr_comment

Post general or inline review comments on a pull request by PR number or URL; use file and line to pin feedback to specific code.

Instructions

Post a comment on a pull request: a general thread comment, or an inline review note pinned to a file/line (pass path + line). Accepts a PR number or a full PR URL. Use when: reporting status into the PR thread, answering a review comment, or leaving a file/line review note (path + line). Avoid when: the PR is not open yet (create it first), or you want to change code (use project_edit_file). Speed: one provider API call (issue-comments, or review-comments for inline notes). Output: pr_comment: repo, provider, pr, inline, comment_id, url, created_at, body_chars (+ path/line/side for inline notes). Batch-safe: no

Input Schema

NameRequiredDescriptionDefault
prYesPR number or PR URL.
bodyYesComment body (markdown).
lineNoLine number to anchor the inline note (new side by default).
pathNoWorkspace/repo file path for an inline review comment (requires `line`); omit for a general comment.
repoNoRepository as "owner/name" or a PR URL (default: VENIRA_GIT_REPO, git.repo in venira.config.json, else the workspace .git origin remote).
sideNoRIGHT = new code (default), LEFT = deleted code.
reasonNoWhy this change is made (e.g. "sua loi null pointer o dong 45"). Recorded in the audit trail so later sessions know the intent. Single line, max 400 chars, secrets are redacted.
providerNoProvider override for this call (default: VENIRA_GIT_PROVIDER, then venira.config.json, then inferred from the origin remote).
commit_idNoCommit sha the note is anchored to (default: the PR head).
start_lineNoFirst line of a multi-line inline note (must be <= line; GitHub/GitLab).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.5.4

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false and openWorldHint=true, and the description usefully adds cost/latency ("one provider API call (issue-comments, or review-comments for inline notes)") plus the exact returned fields (repo, pr, inline, comment_id, url, created_at, body_chars). It stops short of stating auth/scopes required to comment or whether a posted comment can be edited or removed, which is the remaining gap for a non-idempotent write tool.

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

Conciseness4/5

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

Front-loaded with purpose, then labeled Use/Avoid/Speed/Output/Batch-safe blocks, so an agent can scan to the relevant line. It is slightly longer than necessary because the inline-note mode is restated three times (purpose, Use-when, and again in Output), but nothing is padding.

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?

For a 10-parameter, no-output-schema write tool, the description supplies what the structured fields cannot: when to use it, what it returns, per-call API cost, and batching posture. Provider/repo/commit defaulting is left to the schema, which documents it fully, so nothing an agent needs to invoke correctly is missing.

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 description coverage is 100%, so the schema already does the heavy lifting and baseline is 3. The description adds meaning on top by surfacing the cross-parameter dependency ("pass path + line" for inline notes) and the number-vs-URL acceptance for `pr`, which are the two combinations most likely to be mis-invoked.

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?

States a specific verb+resource ("Post a comment on a pull request") and immediately distinguishes its two modes: a general thread comment versus an inline review note pinned to file/line. It also states the accepted identifier forms (PR number or full PR URL), so an agent can tell exactly what this does without opening the schema.

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?

Explicit "Use when" and "Avoid when" clauses cover both the reporting/answering cases and the inline-note case, and it names a concrete alternative for the wrong-tool case ("you want to change code (use project_edit_file)"). The precondition "PR is not open yet (create it first)" is an actual exclusion, not a vague hint.

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