delimit_changelog
Generate a formal changelog entry from git commits or OpenAPI spec diffs, categorizing changes and optionally prepending to CHANGELOG.md.
Instructions
Generate a changelog from git + ledger (git mode) or spec diff (spec mode).
When to use: as part of the deploy gate chain to produce a release note, or to prepend a CHANGELOG.md entry for a tagged release. When NOT to use: for ad-hoc human prose explanation of a spec change (use delimit_explain) or release planning (delimit_release_plan).
Sibling contrast: delimit_explain renders human prose for one diff; delimit_release_plan plans services and versions; this generates a formal changelog entry.
Two modes:
Git mode (pass repo_path): reads git log since last tag, categorizes commits (feat/fix/refactor/docs/test/ci), pulls completed ledger items, formats as Markdown. Works for ANY repo.
Spec mode (pass old_spec + new_spec): compares two OpenAPI specs and produces an API changelog.
Side effects: read-only on git/spec inputs. Writes to output_file when provided. If output_file is "CHANGELOG.md", PREPENDS the entry rather than overwriting — preserving prior history.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| old_spec | No | Old OpenAPI spec path (spec mode). | |
| new_spec | No | New OpenAPI spec path (spec mode). | |
| format | No | "markdown" (default), "json", "keepachangelog", "github-release". | markdown |
| version | No | Version label (e.g. "4.1.0"). | |
| repo_path | No | Repo path (git mode). | |
| since_tag | No | Git tag to diff from. Empty = auto-detect latest tag. | |
| include_ledger | No | Include completed ledger items (git mode). Default True. | |
| output_file | No | Write the rendered changelog here. If "CHANGELOG.md", prepends the entry. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||