Skip to content

[codex] Document agent workflow seam and trust - #1182

Merged
justin808 merged 5 commits into
mainfrom
jg-codex/agent-workflows-seam-trust
Jun 30, 2026
Merged

[codex] Document agent workflow seam and trust#1182
justin808 merged 5 commits into
mainfrom
jg-codex/agent-workflows-seam-trust

Conversation

@justin808

@justin808 justin808 commented Jun 30, 2026

Copy link
Copy Markdown
Member

Summary

  • Expands AGENTS.md into the full shared agent-workflow seam expected by the current seam doctor.
  • Keeps .agents/agent-workflow.yml as a compatibility summary while making AGENTS.md canonical.
  • Adds repo-local trusted actors for maintainers, known review automation, and trusted contributor G-Rath.

Validation

Summary by CodeRabbit

  • Documentation
    • Clarified which workflow/policy definitions are canonical and how older workflow copies are treated for compatibility.
    • Expanded the repo’s agent workflow contract with concrete setup, validation, CI/merge gate expectations, seam validation guidance, and coordination backend naming.
    • Updated related agent README to reference the canonical policy source and explain compatibility summaries.
  • Chores
    • Added a trusted GitHub actor allowlist for automation inputs, with explicit trust boundaries and exceptions.
    • Adjusted approval-exempt change categories to better cover low-risk portable items.

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 46160f02-3ad6-4af3-9a22-b08790c91a7d

📥 Commits

Reviewing files that changed from the base of the PR and between ee6deb9 and c1939db.

📒 Files selected for processing (2)
  • .agents/agent-workflow.yml
  • .agents/trusted-github-actors.yml
🚧 Files skipped from review as they are similar to previous changes (1)
  • .agents/trusted-github-actors.yml

Walkthrough

AGENTS.md becomes the canonical workflow contract with commands, validation, review gates, coordination naming, and seam checks. Compatibility references in .agents/agent-workflow.yml and .agents/bin/README.md are updated. A new trusted GitHub actors allowlist file is added.

Changes

Agent workflow configuration and trusted actors

Layer / File(s) Summary
AGENTS.md canonical workflow contract
AGENTS.md, .agents/agent-workflow.yml, .agents/bin/README.md
AGENTS.md expands into the full repo-local workflow contract, including setup, lint, test, build, merge gate, coordination, and seam validation entries. .agents/agent-workflow.yml adds a compatibility comment and updates the approval-exempt policy text, and .agents/bin/README.md points to AGENTS.md as the canonical policy source.
Trusted GitHub actors allowlist
.agents/trusted-github-actors.yml
New allowlist file defines trusted users, base bots, metadata-only bots, and trusted teams, with comments for bot identity handling and the github-actions metadata exception.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related issues

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately captures the main change: documenting the agent workflow seam and trusted actor boundaries.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch jg-codex/agent-workflows-seam-trust

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@claude

claude Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Review

This PR promotes AGENTS.md to the canonical seam for shared agent-workflow skills, expanding it from 2 bullet points to a full key-value manifest, and adds .agents/trusted-github-actors.yml to control which GitHub actors' comments can influence PR-batch automation without triage. Content in AGENTS.md is accurate against the actual .agents/bin/* scripts.

Three findings worth addressing, detailed as inline comments:

  1. Security (PLAUSIBLE)github-actions is an over-broad entry in trusted_bots: the github-actions[bot] identity is shared across all workflow runs in the org, including base-repo workflows triggered on pull_request events. A crafted PR that triggers a workflow posting a comment as github-actions[bot] would bypass the triage queue.

  2. Security (PLAUSIBLE)cursor[bot] is a globally-shared App identity, not scoped to this repo's specific installation. If Cursor is installed on the upstream repo and auto-reviews an adversarial PR, those generated comments are trusted without human triage.

  3. Correctness (PLAUSIBLE).agents/bin/setup exists and is listed in .agents/bin/README.md as one of the five standard scripts, but it has no entry in the new canonical AGENTS.md seam. A portable skill using only AGENTS.md for capability discovery would treat the dependency-install step as n/a.

One note that didn't rise to a finding: AGENTS.md and agent-workflow.yml now duplicate all policy fields with no sync mechanism. The PR description says agent-workflow.yml is kept only as a compatibility shim, but without a deprecation timeline or automated consistency check the two files will drift further.

Comment thread .agents/trusted-github-actors.yml Outdated
Comment thread .agents/trusted-github-actors.yml Outdated
Comment thread AGENTS.md
@justin808
justin808 marked this pull request as ready for review June 30, 2026 03:19
@greptile-apps

greptile-apps Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR makes AGENTS.md the canonical workflow seam. The main changes are:

  • Expanded AGENTS.md with shared agent workflow commands and policy values.
  • Kept .agents/agent-workflow.yml as a compatibility summary.
  • Updated .agents/bin/README.md to point policy readers at AGENTS.md.
  • Added a repo-local trusted GitHub actor list for automation.

Confidence Score: 4/5

The workflow seam has a contained validation-command issue and one scoped-trust policy concern.

  • The documented seam-doctor command can validate the wrong location because it omits the repo root.
  • The github-actions trust exception relies on prose rather than structured scope.
  • The command scripts and compatibility YAML otherwise match the documented workflow values.

AGENTS.md and .agents/trusted-github-actors.yml

Security Review

The new trusted actor file adds security-sensitive automation policy. The github-actions entry is only scoped by prose, so consumers that read the list uniformly can treat status metadata as trusted instruction input.

Important Files Changed

Filename Overview
AGENTS.md Expanded into the canonical workflow seam; the seam-doctor command should include the repo root argument used during validation.
.agents/agent-workflow.yml Clarifies that the YAML file is a compatibility summary without changing its existing keys.
.agents/bin/README.md Updates the policy link to AGENTS.md and documents the compatibility role of the YAML file.
.agents/trusted-github-actors.yml Adds trusted users, bots, and teams; the github-actions exception is not represented as structured scoped policy.

Reviews (1): Last reviewed commit: "Clarify agent workflow trust metadata" | Re-trigger Greptile

Comment thread AGENTS.md Outdated
Comment thread .agents/trusted-github-actors.yml Outdated
Comment thread .agents/trusted-github-actors.yml Outdated
Comment thread .agents/trusted-github-actors.yml Outdated
Comment thread AGENTS.md Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3fa7fe4fed

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .agents/trusted-github-actors.yml Outdated
Comment thread AGENTS.md Outdated
Comment thread .agents/trusted-github-actors.yml
@claude

claude Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Review: [codex] Document agent workflow seam and trust

This PR expands AGENTS.md into the canonical shared-skills seam document, adds trusted-github-actors.yml for PR-batch automation trust, and demotes .agents/agent-workflow.yml to a compatibility shim. The intent is sound, but there are a few correctness and security issues worth addressing before merging.

Security / Correctness

1. cursor entry in trusted_bots should be cursor[bot] (see inline comment on line 17)
The comment on that line explicitly says the real GitHub login is cursor[bot], but the list entry is cursor. If the consuming code has any bug in its suffix-stripping logic, a human account named cursor would receive bot-level trust.

2. Trusting github-actions creates a workflow-injection vector (see inline comment on line 22)
Any Actions workflow in the repo can post a PR comment (via gh pr comment or actions/github-script). A PR introducing a malicious pull_request_target workflow could post crafted comments that the batch agent executes. The comment saying these are treated as "metadata only" is advisory prose, not an enforced constraint.

3. trusted-github-actors.yml is unreachable from the canonical seam (see inline comment on line 13)
AGENTS.md is declared canonical, but it never references this file. A workflow skill that reads only AGENTS.md has no way to discover or apply the trust restrictions defined here.

Documentation Consistency

4. Review gate drops the (not --required) qualifier (see inline comment on AGENTS.md line 38)
agent-workflow.yml says the merge gate is gh pr checks green (not --required), clarifying that all checks must pass. AGENTS.md omits this qualifier, leaving room for a skill to interpret "green" as "required checks only."

5. Auto-merge "low-risk" is undefined (see inline comment on AGENTS.md line 40)
The approval-exempt policy delegates the low-risk classification entirely to natural-language judgment. There are no file-path globs, diff-size limits, or labels that mechanically enforce the exclusion list — a batch agent could auto-merge source-touching PRs if it judges them low-risk.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.agents/trusted-github-actors.yml:
- Around line 22-28: The trusted metadata bot allowlist is using the wrong
GitHub login strings, so update the `trusted_metadata_bots` entries in
`.agents/trusted-github-actors.yml` to match the exact actor names expected by
the repo contract. Keep the list aligned with the `trusted_metadata_bots` keys
already present, and ensure the entries are `cursor[bot]` and
`github-actions[bot]` rather than the shortened forms.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: bba9992b-3360-40b2-af7b-73e81eda06c7

📥 Commits

Reviewing files that changed from the base of the PR and between 3fa7fe4 and ee6deb9.

📒 Files selected for processing (2)
  • .agents/trusted-github-actors.yml
  • AGENTS.md
✅ Files skipped from review due to trivial changes (1)
  • AGENTS.md

Comment thread .agents/trusted-github-actors.yml Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ee6deb985d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread AGENTS.md
@justin808
justin808 merged commit 0d89881 into main Jun 30, 2026
3 checks passed
@justin808
justin808 deleted the jg-codex/agent-workflows-seam-trust branch June 30, 2026 05:11

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c1939db59c

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread AGENTS.md
- **Pre-push local validation**: `.agents/bin/validate` (runs `.agents/bin/lint`
and `.agents/bin/test`).
- **CI change detector**: `n/a`.
- **Hosted-CI trigger**: `n/a` — CI runs on every PR.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Describe the path-filtered hosted-CI trigger

With this canonical value, agents will assume no hosted trigger is needed, but the PR workflows do not actually run on every PR: the repository CI workflows are path-filtered (for example .github/workflows/node.yml:7-19, .github/workflows/ruby.yml:7-18, .github/workflows/dummy.yml:7-15, and .github/workflows/test-bundlers.yml:4-13), and the Claude review workflow skips Markdown-only changes (.github/workflows/claude-code-review.yml:4-9). A PR that only changes AGENTS.md or .agents/bin/* can therefore have no repository CI checks, leaving the shared readiness flow with no auditable trigger to request despite this seam saying CI is automatic; please replace this with the actual path-filtered/manual trigger policy.

Useful? React with 👍 / 👎.

justin808 added a commit that referenced this pull request Jul 4, 2026
## Summary

Stamps the **`v10.2.0`** release section in `CHANGELOG.md` and adds the
user-visible entries that were still missing for PRs merged since
`v10.1.0`.

Header format matches the repo convention (`## [v10.2.0] - July 3,
2026`) and is parseable by `rakelib/release.rake`'s
`extract_changelog_section` (`## [v<npm-version>]`), so `bundle exec
rake release` / `sync_github_release` will pick up the notes
automatically.

### Changelog changes

- **Version header**: inserted `## [v10.2.0] - July 3, 2026` immediately
after `## [Unreleased]`; all accumulated entries now live under it, and
`## [Unreleased]` is empty.
- **Compare links**: `[unreleased]` now compares `v10.2.0...main`; added
`[v10.2.0]: …/compare/v10.1.0...v10.2.0`.

### New entries added (were missing)

| PR | Section | Note |
| --- | --- | --- |
| [#1187](#1187) | Added |
Babel 8 peer dependency support + preset option compatibility |
| [#1184](#1184) | Added |
Folded into the #695 AI-prompt entry (gates the React on Rails section
on app detection) |
| [#1142](#1142) | Fixed |
Rspack dev-server config no longer loads in static watch mode (fixes
#1137) |

### Already documented (carried into v10.2.0)

`#1180`, `#695`, `#1141`, `#1150`, `#1179`, `#1192`, `#1127`, `#1178`,
`#1161`, `#1147`.

### Reviewed and intentionally excluded (not user-visible)

Docs: `#1145`, `#1148`, `#1152`, `#1155`, `#1183`, `#1188`, `#1189`,
`#1193`.
CI: `#1151`, `#1168`, `#1171`.
Tests / fixtures: `#1128`, `#1154`, `#1167`, `#1186`.
Workflow / agent tooling: `#1153`, `#1176`, `#1182`.

(`#1107` is already documented under `## [v10.1.0]`.)

## Next step

After merge, run the repo's release task (no args) — it reads `v10.2.0`
from the changelog and creates the GitHub release from this section.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant