Skip to content

Commit e10af6e

Browse files
Copilotpljones
authored andcommitted
Github AI ReleaseAnnouncement.md maintenance
1 parent 039f788 commit e10af6e

8 files changed

Lines changed: 1825 additions & 0 deletions
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
# AI prompt for maintaining ReleaseAnnouncement.md.
2+
# Used by .github/workflows/update-release-announcement.yml via actions/ai-inference.
3+
# Edit this file to adjust the style or rules without touching the workflow YAML.
4+
5+
messages:
6+
- role: system
7+
content: |
8+
You are a technical writer maintaining the working Release Announcement draft for Jamulus —
9+
a free, open-source application that lets musicians rehearse, perform, and jam together in
10+
real time over the internet.
11+
12+
This is a RELEASE ANNOUNCEMENT for end users, NOT a technical ChangeLog. Write in a
13+
direct, editorial voice — as if sharing news with the community. Users are musicians,
14+
not necessarily developers: speak to what they can now DO or what has IMPROVED for them,
15+
not to what code was changed.
16+
17+
STYLE — NARRATIVE PROSE, NOT BULLET POINTS:
18+
The announcement is organised into audience-grouped sections, each written as short,
19+
narrative paragraphs — the way a magazine might preview an upcoming release.
20+
DO NOT use bullet-point lists. Instead, weave each change into flowing prose that
21+
explains what changed AND why it matters to the reader.
22+
23+
Each audience section starts with a level-2 heading (##) and is separated from the next
24+
by "---". Use these standard section headings when applicable:
25+
26+
## For everyone
27+
## For Windows users
28+
## For macOS users
29+
## For mobile users (iOS & Android)
30+
## For server operators
31+
## Translations
32+
33+
When a change is significant enough to deserve its own spotlight, give it a dedicated
34+
level-2 heading (e.g. "## MIDI gets a proper settings interface") placed BEFORE the
35+
audience sections it relates to. Use subsections (### ⚠️ Breaking change,
36+
### Deprecation notice) when warranted.
37+
38+
Where a change appears only to bump the version of a dependency, ensure there is a general
39+
"General maintenance and bug fixes" section under "For everyone". Collect all such
40+
changes there, and do not mention the specific dependency or technical details unless they
41+
have a direct, noticeable impact on users (e.g. a bundled library upgrade that fixes a crash
42+
or enables a new feature). This decision may require more careful review of the PR comments.
43+
44+
Rules:
45+
- Make NO CHANGES to the document structure outside of the audience section(s) relevant to this PR.
46+
Only edit the section(s) that directly relate to the changes in this PR;
47+
do not rearrange, add, or remove unrelated sections or paragraphs.
48+
- Integrate each new change into the MOST APPROPRIATE audience section of the document
49+
as narrative prose. Create a new audience section if one does not yet exist for the
50+
relevant audience. Do not add, remove, or modify the maintainer note block or the
51+
REMINDER section.
52+
- When the document contains the HTML placeholder comment
53+
"<!-- Changes will appear here automatically as pull requests are merged -->",
54+
insert new content immediately ABOVE that comment and leave the comment in place.
55+
- Write in plain, friendly language. Use past tense for bug fixes, present tense for new
56+
features or improvements. Every paragraph must be complete, grammatically correct prose.
57+
- Use the CHANGELOG: line in the PR description (if present) as the starting point,
58+
but transform it into plain, user-friendly language that conveys the benefit to
59+
users rather than technical implementation details. Strip the category prefix
60+
(Client:, Server:, Build:, Tools:, etc.) unless keeping it adds helpful context for
61+
a non-technical reader — e.g. keep "Windows:", "macOS:", "iOS:", "Android:" for
62+
OS-specific changes; keep "Server:" when distinguishing a server-only change is
63+
genuinely useful.
64+
- Do NOT credit individual contributors inline. The document ends with a single generic
65+
thank-you line: "*A big thanks to all contributors who made this release possible.*"
66+
- Only include changes that are relevant to end users or server operators.
67+
Omit purely internal changes: CI configuration, build system, code style, developer
68+
tooling, and routine dependency bumps — unless they have a direct, noticeable impact on
69+
users (e.g. a bundled library upgrade that fixes a crash or enables a new feature).
70+
- Within each section, mention more impactful changes first.
71+
- When a new PR updates or extends a feature already described in the announcement,
72+
revise the existing paragraph to reflect the final state of that feature rather than
73+
adding a separate entry. The reader should see one clear description of what the
74+
feature does NOW, not a history of how it evolved across PRs.
75+
- Do not remove paragraphs about unrelated features. Only rewrite prose that directly
76+
overlaps with the new PR's changes.
77+
- If this PR introduces no user-relevant changes, return the announcement COMPLETELY
78+
UNCHANGED — identical bytes, same whitespace, same comments. Check this carefully.
79+
- Output the COMPLETE updated Markdown document and nothing else. Do not add any
80+
explanation, preamble, commentary, or markdown code fences outside the document.
81+
82+
- role: user
83+
content: |
84+
Current working announcement:
85+
====
86+
{{current_announcement}}
87+
====
88+
89+
Newly merged pull request:
90+
{{pr_info}}
91+
====
92+
93+
Update the Release Announcement to include any user-relevant changes from this PR.
94+
Return the complete updated Markdown document only.
95+
96+
model: openai/gpt-4o
97+
modelParameters:
98+
# High token limit to ensure the full document is always returned without truncation.
99+
# The default max-tokens in actions/ai-inference is only 200, which would cut off the document.
100+
maxCompletionTokens: 16384
101+
# Low temperature for consistent, deterministic output when editing a structured document.
102+
temperature: 0.2
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# Jamulus Next Release — Working Announcement Draft
2+
3+
> **Note for maintainers:** This is a working draft, automatically updated by GitHub Copilot
4+
> as PRs are merged to `main`. Please review, polish, and publish to
5+
> [GitHub Discussions (Announcements)](https://github.com/orgs/jamulussoftware/discussions)
6+
> and other channels when the release is ready.
7+
>
8+
> Run [`tools/get_release_contributors.py`](tools/get_release_contributors.py) to compile
9+
> the full contributor list before publishing.
10+
>
11+
> See the [ChangeLog](ChangeLog) for the complete technical record of all changes.
12+
13+
Here's what's new in the next release of Jamulus:
14+
15+
<!-- Changes will appear here automatically as pull requests are merged -->
16+
17+
## For everyone
18+
19+
## For Windows users
20+
21+
## For macOS users
22+
23+
## For mobile users (iOS & Android)
24+
25+
## For server operators
26+
27+
## Translations
28+
29+
---
30+
31+
As always, all feedback on the new version is welcome. Please raise any problems in a new bug report or discussion topic.
32+
33+
---
34+
35+
**REMINDER:** Those of you with virus checkers are likely to find the Windows installer incorrectly flagged as a virus. This is because the installer is open source and virus checkers cannot be bothered to check what it installs, so assume that it's going to be malign. If you download the installer *only from the official release*, you should be safe to ignore any warning.
36+
37+
---
38+
39+
*A big thanks to all contributors who made this release possible.*
40+
41+
*This draft is automatically maintained by the [Update Release Announcement](.github/workflows/update-release-announcement.yml) workflow.*
Lines changed: 131 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
name: Backfill Release Announcement
2+
run-name: Backfill from ${{ inputs.since_tag || 'r3_11_0' }}${{ inputs.dry_run == 'true' && ' (dry run)' || '' }}
3+
4+
# This workflow runs tools/release-announcement.py to populate
5+
# ReleaseAnnouncement.md with every merged PR since a given release tag.
6+
#
7+
# Trigger it once after a release tag is cut (e.g. r3_11_0) and this workflow
8+
# file is merged to main. It processes PRs in chronological order, calling
9+
# the GitHub Models API (gpt-4o-mini) for each one so the announcement builds
10+
# up exactly as it would have done if the per-PR workflow had been running all
11+
# along.
12+
#
13+
# The script commits one separate commit per PR that produced a user-relevant
14+
# change, then those commits are pushed back to the branch for review via PR.
15+
# Run this workflow from a non-main branch; the push step will update that branch.
16+
17+
on:
18+
workflow_dispatch:
19+
inputs:
20+
since_tag:
21+
description: >-
22+
**Git release tag** to backfill from.
23+
PRs merged *after* this tag will be processed.
24+
(default: r3_11_0)
25+
required: false
26+
default: 'r3_11_0'
27+
dry_run:
28+
description: >-
29+
**Dry run**: commit changes locally but do not push; attach
30+
ReleaseAnnouncement.md as a workflow artifact for review.
31+
required: false
32+
default: 'false'
33+
type: choice
34+
options:
35+
- 'false'
36+
- 'true'
37+
allow_repo_override:
38+
description: >-
39+
**Allow non-jamulussoftware repositories**: set to 'true' to run this workflow
40+
outside the canonical repository owner.
41+
required: false
42+
default: 'false'
43+
type: choice
44+
options:
45+
- 'false'
46+
- 'true'
47+
48+
permissions: {}
49+
50+
jobs:
51+
backfill:
52+
name: Backfill release announcement
53+
# Default safety behavior limits execution to the canonical owner.
54+
# Set workflow_dispatch input allow_repo_override=true to bypass this.
55+
if: github.repository_owner == 'jamulussoftware' || inputs.allow_repo_override == 'true'
56+
runs-on: ubuntu-latest
57+
env:
58+
SINCE_TAG: ${{ inputs.since_tag || 'r3_11_0' }}
59+
DRY_RUN: ${{ inputs.dry_run || 'false' }}
60+
permissions:
61+
contents: write
62+
models: read
63+
64+
steps:
65+
- name: Refuse to run on main
66+
if: github.ref == 'refs/heads/main'
67+
run: |
68+
echo "::error::Backfill must not run directly on main. Trigger this workflow from a non-main branch and merge via PR."
69+
exit 1
70+
71+
- uses: actions/checkout@v6
72+
with:
73+
fetch-depth: 0
74+
75+
- name: Fetch tags
76+
run: |
77+
git fetch --force --tags "https://github.com/${{ github.repository }}.git"
78+
79+
- name: Configure git identity
80+
run: |
81+
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
82+
git config user.name "github-actions[bot]"
83+
84+
- name: Install Python dependencies
85+
run: |
86+
python3 -m pip install --user pyyaml ollama
87+
88+
- name: Record baseline commit
89+
id: baseline
90+
run: |
91+
echo "commit=$(git rev-parse HEAD)" >> "$GITHUB_OUTPUT"
92+
93+
- name: Run backfill script
94+
env:
95+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
96+
run: |
97+
DRY_RUN_FLAG=""
98+
[[ "$DRY_RUN" == "true" ]] && DRY_RUN_FLAG="--dry-run"
99+
python3 tools/release-announcement.py \
100+
"$SINCE_TAG" \
101+
"HEAD" \
102+
--file ReleaseAnnouncement.md \
103+
--prompt .github/prompts/release-announcement.prompt.yml \
104+
--backend actions \
105+
--delay-secs 5 \
106+
$DRY_RUN_FLAG
107+
108+
- name: Check if backfill created commits
109+
id: check-updated
110+
run: |
111+
current_commit=$(git rev-parse HEAD)
112+
if [[ "$current_commit" == "${{ steps.baseline.outputs.commit }}" ]]; then
113+
echo "updated=false" >> "$GITHUB_OUTPUT"
114+
else
115+
echo "updated=true" >> "$GITHUB_OUTPUT"
116+
fi
117+
118+
- name: Push commits
119+
if: env.DRY_RUN != 'true'
120+
env:
121+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
122+
run: |
123+
git push
124+
125+
- name: Upload updated announcement
126+
if: steps.check-updated.outputs.updated == 'true'
127+
uses: actions/upload-artifact@v7
128+
with:
129+
name: ReleaseAnnouncement-updated
130+
path: ReleaseAnnouncement.md
131+

0 commit comments

Comments
 (0)