haac-aikit 0.8.0 → 0.8.3

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/README.md CHANGED
@@ -4,9 +4,7 @@
4
4
  [![GitHub](https://img.shields.io/badge/github-Hamad--Center%2Fhaac--aikit-blue?logo=github)](https://github.com/Hamad-Center/haac-aikit)
5
5
  [![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](LICENSE)
6
6
 
7
- A CLI that drops a working AI-coding setup into any repo — rules, skills, safety hooks, subagents, MCP stub, CI templates — and then helps you figure out which of those rules are actually doing anything.
8
-
9
- Works with Claude Code, Cursor, GitHub Copilot, Windsurf, Aider, Gemini CLI, and OpenAI Codex CLI.
7
+ One command drops a working AI-coding setup into any repo — rules, skills, safety hooks, subagents, MCP stub, CI templates — for Claude Code, Cursor, Copilot, Windsurf, Aider, Gemini CLI, and Codex.
10
8
 
11
9
  ## Quickstart
12
10
 
@@ -14,7 +12,7 @@ Works with Claude Code, Cursor, GitHub Copilot, Windsurf, Aider, Gemini CLI, and
14
12
  npx haac-aikit
15
13
  ```
16
14
 
17
- The wizard takes about 30 seconds and writes a `.aikitrc.json` you can commit. Re-run later with `aikit sync`.
15
+ 30-second wizard, writes a `.aikitrc.json` you can commit. Re-run anytime with `aikit sync`.
18
16
 
19
17
  For CI or scripts:
20
18
 
@@ -22,158 +20,39 @@ For CI or scripts:
22
20
  npx haac-aikit --yes --tools=claude,cursor,copilot --preset=standard
23
21
  ```
24
22
 
25
- ## Why this exists
26
-
27
- Every AI tool now wants its own rules file: CLAUDE.md, `.cursor/rules/`, `copilot-instructions.md`, AGENTS.md. They all do roughly the same thing — tell the model how your team writes code — but you end up maintaining four copies, none of which you can tell are working.
28
-
29
- You write 30 rules and pray. The kit you cloned last quarter ships a CLAUDE.md with rules about Python even though you write Go. You never delete the dead ones because you can't tell they're dead.
30
-
31
- haac-aikit gives you the curated baseline like other kits do (skills, hooks, agents, etc.), and on top of that it adds three things no other kit ships:
32
-
33
- 1. **Observability** — telemetry hooks log which rules are loaded and violated, so `aikit doctor --rules` can tell you which to keep, strengthen, or delete.
34
- 2. **Dialect translation** — Cursor's MDC, Claude's emphasis tokens, Aider's imperative phrasing all want different things. Same canonical AGENTS.md, reformatted per tool.
35
- 3. **`aikit learn`** — mines your team's PR review comments for repeated corrections and proposes them as new rules.
36
-
37
- ## What changes after you install it
38
-
39
- **Right after `aikit init`:**
40
-
41
- - One `AGENTS.md` becomes the source of truth for every AI tool you use. You stop maintaining four copies of the same rules.
42
- - Force-pushing to `main`, committing secrets, reading `.env*` / `.ssh/` / `.aws/` files, `rm -rf` outside the project, and about a dozen other footguns are blocked at the hook level. They don't depend on the AI cooperating — the hook fires before the tool call.
43
- - 18 process skills (TDD, brainstorming, debugging, etc.) sit in `.claude/skills/` and load on demand. Always-on cost is roughly 100 tokens per skill, so your context window stays clean.
44
- - Per-PR safety: a `gitleaks` workflow ships in `.github/workflows/` so secrets caught at commit time don't slip through code review either.
45
-
46
- **After a week or two of use:**
47
-
48
- - `aikit doctor --rules` shows you which rules fire often, which fire and get violated, and which never come up. You delete the dead ones, strengthen the disputed ones, and stop guessing.
49
- - The `.aikit/events.jsonl` log accumulates a real record of every rule load and pattern violation — local, gitignored, never uploaded. If you opt into the LLM judge it also includes per-turn cited / violated verdicts.
50
-
51
- **After a month:**
52
-
53
- - `aikit learn --limit=30` mines your merged PRs for repeated review comments and proposes new rules. Patterns like "we always validate at the boundary" or "use named exports here" that used to live only in code review get codified without anyone hand-typing them.
54
- - The optional GitHub Actions workflow posts a sticky PR comment with a rule-adherence score, so regressions across releases are visible at PR-review time.
55
-
56
- **What you don't get locked into:**
57
-
58
- - AGENTS.md is portable — Cursor, Copilot, Codex, Aider, and Gemini all read it. Switching tools doesn't mean rewriting your rules.
59
- - The catalog (skills, hooks, agents) is just markdown and shell scripts under `.claude/`. Take it and walk away whenever — haac-aikit never reaches back into your repo and there's no SaaS to cancel.
60
- - All telemetry is local. The opt-in LLM judge calls the Anthropic API only with your own key, only on `Stop` events, and you can pull the env var anytime.
61
-
62
23
  ## What you get
63
24
 
64
25
  ### Minimal scope
65
26
 
66
27
  | File | Purpose |
67
28
  |---|---|
68
- | `AGENTS.md` | The canonical project rules — your edits outside the BEGIN/END markers are never touched |
69
- | `CLAUDE.md` | Five-line shim that imports `@AGENTS.md` plus a Claude-only override block |
70
- | `.cursor/rules/000-base.mdc` | Cursor MDC, dialect-translated from AGENTS.md (not a generic shim) |
71
- | `.github/copilot-instructions.md`, `GEMINI.md`, `CONVENTIONS.md`, `.windsurf/rules/project.md` | Per-tool shims |
72
- | `.mcp.json` | MCP stub with filesystem, memory, fetch — three servers, ~1k tokens of tool defs |
29
+ | `AGENTS.md` | Canonical rules — your edits outside BEGIN/END markers are never touched |
30
+ | `CLAUDE.md` | Five-line shim that imports `@AGENTS.md` |
31
+ | `.cursor/rules/000-base.mdc` | Dialect-translated MDC (not a generic copy) |
32
+ | Per-tool shims | Copilot, Gemini, Windsurf, Aider |
33
+ | `.mcp.json` | MCP stub: filesystem, memory, fetch |
73
34
  | `.claude/settings.json` | Hardened permissions: deny list for secrets and destructive commands |
74
- | `.aikitrc.json` | Versioned config so re-runs are deterministic |
75
35
 
76
- ### Standard scope (default) adds
36
+ ### Standard scope adds
77
37
 
78
- - 18 process skills, organised into Tier 1 (always-on) and Tier 2 (opt-in). Skill bodies only load when triggered, so the at-rest cost is roughly 100 tokens each.
79
- - **Agents** in `.claude/agents/`: 10 always-on (planner, reviewer, debugger, pr-describer, …) plus opt-in specialty agents (simplifier, prompt-engineer, evals-author, …) selected via the wizard.
80
- - **Conflict-aware sync**: if you've modified an installed template (e.g., `.claude/agents/reviewer.md`), `aikit sync` and `aikit update` now prompt before overwriting instead of silently replacing it.
81
- - Safety hooks that block dangerous bash, force-push to main, secret commits, and reads of sensitive files.
82
- - Observability hooks (see below).
83
- - A starter `.claude/aikit-rules.json` with regex patterns for common things like no `console.log`, no default exports, no `any`.
84
- - `docs/claude-md-reference.md` — a 2026 reference doc on Anthropic's memory features for your team.
85
- - `.claude/rules/example.md` — a starter path-scoped rule that only loads when matching files are read.
86
- - CI workflows: gitleaks, standard CI, optional `@claude` PR responder, optional rule-adherence PR comment.
38
+ - **18 process skills** in `.claude/skills/` TDD, brainstorming, debugging, git workflows, and more. Bodies load on demand, ~100 tokens at rest.
39
+ - **14 agents** in `.claude/agents/` planner, reviewer, debugger, pr-describer, and more.
40
+ - **Safety hooks** — blocks force-push to main, secret commits, `rm -rf`, reads of `.env*` / `.ssh*` / `.aws*`. Fires before the tool call, doesn't rely on the model cooperating.
41
+ - **Rule observability hooks** logs which rules load and which get violated, feeds `aikit doctor --rules`.
42
+ - **HTML design system** — `docs/aikit-html-design-system.html` ships with every standard install; use `/html` to generate rich browser-viewable artifacts instead of long markdown.
43
+ - CI workflows: gitleaks, standard CI, optional `@claude` PR responder.
87
44
 
88
45
  ### Everything scope adds
89
46
 
90
- Dev container, OTel exporter, plugin wrapper, auto-sync CI, and shape-specific agents (frontend / backend / mobile, picked based on the project shape you select in the wizard).
47
+ Dev container, OTel exporter, plugin wrapper, auto-sync CI, shape-specific agents (frontend / backend / mobile).
91
48
 
92
- ## Rule observability
49
+ ## What makes it different
93
50
 
94
- After a few Claude Code sessions:
95
-
96
- ```
97
- $ aikit doctor --rules
98
-
99
- Hot rules (working as intended)
100
- commit.conventional-commits — 47 loads
101
- security.no-sensitive-files — 12 loads
102
-
103
- Disputed rules (>30% violation rate)
104
- code-style.no-console-log — 47 loads, 18 pattern violations
105
- Frequently violated. Strengthen with IMPORTANT/YOU MUST or move to a hook.
106
-
107
- Dead rules (never observed)
108
- legacy.bounded-contexts
109
- Never loaded, cited, or violated. Consider removing or rephrasing.
110
- ```
111
-
112
- This comes from three small hooks shipped at standard scope:
113
-
114
- - **`log-rule-event.sh`** runs on `InstructionsLoaded`. It scans loaded files for `<!-- id: code-style.no-any -->` markers and writes one event per rule per session.
115
- - **`check-pattern-violations.sh`** runs on `PostToolUse` for Edit/Write. It reads `.claude/aikit-rules.json` and flags any pattern matches in the file Claude just wrote.
116
- - **`judge-rule-compliance.sh`** runs on `Stop`. It's opt-in. If you set `AIKIT_JUDGE=1` and `ANTHROPIC_API_KEY`, it asks Claude Haiku to verdict whether each loaded rule was cited or violated this turn (~$0.001/turn). Without both env vars it returns immediately and does nothing.
117
-
118
- All three hooks append to `.aikit/events.jsonl`, which `sync` adds to `.gitignore`. Nothing leaves your machine unless you opt in to the judge.
119
-
120
- `aikit report` formats the same data as Markdown (PR-comment ready) or JSON (`--format=json`, for CI). Without judge data, the adherence score is `null` with `basis: "no-evidence"` rather than a fake number derived from load counts.
121
-
122
- ### Adding observability to your own rules
123
-
124
- In any rule file, add a stable HTML-comment ID:
125
-
126
- ```markdown
127
- - <!-- id: code-style.no-any emphasis=high paths=src/**/*.ts --> Use `unknown` and type guards, not `any`.
128
- ```
51
+ **Rule observability.** Telemetry hooks tell you which rules fire, which get violated, and which are dead weight. `aikit doctor --rules` shows the buckets; `aikit report` formats them for a PR comment. [docs/observability.md](docs/observability.md)
129
52
 
130
- The `id` is required for telemetry. `emphasis` and `paths` are optional metadata read by the dialect translators. HTML comments cost zero context tokens Claude strips them before injection so this is free observability.
53
+ **Dialect translation.** One canonical `AGENTS.md`, reformatted per tool proper MDC frontmatter for Cursor, emphasis tokens for Claude, imperative phrasing for Aider. You stop maintaining four copies of the same rules. [docs/dialects.md](docs/dialects.md)
131
54
 
132
- ## Dialect translation
133
-
134
- Other multi-tool kits copy the same content into every per-tool file. haac-aikit reformats per dialect.
135
-
136
- For Cursor that means: `.cursor/rules/000-base.mdc` gets proper MDC frontmatter, **bold** emphasis on rules tagged `emphasis=high`, and a paths hint surfaced inline. Rule IDs are preserved so the observability hooks see them load alongside AGENTS.md.
137
-
138
- Claude, Aider, Copilot, and Gemini translators are the next thing on the roadmap.
139
-
140
- ## Learn from your PR history
141
-
142
- ```
143
- $ aikit learn --limit=30
144
- ```
145
-
146
- Pulls the last 30 merged PRs via `gh`, scans review and issue comments for correction phrases ("we always", "don't here", "actually let's", "nit:"), tokenises them, clusters by Jaccard similarity, and prints proposals in a paste-ready block:
147
-
148
- ```
149
- <!-- BEGIN:learned -->
150
- ## Learned conventions
151
- - <!-- id: learned.use-named-exports --> we always use named exports here, not default
152
- - <!-- id: learned.validate-input-boundary --> please validate inputs at the API boundary
153
- <!-- END:learned -->
154
- ```
155
-
156
- Review the suggestions, paste the keepers into AGENTS.md. The similarity threshold is intentionally permissive — false positives are easy to reject, missed signal is harder to recover. There are no ML dependencies; it's regex, a stopword list, and a five-line stemmer.
157
-
158
- ## Update safety
159
-
160
- haac-aikit owns content between BEGIN/END markers. Everything outside is yours.
161
-
162
- ```markdown
163
- # My Project
164
-
165
- My own notes — never touched by aikit.
166
-
167
- <!-- BEGIN:haac-aikit -->
168
- managed content
169
- <!-- END:haac-aikit -->
170
-
171
- More of my notes — also never touched.
172
- ```
173
-
174
- `aikit sync` is idempotent: running it twice produces the same files. `aikit diff` shows what would change. `aikit update` shows the diff and prompts before writing.
175
-
176
- The marker engine handles four dialects automatically (`.md` → `<!-- ... -->`, `.yml` → `# `, `.json` → `// `, shell → `# `). If a downstream user removes a marker by accident, the hook refuses to silently re-append — it errors out so you can investigate.
55
+ **Learn from your PR history.** `aikit learn --limit=30` mines merged PR review comments for repeated corrections and proposes them as new rules. No ML — just regex, a stopword list, and Jaccard similarity. → [docs/learn.md](docs/learn.md)
177
56
 
178
57
  ## Commands
179
58
 
@@ -181,7 +60,7 @@ The marker engine handles four dialects automatically (`.md` → `<!-- ... -->`,
181
60
  aikit interactive wizard
182
61
  aikit sync regenerate from .aikitrc.json (idempotent)
183
62
  aikit update pull latest templates, show diff, prompt
184
- aikit diff show drift between current state and a fresh generation
63
+ aikit diff show drift between current state and a fresh sync
185
64
  aikit add <item> add a single skill, command, agent, or hook
186
65
  aikit list show installed items + catalog availability
187
66
  aikit doctor schema, triggers, broken-link checks
@@ -191,39 +70,27 @@ aikit report --format=json same data, structured for CI
191
70
  aikit learn --limit=30 propose rules from your PR review history
192
71
  ```
193
72
 
194
- Most prompts have a `--flag` equivalent for headless use.
195
-
196
- ## Design choices, in case they help you decide
197
-
198
- - **Skills are ~100 tokens at rest.** Bodies load only when the skill is triggered. A kit with 30 always-on skill bodies eats your context window before you've started.
199
- - **AGENTS.md is canonical, CLAUDE.md is a 5-line shim that imports it.** One source of truth across all tools.
200
- - **Three MCP servers by default.** Five servers can be ~77K tokens of tool definitions. Most projects don't need a search engine *and* a database *and* a filesystem in every conversation.
201
- - **Marker-protected templates.** This was the first thing I broke in my own setup before adding the marker engine. Your edits outside the markers survive every `sync`.
202
- - **No LLM-generated content in the catalog.** Every shipped skill / hook / agent is human-curated. ETH Zurich's 2026 study on LLM-augmented context found dumps add cost without improving success rate.
203
-
204
- ## How haac-aikit compares
73
+ ## How it compares
205
74
 
206
75
  | | haac-aikit | rulesync | ruler | claudekit |
207
76
  |---|---|---|---|---|
208
- | Includes content (skills, agents, hooks) | yes | no — config manager only | no — config manager only | Claude-only |
209
- | Cross-tool | 7 tools | yes | yes | no |
210
- | Open Skills standard (agentskills.io) | yes | no | no | no |
211
- | Config file backed | `.aikitrc.json` | no | no | no |
212
- | Idempotent BEGIN/END markers | yes | no | `.bak` backups | no |
77
+ | Includes content (skills, agents, hooks) | yes | no | no | Claude-only |
78
+ | Cross-tool (7 tools) | yes | yes | yes | no |
213
79
  | Rule observability | yes | no | no | no |
214
80
  | Dialect translation | yes | no | no | no |
215
81
  | Learn from PR history | yes | no | no | no |
82
+ | Idempotent BEGIN/END markers | yes | no | `.bak` backups | no |
216
83
 
217
84
  ## Status
218
85
 
219
- This is 0.7.0. The strategy plan reserves 1.0 until at least three external teams have used the observability loop on real PRs until then, expect breaking changes between minor versions. 0.7.0 ships the tiered agent system, 8 new agents, interactive conflict resolution, and the Cursor dialect translator; Claude, Aider, Copilot, and Gemini translators are next.
86
+ 0.8.0. Holding 1.0 until at least three external teams have used the observability loop on real PRs. Until then, expect breaking changes between minor versions.
87
+
88
+ Looking for teams to try it — feedback shapes 1.0. Comment on [issue #1](https://github.com/Hamad-Center/haac-aikit/issues/1).
220
89
 
221
90
  ## Contributing
222
91
 
223
92
  Issues and PRs welcome at [github.com/Hamad-Center/haac-aikit](https://github.com/Hamad-Center/haac-aikit).
224
93
 
225
- I'm looking for **three teams** to try the observability loop on a real codebase. Your feedback shapes 1.0. Comment on [issue #1](https://github.com/Hamad-Center/haac-aikit/issues/1) if you're up for it.
226
-
227
94
  ## License
228
95
 
229
- MIT. See [ATTRIBUTIONS.md](ATTRIBUTIONS.md) for the list of adapted sources.
96
+ MIT. See [ATTRIBUTIONS.md](ATTRIBUTIONS.md).
@@ -10,17 +10,20 @@ Generate an HTML artifact for the current context using the html-artifacts skill
10
10
  - If called with no args: infer intent from the current conversation — what task is in progress, what was just discussed, what files are open.
11
11
 
12
12
  2. **Pick the use-case pattern**
13
- Using the `html-artifacts` skill, identify which of the five patterns fits:
14
- Spec/Planning, Code Review, Report/Research, Prototype, or Custom Editor.
13
+ Using the `html-artifacts` skill, identify which of the eight patterns fits:
14
+ Spec/Planning, Code Review, Report/Research, Prototype, Custom Editor, Visual Explainer, Deck, or Design System.
15
15
 
16
16
  3. **Generate the artifact**
17
17
  - Apply the built-in design system CSS tokens
18
18
  - If `docs/aikit-html-design-system.html` exists in the project, read it first and inherit its CSS variable values
19
19
  - Follow the structure guidance for the chosen pattern
20
20
  - Pure HTML/CSS/JS only — no external CDN dependencies
21
+ - Include in `<head>`: `<title>`, `<meta name="description" content="...">`, and `<meta name="aikit-pattern" content="...">` (the pattern name from step 2) — required for the index
21
22
 
22
23
  4. **Save and report**
23
24
  - Determine a short slug from the intent (e.g. `code-review-auth-pr`, `weekly-report`)
24
- - Save to `.aikit/artifacts/<slug>-<timestamp>.html`
25
- - Print the full path
26
- - Suggest opening: `open <path>` (macOS) / `xdg-open <path>` (Linux)
25
+ - Determine `NN` by listing existing files in `.aikit/artifacts/` (excluding `index.html`) and incrementing the highest number; start at `01`
26
+ - Save to `.aikit/artifacts/NN-<slug>.html` (e.g. `07-code-review-auth-pr.html`)
27
+ - Regenerate `.aikit/artifacts/index.html` per the "Index page (gallery)" section of the `html-artifacts` skill
28
+ - Print both paths
29
+ - Suggest opening: `open .aikit/artifacts/index.html` (macOS) / `xdg-open .aikit/artifacts/index.html` (Linux)
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: html-artifacts
3
- description: Use when generating output that would benefit from rich formatting — specs, plans, reports, code review explainers, design prototypes, or custom editors. Teaches when to proactively offer HTML instead of markdown and how to structure each artifact type.
4
- version: "1.0.0"
3
+ description: Use when generating output that would benefit from rich formatting — specs, plans, reports, code review explainers, prototypes, decks, design-system pages, visual explainers, or custom editors. Maintains a gallery index at .aikit/artifacts/index.html so artifacts compound into a navigable project archive. Inspired by Thariq Shihipar's "Unreasonable Effectiveness of HTML" (Anthropic, 2026).
4
+ version: "1.1.0"
5
5
  source: haac-aikit
6
6
  license: MIT
7
7
  ---
@@ -19,7 +19,7 @@ When conditions above are met but the user didn't explicitly ask for HTML, say o
19
19
 
20
20
  Wait for a yes/no. If yes, proceed with HTML. If no, use markdown.
21
21
 
22
- ## Five use-case patterns
22
+ ## Use-case patterns
23
23
 
24
24
  ### 1. Spec / Planning
25
25
  **Trigger:** Long spec, multiple options to compare
@@ -46,6 +46,21 @@ Wait for a yes/no. If yes, proceed with HTML. If no, use markdown.
46
46
  **Structure:** Drag/sort or form UI, constraint warnings, "copy as JSON/prompt" export button
47
47
  **Don't:** Let the editor be the only output — always export
48
48
 
49
+ ### 6. Visual Explainer
50
+ **Trigger:** Explaining a concept, system, or workflow where a diagram beats prose
51
+ **Structure:** One hero inline `<svg>` with labelled regions, short text blocks anchored to those regions, "view source" toggle that reveals the underlying data
52
+ **Don't:** Use raster images or external icon CDNs — keep SVG inline so the artifact stays self-contained and editable
53
+
54
+ ### 7. Deck
55
+ **Trigger:** Slide presentation, talk preview, pitch, "walk me through this"
56
+ **Structure:** One slide per viewport (`100vh`), large body type (≥32px), arrow-key navigation, single idea per slide, speaker notes hidden behind a key press
57
+ **Don't:** Generate scrolling content — if the user would scroll, it's a Report, not a Deck
58
+
59
+ ### 8. Design System
60
+ **Trigger:** Building or documenting a design system, component library reference, token palette
61
+ **Structure:** Live component samples beside their source HTML/CSS, swatches for color/spacing/type tokens, copy-on-click for each token value
62
+ **Don't:** Use screenshots of components — the components on the page must be the real, live HTML
63
+
49
64
  ## Built-in design system
50
65
 
51
66
  Inject this CSS block into every artifact. If the project has `docs/aikit-html-design-system.html`, read it first and use those variable values instead.
@@ -71,10 +86,24 @@ Inject this CSS block into every artifact. If the project has `docs/aikit-html-d
71
86
  Pre-built components available: `.card`, `.badge` (`.badge-ok/warn/error/info`), `.tabs` + `.tab` + `.tab-panel`, `.code-block`, `.diff-block` + `.diff-line` + `.diff-line-add/del/ctx`.
72
87
 
73
88
  ## Output rules
74
- - Save to `.aikit/artifacts/<slug>-<timestamp>.html` (this path is gitignored)
75
- - After saving, print the path and suggest: `open <path>` (macOS) or `xdg-open <path>` (Linux)
76
- - Pure HTML/CSS/JS only no external CDN dependencies, no build step
77
- - Mobile-responsive: use `max-width` + `padding` on body, `<meta name="viewport">`
89
+ - Save to `.aikit/artifacts/NN-<slug>.html` where `NN` is a zero-padded sequence (`07-auth-spec.html`). This path is gitignored.
90
+ - Determine `NN` by listing existing files in `.aikit/artifacts/` (ignore `index.html`) and incrementing the highest number; start at `01`.
91
+ - Every artifact MUST include `<meta name="aikit-pattern" content="...">` in `<head>` with one of: `Spec`, `Code Review`, `Report`, `Prototype`, `Editor`, `Visual Explainer`, `Deck`, `Design System`. The index uses this to group entries.
92
+ - Every artifact MUST include `<title>` and `<meta name="description">` — the index renders these.
93
+ - Pure HTML/CSS/JS only — no external CDN dependencies, no build step.
94
+ - Mobile-responsive: use `max-width` + `padding` on body, `<meta name="viewport">`.
95
+ - After saving, also rewrite `.aikit/artifacts/index.html` (see below), then print both paths and suggest: `open .aikit/artifacts/index.html` (macOS) or `xdg-open` (Linux).
96
+
97
+ ## Index page (gallery)
98
+ The index is auto-maintained. After every artifact write, regenerate `.aikit/artifacts/index.html` from scratch — do not try to surgically edit it:
99
+
100
+ 1. List `.aikit/artifacts/*.html` excluding `index.html` itself
101
+ 2. For each file, read `<title>`, `<meta name="description">`, and `<meta name="aikit-pattern">`
102
+ 3. Group entries by pattern (Spec, Code Review, Report, Prototype, Editor, Visual Explainer, Deck, Design System)
103
+ 4. Render each group as a section with cards: filename badge, title, one-line description, link to the file
104
+ 5. Reuse the built-in design system CSS so the gallery matches the artifacts
105
+
106
+ Drop empty groups. Sort entries within a group by filename (which is by `NN`). The index itself uses `<meta name="aikit-pattern" content="Index">` so future tooling can recognize it but it is excluded from its own listing.
78
107
 
79
108
  ## Markdown-first rule
80
109
  Existing brainstorming and planning skills stay markdown-first. Only switch to HTML when the user accepts the proactive offer or explicitly requests it (e.g. via `/html`). This preserves cross-tool compatibility.
package/dist/cli.mjs CHANGED
@@ -3407,7 +3407,7 @@ FLAGS
3407
3407
  --no-color Disable ANSI colours
3408
3408
  --config=<path> Use a specific .aikitrc.json location
3409
3409
  --tools=<list> Comma-separated tool list (claude,cursor,copilot,...)
3410
- --preset=<scope> minimal | standard | everything
3410
+ --scope=<scope> minimal | standard | everything (--preset is an alias)
3411
3411
  --rules (with doctor) Show rule-observability buckets
3412
3412
  --format=<fmt> (with report / doctor --rules) markdown | json
3413
3413
  --since=<date> (with report) Restrict events to after this ISO date
@@ -3418,8 +3418,8 @@ FLAGS
3418
3418
  async function main() {
3419
3419
  const argv = lib_default(process.argv.slice(2), {
3420
3420
  boolean: ["yes", "dry-run", "force", "skip-git-check", "no-color", "help", "version", "rules"],
3421
- string: ["config", "tools", "preset", "format", "since", "limit"],
3422
- alias: { y: "yes", h: "help", v: "version" },
3421
+ string: ["config", "tools", "preset", "scope", "format", "since", "limit"],
3422
+ alias: { y: "yes", h: "help", v: "version", scope: "preset" },
3423
3423
  default: {
3424
3424
  yes: false,
3425
3425
  "dry-run": false,