Skip to content

[3443 by Claude Opus 5.5] Ship an automation template catalog with an issue-triage template - #3451

Merged
integry merged 1 commit into
3443-epic-automations-no-t7ofrom
3443/claude-opus-5-5-ship-an-automation-templa-20261111-2201-h3q
Nov 11, 2026
Merged

integry merged 1 commit into
3443-epic-automations-no-t7ofrom
3443/claude-opus-5-5-ship-an-automation-templa-20261111-2201-h3q

Conversation

@propr-dev

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

Copy link
Copy Markdown
Contributor

AI Implementation Summary

Closes #3443

Branch: 3443/claude-opus-5-5-ship-an-automation-templa-20261111-2201-h3q
Commits: ✅ Changes committed (9f38480)


AI Processing Completed

Execution Details:

Summary:
I've shipped the automation template catalog with "Daily issue triage" as the first entry. It's available in the shared package, the API, MCP, the CLI and the web UI. All the tests I ran pass. Typecheck is clean, lint passes on the changed files, and the OpenAPI check is up to date.

Catalog (packages/shared)

  • Each template has a source folder, packages/shared/automation-templates/<id>/, holding template.json and prompt.md.
  • scripts/generate-automation-templates.ts builds the versioned automationTemplates.catalog.json from those folders. It runs as npm run automation-templates:generate, and npm run automation-templates:check fails if the committed catalog is out of date.
  • Every template is checked against the automation definition contract, including the schedule rules. It must also default to dry_run and list repositories, schedule and autonomy as things to review before saving.
  • The typed loader, automationTemplates.ts, re-validates the catalog when it is imported. I put the validation in a separate file so the generator can check a catalog that isn't committed yet.
  • CI runs the check through a new test, test/automationTemplatesCatalog.test.ts, added to test:unit the same way the usage-tips check runs.

Daily issue triage

  • It reads open issues, plus issues closed in the last 30 days, using the run's read-only GitHub token.
  • The report has these sections: summary, needs a human, likely duplicates, proposed severity labels, proposed security labels, and stale issues.
  • The prompt forbids changing any issue and says to treat issue text as untrusted.
  • Suggested schedule is 0 7 * * 1-5 (weekdays 07:00 UTC). It feeds the previous report into the next run so each one focuses on what changed.

Where the catalog is available

  • API: GET /api/automation-definitions/templates. I didn't add a deprecated /api/agent-definitions/... alias for it, since no old client can depend on a new route. Two existing tests assumed every route has an alias, so I updated them to allow this one exception.
  • MCP: a read-only tool, list_automation_templates.
  • CLI: propr automation templates, which prints a table or a versioned JSON document with --json.
  • Web UI:
    • The new-automation form has a "Start from a template" picker and a "Review before saving" note.
    • When there are no automations, the empty list shows the templates. Each one links to /automations/new?template=<id>, which opens the form already filled in.
    • Choosing a template keeps any repositories and coding agent the user already picked, and always sets autonomy to Dry run. Nothing is created until the user saves.

Docs: agents.md has a new Templates section. I also updated propr-cli.md, docs/mcp.md, docs/mcp-coverage.md and the CHANGELOG, and regenerated the OpenAPI spec.

Tests: new or extended tests cover catalog validation, the route, the MCP tool, the CLI command, the form prefill and the empty-state link. The MCP suite's 15 tests all pass, but the process didn't exit on its own afterwards; it stalled on a database-connection timeout during cleanup and I stopped it. That looks like a teardown problem in that suite rather than this change, but I didn't confirm it.

I captured three screenshots: the empty list with templates, the prefilled form on desktop, and the template link on a phone.

Detailed Logs:

  • Conversation: 92 messages
  • Session: 5f89f1ed-8bd1-427a-a5df-2546c0a31f23

Log files stored at:

  • conversation: /usr/src/app/logs/executions/issue-3443-2026-11-11T22-26-09-440Z-conversation.json
  • output: /usr/src/app/logs/executions/issue-3443-2026-11-11T22-26-09-440Z-output.txt
Latest Conversation Messages
ASSISTANT: [content unavailable]

ASSISTANT: I've shipped the automation template catalog with "Daily issue triage" as the first entry. It's available in the shared package, the API, MCP, the CLI and the web UI. All the tests I ran pass. Typeche...


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


💡 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!


Visual preview

Empty Automations list with templates

Empty Automations list with templates

With no automations, the empty state offers "Or start from a template" with the Daily issue triage card (1440x900).

Connect sign-in required. Original retained until 2027-02-09T22:26:13.968Z.

View the full-resolution original in ProPR Connect

New automation prefilled from Daily issue triage

New automation prefilled from Daily issue triage

After choosing the template under "Start from a template": the form is filled in, autonomy stays Dry run, and a "Review before saving" note lists repositories, schedule and autonomy. Nothing is created until Create automation.

Connect sign-in required. Original retained until 2027-02-09T22:26:15.230Z.

View the full-resolution original in ProPR Connect

Template link on a phone

Template link on a phone

/automations/new?template=daily-issue-triage at 390x844 opens the form prefilled, with the review note first.

Connect sign-in required. Original retained until 2027-02-09T22:26:16.763Z.

View the full-resolution original in ProPR Connect

…" as the first entry. It's available in the shared package, the API, MCP, the CLI and the web UI. All the tests I ran pass. Typecheck is clean, lint passes on the changed files, and the OpenAPI check is up to date.

Catalog (`packages/shared`)
- Each template has a source folder, `packages/shared/automation-templates/<id>/`, holding `template.json` and `prompt.md`.
- `scripts/generate-automation-templates.ts` builds the versioned `automationTemplates.catalog.json` from those folders. It runs as `npm run automation-templates:generate`, and `npm run automation-templates:check` fails if the committed catalog is out of date.
- Every template is checked against the automation definition contract, including the schedule rules. It must also default to `dry_run` and list repositories, schedule and autonomy as things to review before saving.
- The typed loader, `automationTemplates.ts`, re-validates the catalog when it is imported. I put the validation in a separate file so the generator can check a catalog that isn't committed yet.
- CI runs the check through a new test, `test/automationTemplatesCatalog.test.ts`, added to `test:unit` the same way the usage-tips check runs.

Daily issue triage
- It reads open issues, plus issues closed in the last 30 days, using the run's read-only GitHub token.
- The report has these sections: summary, needs a human, likely duplicates, proposed severity labels, proposed security labels, and stale issues.
- The prompt forbids changing any issue and says to treat issue text as untrusted.
- Suggested schedule is `0 7 * * 1-5` (weekdays 07:00 UTC). It feeds the previous report into the next run so each one focuses on what changed.

Where the catalog is available
- API: `GET /api/automation-definitions/templates`. I didn't add a deprecated `/api/agent-definitions/...` alias for it, since no old client can depend on a new route. Two existing tests assumed every route has an alias, so I updated them to allow this one exception.
- MCP: a read-only tool, `list_automation_templates`.
- CLI: `propr automation templates`, which prints a table or a versioned JSON document with `--json`.
- Web UI:
  - The new-automation form has a "Start from a template" picker and a "Review before saving" note.
  - When there are no automations, the empty list shows the templates. Each one links to `/automations/new?template=<id>`, which opens the form already filled in.
  - Choosing a template keeps any repositories and coding agent the user already picked, and always sets autonomy to Dry run. Nothing is created until the user saves.

Docs: `agents.md` has a new Templates section. I also updated `propr-cli.md`, `docs/mcp.md`, `docs/mcp-coverage.md` and the CHANGELOG, and regenerated the OpenAPI spec.

Tests: new or extended tests cover catalog validation, the route, the MCP tool, the CLI command, the form prefill and the empty-state link. The MCP suite's 15 tests all pass, but the process didn't exit on its own afterwards; it stalled on a database-connection timeout during cleanup and I stopped it. That looks like a teardown problem in that suite rather than this change, but I didn't confirm it.

I captured three screenshots: the empty list with templates, the prefilled form on desktop, and the template link on a phone.
@propr-dev

propr-dev Bot commented Nov 11, 2026

Copy link
Copy Markdown
Contributor Author

/ultrafix goal=8 max=10
Triggered automatically by the requested execution settings.

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

propr-dev Bot commented Nov 11, 2026

Copy link
Copy Markdown
Contributor Author

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

First action: /review

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

@propr-dev

propr-dev Bot commented Nov 11, 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 11, 2026

Copy link
Copy Markdown
Contributor Author

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

Overall Evaluation

The PR implements the template catalog across shared code, API, MCP, CLI and UI with consistent defaults and focused test coverage. It is merge-ready within the reviewed scope, conditional on the pending Validate Changes check completing successfully.

✅ Shared validation — Both generation and loading validate templates against the existing automation definition contract, including schedules and required review notes.

✅ Controlled form prefill — Applying a template preserves selected repositories, agent and extension profile, resets autonomy to dry run, and leaves persistence to the existing save action.

✅ Cross-surface coverage — Added tests cover catalog freshness, authenticated API access, MCP discovery, CLI output and UI prefill.

This assessment is based on static review of the supplied diff and context. No commands were run. The supplied current-head status reports 34 passed checks, no failures and one pending check.

Merge blockers

No merge blockers.

Suggestions

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

S1: 🟢 Clarify incomplete issue retrieval

In packages/shared/automation-templates/daily-issue-triage/prompt.md:3, the example retrieves at most 200 open issues, while subsequent sections request repository-wide counts and stale issues. Consider explicitly asking the agent to paginate or disclose incomplete coverage. This would improve report reliability for large repositories; it is optional because the command is illustrative and the prompt already requests all open issues.

S2: 🟢 Document the API response schema

The new entry in docs/static/openapi/propr-api.yaml registers the templates endpoint but leaves its successful response undocumented. Adding the versioned catalog schema would help API consumers discover the response structure. This is a documentation improvement rather than a blocker: the implementation returns the shared validated catalog, and the feature guide describes its fields.

Score

The implementation is coherent, preserves the intended save boundary and has relevant coverage across its exposed surfaces. Static review found no demonstrated merge blocker; final readiness remains conditional on the pending check.

Score: 9/10


🤖 Review Details

  • Model: GPT-6 Astra
  • Time: 38s
  • Tokens: 64,290 (63,712 in / 578 out)
  • Cost: $0.56

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 S1 S2

🤖 Review by ProPR

@propr-dev propr-dev Bot removed the ultrafix label Nov 11, 2026
@integry
integry merged commit 7c1fa14 into 3443-epic-automations-no-t7o Nov 11, 2026
72 checks passed
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.

1 participant