analyzthis_design 1.10.0 → 1.12.0

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
@@ -11,44 +11,67 @@ Install once. Run structured UX critiques, multi-phase ideation, and task-ground
11
11
  ## Install
12
12
 
13
13
  ```bash
14
- # Cursor (default)
14
+ # Cursor (default) + cross-agent path on postinstall
15
15
  npx analyzthis_design
16
16
 
17
- # Claude Code
17
+ # Claude Code (skills dir + legacy commands)
18
18
  npx analyzthis_design --target claude
19
19
 
20
20
  # Codex CLI
21
21
  npx analyzthis_design --target codex
22
22
 
23
- # All three at once
24
- npx analyzthis_design --target all
23
+ # Grok Build (xAI)
24
+ npx analyzthis_design --target grok
25
+
26
+ # Windsurf Cascade
27
+ npx analyzthis_design --target windsurf
28
+
29
+ # All supported hosts at once
30
+ npx analyzthis_design --target all --force
25
31
  ```
26
32
 
27
- | Tool | Skills installed to |
28
- |---|---|
29
- | Cursor | `~/.cursor/skills/` |
30
- | Claude Code | `~/.claude/commands/` |
31
- | Codex CLI | `~/.codex/skills/` |
33
+ **After install:** type `/getting-started` in Cursor or Claude Code (or `@getting-started` in Windsurf). Re-print CLI help anytime with `npx analyzthis_design welcome`.
34
+
35
+ | Tool | Skills installed to | Invoke |
36
+ |---|---|---|
37
+ | Cursor | `~/.cursor/skills/<name>/SKILL.md` | `/getting-started` |
38
+ | Claude Code | `~/.claude/skills/<name>/SKILL.md` (+ legacy `~/.claude/commands/`) | `/getting-started` |
39
+ | Codex CLI | `~/.codex/skills/<name>/SKILL.md` | skill name / AGENTS.md |
40
+ | Grok Build | `~/.grok/skills/<name>/SKILL.md` | `/collect-knowledge` |
41
+ | Windsurf Cascade | `~/.codeium/windsurf/skills/<name>/SKILL.md` | `@collect-knowledge` |
42
+ | Cross-agent | `~/.agents/skills/<name>/SKILL.md` | discovered by multiple hosts |
43
+
44
+ All skills use the **Agent Skills** `SKILL.md` standard — same files work across Cursor, Claude, Grok, Windsurf, and Codex. The CLI (`collect`, `run`, `sync`) is host-agnostic; only *where skills are discovered* differs.
32
45
 
33
46
  ---
34
47
 
35
48
  ## Skills Overview
36
49
 
37
- ### Entry points (start here)
50
+ ### Design wireframes (start here for new screens)
38
51
 
39
52
  | Command | What it does |
40
53
  |---|---|
41
- | `/persona-orchestrator` | **Recommended agentic entry point.** Loads MoE router + session state, runs ux-story-gate intake, executes the right persona chain, enforces DS / hierarchy / verify gates, synthesises a SHIP/REVISE/BLOCK verdict. |
42
- | `/ux-story-gate` | Task-first gate: discovers PRDs, DS/Figma discovery, MoE routing, browser verify, assess-only mode. |
43
- | `/design-critic` | 4-persona critique `SHIP / REVISE / BLOCK` verdict with a Composite Score out of 20 + Information Hierarchy Gate. |
44
- | `/ux-ideator` | 6-phase ideation two competing IA concepts, deliberation, delight pass, feasibility check. |
54
+ | `/getting-started` | **First-run guide** which command to use for wireframes vs critique |
55
+ | `/ux-ideator` | **Full ideation** two competing text wireframes (minimalist vs dense), deliberation, delight, feasibility |
56
+ | `/noor` | **Quick minimalist wireframe** Concept A text wireframe, progressive disclosure |
57
+ | `/anuj` | **Power-user wireframe** Concept B text wireframe, density + bulk actions |
45
58
 
46
- ### 7 Individual Personas
59
+ ### Evaluate critique (existing designs)
47
60
 
48
- Invoke directly for targeted, already-grounded questions. For full screen evaluation, prefer `/persona-orchestrator` or `/ux-story-gate`.
61
+ | Command | What it does |
62
+ |---|---|
63
+ | `/collect-knowledge` | **Kavi — Knowledge Archivist.** Scans the codebase, builds an Obsidian vault, LLM-enriches notes, syncs into the knowledge bank. Run once per project before critiques. |
64
+ | `/persona-orchestrator` | **Agentic critique entry point** (not for wireframes). MoE router + session state, ux-story-gate intake, persona chain, DS / hierarchy / verify gates → SHIP/REVISE/BLOCK |
65
+ | `/ux-story-gate` | Task-first gate: PRDs, DS/Figma discovery, MoE routing, browser verify, assess-only mode |
66
+ | `/design-critic` | 4-persona critique → Composite Score + Information Hierarchy Gate |
67
+
68
+ ### 8 Personas
69
+
70
+ Invoke critique personas for targeted, already-grounded questions. For **wireframes**, use `/ux-ideator`, `/noor`, or `/anuj`. For full screen **critique**, prefer `/persona-orchestrator` or `/ux-story-gate`. Run `/collect-knowledge` first so they have project context.
49
71
 
50
72
  | Command | Persona | What they evaluate |
51
73
  |---|---|---|
74
+ | `/collect-knowledge` | Kavi — Knowledge Archivist | Scan repo → Obsidian vault → enrich → sync knowledge bank (producer, not a critic) |
52
75
  | `/arjun` | UX + Visual Design | UX Honeycomb + Visual Design Audit (hierarchy, color, type, spacing, components, style fit, micro-interactions) |
53
76
  | `/meera` | Business Agent | Retention, ARR, GTM lever, adoption risk; hierarchy vs north-star check |
54
77
  | `/priya` | Feasibility Agent | Engineering effort (T-shirt sizing, 2-axis model), state machine traps |
@@ -62,12 +85,12 @@ Invoke directly for targeted, already-grounded questions. For full screen evalua
62
85
  | Command | Purpose |
63
86
  |---|---|
64
87
  | `/design-personas` | Session context template — fill in once before a session |
65
- | `/knowledge-bank` | Auto-populated from your connected vault. All personas read this first. |
88
+ | `/knowledge-bank` | Auto-populated from your connected vault (or from Kavi collect). All personas read this first. |
66
89
  | `/design-reference` | CSV reference data (colors, typography, UX guidelines, stacks, …) |
67
90
 
68
91
  ---
69
92
 
70
- ## Agentic system (v1.10)
93
+ ## Agentic system (v1.12)
71
94
 
72
95
  ```
73
96
  User ask / Figma URL
@@ -268,9 +291,45 @@ Writes `{ system_card, digest, user, assistant }` JSONL pairs to `~/.analyzthis_
268
291
 
269
292
  ---
270
293
 
294
+ ## Knowledge collection — Kavi (v1.11)
295
+
296
+ Kavi is a **producer** persona (not a critic). One command scans the current repo, writes an Obsidian vault, optionally enriches notes with an LLM, then auto-connects and syncs into the knowledge bank.
297
+
298
+ ```
299
+ /collect-knowledge (or npx analyzthis_design collect)
300
+
301
+ Scan codebase (gitignore-aware) → draft Obsidian notes
302
+
303
+ LLM enrich (batched; skip with --no-enrich if no API key)
304
+
305
+ ~/.analyzthis_design/vaults/{project-id}/
306
+
307
+ connect + sync → knowledge-bank skill
308
+
309
+ Arjun / Meera / … read company context first
310
+ ```
311
+
312
+ ```bash
313
+ # In your app repo (sync KB to every host):
314
+ npx analyzthis_design collect --target all
315
+ npx analyzthis_design collect --dry-run
316
+ npx analyzthis_design collect --no-enrich --limit 50
317
+ npx analyzthis_design collect --vault ~/Documents/MyProjectVault --target claude
318
+ ```
319
+
320
+ Vault folders: `PRDs/`, `Brand/`, `Product/`, `Pages/`, `Components/`, `Design/`, `Tech/`, `Research/`, `_meta/`. Notes use YAML frontmatter + `[[wikilinks]]`. Re-runs skip unchanged enriched notes via content hash.
321
+
322
+ Enrichment needs one of: `OPENAI_API_KEY`, `GEMINI_API_KEY`, `ANTHROPIC_API_KEY`, `ZAI_API_KEY`. Without a key, Kavi still writes a draft vault and syncs it.
323
+
324
+ ---
325
+
271
326
  ## Knowledge Bank — Connect your vault
272
327
 
273
328
  ```bash
329
+ # Option A — let Kavi build the vault from the codebase (recommended for new projects)
330
+ npx analyzthis_design collect
331
+
332
+ # Option B — connect an existing Obsidian vault or markdown folder
274
333
  npx analyzthis_design connect --vault ~/Documents/MyVault
275
334
  npx analyzthis_design connect --vault ~/vault --tags design,brand,prd,product
276
335
  npx analyzthis_design connect --vault ~/vault --include Design,Brand,PRDs,Research
@@ -289,13 +348,17 @@ Config: `~/.analyzthis_design/config.json`.
289
348
  ## CLI Reference
290
349
 
291
350
  ```bash
292
- # Install / remove / list
351
+ # Install / remove / list / welcome
293
352
  npx analyzthis_design
294
353
  npx analyzthis_design --target all
295
354
  npx analyzthis_design --force
355
+ npx analyzthis_design welcome [--target cursor|claude|all]
296
356
  npx analyzthis_design remove --target all
297
357
  npx analyzthis_design list --target all
298
358
 
359
+ # Knowledge collection (Kavi)
360
+ npx analyzthis_design collect [--vault path] [--dry-run] [--no-enrich] [--limit N] [--target cursor|claude|grok|windsurf|agents|all]
361
+
299
362
  # Knowledge bank
300
363
  npx analyzthis_design connect --vault <path> [--tags ...] [--include ...]
301
364
  npx analyzthis_design sync [--target all]
@@ -314,7 +377,7 @@ npx analyzthis_design research --query <text>
314
377
  npx analyzthis_design retrieve --file <csv> --column <col> --keywords a,b [--limit N]
315
378
 
316
379
  # Standalone orchestrator
317
- npx analyzthis_design run --task "..." [--figma URL] [--provider anthropic|openai] [--dry-run] [--output path]
380
+ npx analyzthis_design run --task "..." [--figma URL] [--provider anthropic|openai|google|zai] [--dry-run] [--output path]
318
381
  npx analyzthis_design run --task "..." [--lite | --full] [--experts a,b]
319
382
 
320
383
  # Efficiency / cost
@@ -334,7 +397,9 @@ bin/cli.js CLI entry point
334
397
  lib/
335
398
  install.js Skill installation
336
399
  knowledge.js Vault sync + web-context merge
337
- session.js Shared session-state.json (+ digest, metrics, accept flag)
400
+ collect.js Kavi codebase scan Obsidian vault → enrich → sync
401
+ platforms.js Cross-host skill paths (Cursor, Claude, Codex, Grok, Windsurf, agents)
402
+ session.js Shared session-state.json (+ digest, metrics, vault_path)
338
403
  research.js URL / query → web-context.md
339
404
  retrieve.js Filtered, citation-ready CSV row retrieval
340
405
  cache.js On-disk cache for retrieve/kb slices
@@ -343,7 +408,8 @@ lib/
343
408
  orchestrator/run.js Standalone LLM runtime (v2) — MoE, effort-graded tiers, caps, cache-aware
344
409
  scripts/obfuscate.js Build step → dist/
345
410
  skills/
346
- persona-orchestrator/ Agentic entry point
411
+ collect-knowledge/ Kavi Knowledge Archivist
412
+ persona-orchestrator/ Agentic critique entry point
347
413
  ux-story-gate/ Task-first gate + DS/MoE/verify/assess phases
348
414
  design-critic/ 4-persona critique + hierarchy gate
349
415
  ux-ideator/ 6-phase ideation
@@ -356,9 +422,8 @@ skills/
356
422
  ## Requirements
357
423
 
358
424
  - Node.js 16+
359
- - [Cursor](https://cursor.com) with Agent Mode (for `/skill` commands)
360
- - Claude Code or Codex CLI if using those targets
361
- - For `run` (non–dry-run): `ANTHROPIC_API_KEY` or `OPENAI_API_KEY`
425
+ - Any Agent Skills–compatible host: [Cursor](https://cursor.com), [Claude Code](https://code.claude.com), Codex CLI, [Grok Build](https://x.ai), or Windsurf Cascade
426
+ - For `run` / `collect` enrichment: `ANTHROPIC_API_KEY`, `OPENAI_API_KEY`, `GEMINI_API_KEY`, or `ZAI_API_KEY`
362
427
 
363
428
  ---
364
429
 
@@ -0,0 +1,26 @@
1
+ # Kavi — Knowledge Archivist (card)
2
+
3
+ Producer persona. Scans a codebase, builds an Obsidian vault, enriches notes into readable project knowledge, then wires that vault into the knowledge bank so every critique persona reads company context first.
4
+
5
+ **Allowed:** codebase inventory (PRDs, brand/tokens, pages, components, tech stack, research); writing Obsidian notes with YAML frontmatter + `[[wikilinks]]`; LLM enrichment of draft extracts into concise purpose + key facts; connecting and syncing the vault into `knowledge-bank`.
6
+
7
+ **Forbidden:** UX / visual / business critique (→ Arjun / Meera / etc.); inventing files, APIs, or components not present in the raw extract; design generation; code edits in the scanned repo.
8
+
9
+ ## Output schema (enrichment batches)
10
+ For each draft note, emit a full Obsidian markdown file:
11
+ 1. Keep the original YAML frontmatter; set `enriched: true`.
12
+ 2. Sections: Purpose, Key facts (bullets), Related (`[[Folder/Note]]` wikilinks only to notes that exist in the batch or were listed under Related).
13
+ 3. Do not paste large code blocks — summarize what the file does in plain language.
14
+ 4. Do not invent APIs, routes, or props that are not in the Raw extract / Exports / Imports.
15
+
16
+ ## Lite report (after collect CLI)
17
+ ```
18
+ ## Kavi — Collect report
19
+ Vault: [path]
20
+ Notes: [N written / S skipped unchanged]
21
+ Enriched: [E]
22
+ Knowledge bank: [synced count] → [targets]
23
+ Next: run /persona-orchestrator or any critique persona — they read this bank first.
24
+ ```
25
+
26
+ Consult `skills/collect-knowledge/SKILL.md` for the host workflow. Prefer running `npx analyzthis_design collect` over re-scanning files in chat.
@@ -0,0 +1,33 @@
1
+ {
2
+ "id": "kavi",
3
+ "role": "knowledge_archivist",
4
+ "system_skill": "skills/collect-knowledge/SKILL.md",
5
+ "system_card": "agents/cards/kavi.md",
6
+ "tier": "structured",
7
+ "max_output_tokens": 4000,
8
+ "parallel_safe_with": [],
9
+ "inputs": ["cwd", "optional_vault_path"],
10
+ "outputs": ["obsidian_vault", "collect_report", "knowledge_bank_sync"],
11
+ "allowed_tools": ["knowledge-bank", "filesystem_scan"],
12
+ "allowed_jobs": [
13
+ "scan codebase into Obsidian vault notes (PRDs, brand, pages, components, tech, research)",
14
+ "LLM-enrich draft extracts into concise Obsidian notes",
15
+ "auto-connect + sync vault into the knowledge bank for all critique personas"
16
+ ],
17
+ "forbidden_jobs": [
18
+ "UX, visual, business, or delight critique",
19
+ "invent files / APIs / components not in the extract",
20
+ "design generation or code edits in the scanned repo",
21
+ "run inside design-critic or ideation chains"
22
+ ],
23
+ "routing_triggers": ["collect_knowledge", "scan_codebase", "build_vault", "knowledge_archivist"],
24
+ "never_route_for": ["ux_friction", "full_screen_review", "delight", "stalemate"],
25
+ "chain_position": null,
26
+ "handoff_from": [],
27
+ "handoff_to": [],
28
+ "requires_session_state": true,
29
+ "effort_overrides": {
30
+ "standard": { "when": "enrichment batch (default)", "max_output_tokens": 4000 },
31
+ "trivial": { "when": "draft-only / --no-enrich (no LLM)", "max_output_tokens": 500 }
32
+ }
33
+ }
@@ -1,6 +1,13 @@
1
1
  {
2
2
  "description": "MoE routing table — maps a classified problem type to the expert(s) that should run, and the experts that must never run for that problem type. Used by ux-story-gate Phase 1.5 and persona-orchestrator.",
3
3
  "rules": [
4
+ {
5
+ "problem_type": "ideation_wireframe",
6
+ "signals": ["wireframe", "mockup", "new screen", "design from scratch", "layout", "ia concept", "ideation", "ux ideator", "text wireframe", "screen layout"],
7
+ "route_to": ["ideation_chain"],
8
+ "never_route_to": ["design-critic_chain", "zara"],
9
+ "notes": "Uses ideation_chain from chain.json — full text wireframes via Noor + Anuj. Never the critique lite chain."
10
+ },
4
11
  {
5
12
  "problem_type": "structure_ia",
6
13
  "signals": ["structure", "ia", "navigation", "nested_ui", "information architecture", "wizard", "form flow"],
@@ -59,6 +66,13 @@
59
66
  "route_to": ["design-critic_chain"],
60
67
  "never_route_to": ["direct_noor_without_gate"],
61
68
  "notes": "Always enter through ux-story-gate, never call /noor directly without the gate."
69
+ },
70
+ {
71
+ "problem_type": "collect_knowledge",
72
+ "signals": ["collect knowledge", "scan codebase", "build vault", "knowledge archivist", "collect-knowledge"],
73
+ "route_to": ["kavi"],
74
+ "never_route_to": ["design-critic_chain", "zara", "arjun", "meera", "priya"],
75
+ "notes": "Producer only — run /collect-knowledge or `npx analyzthis_design collect`. Never part of a critique chain."
62
76
  }
63
77
  ]
64
78
  }
@@ -39,6 +39,8 @@
39
39
  "reason": "string — why not_run, when applicable (e.g. 'assess_only, no URL')"
40
40
  },
41
41
  "mode": "assess_only | build_approved",
42
+ "vault_path": "string — Obsidian vault written by Kavi collect (empty until first collect)",
43
+ "last_collect_at": "ISO 8601 timestamp — last successful collect run",
42
44
  "digest": {
43
45
  "task_map_summary": "string — short summary passed to persona calls instead of the full task_map/persona_outputs history",
44
46
  "hierarchy_top3": ["string — top 3 ranked hierarchy items, if declared"],