Skip to main content
Glama

review_and_commit

Automatically review code changes with AI analysis and commit them if they pass security and quality checks.

Instructions

Review code changes using Gemini and commit if approved (LGTM). Returns review comments if not approved or success message with commit hash if approved and committed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commit_messageYesCommit message to use if changes are approved
directoryYesPath to the git repository directory to review
Behavior3/5

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

With no annotations, the description carries full burden. It discloses key behavioral traits: uses Gemini for review, conditionally commits based on approval, and returns different outcomes (comments vs. success message with commit hash). However, it lacks details on review criteria, what 'approved' means, error handling, or side effects like branch changes.

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

Conciseness5/5

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

The description is highly concise and front-loaded: a single sentence efficiently conveys the tool's core functionality, conditional logic, and return outcomes. Every word earns its place with zero waste or redundancy.

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

Completeness4/5

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

Given no annotations and no output schema, the description does well by explaining the conditional behavior and return values. However, as a mutation tool (commits changes), it could benefit from more details on permissions, review standards, or error cases to be fully complete for agent use.

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

Parameters3/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 documents both parameters fully. The description adds no additional meaning about parameters beyond what the schema provides (e.g., no context on commit message format or directory requirements). Baseline 3 is appropriate when schema does the heavy lifting.

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?

The description clearly states the tool's purpose with specific verbs ('review code changes using Gemini', 'commit if approved') and resources ('code changes', 'commit hash'). It distinguishes from the sibling 'review_only' by explicitly mentioning the conditional commit action and different return outcomes.

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?

The description provides explicit usage guidance: use this tool when you want to review AND potentially commit code changes, with conditional logic (commit if approved/LGTM). It implicitly contrasts with 'review_only' by showing this tool includes commit functionality, making alternatives clear.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/shields/lgtmcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server