You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -246,6 +248,51 @@ If both the `--release` and the `--library-name` are passed, the command will lo
246
248
|`--delete-versions`| bool | If passed, all existing beta Version records will be deleted before the new beta release is imported. |
247
249
248
250
251
+
## `import_release_notes`
252
+
253
+
**Purpose**: Fetch the rendered release notes for Boost versions and store them in the `RenderedContent` cache (keyed `release_notes_boost-X-XX-X`). Tries the AsciiDoc source on S3 first, falls back to the legacy HTML in the `boostorg/website` GitHub repo. Also fetches the in-progress release notes.
254
+
255
+
When a release note is freshly stored and the `Version.whats_new` field is empty, this command also queues the AI "What's New" summary task — see [`generate_whats_new`](#generate_whats_new).
|`--new`| bool | Default: `true`. If `true`, only imports notes for the most recent version. Set to `false` to import for all active versions. |
268
+
269
+
## `generate_whats_new`
270
+
271
+
**Purpose**: Generate the AI-powered "What's New" draft summary for one or more Boost releases. The summary is a short, fixed-rubric bullet list (new libraries, performance, dependencies, security & reliability, developer experience) saved on the `Version` model as `whats_new` (markdown bullets). The public site parses the bullets into `whats_new_items` and renders them in the release-highlights card. Drafts are not shown on the public site until an admin sets `whats_new_approved=True` (also available as a Django admin action).
272
+
273
+
This command is opt-in. Auto-generation only runs as a side-effect of `import_release_notes` when a version's `whats_new` is empty. Use this command to backfill historical versions or to regenerate after editing the prompt.
274
+
275
+
The LLM call is a Celery task; the worker must be running and `OPENROUTER_API_KEY` must be set (see [Environment Variables](./env_vars.md)).
|`--all-missing`| bool | Queue generation for every active version that has stored release notes but no `whats_new` summary yet. |
290
+
|`--version`| string | Slug of a single version to (re)generate. Format: `boost-1-90-0`. |
291
+
|`--force`| bool | Regenerate even when a summary already exists. The chained save task overwrites `whats_new` and resets `whats_new_approved` to `False`, so regenerated content goes back through admin moderation. |
292
+
|`--dry-run`| bool | List the versions that would be queued without queuing them. |
293
+
|`--validate`| bool | Run the prompt synchronously against the latest `--limit` versions (that have release notes) and print the LLM output. No DB writes. Use to review prompt changes before sign-off. |
294
+
|`--limit`| int | Number of versions to process when `--validate` is set. Default: 10. |
295
+
249
296
## `sync_mailinglist_stats`
250
297
251
298
**Purpose**: Build EmailData objects from the hyperkitty email archive database.
- The Boost release-notes "What's New" draft summary (`versions/tasks.py`)
93
+
- Default model is `gpt-oss-120b`. To use a different model (e.g. a Claude model via OpenRouter), change `WHATS_NEW_MODEL` in `versions/tasks.py` and the per-handler model strings in `news/tasks.py`.
94
+
- For **local development**, set this in your `.env` file. Note: docker compose only loads `env_file` at container creation, so after adding the variable run `docker compose up -d --force-recreate web celery-worker celery-beat` to pick it up.
95
+
- In **deployed environments**, set as a kube secret in `kube/boost/values.yaml` (or the environment-specific yaml file).
96
+
- Without this variable set, OpenRouter responds with `401 No cookie auth credentials found` and Celery retries the task up to 3 times before giving up.
Copy file name to clipboardExpand all lines: docs/news.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,3 +37,9 @@ Users can moderate if:
37
37
- The user posses the `change_entry` permission to the News Entry model
38
38
- The user is in a group which posses the `change_entry` permission to the News Entry model
39
39
- The user is a Superuser
40
+
41
+
## AI-generated entry summaries
42
+
43
+
When an `Entry` is saved without a `summary`, `news/tasks.py` dispatches a Celery task that asks an LLM (via [OpenRouter](https://openrouter.ai), default model `gpt-oss-120b`) to produce a short plain-text summary, then writes it back to the entry. Clearing the `summary` field and saving triggers regeneration.
44
+
45
+
This is the same OpenRouter integration used by the Boost release-notes "What's New" summary in `versions/tasks.py`. Both share `OPENROUTER_API_KEY` — see [Environment Variables](./env_vars.md).
0 commit comments