Skip to content

[agentic-token-optimizer] Release workflow: prompt verbosity reduction (~390 tokens/run) #78

@github-actions

Description

@github-actions

Target Workflow

Release (workflows/release.md) — the only non-excluded agentic (LLM-driven) workflow not in scope for the "Token in name" exclusion and not optimized in the last 14 days with substantial analysis. Selected because its LLM prompt is the largest per-run payload relative to its output; the two prior entries in the optimization log audited only 1–2 runs each with minimal findings.


Analysis Period & Runs Analyzed

Period Runs Conclusions
2026-05-14 → 2026-05-26 (12 days) 2 2 success, 0 failure

Note: Token instrumentation returned 0 values for all workflows in the audit data for this period. Token estimates below are derived from prompt character counts and typical LLM encoding ratios (~0.25 tokens/char for English prose). Actual values may differ; estimates are conservative.


Token Profile

Metric Value
Runs analyzed 2
Avg agent job duration ~2 min 13 sec
Prompt body (chars) ~7,600
Estimated prompt tokens ~1,900
Estimated output tokens ~400
Total estimated tokens/run ~2,300
Cache efficiency Unknown (no telemetry)

References:


Ranked Recommendations

1. Remove the "Selection rubric" section (est. –125 tokens/run)

The ## What to Write section already instructs the agent to focus on user-facing changes and exclude internal ones. The "Selection rubric for whether a change belongs in the release notes or changelog" (~500 chars) restates this guidance in a different form without adding new constraints.

Action: Delete the "Selection rubric..." paragraph block from the prompt. The three include/omit/collapse bullets are already covered by earlier instructions and the "Exclude internal-only changes" section that follows immediately after.


2. Merge "Anti-patterns to avoid" + "Writing quality constraints" into a single short list (est. –150 tokens/run)

These two sections (~1,100 combined chars) have significant overlap. "Avoid repeating the same fact in both ## Highlights and ## Upgrade Notes" is also covered by the structure instructions. "Keep bullets parallel and scannable" duplicates "use plain English and strong verbs."

Action: Replace both sections with a single **Avoid:** bullet list and a one-line style note:

**Avoid:** rewriting commit subjects as bullets; listing changed files as user value;
vague filler ("various fixes"); overstating maintenance changes; contributor attribution
in the release body; repeating the same fact in both Highlights and Upgrade Notes.

**Style:** plain English, strong verbs, outcome-first bullets, concise over exhaustive.

Estimated reduction: ~700 chars → ~200 chars, saving ~125 tokens per invocation.


3. Condense the semver guidance section (est. –65 tokens/run)

The four-bullet semver list (major / minor / patch / 0.y.z) restates the general principle ("infer from user-visible diff, not from commit prefixes") four times with minor variation. The final bullet restates the major-release bullet.

Action: Collapse to two bullets:

  • Major: breaking changes, removals, migration; Minor: new capabilities, deprecations; Patch: fixes, polish, reliability.
  • 0.y.z: note pre-1.0 status; call out breakage plainly.

Estimated reduction: ~400 chars → ~150 chars, saving ~65 tokens per run.


4. Remove "Treat the public surface" paragraph (est. –50 tokens/run)

The paragraph "Treat the public surface of this project as the workflow behavior users depend on: workflow names, supported triggers and inputs..." (~200 chars) restates what is already implied by the user-facing framing throughout ## What to Write.

Action: Delete this paragraph. The subsequent anti-patterns and style sections already scope the content appropriately.


Summary

# Recommendation Est. savings/run
1 Remove "Selection rubric" section ~125 tokens
2 Merge anti-patterns + style constraints ~150 tokens
3 Condense semver guidance bullets ~65 tokens
4 Remove "Treat the public surface" paragraph ~50 tokens
Total ~390 tokens/run

Combined, these changes reduce the prompt body by approximately 20% (from ~7,600 to ~6,100 chars) with no behavioral change — all preserved intent is already stated elsewhere in the prompt.


Caveats

  • Token telemetry returned 0 for all workflows in the current audit window; all savings estimates are derived from prompt character counts and approximate encoding ratios, not measured values.
  • The Release workflow runs infrequently (≤2 runs in the 12-day window), so aggregate monthly savings are modest (~800 tokens/month). However, reducing instruction redundancy also lowers the risk of conflicting guidance being applied inconsistently.
  • No structural (sub-agent) changes are recommended: the single LLM task — synthesizing a changelog from diverse inputs (commits, file diffs, prior releases, workflow sources) — requires cross-referencing multiple heterogeneous sources and strategic synthesis. This is not well-suited to a smaller extractive model.

Generated by Agentic Workflow Token Usage Optimizer · ● 7.8M ·

  • expires on Jun 2, 2026, 3:43 PM UTC

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions