Skip to content

Commit 40e4b0d

Browse files
authored
docs(agents): restore and enforce progressive disclosure (#1888)
* docs(agents): restore and enforce progressive disclosure * test(maestro): pin typed selector fallback signal * docs(agents): address progressive disclosure review * docs(agents): restore orphaned traps and close guidance-gate bypasses - AGENTS.md: skills carry a minimal start/routing card; command semantics stay in versioned CLI help (the skills contract enumerates two skills by hand, so prose retains ownership for the rest) - testing.md: restore the two local-only XCTest snags CI never hits (unsigned-bundle policy refusal signature + first-run automation permission) - scripts/gate/routing.ts: record GitHub's 300-changed-file path-filter limit at the paths-ignore assertion it bounds - agent-guidance-contract.test.ts: recurse docs/agents so nested guidance cannot evade the byte budgets while the gate stays green
1 parent dd2a18e commit 40e4b0d

22 files changed

Lines changed: 781 additions & 1840 deletions
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Agent Guidance
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- 'AGENTS.md'
7+
- 'CONTEXT.md'
8+
- 'docs/agents/**'
9+
- 'scripts/__tests__/agent-guidance-contract.test.ts'
10+
- 'scripts/check-affected/**'
11+
- 'package.json'
12+
- '.github/actions/run-gate/action.yml'
13+
- '.github/actions/setup-node-pnpm/action.yml'
14+
- '.github/workflows/agent-guidance.yml'
15+
push:
16+
branches:
17+
- main
18+
paths:
19+
- 'AGENTS.md'
20+
- 'CONTEXT.md'
21+
- 'docs/agents/**'
22+
- 'scripts/__tests__/agent-guidance-contract.test.ts'
23+
- 'scripts/check-affected/**'
24+
- 'package.json'
25+
- '.github/actions/run-gate/action.yml'
26+
- '.github/actions/setup-node-pnpm/action.yml'
27+
- '.github/workflows/agent-guidance.yml'
28+
29+
permissions:
30+
contents: read
31+
32+
jobs:
33+
contract:
34+
name: Ownership and context budgets
35+
runs-on: ubuntu-latest
36+
timeout-minutes: 5
37+
steps:
38+
- name: Checkout
39+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
40+
41+
- name: Setup Node and pnpm
42+
uses: ./.github/actions/setup-node-pnpm
43+
44+
- name: Check agent guidance
45+
uses: ./.github/actions/run-gate
46+
with: { gate: agent-guidance }

AGENTS.md

Lines changed: 142 additions & 267 deletions
Large diffs are not rendered by default.

CONTEXT.md

Lines changed: 286 additions & 636 deletions
Large diffs are not rendered by default.

docs/adr/0008-command-descriptor-registry.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,4 +95,4 @@ modules must move those contracts before their client methods can stop returning
9595
`CommandRequestResult`.
9696

9797
This ADR owns the decision and its constraints; the roadmap that prototyped it has been retired, with
98-
the delivered end-state recorded in [CONTEXT.md](../../CONTEXT.md) (Architecture).
98+
the delivered end-state enforced by the descriptor projections and parity gates below.

docs/adr/0009-apple-platform-consolidation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ Model Apple OSes with an **`AppleOS` discriminant** (`ios | ipados | tvos | watc
2929
under a single `apple` Platform — **not** six `Platform` literals. The OS-agnostic Apple engine consolidates
3030
under `src/platforms/apple/core/`, with genuinely per-OS code in `src/platforms/apple/os/<os>/` leaves;
3131
the Apple plugin is the first instance of the platform-plugin registry (the platform axis of the
32-
completed perfect-shape refactor; see [CONTEXT.md](../../CONTEXT.md) Architecture). Per-OS capability
33-
differences become data keyed by `AppleOS`. The additive,
32+
completed perfect-shape refactor; the registry and enforcement paths below are authoritative).
33+
Per-OS capability differences become data keyed by `AppleOS`. The additive,
3434
non-breaking `appleOs` discriminant — the groundwork for this — shipped in #896.
3535

3636
## Alternatives Considered

docs/agents/contract-projection-output-economy-spike.md

Lines changed: 0 additions & 198 deletions
This file was deleted.

docs/agents/domain.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Domain Docs
22

33
Single-context repo. Before architecture, diagnosis, TDD, triage, PRD, or roadmap work, read
4-
`CONTEXT.md` for domain vocabulary and the capture-reliability contract, plus the relevant ADRs in
5-
`docs/adr/`.
4+
`CONTEXT.md` for domain vocabulary and the relevant ADRs in `docs/adr/`. Selector-capture work also
5+
reads `docs/agents/selector-capture.md`.
66

77
Use `CONTEXT.md` vocabulary in issue titles, refactor proposals, test names, and architecture notes.
88
If a proposed change contradicts an ADR, say so explicitly and explain why the decision should be

0 commit comments

Comments
 (0)