All checks were successful
Enterprise AI Code Review / ai-review (pull_request) Successful in 41s
Implements PR changelog generator that analyzes diffs and generates Keep a Changelog format entries ready for CHANGELOG.md. Features: - Generates structured changelog entries (Added/Changed/Fixed/etc.) - Automatically detects breaking changes - Includes technical details (files, LOC, components) - User-focused language filtering out noise - Ready to copy-paste into CHANGELOG.md Implementation: - Added changelog.md prompt template with Keep a Changelog format - Implemented _handle_changelog_command() in PRAgent - Added _format_changelog() for markdown formatting - Updated PRAgent.can_handle() to route changelog commands - Added 'changelog' to config.yml commands list Workflow Safety (prevents duplicate runs): - Added '@codebot changelog' to ai-comment-reply.yml conditions - Excluded from ai-chat.yml to prevent duplication - Only triggers on PR comments (not issues) - Manual command only (no automatic triggering) Testing: - 9 comprehensive tests in TestChangelogGeneration class - Tests command detection, formatting, config validation - Verifies prompt formatting and Keep a Changelog structure Documentation: - Updated README.md with changelog command and examples - Added detailed implementation guide in CLAUDE.md - Included example output and use cases Related: Milestone 2 feature - PR changelog generation for release notes
233 lines
7.4 KiB
YAML
233 lines
7.4 KiB
YAML
provider: openai # openai | openrouter | ollama
|
|
|
|
model:
|
|
openai: gpt-4.1-mini
|
|
openrouter: anthropic/claude-3.5-sonnet
|
|
ollama: codellama:13b
|
|
|
|
temperature: 0
|
|
max_tokens: 4096
|
|
|
|
# Review settings
|
|
review:
|
|
fail_on_severity: HIGH
|
|
max_diff_lines: 800
|
|
inline_comments: true
|
|
security_scan: true
|
|
|
|
# Agent settings
|
|
agents:
|
|
issue:
|
|
enabled: true
|
|
auto_label: true
|
|
auto_triage: true
|
|
duplicate_threshold: 0.85
|
|
events:
|
|
- opened
|
|
- labeled
|
|
pr:
|
|
enabled: true
|
|
inline_comments: true
|
|
security_scan: true
|
|
events:
|
|
- opened
|
|
- synchronize
|
|
auto_summary:
|
|
enabled: true # Auto-generate summary for PRs with empty descriptions
|
|
post_as_comment: true # true = post as comment, false = update PR description
|
|
codebase:
|
|
enabled: true
|
|
schedule: "0 0 * * 0" # Weekly on Sunday
|
|
chat:
|
|
enabled: true
|
|
name: "Bartender"
|
|
max_iterations: 5 # Max tool call iterations per chat
|
|
tools:
|
|
- search_codebase
|
|
- read_file
|
|
- search_web
|
|
searxng_url: "" # Set via SEARXNG_URL env var or here
|
|
|
|
# Interaction settings
|
|
# CUSTOMIZE YOUR BOT NAME HERE!
|
|
# Change mention_prefix to your preferred bot name:
|
|
# "@ai-bot" - Default
|
|
# "@bartender" - Friendly bar theme
|
|
# "@uni" - Short and simple
|
|
# "@joey" - Personal assistant name
|
|
# "@codebot" - Code-focused name
|
|
# NOTE: Also update the workflow files (.github/workflows/ or .gitea/workflows/)
|
|
# to match this prefix in the 'if: contains(...)' condition
|
|
interaction:
|
|
respond_to_mentions: true
|
|
mention_prefix: "@codebot" # Change this to customize your bot's name!
|
|
commands:
|
|
- help
|
|
- explain
|
|
- suggest
|
|
- security
|
|
- summarize # Generate PR summary (works on both issues and PRs)
|
|
- changelog # Generate Keep a Changelog format entries (PR comments only)
|
|
- triage
|
|
- review-again
|
|
|
|
# Enterprise settings
|
|
enterprise:
|
|
audit_log: true
|
|
audit_path: "/var/log/ai-review/"
|
|
metrics_enabled: true
|
|
rate_limit:
|
|
requests_per_minute: 30
|
|
max_concurrent: 4
|
|
|
|
# Label mappings for auto-labeling
|
|
# Each label has:
|
|
# name: The label name to use/create (string) or full config (dict)
|
|
# aliases: Alternative names for auto-detection (optional)
|
|
# color: Hex color code without # (optional, for label creation)
|
|
# description: Label description (optional, for label creation)
|
|
labels:
|
|
priority:
|
|
critical:
|
|
name: "priority: critical"
|
|
color: "b60205" # Dark Red
|
|
description: "Critical priority - immediate attention required"
|
|
aliases:
|
|
["Priority - Critical", "P0", "critical", "Priority/Critical"]
|
|
high:
|
|
name: "priority: high"
|
|
color: "d73a4a" # Red
|
|
description: "High priority issue"
|
|
aliases: ["Priority - High", "P1", "high", "Priority/High"]
|
|
medium:
|
|
name: "priority: medium"
|
|
color: "fbca04" # Yellow
|
|
description: "Medium priority issue"
|
|
aliases: ["Priority - Medium", "P2", "medium", "Priority/Medium"]
|
|
low:
|
|
name: "priority: low"
|
|
color: "28a745" # Green
|
|
description: "Low priority issue"
|
|
aliases: ["Priority - Low", "P3", "low", "Priority/Low"]
|
|
type:
|
|
bug:
|
|
name: "type: bug"
|
|
color: "d73a4a" # Red
|
|
description: "Something isn't working"
|
|
aliases: ["Kind/Bug", "bug", "Type: Bug", "Type/Bug", "Kind - Bug"]
|
|
feature:
|
|
name: "type: feature"
|
|
color: "1d76db" # Blue
|
|
description: "New feature request"
|
|
aliases:
|
|
[
|
|
"Kind/Feature",
|
|
"feature",
|
|
"enhancement",
|
|
"Kind/Enhancement",
|
|
"Type: Feature",
|
|
"Type/Feature",
|
|
"Kind - Feature",
|
|
]
|
|
question:
|
|
name: "type: question"
|
|
color: "cc317c" # Purple
|
|
description: "Further information is requested"
|
|
aliases:
|
|
[
|
|
"Kind/Question",
|
|
"question",
|
|
"Type: Question",
|
|
"Type/Question",
|
|
"Kind - Question",
|
|
]
|
|
docs:
|
|
name: "type: documentation"
|
|
color: "0075ca" # Light Blue
|
|
description: "Documentation improvements"
|
|
aliases:
|
|
[
|
|
"Kind/Documentation",
|
|
"documentation",
|
|
"docs",
|
|
"Type: Documentation",
|
|
"Type/Documentation",
|
|
"Kind - Documentation",
|
|
]
|
|
security:
|
|
name: "type: security"
|
|
color: "b60205" # Dark Red
|
|
description: "Security vulnerability or concern"
|
|
aliases:
|
|
[
|
|
"Kind/Security",
|
|
"security",
|
|
"Type: Security",
|
|
"Type/Security",
|
|
"Kind - Security",
|
|
]
|
|
testing:
|
|
name: "type: testing"
|
|
color: "0e8a16" # Green
|
|
description: "Related to testing"
|
|
aliases:
|
|
[
|
|
"Kind/Testing",
|
|
"testing",
|
|
"tests",
|
|
"Type: Testing",
|
|
"Type/Testing",
|
|
"Kind - Testing",
|
|
]
|
|
status:
|
|
ai_approved:
|
|
name: "ai-approved"
|
|
color: "28a745" # Green
|
|
description: "AI review approved this PR"
|
|
aliases:
|
|
[
|
|
"Status - Approved",
|
|
"approved",
|
|
"Status/Approved",
|
|
"Status - AI Approved",
|
|
]
|
|
ai_changes_required:
|
|
name: "ai-changes-required"
|
|
color: "d73a4a" # Red
|
|
description: "AI review found issues requiring changes"
|
|
aliases:
|
|
[
|
|
"Status - Changes Required",
|
|
"changes-required",
|
|
"Status/Changes Required",
|
|
"Status - AI Changes Required",
|
|
]
|
|
ai_reviewed:
|
|
name: "ai-reviewed"
|
|
color: "1d76db" # Blue
|
|
description: "This issue/PR has been reviewed by AI"
|
|
aliases:
|
|
[
|
|
"Reviewed - Confirmed",
|
|
"reviewed",
|
|
"Status/Reviewed",
|
|
"Reviewed/Confirmed",
|
|
"Status - Reviewed",
|
|
]
|
|
|
|
# Label schema detection patterns
|
|
# Used by setup-labels command to detect existing naming conventions
|
|
label_patterns:
|
|
# Detect prefix-based naming (e.g., Kind/Bug, Type/Feature)
|
|
prefix_slash: "^(Kind|Type|Category)/(.+)$"
|
|
# Detect dash-separated naming (e.g., Priority - High, Status - Blocked)
|
|
prefix_dash: "^(Priority|Status|Reviewed) - (.+)$"
|
|
# Detect colon-separated naming (e.g., type: bug, priority: high)
|
|
colon: "^(type|priority|status): (.+)$"
|
|
|
|
# Security scanning rules
|
|
security:
|
|
enabled: true
|
|
fail_on_high: true
|
|
rules_file: "security/security_rules.yml"
|