Skip to main content
The AI API provides endpoints for various AI-powered features including PR descriptions, code explanations, conflict resolution suggestions, and semantic search.

Overview

All AI endpoints are available through the tRPC API at /trpc/ai.*.

Status

Check AI availability and configuration.

Response


PR Description

Generate AI-powered PR title and description based on the diff.

Response

Example Usage


Explain File Diff

Get an AI explanation of changes to a file.

Response


Conflict Resolution

Get AI suggestions for resolving merge conflicts.

Response


Squash Commit Message

Generate a squash commit message summarizing multiple commits.

Response


Chat

Have a conversation about the repository.

Response


Search the codebase using natural language.

Response


Usage Examples

Generate PR Description

Resolve Conflicts


Configuration

AI features require API keys for the underlying providers:
Repository-specific keys can be set via the repoAiKeys API.

Rate Limiting

AI endpoints have the following rate limits:
  • PR Description: 10/minute
  • File Explanation: 30/minute
  • Conflict Resolution: 20/minute
  • Chat: 30/minute
  • Semantic Search: 60/minute