Skip to content

Improve changelog automation prompt#9070

Open
amyblais wants to merge 3 commits into
mattermost:masterfrom
amyblais:amyblais/update-generate-changelog
Open

Improve changelog automation prompt#9070
amyblais wants to merge 3 commits into
mattermost:masterfrom
amyblais:amyblais/update-generate-changelog

Conversation

@amyblais

Copy link
Copy Markdown
Member

Summary

  • Expanded system prompt with new instructions: blank-line rules between headings and content, DM/GM abbreviation expansion (DMDirect Message, GMGroup Message), one-section-per-note rule, and a new instruction Test image #10 ("Focus")
  • Added normalize_go_version() and extract_previous_go_version() helpers so the Go Version section always shows a concrete version number (looked up from the existing changelog when GO_VERSION is not provided)
  • Feature release anchor/heading now uses the -feature-release suffix to match the ESR pattern, and includes the full release-policy URL
  • CHANGELOG_PATH env var is now read in main() before building the Go section
  • go_section output changed from a bullet point to a bare sentence matching Mattermost changelog convention

Test plan

  • Run the script against a test milestone and verify the generated changelog entry matches the expected format
  • Verify Go version normalization handles both go1.22.5 and v1.22.5 input formats
  • Verify feature release heading includes the -feature-release anchor suffix

🤖 Generated with Claude Code

Copilot AI review requested due to automatic review settings June 25, 2026 12:10
@coderabbitai

coderabbitai Bot commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@amyblais, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 17 minutes and 40 seconds. Learn how PR review limits work.

Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file).

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits.

🚦 How do rate limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 97dc4e32-e04e-40ec-b526-8845e2f83468

📥 Commits

Reviewing files that changed from the base of the PR and between 6e6ca68 and c0877e8.

📒 Files selected for processing (1)
  • .github/scripts/generate_changelog.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@amyblais amyblais changed the title Update generate_changelog.py with improved system prompt and Go version handling Improve changelog automation prompt Jun 25, 2026
@amyblais

Copy link
Copy Markdown
Member Author

@coderabbitai full review

@coderabbitai

coderabbitai Bot commented Jun 25, 2026

Copy link
Copy Markdown
Contributor
✅ Action performed

Full review finished.

@amyblais amyblais added the Work In Progress Not yet ready for review label Jun 25, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the changelog generation script used by the docs repo workflow to (a) refine the AI system prompt used for release-note polishing and (b) improve Go version handling so the generated ### Go Version section includes a concrete version even when GO_VERSION isn’t provided.

Changes:

  • Expanded the Claude system prompt with stricter formatting/terminology rules (including DM/GM expansion and one-section-per-note).
  • Added helpers to normalize Go versions and to extract the previously documented Go version from the existing changelog when GO_VERSION is empty.
  • Updated feature-release anchors/headings to use the -feature-release suffix and adjusted how the Go Version section is rendered.

Comment thread .github/scripts/generate_changelog.py Outdated
Comment thread .github/scripts/generate_changelog.py Outdated
Comment thread .github/scripts/generate_changelog.py
Comment thread .github/scripts/generate_changelog.py Outdated
Comment thread .github/scripts/generate_changelog.py Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Work In Progress Not yet ready for review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants