Commit 8bb8aa7
authored
docs: adopt docs-governance suite + agents-tier-system + add fallow ongoing tracker (#25)
## Summary
Adds durable, project-agnostic agent infrastructure to codemap's `.agents/` tree, plus an ongoing fallow capability tracker grounded in real hands-on usage data.
Three commits, reviewable independently:
1. **`docs(research): add fallow ongoing tracker`** — `docs/research/fallow.md` complementing the dated three-tool scan from PR #23. Stays in Open state per [`docs/README.md` Rule 8](https://github.com/stainless-code/codemap/blob/main/docs/README.md).
2. **`docs(agents): add docs-governance suite + agents-tier-system + comment hygiene rules`** — 3 new skills, 3 new rules, 1 modified rule, 6 new `.cursor/` symlinks.
3. **`docs(agents): add pr-comment-fact-check rule + skill`**.
No `templates/agents/` changes — these rules and skills are for codemap maintainers only, **not pushed onto npm consumers**.
## What's new
### 4 new skills (Tier 3 — discoverable, no always-on cost)
| Skill | What it does |
| ----- | ----- |
| `docs-governance` | Repo-wide docs blueprint: 5 lifecycle types, existence test, anchor-preservation discipline, surface-tier prescriptions. Codemap-active tiers: **Tier B** (`docs/`) + **Tier 0** (`.agents/`). |
| `docs-lifecycle-sweep` | The doc janitor — walks any doc surface, classifies each file Tier A/B/C with evidence, surfaces a report for user approval, executes lift / delete / slim. |
| `audit-pr-architecture` | PR-architecture audit framework: 6-step recipe (codemap reindex → derive boundary queries from `architecture.md` → `fallow audit` → cross-check STOP signals → cross-check `architecture.md` → write audit doc). STOP-signal table calibrated for codemap's `src/cli` + `src/application` + `src/adapters` + `src/db.ts` shape. |
| `pr-comment-fact-check` | Triage and fact-check PR review comments (human or bot — Bugbot, CodeRabbit, Copilot) against the actual code, project rules, and skills. Process: pull → group → fact-check → categorize → apply/reply/resolve. Hallucination patterns grounded in `docs/roadmap.md § Non-goals`. Resolve-on-merge-gate exception trimmed to a short subsection — verified live that codemap's `main` doesn't require conversation resolution (`gh api repos/stainless-code/codemap/branches/main/protection` confirms `required_conversation_resolution.enabled: false`). |
### 4 new rules
| Rule | Tier |
| ----- | ----- |
| `agents-tier-system` | **Tier 2** (auto-attached to `.agents/**` + `.cursor/**`). Carries the durability sub-rules: no specific filenames / hashes / line numbers as canonical examples — they rot. |
| `concise-comments` | **Tier 1** (always-on, globbed to `ts/tsx/css/html/md`). Examples in "Keep" are codemap-shape (SQLite quirks, parser idiosyncrasies, oxc-resolver returning null). |
| `preserve-comments` | **Tier 1** (always-on, globbed to `ts/tsx/css/html`). Pairs with `concise-comments`. |
| `pr-comment-fact-check` | **Tier 1** (always-on, intent-triggered priming). Cross-links `docs-governance` since fact-checking comments about docs uses the same anchor-preservation discipline. |
### 1 modified rule
- `docs-governance.md` — slimmed from `alwaysApply: true` to **Tier 2** (`globs: "docs/**, .agents/**", alwaysApply: false`). Now explicitly the priming layer pointing at the new skill. Cited Rule numbers (1–9) in `docs/README.md` left untouched per the anchor-preservation discipline.
### 8 new `.cursor/` symlinks
Per [`agents-first-convention`](https://github.com/stainless-code/codemap/blob/main/.agents/rules/agents-first-convention.md): `.agents/` is source of truth, `.cursor/` is symlinks. (4 rules + 4 skills.)
## How the new pieces fit together
```text
docs/README.md ← Rules 1–9 cited from across docs/ + .agents/
│
├── doc-touching edit primes →
│ .agents/rules/docs-governance.md ← Tier 2 (auto-attached to docs/**, .agents/**)
│ │
│ └── deep reference →
│ .agents/skills/docs-governance/SKILL.md
│ ├── operationalised by →
│ │ .agents/skills/docs-lifecycle-sweep/SKILL.md
│ └── audit substrate prescriptions used by →
│ .agents/skills/audit-pr-architecture/SKILL.md
│
├── any rule/skill edit primes →
│ .agents/rules/agents-tier-system.md ← Tier 2 (auto-attached to .agents/**, .cursor/**)
│
├── any code edit primes →
│ .agents/rules/concise-comments.md ← Tier 1 (always-on, scoped via globs)
│ .agents/rules/preserve-comments.md ← Tier 1 (always-on, scoped via globs)
│
└── PR-comment intent primes →
.agents/rules/pr-comment-fact-check.md ← Tier 1 (always-on, intent-triggered)
│
└── deep reference →
.agents/skills/pr-comment-fact-check/SKILL.md
```
Plus the `docs/research/fallow.md` ongoing tracker, complementing PR #23's dated competitive scan.
## Test plan
- [x] `bun run check` passes locally (build, format:check, lint:ci, test, typecheck, test:golden — 185 tests across 18 files, 19 golden scenarios). Re-run after the third commit; still green.
- [x] All `.cursor/` symlinks resolve (`ls -la .cursor/rules/ .cursor/skills/`).
- [x] Cited Rule numbers in `docs/README.md` unchanged (`rg "Rule [0-9]+" docs/ .agents/` shows the same anchors as before).
- [x] Branch protection check verified live for `pr-comment-fact-check` skill's "merge-gate exception" subsection (codemap's `main` has `required_conversation_resolution.enabled: false`, so the default flow applies).
- [ ] Reviewer spot-checks `audit-pr-architecture` STOP-signal table (§ 4) and `pr-comment-fact-check` hallucination patterns (1–4 are codemap-thesis-shaped) since those are the most opinionated sections.
- [ ] CI green.
## No changeset
Only `.agents/`, `.cursor/`, and `docs/` touched. None of those ship to npm consumers (`package.json` `files`: `CHANGELOG.md`, `dist`, `templates`). Prior pure-docs / pure-agents commits in this repo (e.g. `f9726a9`, `8a8a791`) shipped without changesets — same precedent here.1 parent 55d9c92 commit 8bb8aa7
19 files changed
Lines changed: 1148 additions & 41 deletions
File tree
- .agents
- rules
- skills
- audit-pr-architecture
- docs-governance
- docs-lifecycle-sweep
- pr-comment-fact-check
- .cursor
- rules
- skills
- docs/research
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
3 | | - | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
4 | 5 | | |
5 | 6 | | |
6 | | - | |
| 7 | + | |
7 | 8 | | |
8 | | - | |
| 9 | + | |
9 | 10 | | |
10 | | - | |
| 11 | + | |
11 | 12 | | |
12 | | - | |
| 13 | + | |
13 | 14 | | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
23 | 19 | | |
24 | | - | |
| 20 | + | |
25 | 21 | | |
26 | | - | |
| 22 | + | |
27 | 23 | | |
28 | | - | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
29 | 31 | | |
30 | | - | |
| 32 | + | |
31 | 33 | | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
40 | 37 | | |
41 | | - | |
| 38 | + | |
42 | 39 | | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
| 40 | + | |
50 | 41 | | |
51 | | - | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
52 | 46 | | |
53 | | - | |
54 | | - | |
55 | | - | |
| 47 | + | |
56 | 48 | | |
57 | 49 | | |
58 | 50 | | |
59 | | - | |
60 | | - | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
0 commit comments