@seanyao/roll 0.5.0 → 2.602.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +736 -0
- package/LICENSE +21 -0
- package/README.md +65 -165
- package/bin/dream-test-quality-scan +110 -0
- package/bin/roll +15030 -814
- package/conventions/config.yaml +17 -1
- package/conventions/global/AGENTS.md +146 -100
- package/conventions/global/CLAUDE.md +1 -21
- package/conventions/global/GEMINI.md +8 -22
- package/conventions/global/project_rules.md +9 -0
- package/conventions/templates/backend-service/AGENTS.md +30 -81
- package/conventions/templates/backend-service/GEMINI.md +3 -3
- package/conventions/templates/backend-service/project_rules.md +16 -0
- package/conventions/templates/cli/AGENTS.md +31 -58
- package/conventions/templates/cli/CLAUDE.md +3 -5
- package/conventions/templates/cli/GEMINI.md +3 -3
- package/conventions/templates/cli/project_rules.md +16 -0
- package/conventions/templates/frontend-only/AGENTS.md +29 -64
- package/conventions/templates/frontend-only/GEMINI.md +3 -3
- package/conventions/templates/frontend-only/project_rules.md +14 -0
- package/conventions/templates/fullstack/AGENTS.md +31 -79
- package/conventions/templates/fullstack/CLAUDE.md +1 -1
- package/conventions/templates/fullstack/GEMINI.md +3 -3
- package/conventions/templates/fullstack/project_rules.md +15 -0
- package/lib/README.md +42 -0
- package/lib/__pycache__/github_sync.cpython-314.pyc +0 -0
- package/lib/__pycache__/loop-fmt.cpython-314.pyc +0 -0
- package/lib/__pycache__/loop_result_eval.cpython-314.pyc +0 -0
- package/lib/__pycache__/loop_unstick.cpython-314.pyc +0 -0
- package/lib/__pycache__/model_prices.cpython-314.pyc +0 -0
- package/lib/__pycache__/prices_fetcher.cpython-314.pyc +0 -0
- package/lib/__pycache__/roll-home.cpython-314.pyc +0 -0
- package/lib/__pycache__/roll-loop-status.cpython-314.pyc +0 -0
- package/lib/__pycache__/roll_git.cpython-314.pyc +0 -0
- package/lib/__pycache__/roll_render.cpython-314.pyc +0 -0
- package/lib/__pycache__/slides-render.cpython-314.pyc +0 -0
- package/lib/agent_usage/README.md +49 -0
- package/lib/agent_usage/__init__.py +108 -0
- package/lib/agent_usage/__pycache__/__init__.cpython-314.pyc +0 -0
- package/lib/agent_usage/__pycache__/gemini.cpython-314.pyc +0 -0
- package/lib/agent_usage/__pycache__/kimi.cpython-314.pyc +0 -0
- package/lib/agent_usage/__pycache__/openai.cpython-314.pyc +0 -0
- package/lib/agent_usage/__pycache__/pi.cpython-314.pyc +0 -0
- package/lib/agent_usage/__pycache__/pi_emit.cpython-314.pyc +0 -0
- package/lib/agent_usage/__pycache__/qwen.cpython-314.pyc +0 -0
- package/lib/agent_usage/gemini.py +127 -0
- package/lib/agent_usage/kimi.py +278 -0
- package/lib/agent_usage/kimi_emit.py +123 -0
- package/lib/agent_usage/openai.py +126 -0
- package/lib/agent_usage/pi.py +200 -0
- package/lib/agent_usage/pi_emit.py +135 -0
- package/lib/agent_usage/qwen.py +128 -0
- package/lib/backfill-pi-usage.py +243 -0
- package/lib/changelog_audit.py +155 -0
- package/lib/changelog_generate.py +263 -0
- package/lib/context_feed_budget.sh +194 -0
- package/lib/github_sync.py +876 -0
- package/lib/i18n/README.md +54 -0
- package/lib/i18n/agent.sh +75 -0
- package/lib/i18n/alert.sh +20 -0
- package/lib/i18n/backlog.sh +96 -0
- package/lib/i18n/brief.sh +5 -0
- package/lib/i18n/changelog.sh +5 -0
- package/lib/i18n/ci.sh +15 -0
- package/lib/i18n/debug.sh +0 -0
- package/lib/i18n/doctor.sh +44 -0
- package/lib/i18n/dream.sh +0 -0
- package/lib/i18n/init.sh +91 -0
- package/lib/i18n/lang.sh +10 -0
- package/lib/i18n/loop.sh +140 -0
- package/lib/i18n/migrate.sh +74 -0
- package/lib/i18n/offboard.sh +31 -0
- package/lib/i18n/onboard.sh +0 -0
- package/lib/i18n/peer.sh +41 -0
- package/lib/i18n/peer_help.sh +25 -0
- package/lib/i18n/peer_reset.sh +7 -0
- package/lib/i18n/peer_status.sh +5 -0
- package/lib/i18n/prices.sh +3 -0
- package/lib/i18n/prices_refresh.sh +17 -0
- package/lib/i18n/prices_show.sh +7 -0
- package/lib/i18n/propose.sh +0 -0
- package/lib/i18n/release.sh +0 -0
- package/lib/i18n/research.sh +0 -0
- package/lib/i18n/review_pr.sh +0 -0
- package/lib/i18n/sentinel.sh +0 -0
- package/lib/i18n/setup.sh +3 -0
- package/lib/i18n/shared.sh +157 -0
- package/lib/i18n/skills/roll-brief.sh +47 -0
- package/lib/i18n/skills/roll-build.sh +97 -0
- package/lib/i18n/skills/roll-design.sh +18 -0
- package/lib/i18n/skills/roll-fix.sh +53 -0
- package/lib/i18n/skills/roll-loop.sh +28 -0
- package/lib/i18n/skills/roll-onboard.sh +33 -0
- package/lib/i18n/skills_catalog.sh +30 -0
- package/lib/i18n/slides.sh +3 -0
- package/lib/i18n/slides_build.sh +38 -0
- package/lib/i18n/slides_delete.sh +19 -0
- package/lib/i18n/slides_list.sh +14 -0
- package/lib/i18n/slides_logs.sh +12 -0
- package/lib/i18n/slides_new.sh +15 -0
- package/lib/i18n/slides_preview.sh +14 -0
- package/lib/i18n/slides_templates.sh +7 -0
- package/lib/i18n/status.sh +21 -0
- package/lib/i18n/update.sh +24 -0
- package/lib/i18n.sh +211 -0
- package/lib/loop-exit-summary.py +393 -0
- package/lib/loop-fmt.py +589 -0
- package/lib/loop_pick_agent.py +316 -0
- package/lib/loop_result_eval.py +469 -0
- package/lib/loop_unstick.py +180 -0
- package/lib/model_prices.py +194 -0
- package/lib/prices/README.md +35 -0
- package/lib/prices/snapshot-2026-05-22.json +22 -0
- package/lib/prices/snapshot-2026-05-23-deepseek.json +15 -0
- package/lib/prices/snapshot-2026-05-23-kimi.json +15 -0
- package/lib/prices_fetcher.py +285 -0
- package/lib/roll-backlog.py +225 -0
- package/lib/roll-brief.py +286 -0
- package/lib/roll-help.py +158 -0
- package/lib/roll-home.py +556 -0
- package/lib/roll-init.py +156 -0
- package/lib/roll-loop-status.py +1683 -0
- package/lib/roll-loop-story.py +191 -0
- package/lib/roll-onboard-render.py +378 -0
- package/lib/roll-peer.py +252 -0
- package/lib/roll-plan-validate.py +386 -0
- package/lib/roll-setup.py +102 -0
- package/lib/roll-status.py +367 -0
- package/lib/roll_git.py +41 -0
- package/lib/roll_render.py +414 -0
- package/lib/slides/components/README.md +123 -0
- package/lib/slides/components/cards-2.html +9 -0
- package/lib/slides/components/cards-3.html +9 -0
- package/lib/slides/components/cards-4.html +9 -0
- package/lib/slides/components/compare.html +22 -0
- package/lib/slides/components/highlight.html +9 -0
- package/lib/slides/components/pipeline.html +12 -0
- package/lib/slides/components/plain.html +7 -0
- package/lib/slides/components/quote.html +4 -0
- package/lib/slides/components/timeline.html +9 -0
- package/lib/slides/templates/introduction-v3.html +571 -0
- package/lib/slides/templates/pitch.html +0 -0
- package/lib/slides-render.py +778 -0
- package/lib/slides-validate.py +357 -0
- package/lib/test_quality_gate.py +143 -0
- package/package.json +8 -7
- package/skills/roll-.changelog/SKILL.md +406 -33
- package/skills/roll-.clarify/SKILL.md +5 -2
- package/skills/roll-.dream/SKILL.md +374 -0
- package/skills/roll-.echo/SKILL.md +5 -2
- package/skills/roll-.qa/SKILL.md +57 -3
- package/skills/roll-.review/SKILL.md +42 -3
- package/skills/roll-brief/SKILL.md +209 -0
- package/skills/roll-build/SKILL.md +308 -63
- package/skills/roll-debug/SKILL.md +341 -162
- package/skills/roll-debug/injectable-bb.js +263 -0
- package/skills/roll-deck/SKILL.md +296 -0
- package/skills/roll-design/ENGINEERING_CHECKLIST.md +1 -1
- package/skills/roll-design/SKILL.md +733 -94
- package/skills/roll-doc/SKILL.md +595 -0
- package/skills/roll-doctor/SKILL.md +192 -0
- package/skills/roll-fix/SKILL.md +149 -32
- package/skills/{roll-jot → roll-idea}/SKILL.md +18 -10
- package/skills/roll-loop/SKILL.md +579 -0
- package/skills/roll-notes/SKILL.md +103 -0
- package/skills/roll-onboard/SKILL.md +234 -0
- package/skills/roll-peer/SKILL.md +336 -0
- package/skills/roll-propose/SKILL.md +157 -0
- package/skills/roll-review-pr/SKILL.md +58 -0
- package/skills/roll-sentinel/SKILL.md +11 -2
- package/skills/roll-spar/SKILL.md +8 -6
- package/template/.github/workflows/ci.yml +5 -2
- package/template/AGENTS.md +20 -74
- package/skills/roll-research/SKILL.md +0 -307
- package/skills/roll-research/references/schema.json +0 -162
- package/skills/roll-research/scripts/md_to_pdf.py +0 -289
- package/tools/roll-fetch/SKILL.md +0 -182
- package/tools/roll-fetch/package.json +0 -15
- package/tools/roll-fetch/smart-web-fetch.js +0 -558
- package/tools/roll-probe/SKILL.md +0 -84
- /package/template/{BACKLOG.md → .roll/backlog.md} +0 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Sean YAO
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -7,195 +7,95 @@
|
|
|
7
7
|
╚═╝ ╚═╝ ╚═════╝ ╚══════╝╚══════╝
|
|
8
8
|
```
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
**[中文版 README](README_CN.md)**
|
|
11
11
|
|
|
12
|
+
[](https://seanyao.github.io/roll/)
|
|
12
13
|
[](LICENSE)
|
|
13
|
-
[](https://www.npmjs.com/package/roll)
|
|
14
|
+
[](https://www.npmjs.com/package/@seanyao/roll)
|
|
15
|
+
[](https://github.com/seanyao/roll/actions/workflows/ci.yml)
|
|
14
16
|
|
|
15
|
-
|
|
17
|
+
Roll — a CLI that lets AI agents pick up backlog items and ship them through your normal git + CI workflow. Works with Claude, Cursor, Codex, Kimi, and others.
|
|
16
18
|
|
|
17
|
-
##
|
|
19
|
+
## Install
|
|
18
20
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
1. **Convention CLI** — a single source of engineering conventions distributed to every AI client on the machine (`~/.claude/`, `~/.cursor/`, `~/.gemini/`, etc.)
|
|
24
|
-
2. **Skill System** — proven engineering practices (TDD, TCR, SRE, INVEST) encoded as instructions that any AI agent can follow
|
|
25
|
-
|
|
26
|
-
The result: any agent, any client, same constraints.
|
|
27
|
-
|
|
28
|
-
---
|
|
29
|
-
|
|
30
|
-
## Start Here
|
|
31
|
-
|
|
32
|
-
Before commands and skills, read the Engineering Methodology — it explains the three-loop architecture (Research → Build → Observe), why each skill exists, and how they connect into a complete delivery system.
|
|
33
|
-
|
|
34
|
-
**[English](docs/methodology-en.md)** · **[中文](docs/methodology.md)**
|
|
35
|
-
|
|
36
|
-
---
|
|
37
|
-
|
|
38
|
-
## Installation
|
|
21
|
+
```bash
|
|
22
|
+
curl -fsSL https://seanyao.github.io/roll/install | bash
|
|
23
|
+
```
|
|
39
24
|
|
|
40
25
|
```bash
|
|
41
26
|
npm install -g @seanyao/roll
|
|
42
|
-
roll setup
|
|
43
27
|
```
|
|
44
28
|
|
|
45
|
-
|
|
29
|
+
Requirements: bash 3.2+. npm/Node.js not required — curl install is self-contained.
|
|
46
30
|
|
|
47
|
-
|
|
31
|
+
## Use
|
|
48
32
|
|
|
49
33
|
```bash
|
|
50
|
-
|
|
34
|
+
cd your-project
|
|
35
|
+
roll init # set up Roll here
|
|
36
|
+
roll loop on # let AI work through the backlog (optional)
|
|
51
37
|
```
|
|
52
38
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
---
|
|
39
|
+
`roll init` detects legacy code and routes you to `$roll-onboard` when appropriate.
|
|
56
40
|
|
|
57
|
-
##
|
|
58
|
-
|
|
59
|
-
Unified behavioral conventions for Claude Code / Gemini CLI / Cursor / Codex — all from one source.
|
|
60
|
-
|
|
61
|
-
### Commands
|
|
41
|
+
## Commands
|
|
62
42
|
|
|
63
43
|
| Command | Description |
|
|
64
44
|
|---------|-------------|
|
|
65
|
-
|
|
|
66
|
-
| `roll
|
|
67
|
-
| `roll
|
|
68
|
-
| `roll
|
|
69
|
-
| `roll
|
|
70
|
-
| `roll
|
|
71
|
-
|
|
|
72
|
-
| `roll
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
roll
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
│ ├── AGENTS.md
|
|
111
|
-
│ ├── CLAUDE.md / GEMINI.md / .cursor-rules
|
|
112
|
-
└── templates/ # project type templates
|
|
113
|
-
├── fullstack/
|
|
114
|
-
├── frontend-only/
|
|
115
|
-
├── backend-service/
|
|
116
|
-
└── cli/
|
|
117
|
-
```
|
|
118
|
-
|
|
119
|
-
---
|
|
120
|
-
|
|
121
|
-
## Skill System
|
|
122
|
-
|
|
123
|
-
Skills are instructions that encode proven engineering practices into a form AI agents can reliably follow. They live in `~/.roll/skills/` and are symlinked into each AI client's skill directory on `roll sync`.
|
|
124
|
-
|
|
125
|
-
### Workflow
|
|
126
|
-
|
|
127
|
-
```
|
|
128
|
-
Research → Design → Build → Check → Fix → (loop)
|
|
129
|
-
```
|
|
130
|
-
|
|
131
|
-
### Quick Reference
|
|
132
|
-
|
|
133
|
-
| Scenario | Skill |
|
|
134
|
-
|----------|-------|
|
|
135
|
-
| Uncertain approach, need to think it through | `$roll-design "topic"` |
|
|
136
|
-
| Execute a planned Story | `$roll-build US-001` |
|
|
137
|
-
| Free-form feature request | `$roll-build "add search to admin"` |
|
|
138
|
-
| Bug fix | `$roll-fix FIX-001` |
|
|
139
|
-
| Fast backlog capture (bug / idea) | `$roll-jot "description"` |
|
|
140
|
-
| High-risk logic (payments, auth, state machines) | `$roll-spar "feature"` |
|
|
141
|
-
| Deep research (product / company / tech) | `$roll-research "subject"` |
|
|
142
|
-
| Patrol production for regressions | `$roll-sentinel patrol` |
|
|
143
|
-
| Debug a broken page | `$roll-debug <URL>` |
|
|
144
|
-
|
|
145
|
-
### Full Skill List
|
|
146
|
-
|
|
147
|
-
| Skill | Phase | Description |
|
|
148
|
-
|-------|-------|-------------|
|
|
149
|
-
| `$roll-build` | DESIGN+BUILD | Universal entry: Story ID, fix ID, or free-text fly mode |
|
|
150
|
-
| `$roll-design` | DESIGN | Explore approaches → design solution → write Stories to BACKLOG |
|
|
151
|
-
| `$roll-fix` | FIX | Bug fix / hotfix from BACKLOG |
|
|
152
|
-
| `$roll-jot` | Support | Fast capture a bug or idea into BACKLOG.md |
|
|
153
|
-
| `$roll-spar` | BUILD | Adversarial TDD — Attacker writes tests, Defender writes code |
|
|
154
|
-
| `$roll-sentinel` | CHECK | Scheduled production patrol |
|
|
155
|
-
| `$roll-debug` | CHECK | Deep page diagnostics + root cause analysis |
|
|
156
|
-
| `$roll-research` | RESEARCH | HV Analysis framework, outputs PDF report |
|
|
157
|
-
| `$roll-.review` | Support | Pre-commit self code review |
|
|
158
|
-
| `$roll-.qa` | Support | Test pyramid and coverage standards reference |
|
|
159
|
-
| `$roll-.changelog` | Support | Auto-generate CHANGELOG from BACKLOG |
|
|
160
|
-
| `$roll-.echo` | Support | Passive intent clarification |
|
|
161
|
-
| `$roll-.clarify` | Support | Passive scope clarification for vague build requests |
|
|
162
|
-
|
|
163
|
-
---
|
|
164
|
-
|
|
165
|
-
## Project Structure (`roll init`)
|
|
166
|
-
|
|
167
|
-
```
|
|
168
|
-
my-project/
|
|
169
|
-
├── AGENTS.md # Project constraints & skill routing
|
|
170
|
-
├── BACKLOG.md # Story and bug index
|
|
171
|
-
├── docs/features/ # Story details and specs
|
|
172
|
-
└── ... your project files
|
|
173
|
-
```
|
|
174
|
-
|
|
175
|
-
---
|
|
45
|
+
| **Autonomy · daily use** | |
|
|
46
|
+
| `roll loop <on\|off\|now\|status\|eval\|signals\|runs\|story\|monitor\|…>` | Manage the autonomous BACKLOG executor (incl. per-cycle result scoring) |
|
|
47
|
+
| `roll brief` | Show latest owner brief |
|
|
48
|
+
| `roll backlog [sync\|block\|defer\|lint\|…]` | View, manage, and sync (from GitHub Issues) pending tasks |
|
|
49
|
+
| `roll peer` | Cross-agent negotiation & review |
|
|
50
|
+
| `roll alert` | View / clear loop alerts |
|
|
51
|
+
| **Project · per repo** | |
|
|
52
|
+
| `roll init` | Set up Roll in this project |
|
|
53
|
+
| `roll status` | Show current state and drift |
|
|
54
|
+
| `roll agent [use <name>]` | Per-project agent selection |
|
|
55
|
+
| `roll ci [--wait]` | Show or wait for current commit's CI status |
|
|
56
|
+
| `roll test [--where] [--reset]` | Run the test suite (routes through isolation adapter; Tart VM on Apple Silicon) |
|
|
57
|
+
| `roll release` | Run the release script (human-only) |
|
|
58
|
+
| `roll review-pr <number>` | AI-powered code review for a PR |
|
|
59
|
+
| **Machine · global** | |
|
|
60
|
+
| `roll setup [-f]` | First-time install or re-sync conventions to all AI clients |
|
|
61
|
+
| `roll update` | Upgrade to latest + re-sync |
|
|
62
|
+
| `roll version` | Print installed roll version |
|
|
63
|
+
|
|
64
|
+
## Documentation
|
|
65
|
+
|
|
66
|
+
| Topic | English | 中文 |
|
|
67
|
+
|-------|---------|------|
|
|
68
|
+
| Overview & architecture | [guide/en/overview.md](guide/en/overview.md) | [guide/zh/overview.md](guide/zh/overview.md) |
|
|
69
|
+
| Engineering methodology | [guide/en/methodology.md](guide/en/methodology.md) | [guide/zh/methodology.md](guide/zh/methodology.md) |
|
|
70
|
+
| Loop (autonomous executor) | [guide/en/loop.md](guide/en/loop.md) | [guide/zh/loop.md](guide/zh/loop.md) |
|
|
71
|
+
| Loop data layout (Phase 2.0) | [guide/en/loop-data-layout.md](guide/en/loop-data-layout.md) | [guide/zh/loop-data-layout.md](guide/zh/loop-data-layout.md) |
|
|
72
|
+
| Dream (nightly health scan) | [guide/en/dream.md](guide/en/dream.md) | [guide/zh/dream.md](guide/zh/dream.md) |
|
|
73
|
+
| Peer (cross-agent review) | [guide/en/peer.md](guide/en/peer.md) | [guide/zh/peer.md](guide/zh/peer.md) |
|
|
74
|
+
| AI agents & complexity routing | [guide/en/ai-agents.md](guide/en/ai-agents.md) | [guide/zh/ai-agents.md](guide/zh/ai-agents.md) |
|
|
75
|
+
| Configuration (env vars) | [guide/en/configuration.md](guide/en/configuration.md) | [guide/zh/configuration.md](guide/zh/configuration.md) |
|
|
76
|
+
| Skill selection guide | [guide/en/skills.md](guide/en/skills.md) | [guide/zh/skills.md](guide/zh/skills.md) |
|
|
77
|
+
| roll-doc (legacy doc automation: four phases + Phase 3b deep read) | [guide/en/roll-doc.md](guide/en/roll-doc.md) | [guide/zh/roll-doc.md](guide/zh/roll-doc.md) |
|
|
78
|
+
| Slides (deck generator) | [guide/en/slides.md](guide/en/slides.md) | [guide/zh/slides.md](guide/zh/slides.md) |
|
|
79
|
+
| Slides — Layouts reference | [guide/en/slides.md#layouts](guide/en/slides.md#layouts) | [guide/zh/slides.md#layouts布局](guide/zh/slides.md#layouts%E5%B8%83%E5%B1%80) |
|
|
80
|
+
| Feedback (`roll feedback`) | [guide/en/feedback.md](guide/en/feedback.md) | [guide/zh/feedback.md](guide/zh/feedback.md) |
|
|
81
|
+
| Backlog GitHub sync (`roll backlog sync`) | [guide/en/backlog-github-sync.md](guide/en/backlog-github-sync.md) | [guide/zh/backlog-github-sync.md](guide/zh/backlog-github-sync.md) |
|
|
82
|
+
| Test isolation (`roll test` + Tart VM) | [guide/en/test-isolation.md](guide/en/test-isolation.md) | [guide/zh/test-isolation.md](guide/zh/test-isolation.md) |
|
|
83
|
+
| Cross-machine sync | [guide/en/loop.md#cross-machine-sync](guide/en/loop.md#cross-machine-sync) | [guide/zh/loop.md#跨机器同步](guide/zh/loop.md#%E8%B7%A8%E6%9C%BA%E5%99%A8%E5%90%8C%E6%AD%A5) |
|
|
84
|
+
| Remote monitoring (watch loop from a phone via `remote-watch`) | [guide/en/loop.md#remote-monitoring](guide/en/loop.md#remote-monitoring) | [guide/zh/loop.md#远程监控remote-monitoring](guide/zh/loop.md#%E8%BF%9C%E7%A8%8B%E7%9B%91%E6%8E%A7remote-monitoring) |
|
|
85
|
+
| Cycle result eval (`roll loop eval`) | [guide/en/loop.md#cycle-result-eval](guide/en/loop.md#cycle-result-eval) | [guide/zh/loop.md#cycle-结果评分result-eval](guide/zh/loop.md#cycle-%E7%BB%93%E6%9E%9C%E8%AF%84%E5%88%86result-eval) |
|
|
86
|
+
| Cycle exit summary (`.command` window recap) | [guide/en/loop.md#cycle-exit-summary](guide/en/loop.md#cycle-exit-summary) | [guide/zh/loop.md#cycle-退出摘要cycle-exit-summary](guide/zh/loop.md#cycle-%E9%80%80%E5%87%BA%E6%91%98%E8%A6%81cycle-exit-summary) |
|
|
87
|
+
| Pricing (cost visibility) | [guide/en/pricing.md](guide/en/pricing.md) | [guide/zh/pricing.md](guide/zh/pricing.md) |
|
|
88
|
+
| FAQ (troubleshooting) | [guide/en/faq.md](guide/en/faq.md) | [guide/zh/faq.md](guide/zh/faq.md) |
|
|
89
|
+
| Adoption patterns | [guide/en/patterns/](guide/en/patterns/) | [guide/zh/patterns/](guide/zh/patterns/) |
|
|
176
90
|
|
|
177
91
|
## Contributing
|
|
178
92
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
1. Fork the repo and create a branch from `main`
|
|
182
|
-
2. Make your changes with tests where applicable (`tests/`)
|
|
183
|
-
3. Ensure `./bin/roll --help` output is correct
|
|
184
|
-
4. Open a pull request with a clear description
|
|
185
|
-
|
|
186
|
-
For larger changes, open an issue first to discuss the approach.
|
|
187
|
-
|
|
188
|
-
---
|
|
189
|
-
|
|
190
|
-
## Acknowledgments
|
|
191
|
-
|
|
192
|
-
Roll builds on ideas and inspiration from the open-source community:
|
|
93
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md) for the development workflow, test setup, and PR conventions.
|
|
193
94
|
|
|
194
|
-
|
|
195
|
-
- **[superpowers](https://github.com/obra/superpowers)** by Jesse Vincent — A composable skills library for AI coding agents that informed several workflow patterns in Roll.
|
|
95
|
+
## Security
|
|
196
96
|
|
|
197
|
-
|
|
97
|
+
See [SECURITY.md](SECURITY.md). Please report vulnerabilities privately, not through public issues.
|
|
198
98
|
|
|
199
99
|
## License
|
|
200
100
|
|
|
201
|
-
MIT
|
|
101
|
+
[MIT](LICENSE)
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
# dream-test-quality-scan — ad-hoc helper for roll-.dream Scan 7.
|
|
3
|
+
#
|
|
4
|
+
# Walks bats files and flags ❶-class anti-patterns (hardcoded business data
|
|
5
|
+
# in assertion bodies). Emits structured REFACTOR-shaped lines so the
|
|
6
|
+
# maintainer can sanity-check the rubric against the current suite without
|
|
7
|
+
# waiting for the nightly dream cycle.
|
|
8
|
+
#
|
|
9
|
+
# Usage:
|
|
10
|
+
# dream-test-quality-scan [--category N] [--path PATH] [--max N]
|
|
11
|
+
# dream-test-quality-scan --help
|
|
12
|
+
#
|
|
13
|
+
# Only category 1 (❶ hardcoded business data) is implemented as a deterministic
|
|
14
|
+
# heuristic; categories ❷..❻ stay with the dream skill (AI agent applies the
|
|
15
|
+
# rubric). The helper exists so a smoke test and a maintainer dry-run can
|
|
16
|
+
# confirm ❶ detection keeps working as the suite evolves.
|
|
17
|
+
|
|
18
|
+
set -euo pipefail
|
|
19
|
+
|
|
20
|
+
CATEGORY=1
|
|
21
|
+
TARGET=""
|
|
22
|
+
MAX=5
|
|
23
|
+
|
|
24
|
+
usage() {
|
|
25
|
+
cat <<'EOF'
|
|
26
|
+
dream-test-quality-scan — Scan 7 ❶ dry-run helper
|
|
27
|
+
|
|
28
|
+
Usage:
|
|
29
|
+
dream-test-quality-scan [--category N] [--path PATH] [--max N]
|
|
30
|
+
dream-test-quality-scan --help
|
|
31
|
+
|
|
32
|
+
Options:
|
|
33
|
+
--category N Anti-pattern category (only 1 is implemented; default 1)
|
|
34
|
+
--path PATH File or directory to scan (default: tests/)
|
|
35
|
+
--max N Maximum entries to emit (default: 5; matches dream skill cap)
|
|
36
|
+
--help Show this message
|
|
37
|
+
|
|
38
|
+
Output:
|
|
39
|
+
One line per finding:
|
|
40
|
+
[test-quality:❶] <file>:<line> — <one-line description>
|
|
41
|
+
Exit code is 0 even when nothing is found (dry-run is informational).
|
|
42
|
+
EOF
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
while [[ $# -gt 0 ]]; do
|
|
46
|
+
case "$1" in
|
|
47
|
+
--category) CATEGORY="${2:-1}"; shift 2 ;;
|
|
48
|
+
--path) TARGET="${2:-}"; shift 2 ;;
|
|
49
|
+
--max) MAX="${2:-5}"; shift 2 ;;
|
|
50
|
+
--help|-h) usage; exit 0 ;;
|
|
51
|
+
*) echo "unknown flag: $1" >&2; usage >&2; exit 2 ;;
|
|
52
|
+
esac
|
|
53
|
+
done
|
|
54
|
+
|
|
55
|
+
if [[ "$CATEGORY" -ne 1 ]]; then
|
|
56
|
+
echo "category $CATEGORY not yet implemented — only ❶ is mechanical" >&2
|
|
57
|
+
exit 0
|
|
58
|
+
fi
|
|
59
|
+
|
|
60
|
+
# Default scan root.
|
|
61
|
+
if [[ -z "$TARGET" ]]; then
|
|
62
|
+
repo_root=$(git rev-parse --show-toplevel 2>/dev/null || pwd)
|
|
63
|
+
TARGET="${repo_root}/tests"
|
|
64
|
+
fi
|
|
65
|
+
|
|
66
|
+
if [[ ! -e "$TARGET" ]]; then
|
|
67
|
+
echo "path not found: $TARGET" >&2
|
|
68
|
+
exit 2
|
|
69
|
+
fi
|
|
70
|
+
|
|
71
|
+
scan_file() {
|
|
72
|
+
local file="$1"
|
|
73
|
+
# ❶ heuristic — assertion lines whose RHS contains a numeric literal:
|
|
74
|
+
# - lines containing `[[` or `[ ` (bats assertion syntax)
|
|
75
|
+
# - AND containing `==` or `=` (equality)
|
|
76
|
+
# - AND containing a decimal/integer literal of length ≥ 1 inside quotes
|
|
77
|
+
# Emits one entry per file (not per line) to stay under the rate cap.
|
|
78
|
+
local first_hit
|
|
79
|
+
first_hit=$(grep -nE '\[\[.*"[^"]*[0-9]+(\.[0-9]+)?[^"]*"' "$file" 2>/dev/null \
|
|
80
|
+
| head -1 || true)
|
|
81
|
+
[[ -z "$first_hit" ]] && return 1
|
|
82
|
+
|
|
83
|
+
local lineno
|
|
84
|
+
lineno=$(echo "$first_hit" | cut -d: -f1)
|
|
85
|
+
local rel
|
|
86
|
+
rel=$(python3 -c "import os,sys; print(os.path.relpath(sys.argv[1]))" "$file" 2>/dev/null || echo "$file")
|
|
87
|
+
printf '[test-quality:❶] %s:%s — assertion body hardcodes a numeric literal that likely owns its value elsewhere\n' \
|
|
88
|
+
"$rel" "$lineno"
|
|
89
|
+
return 0
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
emitted=0
|
|
93
|
+
if [[ -d "$TARGET" ]]; then
|
|
94
|
+
# Iterate over .bats files under TARGET; stop after MAX hits.
|
|
95
|
+
# Exclude vendored bats-core helpers — those are framework tests, not ours.
|
|
96
|
+
while IFS= read -r f; do
|
|
97
|
+
case "$f" in
|
|
98
|
+
*/tests/helpers/bats-*/*) continue ;;
|
|
99
|
+
esac
|
|
100
|
+
if scan_file "$f"; then
|
|
101
|
+
emitted=$((emitted + 1))
|
|
102
|
+
[[ "$emitted" -ge "$MAX" ]] && break
|
|
103
|
+
fi
|
|
104
|
+
done < <(find "$TARGET" -type f -name '*.bats' | sort)
|
|
105
|
+
else
|
|
106
|
+
scan_file "$TARGET" && emitted=1 || true
|
|
107
|
+
fi
|
|
108
|
+
|
|
109
|
+
# Always succeed — dry-run is informational, the dream cycle decides what to do.
|
|
110
|
+
exit 0
|