Skip to content

chore(contracts): absorb AGENTS.md - #36

Merged
yakimoto merged 1 commit into
mainfrom
contract-files/rollout-r
Aug 30, 2026
Merged

chore(contracts): absorb AGENTS.md#36
yakimoto merged 1 commit into
mainfrom
contract-files/rollout-r

Conversation

@yakimoto

@yakimotoyakimoto commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

contract-files rollout — batch R · AGENTS.md

Generated by governance/bin/fleet/contract-rollout.mjs (claude-workstation, contract-files-plane E5-FLEET P2) from the origin census taken 2026-08-30T22:39:13.961Z, in which this repo's default branch head was e5e5d403f872. The scaffold is contracts init from wave-av/contract-files v0.8.0 (engine cca6e3b87). Plan and receipts: governance/plans/contract-files-plane/E5-P1-ROLLOUT-PLAN.md and receipts/contract-census-2026-08-29.md in claude-workstation.

What this changes

  • Appends one fenced yaml secrets-contract block (under a ## Machine surface heading) to the EXISTING SECRETS.md. The prose inventory above it is byte-for-byte untouched — the generator asserts the new file starts with the old file's exact bytes, and the reviewer can check the diff is append-only. Names and vault locations only; the schema makes a value key unrepresentable, so a secret value cannot validate into this file.

Guarantees

  • One reversible commit. Reverting that single commit restores the repo exactly; nothing else in the tree is touched.
  • Validated before it was written.contracts init refuses to emit a file that does not pass its own schema validator, and the generator re-ran contracts validate on the result inside the clone.
  • Gates stay in observe. No hook in this repo is armed by this PR; arming is a separate, receipted decision under the E2-GATES false-positive budget.
  • Operator-confirmed merge. This PR carries SECRETS-bearing content and therefore no auto-merge label: it merges only when the operator names batch B (confirm-before-irreversible-op).

How to verify locally

npx --yes github:wave-av/contract-files contracts validate --type agents-router --repo .

Falsifiers (from the plan): a rolled repo whose gate clears with an absent or schema-invalid contract; a prose incumbent changed outside the appended block; a census that read a working tree instead of origin. Any of those reopens E5-FLEET P2 for this repo.


View with [code]smithAutofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.


Note

Low Risk
Append-only contract metadata in AGENTS.md; no application code, secrets, or armed CI gates in this change.

Overview
Appends a ## Machine surface section to AGENTS.md with a schema-valid agents-router YAML block (version: "0.1", budget_lines: 200) that indexesPERMISSIONS.md under the permissions-contract family. Existing agent prose and guidelines above the append are unchanged.

This wires the repo into the contract-files rollout so tooling can discover the permissions contract from the agent contract without editing PERMISSIONS.md itself.

Reviewed by Cursor Bugbot for commit 3624bf7. Bugbot is set up for automated code reviews on this repo. Configure here.

Summary by Sourcery

New Features:

  • Add a machine-readable agents-router contract to AGENTS.md, linking the permissions contract for automated discovery.

Review in cubic

@codeant-ai

Copy link
Copy Markdown

Your free trial PR review limit of 300 PRs has been reached. Please upgrade your plan to continue using CodeAnt AI.

@qodo-code-review

Copy link
Copy Markdown

ⓘ Qodo reviews are paused because your workspace is out of credits. Ask your workspace admin to add credits to resume reviews. Manage billing

@cursor

cursorBot commented Aug 30, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_08e8cd47-42ed-4a98-82f2-d9927006e715)

@sourcery-ai

sourcery-aiBot commented Aug 30, 2026

Copy link
Copy Markdown
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Adds an append-only, validated agents-router YAML contract to AGENTS.md, linking the repository’s permissions contract while preserving existing guidance and avoiding any gate activation.

Flow diagram for validated AGENTS.md contract rollout

flowchart LR
Existing[AGENTS.md existing guidance] --> Append[Append agents-router YAML block]
Append --> Validate[contracts validate --type agents-router --repo .]
Validate --> Preserved[AGENTS.md with permissions-contract link]
Validate --> Observe[Gates remain in observe]
Loading

File-Level Changes

ChangeDetailsFiles
Appends a schema-validated machine-readable agents-router contract to the existing agent guidance without changing the incumbent prose.
  • Adds a Machine surface section after the existing content.
  • Defines the contract version, budget-line limit, and permissions-contract index entry.
  • Preserves the prior file as an unchanged prefix, with no hooks or other files modified.
AGENTS.md

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@coderabbitai

coderabbitaiBot commented Aug 30, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: cbb565e0-c4ac-4fcc-8bee-157d76d3b5b5

📥 Commits

Reviewing files that changed from the base of the PR and between e5e5d40 and 3624bf7.

📒 Files selected for processing (1)
  • AGENTS.md

Included review availability: 0 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 1 review per hour.

📜 Recent review details
⏰ Context from checks skipped due to timeout. (2)
  • GitHub Check: semgrep-cloud-platform/scan
  • GitHub Check: semgrep-cloud-platform/scan
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: CR
Repo: wave-av/sdk-python
Timestamp: 2026-08-30T22:42:14.294Z
Learning: Run the repo's lint / typecheck / test before opening a PR, and fix what you broke.
Learnt from: CR
Repo: wave-av/sdk-python
Timestamp: 2026-08-30T22:42:14.294Z
Learning: Branch and open a PR; never push to the default branch. All required gates must pass before merge.
Learnt from: CR
Repo: wave-av/sdk-python
Timestamp: 2026-08-30T22:42:14.294Z
Learning: No secrets in commits — secret-scan is a required gate and will block.
Learnt from: CR
Repo: wave-av/sdk-python
Timestamp: 2026-08-30T22:42:14.294Z
Learning: Match the existing code conventions; keep files focused (~200-500 lines).
Learnt from: CR
Repo: wave-av/sdk-python
Timestamp: 2026-08-30T22:42:14.294Z
Learning: Report vulnerabilities via the [Security Policy](https://github.com/wave-av/.github/blob/main/SECURITY.md) (securitywave.online) — never in a public issue.
Learnt from: CR
Repo: wave-av/sdk-python
Timestamp: 2026-08-30T22:42:14.294Z
Learning: The registry is the SSOT.
Learnt from: CR
Repo: wave-av/sdk-python
Timestamp: 2026-08-30T22:42:14.294Z
Learning: Every capability ships its four renderings (API + CLI + SDK + MCP); the API is the authority.
Learnt from: CR
Repo: wave-av/sdk-python
Timestamp: 2026-08-30T22:42:14.294Z
Learning: Tests ship with the artifact in the same PR — no test, no ship; a green suite is not a live system.
🔇 Additional comments (1)
AGENTS.md (1)

53-58: 🔒 Security & Privacy

Authorization Bypass (CWE-862): Missing Authorization

Provide the agents-router consumer or integration test.

The contract defines restrictive deny and ask rules, but no repository evidence shows that agents-router discovers index[].path or enforces those rules before tool execution.


📝 Walkthrough

Summary by CodeRabbit

  • Documentation
    • Added project guidance for machine-readable surface definitions.
    • Documented the permissions contract reference and associated metadata.

Walkthrough

AGENTS.md now defines Machine surface metadata, including version 0.1, a 200-line budget, and an index entry for permissions-contract at PERMISSIONS.md.

Changes

Machine surface configuration

Layer / File(s)Summary
Add Machine surface metadata
AGENTS.md
Adds the Machine surface YAML block with version 0.1, a 200-line budget, and the permissions-contract path index.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Merge Risk:🔵 Low · up to 3624b

This change adds a machine-readable index to the existing permission rules without changing the rules themselves or granting new access. Merge is reasonable with explicit owner awareness that the index’s consumer and enforcement authority should be documented before it is relied on as an authorization control.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check nameStatusExplanation
Title check✅ PassedThe title identifies a contract-related change to AGENTS.md. It is somewhat broad but remains related to the changeset.
Description check✅ PassedThe description includes an accurate summary of the AGENTS.md contract addition, but it also contains conflicting references to SECRETS.md and a secrets contract. It is still related to the changeset.
Docstring Coverage✅ PassedNo functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check✅ PassedCheck skipped because no linked issues were found for this pull request.
Out of Scope Changes check✅ PassedCheck skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0 files. (1 skipped: 1 unsupported.)

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch contract-files/rollout-r
✨ Simplify code
  • Create PR with simplified code
  • Commit simplified code in branch contract-files/rollout-r

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

@gitar-bot

gitar-botBot commented Aug 30, 2026

Copy link
Copy Markdown

Note

Automatic reviews are paused because your team has used its included automatic processing for this billing period (headroom scales with your seat count). You can still comment "Gitar review" to run one anytime, and automatic reviews resume on their own by September 1. Add seats for more headroom.
Learn more

Code Review👍 Approved with suggestions0 resolved / 1 findings

Appends a schema-valid agents-router contract block to AGENTS.md that indexes the permissions contract for automated discovery. The PR description incorrectly references SECRETS.md instead of AGENTS.md—verify the correct template was used for this repo's batch.

💡 Quality: PR description describes a different change than the actual diff

🔗 link

The PR description states this change 'appends a fenced yaml secrets-contract block... to the EXISTING SECRETS.md' and centers its guarantees/falsifiers around SECRETS.md, but the actual diff only touches AGENTS.md with an agents-router block (SECRETS.md does not exist in this repo). This mismatch could mislead reviewers relying on the description's verification steps (e.g. checking that SECRETS.md prose is byte-for-byte untouched) since there is no SECRETS.md to check. Regenerate the PR description from the actual file touched, or confirm the correct template/target file was used for this repo's batch.

🤖 Prompt for agents
Code Review: Appends a schema-valid `agents-router` contract block to `AGENTS.md` that indexes the permissions contract for automated discovery. The PR description incorrectly references `SECRETS.md` instead of `AGENTS.md`—verify the correct template was used for this repo's batch.
1. 💡 Quality: PR description describes a different change than the actual diff
The PR description states this change 'appends a fenced yaml secrets-contract block... to the EXISTING SECRETS.md' and centers its guarantees/falsifiers around SECRETS.md, but the actual diff only touches AGENTS.md with an `agents-router` block (SECRETS.md does not exist in this repo). This mismatch could mislead reviewers relying on the description's verification steps (e.g. checking that SECRETS.md prose is byte-for-byte untouched) since there is no SECRETS.md to check. Regenerate the PR description from the actual file touched, or confirm the correct template/target file was used for this repo's batch.
Options

Display: compact → Showing less information.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose 

Was this helpful? React with 👍 / 👎 | Gitar

@sourcery-aisourcery-aiBot 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.

Hey - I've reviewed your changes and they look great!

Sourcery assessment

Approved.


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@macroscopeapp

Copy link
Copy Markdown

Approvability

Verdict: Would Approve

Macroscope's review found this PR approvable — This is a one-file, append-only governance metadata change that indexes the existing permissions contract for read-only tooling discovery. It does not modify SDK behavior, permission rules, CI gates, APIs, or production infrastructure.

Not approved because:

  • Credit balance exhausted. Approvability relies on correctness review in order to determine eligibility

Review your spending limits in Billing settings. You can add or adjust custom eligibility rules. Learn more.

@yakimoto
yakimoto merged commit 52888d4 into mainAug 30, 2026
23 checks passed
@yakimoto
yakimoto deleted the contract-files/rollout-r branch August 30, 2026 23:33
Sign up for freeto 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

@yakimoto