Skip to content

[3736 by Claude Opus 5.5] Commit subjects: a short imperative line generated separately from the run summary - #3749

Merged
integry merged 4 commits into
mainfrom
3736/claude-opus-5-5-commit-subjects-a-short-i-20261120-1619-d6d
Nov 20, 2026
Merged

integry merged 4 commits into
mainfrom
3736/claude-opus-5-5-commit-subjects-a-short-i-20261120-1619-d6d

Conversation

@propr-dev

@propr-dev propr-dev Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

AI Implementation Summary

Closes #3736

Branch: 3736/claude-opus-5-5-commit-subjects-a-short-i-20261120-1619-d6d
Commits: ✅ Changes committed (177313e)


AI Processing Completed

Execution Details:

Summary:
ProPR commits now get a short imperative subject that says what changed, such as fix: keep the create dialog open. The run summary goes in the commit body. My new tests and the related suites I ran all pass, and lint and typecheck are clean. I didn't run the full test suite, and nothing has run against a real small model yet.

What a commit looks like now

  • Subject: at most 72 characters, cut at a word boundary with "…". A separate small-model call writes it, using the same model setting as PR task titles.
  • Rejected replies: a reply in the first person ("I fixed…") or one that reports test results is thrown away.
  • Fallback: if the call fails, times out, gets rejected, or no small model is configured, the subject is the PR or issue title with the [N by Model] prefix and (#N) suffix removed. It never uses the summary text.
  • Type: if every changed file is docs, tests, CI or dependency files, the type is docs, test, ci or build. Otherwise the earliest keyword in the title decides (fix, feat, refactor, …), and anything unclear is chore. It's word matching, so it can misjudge: the title "Fold an aggregate CI job…" comes out as ci because "CI" appears before any other keyword.
  • AI marker: the (ai) scope is gone. Agent commits end with a ProPR-Agent: <agent alias>/<model> trailer instead.

Where it applies

  • Issue runs and PR follow-ups: they share one builder. The changed paths come from git status in the worktree just before the commit.
  • Epic-branch squash (checkRunHandler.ts): the subject is built from the sub-PR title plus (#N), and the first commit's message becomes the body. This now applies only when the merge method is squash. Before, an epic merge with the merge method also used the first commit's subject; it now gets GitHub's standard "Merge pull request #N" title.
  • Merge-conflict commits: they keep their merge: subjects, now capped at 72 characters. I didn't add the trailer to them.
  • Follow-up recovery commit: it becomes chore: recover interrupted follow-up for PR #N, with the trailer when the model is known.
  • Commits not covered: goal checkpoint commits still use the message the agent declares. That path wasn't in the issue, so I left it alone.

Old and new history

  • parseCommitSubject and isProprAgentCommit in @propr/shared read both old feat(ai): … subjects and new ones.
  • The completion comment's fallback strips the trailer before showing the commit body.
  • No release-notes script parses commit subjects, so nothing else needed changing.

Tests

  • New tests: packages/shared/test/commitSubject.test.ts (10) and test/commitSubjectGeneration.test.ts (9) cover each case the issue lists: first-person summary in, imperative subject out; truncation; fallback to the title; type by path; trailer present.
  • Existing suites: I updated one assertion in test/runSummarySelection.test.ts. I ran 69 suites in the issue-job, follow-up, handoff, epic and auto-merge areas, plus checkRunHandler, commitOperations and mergeConflictHelpers, and all pass.
  • One fix from the run: test/prPublicationRecoveryJob.test.ts first failed all 39 tests because its job data has a non-string task title. I made the title parsing tolerate that, and it now passes.

Cost and where the code is

  • One more small-model call per run that publishes a summary. It is opt-in through a new commitSubject field on applyRunSummarySelection, so other callers don't make it.
  • The pure builder is packages/shared/src/commitSubject.ts and the model call is packages/core/src/agents/commitSubjectGeneration.ts.
  • The root helper src/jobs/agentCommitMessage.ts only imports @propr/shared, so existing test mocks of @propr/core didn't need new entries.

I added the CHANGELOG entry under Unreleased. There's nothing visual to preview.

Review digest

Risk-tiered paths

  • High risk: none
  • Normal risk (19 files)
    • packages/core/src/agents/commitSubjectGeneration.ts (added, +87/−0)
    • packages/core/src/agents/runSummarySelection.ts (+18/−0)
    • packages/core/src/agents/types.ts (+2/−0)
    • packages/core/src/claude/claudeService.ts (+4/−0)
    • packages/core/src/git/commitOperations.ts (+4/−2)
    • packages/core/src/index.ts (+1/−0)
    • packages/core/src/webhook/checkRunHandler.ts (+9/−6)
    • packages/shared/src/commitSubject.ts (added, +236/−0)
    • packages/shared/src/index.ts (+2/−0)
    • src/jobs/agentCommitMessage.ts (added, +70/−0)
    • src/jobs/followupHandoffMessages.ts (+5/−2)
    • src/jobs/issueJob/agent.ts (+7/−1)
    • src/jobs/issueJobPostProcessing.ts (+12/−6)
    • src/jobs/mergeConflictHelpers.ts (+3/−3)
    • src/jobs/prCommentAgentUtils.ts (+2/−2)
    • src/jobs/prCommentJobUtils.ts (+16/−14)
    • src/jobs/prCommentPostExecution.ts (+5/−1)
    • src/jobs/prCompletionComment.ts (+2/−2)
    • src/jobs/prFileUtils.ts (+1/−0)
  • Low risk (4 files)
    • CHANGELOG.md (+25/−0)
    • packages/shared/test/commitSubject.test.ts (added, +116/−0)
    • test/commitSubjectGeneration.test.ts (added, +135/−0)
    • test/runSummarySelection.test.ts (+3/−2)

Diff size: 23 files changed, +765/−41 lines

View task for the run's logs and conversation.


This PR was created automatically by ProPR after processing issue #3736.


💡 Need changes?

Comment on this PR to request refinements — the AI agent monitors comments and will update the implementation based on your feedback. Keep iterating until you're satisfied!

…ed, such as `fix: keep the create dialog open`. The run summary goes in the commit body. My new tests and the related suites I ran all pass, and lint and typecheck are clean. I didn't run the full test suite, and nothing has run against a real small model yet.

What a commit looks like now
- Subject: at most 72 characters, cut at a word boundary with "…". A separate small-model call writes it, using the same model setting as PR task titles.
- Rejected replies: a reply in the first person ("I fixed…") or one that reports test results is thrown away.
- Fallback: if the call fails, times out, gets rejected, or no small model is configured, the subject is the PR or issue title with the `[N by Model]` prefix and `(#N)` suffix removed. It never uses the summary text.
- Type: if every changed file is docs, tests, CI or dependency files, the type is `docs`, `test`, `ci` or `build`. Otherwise the earliest keyword in the title decides (`fix`, `feat`, `refactor`, …), and anything unclear is `chore`. It's word matching, so it can misjudge: the title "Fold an aggregate CI job…" comes out as `ci` because "CI" appears before any other keyword.
- AI marker: the `(ai)` scope is gone. Agent commits end with a `ProPR-Agent: <agent alias>/<model>` trailer instead.

Where it applies
- Issue runs and PR follow-ups: they share one builder. The changed paths come from `git status` in the worktree just before the commit.
- Epic-branch squash (`checkRunHandler.ts`): the subject is built from the sub-PR title plus ` (#N)`, and the first commit's message becomes the body. This now applies only when the merge method is squash. Before, an epic merge with the merge method also used the first commit's subject; it now gets GitHub's standard "Merge pull request #N" title.
- Merge-conflict commits: they keep their `merge:` subjects, now capped at 72 characters. I didn't add the trailer to them.
- Follow-up recovery commit: it becomes `chore: recover interrupted follow-up for PR #N`, with the trailer when the model is known.
- Commits not covered: goal checkpoint commits still use the message the agent declares. That path wasn't in the issue, so I left it alone.

Old and new history
- `parseCommitSubject` and `isProprAgentCommit` in `@propr/shared` read both old `feat(ai): …` subjects and new ones.
- The completion comment's fallback strips the trailer before showing the commit body.
- No release-notes script parses commit subjects, so nothing else needed changing.

Tests
- New tests: `packages/shared/test/commitSubject.test.ts` (10) and `test/commitSubjectGeneration.test.ts` (9) cover each case the issue lists: first-person summary in, imperative subject out; truncation; fallback to the title; type by path; trailer present.
- Existing suites: I updated one assertion in `test/runSummarySelection.test.ts`. I ran 69 suites in the issue-job, follow-up, handoff, epic and auto-merge areas, plus `checkRunHandler`, `commitOperations` and `mergeConflictHelpers`, and all pass.
- One fix from the run: `test/prPublicationRecoveryJob.test.ts` first failed all 39 tests because its job data has a non-string task title. I made the title parsing tolerate that, and it now passes.

Cost and where the code is
- One more small-model call per run that publishes a summary. It is opt-in through a new `commitSubject` field on `applyRunSummarySelection`, so other callers don't make it.
- The pure builder is `packages/shared/src/commitSubject.ts` and the model call is `packages/core/src/agents/commitSubjectGeneration.ts`.
- The root helper `src/jobs/agentCommitMessage.ts` only imports `@propr/shared`, so existing test mocks of `@propr/core` didn't need new entries.

I added the CHANGELOG entry under Unreleased. There's nothing visual to preview.

integry commented Nov 20, 2026

Copy link
Copy Markdown
Owner

/ultrafix goal=8 max=3

@propr-dev propr-dev Bot added the ultrafix label Nov 20, 2026
@propr-dev

propr-dev Bot commented Nov 20, 2026

Copy link
Copy Markdown
Contributor Author

🔄 Ultrafix loop started (goal: 8/10, max cycles: 3)

First action: /review

💡 Tip: Remove the ultrafix label from this PR to stop further ultrafix cycles.

@propr-dev

propr-dev Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ AI Code Review Complete requested by @propr-ultrafix

Posted 1 review:

View Task Details

@propr-dev

propr-dev Bot commented Nov 20, 2026

Copy link
Copy Markdown
Contributor Author

CI failed: CodeQL

Please investigate and fix this CI failure.

Failure evidence

packages/shared/src/commitSubject.ts:152 — Polynomial regular expression used on uncontrolled data
This regular expression that depends on library input may run slow on strings with many repetitions of '\t'.
This regular expression that depends on library input may run slow on strings with many repetitions of '\t'.
This regular expression that depends on library input may run slow on strings with many repetitions of '\t'.
This regular expression that depends on library input may run slow on strings with many repetitions of '\t'.
This regular expression that depends on library input may run slow on strings with many repetitions of '\t'.

@propr-dev

propr-dev Bot commented Nov 20, 2026

Copy link
Copy Markdown
Contributor Author

🔍 AI Code Review — codex:gpt-6-astra

Overall Evaluation

The PR separates commit subjects from run summaries and updates issue, follow-up, recovery, and epic-squash paths. It needs minor corrections before merge.

✅ Separate subject generation — A dedicated model call proposes the description; generation failures fall back without failing publication.

✅ Bounded subjects — Shared formatting caps ordinary subjects and reserves space for epic-squash PR-number suffixes.

The issue specification contains an explicit truncation notice; this review assesses the visible requirements and supplied code. Current checks report no failures, with six pending. No commands were run.

Merge blockers

Every finding below was introduced by this PR and must be resolved before merging.

F1: 🔴 Validate title-derived subjects too

  • Category: requirement

  • Required behavior: Commit subjects must contain no first-person narration or test-result reports.

  • Evidence: packages/shared/src/commitSubject.ts, buildCommitSubject and epicSquashCommitFields

    1. An issue has the title I cannot log in, and subject generation is unavailable or fails.
    2. buildCommitSubject normalizes that title but applies isAcceptableCommitDescription only to the generated description.
    3. It publishes chore: I cannot log in, retaining first-person wording. Similarly, a title such as All tests pass becomes a test-result subject.
    4. epicSquashCommitFields also uses a nonempty normalized title without validating it, allowing the same outcomes during squash.

    The generated-description validator does not protect either title path. Existing fallback tests use acceptable titles and therefore miss this case. Verification provenance — static trace: the supplied normalization, validation, and subject-selection functions.

  • Minimum fix: Apply the description validator to title-derived descriptions in both builders, falling back to the fixed description when the title is unacceptable. Add regression cases for first-person and test-report titles.

F2: 🔴 Classify only publishable changed paths

  • Category: correctness

  • Required behavior: The conventional type must reflect the committed change; documentation-only changes should receive docs.

  • Evidence: src/jobs/agentCommitMessage.ts, pendingChangePaths; packages/core/src/git/commitOperations.ts, GENERATED_PROPR_RUNTIME_PATHS and stageCommitFiles

    1. A run titled Add retry documentation changes docs/retries.md and leaves an unignored generated file at .propr/assets/output.json.
    2. pendingChangePaths excludes only .propr/previews/ and .propr/tmp/, so both paths reach type inference.
    3. The mixed paths defeat documentation-only classification; the title’s Add keyword selects feat.
    4. stageCommitFiles excludes .propr/assets from staging. The resulting commit contains only documentation but permanently receives a feat: subject.

    Staging protects the commit contents, but happens after subject construction and cannot correct the inferred type. The new runtime-file test covers only previews. Verification provenance — static trace: the supplied path collector, type inference, and staging exclusions.

  • Minimum fix: Make path collection use the complete runtime exclusion policy used by staging, preferably through a shared definition. Cover documentation changes accompanied by excluded assets or cache files.

Suggestions

These are optional follow-ups and are not sent to /fix.

S1: 🟢 Exercise successful summary selection

The new “own call” test returns a subject string for both model calls, so summary selection encounters invalid JSON and falls back. Returning valid selection JSON first and a subject second would additionally verify successful selection feeds the separate generator. This is optional because the existing test still verifies that two calls occur and the summary survives.

Score

The implementation is cohesive and has useful focused coverage, but two deterministic boundary cases undermine the new subject contract. The supplied checks have no current failures; six remain pending.

Score: 6/10


🤖 Review Details

  • Model: GPT-6 Astra
  • Time: 39s
  • Tokens: 56,842 (55,513 in / 1,329 out)
  • Cost: $0.51

View Task


💡 Next step: Comment /fix to address every F# merge blocker, /fix all for every pending blocker and suggestion, or name records explicitly, as in /fix F3 S5.
F# and S# IDs increment across review comments and remain permanent, so selectors such as /fix F3 F5 stay unambiguous across cycles. S# suggestions stay optional: they are implemented only when you name them or request /fix all, and they never relax a merge blocker.

Copy and edit to choose records from this review:

/fix F1 F2 S1

🤖 Review by ProPR

@propr-dev

propr-dev Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ Applied the requested follow-up changes in commit f865267

Processed 2 comments:

  • Comment 1 by @github-advanced-security[bot] (ID: 4645214108✓)
  • Comment 2 by @propr-dev[bot] (ID: 7045344994✓)

Summary of Changes

I fixed the slow regex that CodeQL flagged in cleanCommitTitle (packages/shared/src/commitSubject.ts:149). CodeQL itself hasn't re-run yet, so whether the alert clears will show on the next CI run.

The cause: the line that strips a trailing (#N) from a title used /\s*\(#\d+\)\s*$/. Because the pattern starts with \s* and isn't anchored at the front, the regex engine retries from every position inside a long run of whitespace. Its run time grows with the square of the length. I measured it: with 50,000 tabs, the old regex took 5.8 seconds.

The fix: cleanCommitTitle now trims the title first and then strips the two parts with plain scans instead of the risky patterns:

  • The [N by Model] prefix: if the title starts with [, it finds the first ] and drops that bracket only if the text inside contains the word "by". This matches what the old prefix regex did.
  • The (#N) suffix: it uses /\(#\d+\)$/, which has no leading \s*, then trims what's left.

Normal titles come out the same as before.

Testing: I added a test to packages/shared/test/commitSubject.test.ts. It checks normal title cleaning and two inputs with 200,000 tabs each, which now finish in milliseconds. The shared commit-subject tests (11) and the related root suites commitSubjectGeneration and runSummarySelection (44 tests) all pass, and the shared package typechecks. ESLint has no rules set up for packages/shared, so lint doesn't cover these two files.

There's nothing visual to preview.

Review digest

Risk-tiered paths

  • High risk: none
  • Normal risk (1 file)
    • packages/shared/src/commitSubject.ts (+8/−2)
  • Low risk (1 file)
    • packages/shared/test/commitSubject.test.ts (+12/−0)

Diff size: 2 files changed, +20/−2 lines


🤖 Implementation Details

  • Model: Claude Opus 5.5 (medium)
  • Requested By: @github-advanced-security[bot], @propr-dev[bot]
  • Time: 4m 5s
  • Tokens: 589,740 (586,216 in / 3,524 out)
  • Cost: $0.40

Undo Changes • View Task Execution


💡 ProPR Slash Commands
Command Description Example
/merge Merge target branch into this PR and resolve conflicts /merge
/review Request an AI code review /review or /review claude-sonnet
/fix Address review blockers, or blockers and suggestions with /fix all /fix, /fix all, or /fix F3 S5
/switch Change the AI model for this PR /switch claude-opus
/use Override the model for a single follow-up run /use claude-sonnet
/ultrafix Loop review→fix cycles until score goal is met /ultrafix or /ultrafix goal=8 max=10

🤖 Generated by ProPR
Processing comment IDs: 4645214108✓, 7045344994✓

…itle` (`packages/shared/src/commitSubject.ts:149`). CodeQL itself hasn't re-run yet, so whether the alert clears will show on the next CI run.

I fixed the slow regex that CodeQL flagged in `cleanCommitTitle` (`packages/shared/src/commitSubject.ts:149`). CodeQL itself hasn't re-run yet, so whether the alert clears will show on the next CI run.

**The cause:** the line that strips a trailing `(#N)` from a title used `/\s*\(#\d+\)\s*$/`. Because the pattern starts with `\s*` and isn't anchored at the front, the regex engine retries from every position inside a long run of whitespace. Its run time grows with the square of the length. I measured it: with 50,000 tabs, the old regex took 5.8 seconds.

**The fix:** `cleanCommitTitle` now trims the title first and then strips the two parts with plain scans instead of the risky patterns:
- **The `[N by Model]` prefix:** if the title starts with `[`, it finds the first `]` and drops that bracket only if the text inside contains the word "by". This matches what the old prefix regex did.
- **The `(#N)` suffix:** it uses `/\(#\d+\)$/`, which has no leading `\s*`, then trims what's left.

Normal titles come out the same as before.

**Testing:** I added a test to `packages/shared/test/commitSubject.test.ts`. It checks normal title cleaning and two inputs with 200,000 tabs each, which now finish in milliseconds. The shared commit-subject tests (11) and the related root suites `commitSubjectGeneration` and `runSummarySelection` (44 tests) all pass, and the shared package typechecks. ESLint has no rules set up for `packages/shared`, so lint doesn't cover these two files.

There's nothing visual to preview.

PR: #3749
Comment by: @github-advanced-security[bot] (ID: 4645214108)
Comment by: @propr-dev[bot] (ID: 7045344994)
Model: Claude Opus 5.5
@propr-dev

propr-dev Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ Applied the requested follow-up changes in commit b49f441

Addressed 1 AI review comment (IDs: 7045354565)

Addressed findings F1, F2

Summary of Changes

I fixed both findings, and the tests I ran pass.

F1: titles now go through the same check as generated subjects.

  • buildCommitSubject (packages/shared/src/commitSubject.ts) now tries the generated description, then the title, and uses the first one that passes isAcceptableCommitDescription. If neither passes, it uses the fixed fallback. So an issue titled I cannot log in with no usable generated subject now gets chore: resolve issue #12 instead of chore: I cannot log in.
  • epicSquashCommitFields follows the same order: sub-PR title, then the first commit's new-style subject, then merge pull request #N. Before, any non-empty title was used without checking.
  • The title can still set the conventional type when its wording is rejected. For example, All tests pass gives test: merge pull request #6 (#6). This matches the minimum fix the finding asked for.
  • New tests in packages/shared/test/commitSubject.test.ts cover first-person titles, test-report titles and a prefixed title like [12 by Codex] We broke the export (#13), for both builders.

F2: the commit type and staging now skip the same paths.

  • The list of ProPR runtime paths that commits never stage now lives in one place, the new packages/shared/src/proprRuntimePaths.ts. It covers .propr/assets, .propr/cache, .propr/.cache, .propr/node_modules, [local preview omitted] and [local preview omitted].
  • stageCommitFiles in core and pendingChangePaths (src/jobs/agentCommitMessage.ts) both use that list now. Core still exports isGeneratedRuntimePath under the same name, and visualPreviewPaths.ts takes its two preview directory names from the shared file.
  • The runtime-file test in test/commitSubjectGeneration.test.ts now creates a file in each of those paths next to docs/a.md. It checks that only docs/a.md comes back and that the title Add retry documentation gets docs, not feat.

What I ran: the shared and root commit-subject suites, the core and root commitOperations suites, the blocked-run and follow-up-handoff suites, and the visual-preview service and config suites. All pass. Shared, core and root typecheck cleanly, and lint passes on the changed source files.

One behaviour change: the old path filter also skipped .propr/tmp/. Staging does not skip it and it isn't gitignored, so it does get committed. To match staging, pendingChangePaths now counts it toward the type.

No preview was captured because nothing here changes what users see.

Review digest

Risk-tiered paths

  • High risk: none
  • Normal risk (6 files)
    • packages/core/src/git/commitOperations.ts (+3/−14)
    • packages/core/src/services/visualPreviewPaths.ts (+3/−2)
    • packages/shared/src/commitSubject.ts (+4/−4)
    • packages/shared/src/index.ts (+1/−0)
    • packages/shared/src/proprRuntimePaths.ts (added, +21/−0)
    • src/jobs/agentCommitMessage.ts (+3/−3)
  • Low risk (2 files)
    • packages/shared/test/commitSubject.test.ts (+18/−0)
    • test/commitSubjectGeneration.test.ts (+10/−3)

Diff size: 8 files changed, +63/−26 lines


🤖 Implementation Details

  • Model: Claude Opus 5.5 (medium)
  • Requested By: @propr-ultrafix
  • Time: 7m 19s
  • Tokens: 1,267,832 (1,258,608 in / 9,224 out)
  • Cost: $0.74

View Task Execution


💡 ProPR Slash Commands
Command Description Example
/merge Merge target branch into this PR and resolve conflicts /merge
/review Request an AI code review /review or /review claude-sonnet
/fix Address review blockers, or blockers and suggestions with /fix all /fix, /fix all, or /fix F3 S5
/switch Change the AI model for this PR /switch claude-opus
/use Override the model for a single follow-up run /use claude-sonnet
/ultrafix Loop review→fix cycles until score goal is met /ultrafix or /ultrafix goal=8 max=10

🤖 Generated by ProPR

I fixed both findings, and the tests I ran pass.

**F1: titles now go through the same check as generated subjects.**
- `buildCommitSubject` (`packages/shared/src/commitSubject.ts`) now tries the generated description, then the title, and uses the first one that passes `isAcceptableCommitDescription`. If neither passes, it uses the fixed fallback. So an issue titled `I cannot log in` with no usable generated subject now gets `chore: resolve issue #12` instead of `chore: I cannot log in`.
- `epicSquashCommitFields` follows the same order: sub-PR title, then the first commit's new-style subject, then `merge pull request #N`. Before, any non-empty title was used without checking.
- The title can still set the conventional type when its wording is rejected. For example, `All tests pass` gives `test: merge pull request #6 (#6)`. This matches the minimum fix the finding asked for.
- New tests in `packages/shared/test/commitSubject.test.ts` cover first-person titles, test-report titles and a prefixed title like `[12 by Codex] We broke the export (#13)`, for both builders.

**F2: the commit type and staging now skip the same paths.**
- The list of ProPR runtime paths that commits never stage now lives in one place, the new `packages/shared/src/proprRuntimePaths.ts`. It covers `.propr/assets`, `.propr/cache`, `.propr/.cache`, `.propr/node_modules`, `.propr/previews` and `.propr/preview-src`.
- `stageCommitFiles` in core and `pendingChangePaths` (`src/jobs/agentCommitMessage.ts`) both use that list now. Core still exports `isGeneratedRuntimePath` under the same name, and `visualPreviewPaths.ts` takes its two preview directory names from the shared file.
- The runtime-file test in `test/commitSubjectGeneration.test.ts` now creates a file in each of those paths next to `docs/a.md`. It checks that only `docs/a.md` comes back and that the title `Add retry documentation` gets `docs`, not `feat`.

**What I ran:** the shared and root commit-subject suites, the core and root `commitOperations` suites, the blocked-run and follow-up-handoff suites, and the visual-preview service and config suites. All pass. Shared, core and root typecheck cleanly, and lint passes on the changed source files.

**One behaviour change:** the old path filter also skipped `.propr/tmp/`. Staging does not skip it and it isn't gitignored, so it does get committed. To match staging, `pendingChangePaths` now counts it toward the type.

No preview was captured because nothing here changes what users see.

PR: #3749
Comment by: @propr-ultrafix (ID: 0)
Model: Claude Opus 5.5
@propr-dev

propr-dev Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ AI Code Review Complete requested by @propr-ultrafix

Posted 1 review:

View Task Details

@propr-dev

propr-dev Bot commented Nov 20, 2026

Copy link
Copy Markdown
Contributor Author

🔍 AI Code Review — codex:gpt-6-astra

Overall Evaluation

The PR separates commit subjects from run summaries and adds shared formatting, type inference, and attribution helpers. It needs one localized correction before merge.

✅ Separate subject generation — A dedicated model call generates the description, with failure handling that falls back to the issue or PR title.

✅ Consistent runtime exclusions — Staging and changed-path classification now share the same generated-runtime path definitions.

✅ Focused coverage — Tests cover subject length, rejected narration, generation failures, trailers, and epic squash formatting.

The supplied issue specification is truncated, so this review assesses the visible requirements and supplied code. Current checks show no failures, with six checks pending.

Merge blockers

Every finding below was introduced by this PR and must be resolved before merging.

F3: 🔴 Dependency manifests receive the docs type

  • Category: correctness

  • Required behavior: The conventional-commit type should reflect the change; the implementation explicitly promises build for changes containing only dependency files.

  • Evidence: packages/shared/src/commitSubject.ts:pathClass

    1. An agent changes only requirements.txt, a dependency manifest recognized by the supplied isDependencyManifest implementation.
    2. pendingChangePaths passes that filename to buildCommitSubject, which calls inferCommitType.
    3. pathClass checks isDocumentationFile before isDependencyFile. Because documentation classification accepts every .txt file, it returns docs immediately.
    4. The dependency update is persistently committed as docs: …, even if the title explicitly identifies a dependency upgrade.

    static trace: Verified against the changed classifier and supplied changedFileKinds.ts definitions. The same failure affects recognized names such as requirements-dev.txt. Title inference cannot correct it because path classification returns first. Existing dependency tests use JSON manifests and lockfiles, so they do not exercise this overlap.

  • Minimum fix: Check whether all paths are dependency files before the broad documentation classification, and add a regression covering requirements.txt and a recognized requirements filename variant.

Suggestions

These are optional follow-ups and are not sent to /fix.

S2: 🟢 Exercise successful summary selection

The new integration test in test/commitSubjectGeneration.test.ts returns the same plain-text reply for both model calls. The summary-selection call therefore receives invalid JSON and exercises its fallback. Optionally return valid selection JSON first and an imperative subject second, then assert that subject generation receives the selected summary. This would complement the existing fallback coverage.

Score

The implementation largely fulfills the visible objective, but a deterministic classification error needs correction. Coverage is substantial; the supplied current-head checks have no failures and six remain pending.

Score: 6/10


🤖 Review Details

  • Model: GPT-6 Astra
  • Time: 59s
  • Tokens: 58,210 (57,276 in / 934 out)
  • Cost: $0.49

View Task


💡 Next step: Comment /fix to address every F# merge blocker, /fix all for every pending blocker and suggestion, or name records explicitly, as in /fix F3 S5.
F# and S# IDs increment across review comments and remain permanent, so selectors such as /fix F3 F5 stay unambiguous across cycles. S# suggestions stay optional: they are implemented only when you name them or request /fix all, and they never relax a merge blocker.

Copy and edit to choose records from this review:

/fix F3 S2

🤖 Review by ProPR

@propr-dev

propr-dev Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ Applied the requested follow-up changes in commit 59dabe4

Addressed 1 AI review comment (IDs: 7045773796)

Addressed finding F3

Summary of Changes

I fixed F3: a commit that changes only requirements.txt now gets the build type instead of docs.

The fix (packages/shared/src/commitSubject.ts): the docs check accepts every .txt file, so it was claiming dependency manifests before the dependency check ran. A new helper, isDocsChangeFile, counts a file as documentation only if it is not a dependency file. pathClass now checks "all dependency files → build" before the docs check.

The same mistake in other places:

  • Docs plus tests: the rule that types a mix of test and doc files as test used the same docs check, so test/test_api.py + requirements-dev.txt came out as test. It now uses the new helper, and that mix falls through to the title wording.
  • Manifests under docs/: any path under docs/ counts as documentation, so docs/package.json and docs/requirements.txt were typed docs. They now get build.
  • Mixes like README.md + requirements.txt used to be typed docs; now the type comes from the title.

New tests (packages/shared/test/commitSubject.test.ts):

  • requirements.txt alone, and with requirements-dev.txt, gives build.
  • docs/requirements.txt and docs/package.json + docs/package-lock.json give build.
  • A dependency-upgrade title on requirements.txt gives build.
  • README.md + requirements-dev.txt and a test file + requirements-dev.txt take the type from the title (feat).
  • A plain notes.txt is still docs.

Test results:

  • The shared commitSubject suite passes (14 of 14). Run against the old classifier, both new tests fail, so they do catch the bug.
  • The shared package typecheck is clean.
  • The related root suites (commitSubjectGeneration, runSummarySelection) pass (44 of 44).
  • ESLint skips packages/shared, so there was no lint gate to run on these files.

Nothing visible changed, so there are no previews.

Review digest

Risk-tiered paths

  • High risk: none
  • Normal risk (1 file)
    • packages/shared/src/commitSubject.ts (+8/−3)
  • Low risk (1 file)
    • packages/shared/test/commitSubject.test.ts (+11/−0)

Diff size: 2 files changed, +19/−3 lines


🤖 Implementation Details

  • Model: Claude Opus 5.5 (medium)
  • Requested By: @propr-ultrafix
  • Time: 3m 53s
  • Tokens: 462,791 (459,228 in / 3,563 out)
  • Cost: $0.36

View Task Execution


💡 ProPR Slash Commands
Command Description Example
/merge Merge target branch into this PR and resolve conflicts /merge
/review Request an AI code review /review or /review claude-sonnet
/fix Address review blockers, or blockers and suggestions with /fix all /fix, /fix all, or /fix F3 S5
/switch Change the AI model for this PR /switch claude-opus
/use Override the model for a single follow-up run /use claude-sonnet
/ultrafix Loop review→fix cycles until score goal is met /ultrafix or /ultrafix goal=8 max=10

🤖 Generated by ProPR

…ow gets the `build` type instead of `docs`.

I fixed F3: a commit that changes only `requirements.txt` now gets the `build` type instead of `docs`.

**The fix** (`packages/shared/src/commitSubject.ts`): the docs check accepts every `.txt` file, so it was claiming dependency manifests before the dependency check ran. A new helper, `isDocsChangeFile`, counts a file as documentation only if it is not a dependency file. `pathClass` now checks "all dependency files → `build`" before the docs check.

**The same mistake in other places:**
- **Docs plus tests:** the rule that types a mix of test and doc files as `test` used the same docs check, so `test/test_api.py` + `requirements-dev.txt` came out as `test`. It now uses the new helper, and that mix falls through to the title wording.
- **Manifests under `docs/`:** any path under `docs/` counts as documentation, so `docs/package.json` and `docs/requirements.txt` were typed `docs`. They now get `build`.
- Mixes like `README.md` + `requirements.txt` used to be typed `docs`; now the type comes from the title.

**New tests** (`packages/shared/test/commitSubject.test.ts`):
- `requirements.txt` alone, and with `requirements-dev.txt`, gives `build`.
- `docs/requirements.txt` and `docs/package.json` + `docs/package-lock.json` give `build`.
- A dependency-upgrade title on `requirements.txt` gives `build`.
- `README.md` + `requirements-dev.txt` and a test file + `requirements-dev.txt` take the type from the title (`feat`).
- A plain `notes.txt` is still `docs`.

**Test results:**
- The shared `commitSubject` suite passes (14 of 14). Run against the old classifier, both new tests fail, so they do catch the bug.
- The shared package typecheck is clean.
- The related root suites (`commitSubjectGeneration`, `runSummarySelection`) pass (44 of 44).
- ESLint skips `packages/shared`, so there was no lint gate to run on these files.

Nothing visible changed, so there are no previews.

PR: #3749
Comment by: @propr-ultrafix (ID: 0)
Model: Claude Opus 5.5
@propr-dev

propr-dev Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ AI Code Review Complete requested by @propr-ultrafix

Posted 1 review:

View Task Details

@propr-dev

propr-dev Bot commented Nov 20, 2026

Copy link
Copy Markdown
Contributor Author

🔍 AI Code Review — codex:gpt-6-astra

Overall Evaluation

The PR separates commit-subject generation from run summaries, centralizes formatting and type inference, and updates epic squash subjects. The implementation appears merge-ready within the visible scope, conditional on pending checks completing successfully.

✅ Separate subject generation — Issue runs and PR follow-ups request a dedicated subject, with title-based fallback when generation fails.

✅ Consistent formatting — Shared helpers cap subjects, infer conventional types, and append agent trailers while retaining summary bodies.

✅ Runtime-path consistency — Staging and changed-path classification share the same exclusions for generated ProPR files.

This was a static review of the supplied code; no commands were run. The issue specification is explicitly truncated, so requirements beyond its visible text could not be assessed. Current checks show no failures and five pending checks.

Merge blockers

No merge blockers.

Suggestions

These are optional follow-ups and are not sent to /fix.

S3: 🟢 Test successful summary selection integration

In test/commitSubjectGeneration.test.ts, the integration test returns the subject text for both model calls, causing summary selection to use its malformed-response fallback. Add a separate case with multiple summary candidates, a valid selection response, and a distinct subject response. This would verify that generation receives the selected summary and publication retains it in the body. The supplied control flow supports this behavior; the additional test is optional coverage.

Score

The visible implementation addresses the objective coherently and includes substantial focused coverage, with no verified merge blockers. Pending checks and the truncated issue specification limit confidence in final acceptance.

Score: 8/10


🤖 Review Details

  • Model: GPT-6 Astra
  • Time: 31s
  • Tokens: 57,945 (57,168 in / 777 out)
  • Cost: $0.50

View Task


💡 Next step: Comment /fix to address every F# merge blocker, /fix all for every pending blocker and suggestion, or name records explicitly, as in /fix F3 S5.
F# and S# IDs increment across review comments and remain permanent, so selectors such as /fix F3 F5 stay unambiguous across cycles. S# suggestions stay optional: they are implemented only when you name them or request /fix all, and they never relax a merge blocker.

Copy and edit to choose records from this review:

/fix S3

🤖 Review by ProPR

@propr-dev propr-dev Bot removed the ultrafix label Nov 20, 2026
@propr-dev propr-dev Bot changed the title 🔨 [3736 by Claude Opus 5.5] Commit subjects: a short imperative line generated separately from the run summary ✅❽ [3736 by Claude Opus 5.5] Commit subjects: a short imperative line generated separately from the run summary Nov 20, 2026
@integry
integry merged commit 9ad0d25 into main Nov 20, 2026
47 checks passed
@propr-dev propr-dev Bot changed the title ✅❽ [3736 by Claude Opus 5.5] Commit subjects: a short imperative line generated separately from the run summary [3736 by Claude Opus 5.5] Commit subjects: a short imperative line generated separately from the run summary Nov 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Commit subjects: a short imperative line generated separately from the run summary

2 participants