#39

feat: add commit comment tools

Openbensabicwants to merge intofrom

Adds five commit-comment tools, bringing the total to 47. They follow the existing core → tools → registry pattern and are wired through the AI SDK entry, presets, the @github-tools/sdk/eve subpath, the chat app, and docs.

ToolTypeGitHub endpoint
getCommitCommentreadrepos.getCommitComment
listCommitCommentsreadrepos.listCommentsForCommit (comments on one commit)
createCommitCommentwrite (approval)repos.createCommitComment
updateCommitCommentwrite (approval)repos.updateCommitComment
deleteCommitCommentwrite (approval)repos.deleteCommitComment

createCommitComment can be general or anchored to a diff line via path + position. The three write tools require approval by default.

Presets: reads are in code-review, repo-explorer, and maintainer; createCommitComment is also in code-review; update/delete are maintainer-only — mirroring how PR and gist comment tools are distributed.

Example

import { createGithubTools } from '@github-tools/sdk'
import { generateText } from 'ai'

const result = await generateText({
  model: yourModel,
  tools: createGithubTools({ token: process.env.GITHUB_TOKEN! }),
  prompt: 'Leave a comment on commit abc123 in vercel/ai noting the missing null check, then list all comments on it.',
})

Or cherry-pick a single factory:

import { createCommitComment } from '@github-tools/sdk'

const tools = {
  createCommitComment: createCommitComment(process.env.GITHUB_TOKEN!),
}

Activity

4
vercel[bot]4mo ago

The latest updates on your projects. Learn more about Vercel for GitHub.

ProjectDeploymentActionsUpdated (UTC)
github-tools-docs ReadyPreview, CommentJul 8, 2026 6:48am
github-actions[bot]4mo ago

Thank you for following the naming conventions! 🙏

HugoRCD6d ago

Thanks @bensabic! Closing this for now while we rework the tool set. We may reopen it later.