codymaster 4.6.0 → 4.8.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.
Files changed (127) hide show
  1. package/CHANGELOG.md +19 -1
  2. package/README.md +80 -30
  3. package/dist/browse-server.js +251 -0
  4. package/dist/cli/command-registry.js +26 -0
  5. package/dist/cli/commands/agent.js +120 -0
  6. package/dist/cli/commands/dashboard.js +93 -0
  7. package/dist/cli/commands/design-studio.js +111 -0
  8. package/dist/cli/commands/distro.js +25 -0
  9. package/dist/cli/commands/engineering.js +488 -0
  10. package/dist/cli/commands/project.js +324 -0
  11. package/dist/cli/commands/skill-chain.js +269 -0
  12. package/dist/cli/commands/system.js +89 -0
  13. package/dist/cli/commands/task.js +254 -0
  14. package/dist/cli/update-check.js +83 -0
  15. package/dist/cm-config.js +110 -0
  16. package/dist/cm-suggest.js +77 -0
  17. package/dist/distro-validate.js +54 -0
  18. package/dist/guardian-core.js +74 -0
  19. package/dist/index.js +36 -2759
  20. package/dist/mcp-context-server.js +60 -1
  21. package/dist/mcp-skills-tools.js +81 -0
  22. package/dist/retro-summary.js +70 -0
  23. package/dist/second-opinion-providers.js +79 -0
  24. package/dist/sprint-pipeline.js +228 -0
  25. package/dist/storage-backend.js +5 -60
  26. package/dist/utils/cli-utils.js +76 -0
  27. package/dist/utils/skill-utils.js +32 -0
  28. package/install.sh +274 -50
  29. package/package.json +16 -5
  30. package/scripts/build-skills.mjs +51 -0
  31. package/scripts/gate-0-repo-hygiene.js +75 -0
  32. package/scripts/postinstall.js +55 -0
  33. package/scripts/security-scan.js +1 -1
  34. package/scripts/validate-skills.mjs +42 -0
  35. package/scripts/viking-demo.ts +105 -0
  36. package/skills/CLAUDE.md +2 -2
  37. package/skills/cm-ads-tracker/SKILL.md +3 -6
  38. package/skills/cm-browse/SKILL.md +28 -0
  39. package/skills/cm-conductor-worktrees/SKILL.md +24 -0
  40. package/skills/cm-content-factory/SKILL.md +1 -1
  41. package/skills/cm-content-factory/landing/docs/content/changelog.md +36 -0
  42. package/skills/cm-content-factory/landing/docs/content/deployment.md +46 -0
  43. package/skills/cm-content-factory/landing/docs/content/execution-flow.md +67 -0
  44. package/skills/cm-content-factory/landing/docs/content/openspace.md +27 -0
  45. package/skills/cm-content-factory/landing/docs/content/openviking.md +33 -0
  46. package/skills/cm-content-factory/landing/docs/content/use-cases.md +26 -0
  47. package/skills/cm-content-factory/landing/docs/content/v5-intro.md +28 -0
  48. package/skills/cm-content-factory/landing/docs/index.html +240 -0
  49. package/skills/cm-content-factory/landing/index.html +99 -99
  50. package/skills/cm-content-factory/landing/script.js +42 -0
  51. package/skills/cm-content-factory/landing/translations.js +400 -400
  52. package/skills/cm-design-studio/SKILL.md +30 -0
  53. package/skills/cm-ecosystem-roadmap/SKILL.md +11 -0
  54. package/skills/cm-engineering-meta/SKILL.md +69 -0
  55. package/skills/cm-growth-hacking/SKILL.md +1 -12
  56. package/skills/cm-guardian-runtime/SKILL.md +22 -0
  57. package/skills/cm-mcp-engineering/SKILL.md +18 -0
  58. package/skills/cm-notebooklm/SKILL.md +1 -17
  59. package/skills/cm-post-deploy-canary/SKILL.md +18 -0
  60. package/skills/cm-qa-visual-cli/SKILL.md +18 -0
  61. package/skills/cm-retro-cli/SKILL.md +19 -0
  62. package/skills/cm-second-opinion-cli/SKILL.md +19 -0
  63. package/skills/cm-secret-shield/SKILL.md +2 -2
  64. package/skills/cm-sprint-bus/SKILL.md +29 -0
  65. package/skills/cm-tdd/SKILL.md +61 -74
  66. package/skills/profiles/README.md +21 -0
  67. package/skills/profiles/core.txt +23 -0
  68. package/skills/profiles/design.txt +6 -0
  69. package/skills/profiles/full.txt +58 -0
  70. package/skills/profiles/growth.txt +10 -0
  71. package/skills/profiles/knowledge.txt +7 -0
  72. package/scripts/test-gemini.js +0 -13
  73. package/skills/cm-frappe-agent/SKILL.md +0 -134
  74. package/skills/cm-frappe-agent/agents/doctype-architect.md +0 -596
  75. package/skills/cm-frappe-agent/agents/erpnext-customizer.md +0 -643
  76. package/skills/cm-frappe-agent/agents/frappe-backend.md +0 -814
  77. package/skills/cm-frappe-agent/agents/frappe-custom-frontend.md +0 -557
  78. package/skills/cm-frappe-agent/agents/frappe-debugger.md +0 -625
  79. package/skills/cm-frappe-agent/agents/frappe-fixer.md +0 -275
  80. package/skills/cm-frappe-agent/agents/frappe-frontend.md +0 -660
  81. package/skills/cm-frappe-agent/agents/frappe-installer.md +0 -158
  82. package/skills/cm-frappe-agent/agents/frappe-performance.md +0 -307
  83. package/skills/cm-frappe-agent/agents/frappe-planner.md +0 -419
  84. package/skills/cm-frappe-agent/agents/frappe-remote-ops.md +0 -153
  85. package/skills/cm-frappe-agent/agents/github-workflow.md +0 -286
  86. package/skills/cm-frappe-agent/commands/frappe-app.md +0 -351
  87. package/skills/cm-frappe-agent/commands/frappe-backend.md +0 -162
  88. package/skills/cm-frappe-agent/commands/frappe-bench.md +0 -254
  89. package/skills/cm-frappe-agent/commands/frappe-debug.md +0 -263
  90. package/skills/cm-frappe-agent/commands/frappe-doctype-create.md +0 -272
  91. package/skills/cm-frappe-agent/commands/frappe-doctype-field.md +0 -310
  92. package/skills/cm-frappe-agent/commands/frappe-erpnext.md +0 -210
  93. package/skills/cm-frappe-agent/commands/frappe-fix.md +0 -59
  94. package/skills/cm-frappe-agent/commands/frappe-frontend.md +0 -210
  95. package/skills/cm-frappe-agent/commands/frappe-fullstack.md +0 -243
  96. package/skills/cm-frappe-agent/commands/frappe-github.md +0 -57
  97. package/skills/cm-frappe-agent/commands/frappe-install.md +0 -52
  98. package/skills/cm-frappe-agent/commands/frappe-plan.md +0 -442
  99. package/skills/cm-frappe-agent/commands/frappe-remote.md +0 -58
  100. package/skills/cm-frappe-agent/commands/frappe-test.md +0 -356
  101. package/skills/cm-frappe-agent/docs/README.md +0 -51
  102. package/skills/cm-frappe-agent/docs/agents-catalog.md +0 -113
  103. package/skills/cm-frappe-agent/docs/architecture.md +0 -149
  104. package/skills/cm-frappe-agent/docs/commands-catalog.md +0 -82
  105. package/skills/cm-frappe-agent/docs/resources-catalog.md +0 -66
  106. package/skills/cm-frappe-agent/docs/sitemap-urls.txt +0 -52
  107. package/skills/cm-frappe-agent/docs/sitemap.md +0 -81
  108. package/skills/cm-frappe-agent/docs/sop/user-guide.md +0 -178
  109. package/skills/cm-frappe-agent/docs/sop/vibe-coding-guide.md +0 -122
  110. package/skills/cm-frappe-agent/resources/7-layer-architecture.md +0 -985
  111. package/skills/cm-frappe-agent/resources/bench_commands.md +0 -73
  112. package/skills/cm-frappe-agent/resources/code-patterns-guide.md +0 -948
  113. package/skills/cm-frappe-agent/resources/common_pitfalls.md +0 -266
  114. package/skills/cm-frappe-agent/resources/doctype-registry.md +0 -158
  115. package/skills/cm-frappe-agent/resources/installation-guide.md +0 -289
  116. package/skills/cm-frappe-agent/resources/rest-api-patterns.md +0 -182
  117. package/skills/cm-frappe-agent/resources/scaffold_checklist.md +0 -82
  118. package/skills/cm-frappe-agent/resources/upgrade_patterns.md +0 -113
  119. package/skills/cm-frappe-agent/resources/web-form-patterns.md +0 -252
  120. package/skills/cm-frappe-agent/skills/bench-commands/SKILL.md +0 -621
  121. package/skills/cm-frappe-agent/skills/client-scripts/SKILL.md +0 -642
  122. package/skills/cm-frappe-agent/skills/doctype-patterns/SKILL.md +0 -576
  123. package/skills/cm-frappe-agent/skills/frappe-api/SKILL.md +0 -740
  124. package/skills/cm-frappe-agent/skills/remote-operations/SKILL.md +0 -47
  125. package/skills/cm-frappe-agent/skills/server-scripts/SKILL.md +0 -608
  126. package/skills/cm-frappe-agent/skills/web-forms/SKILL.md +0 -46
  127. package/skills/frappe-app-builder.zip +0 -0
package/CHANGELOG.md CHANGED
@@ -4,6 +4,25 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  Categories: 🚀 **Improvements** | 🐛 **Bug Fixes** | 🔒 **Security**
6
6
 
7
+ ## [4.8.0] - 2026-04-10
8
+
9
+ ### 🚀 Improvements — Documentation site & README accuracy
10
+
11
+ - **VitePress documentation** — Rebuilt `docs/` as a browsable site with sidebar IA (Getting Started, Architecture, Operations, Skills Library, API, Resources). Config: `docs/.vitepress/config.mts`. Local preview: `npm run docs:dev`; production build: `npm run docs:build`.
12
+ - **Skills index** — Documented all **56** bundled `skills/cm-*/SKILL.md` packs with category pages under `docs/skills/`.
13
+ - **API hub** — Added `docs/api/api-reference.md` (CLI + dashboard + browse daemon + MCP tools) aligned to `src/mcp-context-server.ts` (**13** MCP tools).
14
+ - **README refresh (all languages)** — Version badges bumped to **4.8.0**; broken `docs/` links replaced; CLI examples updated to match `src/cli/command-registry.ts` (no fictional `cm continuity` / `cm list` commands). License callouts aligned to **ISC** (`package.json`).
15
+ - **npm scripts** — `docs:dev`, `docs:build`, `docs:preview` for maintainers.
16
+
17
+ ## [4.7.0] - 2026-04-02
18
+
19
+ ### 🚀 Improvements — Zero-Touch Installation & Advanced Pipeline
20
+
21
+ - **Zero-Touch CLI Installation** — `install.sh` and `scripts/postinstall.js` overhauled to automatically activate the `cm` CLI. The script supports `--auto` for non-interactive `npm install -g codymaster`, while NPM seamlessly executes `npm link` or global install.
22
+ - **OpenViking Core Feature** — Integrated OpenViking installation via `pip/pip3` natively into the installation process. Both `bash install.sh --all` and `npm i codymaster` will now automatically set up the OpenViking daemon, unlocking true semantic vector graph memory out-of-the-box.
23
+ - **Skill Chain Auto-Dispatch** — Inspired by OpenSpace orchestrations, `cm-skill-chain` received a massive upgrade. Re-introduced the missing `auto` command enabling intelligent task detection, auto-selection of tools, and 100% automated handoffs between multi-agent sequences without human intervention.
24
+ - **Systematic Auto-healing** — Enhancements to `postinstall.js` for automatic fallbacks across different OS privileges and execution environments.
25
+
7
26
  ## [4.6.0] - 2026-04-02
8
27
 
9
28
  ### 🚀 Improvements — OpenViking Backend (Real Implementation)
@@ -74,7 +93,6 @@ Categories: 🚀 **Improvements** | 🐛 **Bug Fixes** | 🔒 **Security**
74
93
  - `cm-skill-evolution` — 3-mode evolution engine (FIX/DERIVED/CAPTURED) with version DAG and lineage tracking. Auto-patches degraded skills.
75
94
  - `cm-skill-search` — BM25 + health-score ranking for intelligent skill discovery.
76
95
  - `cm-skill-share` — Export/import skills across teams and machines with version integrity.
77
- - **🏢 cm-frappe-agent** — Full-stack Frappe/ERPNext development agent with 7-layer architecture: doctypes, workflows, REST APIs, permissions, fixtures, performance optimization, and production deploys.
78
96
  - **🚀 Growth Hacking Engine** — `cm-growth-hacking` generates complete conversion systems (Bottom Sheet + Calendar CTA + Tracking) with industry auto-detection.
79
97
  - **cm-auto-publisher** — Publishing automation bridge: AI agents → Content Factory Router → any Astro site.
80
98
  - **cm-clean-code** — TRIZ-powered code hygiene gate: dead code detection, duplicate elimination, naming analysis.
package/README.md CHANGED
@@ -9,10 +9,10 @@
9
9
  **68+ Skills · 18 Commands · 1 Plugin · 7+ Platforms · 6 Languages**
10
10
 
11
11
  <p align="center">
12
- <img alt="Version" src="https://img.shields.io/badge/version-4.6.0-blue.svg?cacheSeconds=2592000" />
12
+ <img alt="Version" src="https://img.shields.io/badge/version-4.8.0-blue.svg?cacheSeconds=2592000" />
13
13
  <img alt="Skills" src="https://img.shields.io/badge/skills-68+-success.svg" />
14
14
  <img alt="Platforms" src="https://img.shields.io/badge/platforms-7+-orange.svg" />
15
- <img alt="Open Source" src="https://img.shields.io/badge/license-MIT-purple.svg" />
15
+ <img alt="Open Source" src="https://img.shields.io/badge/license-ISC-purple.svg" />
16
16
  <a href="https://github.com/tody-agent/codymaster#readme" target="_blank">
17
17
  <img alt="Documentation" src="https://img.shields.io/badge/documentation-yes-brightgreen.svg" />
18
18
  </a>
@@ -71,7 +71,7 @@ graph TD
71
71
  A --> E["🔒 DevOps Engineer<br/><i>cm-safe-deploy · cm-secret-shield · cm-security-gate · cm-identity-guard</i>"]
72
72
  A --> F["📝 Technical Writer<br/><i>cm-dockit · cm-content-factory · cm-auto-publisher</i>"]
73
73
  A --> G["📈 Growth Marketer<br/><i>cm-ads-tracker · cm-cro-methodology · cm-growth-hacking</i>"]
74
- A --> H["🏭 Enterprise Dev<br/><i>cm-frappe-agent · cm-booking-calendar · cm-google-form</i>"]
74
+ A --> H["🏭 Enterprise Dev<br/><i>cm-booking-calendar · cm-google-form</i>"]
75
75
  style A fill:#fbc531,stroke:#e1b12c,color:#2f3640,stroke-width:3px
76
76
  classDef team fill:#2f3640,stroke:#dcdde1,stroke-width:1px,color:#fff;
77
77
  class B,C,D,E,F,G,H team;
@@ -121,13 +121,13 @@ Your AI doesn't just execute — it **understands and remembers** using a multi-
121
121
  - **cm:// URI Scheme** — Skills request context by URI, not file paths.
122
122
  - **Token Budget** — 200k window pre-allocated by category. No more silent overflow.
123
123
  - **Context Bus** — Skills share outputs in real-time within a chain.
124
- - **MCP Server** — 7 tools exposed to Claude Desktop and any MCP client.
125
- - **OpenViking Backend (optional)** — Swap SQLite for [OpenViking](https://github.com/volcengine/OpenViking): true vector semantic search, auto L0/L1/L2 generation, session compression. One config line: `storage.backend: viking`.
124
+ - **MCP Server** — 13 tools exposed to Claude Desktop and any MCP client (`src/mcp-context-server.ts`).
125
+ - **OpenViking Backend natively integrated** — Inspired by OpenViking's architecture, CodyMaster defaults to `openviking` auto-installation. It delivers true semantic vector graph memory, automatic session compression, and temporal context layering. (One config line change: `storage.backend: viking`).
126
126
 
127
127
  ☁️ **The Cloud Brain (`cm-notebooklm`)**
128
128
  High-value knowledge and design patterns are synced to NotebookLM, providing a universal, cross-machine "Soul" for your project. Auto-generate podcasts and flashcards to onboard human developers alongside the AI.
129
129
 
130
- 📖 [Read the full Knowledge Architecture →](docs/architecture/knowledge-architecture.md)
130
+ 📖 [CodyMaster Brain & memory model →](docs/architecture/codymaster-brain.md)
131
131
 
132
132
  ### 🛡️ Multi-Layer Protection (Your Codebase Won't Get Destroyed)
133
133
 
@@ -175,7 +175,7 @@ Don't know what the old code does? **`cm-dockit`** reads your entire codebase an
175
175
 
176
176
  Before diving into code for complex requests, **`cm-brainstorm-idea`** evaluates your product using multi-dimensional analysis (Tech, Product, Design, Business). It generates 2-3 qualified options using the 9 Windows (TRIZ) framework and provides a visual UI Preview via **Pencil.dev** or **Google Stitch** to validate the direction before detailed planning.
177
177
 
178
- 📖 [Read more about the UI Preview Phase →](docs/workflows/brainstorm-ui-preview.md)
178
+ 📖 [TRIZ-parallel workflow & UI preview handoff →](docs/architecture/triz-parallel-engine.md)
179
179
 
180
180
 
181
181
  ### 🏭 AI Content Factory v2.0 & Visual Dashboard
@@ -190,15 +190,12 @@ CodyMaster doesn't just run skills — it **watches them, scores them, and heals
190
190
 
191
191
  - **`cm-skill-health`** monitors every invocation: success rate, token usage, error patterns.
192
192
  - **`cm-skill-evolution`** auto-patches degraded skills (Mode: FIX) when health scores drop below threshold.
193
+ - **`cm-skill-chain` Auto-Dispatch** — Inspired by OpenSpace automation orchestrators, sequence dispatching is now 100% automated with intelligent task detection, zero-touch handoffs, and multi-agent coordination.
193
194
  - **`cm-skill-search`** uses BM25 ranking to find the right skill for any task.
194
195
  - **`cm-skill-share`** exports & imports skills across teams and machines.
195
196
 
196
197
  > **Think of it like an immune system for your AI toolkit.** Skills that break get healed. Skills that work well get reinforced. Dead skills get archived.
197
198
 
198
- ### 🏢 Enterprise-Ready: Frappe/ERPNext Full-Stack
199
-
200
- Building on Frappe Framework? **`cm-frappe-agent`** is a 7-layer architecture agent covering the entire Frappe lifecycle — from `bench new-app` to production deploys. Custom doctypes, workflows, REST APIs, permissions, fixtures, and performance optimization — all battle-tested.
201
-
202
199
  ### 🚀 Growth Hacking Engine
203
200
 
204
201
  Need popups, booking flows, or lead capture? **`cm-growth-hacking`** generates complete conversion systems: Bottom Sheet + Calendar CTA + Tracking. Auto-detects industry, selects the right pattern, wires up **`cm-booking-calendar`** for appointments and **`cm-ads-tracker`** for pixel tracking. Zero dependencies.
@@ -253,12 +250,53 @@ One command installs all 68+ skills to your environment. Supports Claude Code, G
253
250
  bash <(curl -fsSL https://raw.githubusercontent.com/tody-agent/codymaster/main/install.sh) --all
254
251
  ```
255
252
 
253
+ #### After `install.sh --all` (verify)
254
+
255
+ - **Restart** Claude Code, Cursor, or Gemini / Antigravity so they reload config and rules from disk.
256
+ - **Cursor:** rules go to **`~/.cursor/rules`** (always under your home folder, not wherever you ran the script). In Agent chat, run **`/add-plugin cody-master`**. To install rules **only inside one git repo**, run from that repo: `bash install.sh --cursor --cursor-project`.
257
+ - **Gemini / Antigravity:** skills live in `~/.gemini/antigravity/skills`. The installer **creates or appends** `~/.gemini/GEMINI.md` with `@~/.gemini/antigravity/skills/cm-skill-index/SKILL.md` when that hint is missing.
258
+ - **Claude Code:** if commands like `/cm:demo` do not appear, run `claude plugin marketplace add tody-agent/codymaster` then `claude plugin install cm@codymaster --scope user` (or `--scope project`).
259
+ - **Non-interactive:** `--all` skips the onboarding menu. For a single platform, add **`--yes`** (e.g. `bash install.sh --gemini --yes`).
260
+
261
+ #### Google Antigravity / Gemini CLI / Windsurf (token budget)
262
+
263
+ Antigravity and some Windsurf builds count **skills + MCP** against a customization token budget. Installing every skill globally can trigger truncation or unstable agent runs (especially if an MCP server errors and retries).
264
+
265
+ - **Recommended:** install a **small global profile**, add the rest per project.
266
+
267
+ ```bash
268
+ # Core only → ~/.gemini/antigravity/skills (merge more profiles later with the same command)
269
+ bash <(curl -fsSL https://raw.githubusercontent.com/tody-agent/codymaster/main/install.sh) --gemini --profile core
270
+
271
+ # Optional packs (re-run to add folders alongside core)
272
+ bash install.sh --gemini --profile growth
273
+ bash install.sh --gemini --profile design
274
+ bash install.sh --gemini --profile knowledge
275
+ ```
276
+
277
+ - **Paths:** Antigravity / Gemini CLI skills → `~/.gemini/antigravity/skills`. This repo’s installer for **Windsurf** writes to **project** `.windsurf/rules` when you run `install.sh --windsurf` from a repo root. Some Windsurf/Codeium setups also use a **global** skills directory (e.g. under Codeium); if you copy skills there manually, use the same `--profile` flags to avoid duplicating hundreds of rules.
278
+ - **MCP:** Disable MCP servers you are not using in the IDE settings. Flaky or rate-limited MCPs can cause “MCP Error” loops until the agent terminates.
279
+ - **Progressive disclosure:** Add `@~/.gemini/antigravity/skills/cm-skill-index/SKILL.md` to `GEMINI.md` so the model loads the index before pulling full skills.
280
+
281
+ Profiles are defined under [`skills/profiles/`](skills/profiles/README.md).
282
+
256
283
  *For Cursor IDE users, you can also just type `/add-plugin cody-master` in your agent chat.*
257
284
 
258
285
  ### 2. Install Mission Control Dashboard (Optional but Recommended)
259
286
 
260
287
  Visualize your progress, manage tasks, and track your 10x coding streak with Cody the Hamster 🐹.
261
288
 
289
+ **Both are official:** install **per project** (no `-g`) or **globally**.
290
+
291
+ Per project — keeps the CLI version with the repo (use `npx` so you do not need `cm` on your PATH):
292
+
293
+ ```bash
294
+ npm install codymaster
295
+ npx cm
296
+ ```
297
+
298
+ Global — type `cm` from any directory:
299
+
262
300
  ```bash
263
301
  npm install -g codymaster
264
302
  cm
@@ -293,7 +331,7 @@ The CLI will greet you and keep you organized on your long coding sessions!
293
331
  | ⚙️ **Operations** | `cm-safe-deploy` `cm-identity-guard` `cm-secret-shield` `cm-security-gate` `cm-git-worktrees` `cm-terminal` `cm-safe-i18n` |
294
332
  | 🎨 **Product & UX** | `cm-planning` `cm-design-system` `cm-ux-master` `cm-ui-preview` `cm-project-bootstrap` `cm-jtbd` `cm-brainstorm-idea` `cm-dockit` `cm-readit` |
295
333
  | 📈 **Growth & CRO** | `cm-content-factory` `cm-auto-publisher` `cm-ads-tracker` `cm-cro-methodology` `cm-growth-hacking` `cm-booking-calendar` `cm-google-form` |
296
- | 🏢 **Enterprise** | `cm-frappe-agent` `cm-reactor` `cm-notebooklm` |
334
+ | 🏢 **Enterprise** | `cm-reactor` `cm-notebooklm` |
297
335
  | 🧬 **Self-Healing** | `cm-skill-health` `cm-skill-evolution` `cm-skill-search` `cm-skill-share` `cm-skill-chain` `cm-skill-mastery` `cm-skill-index` |
298
336
  | 🎯 **Orchestration** | `cm-execution` `cm-continuity` `cm-deep-search` `cm-codeintell` `cm-how-it-work` |
299
337
  | 🖥️ **Workflow** | `cm-start` `cm-dashboard` `cm-status` |
@@ -302,23 +340,32 @@ The CLI will greet you and keep you organized on your long coding sessions!
302
340
 
303
341
  ## 🎮 Commands
304
342
 
343
+ Run `cm --help` (or `node dist/index.js --help` from a clone) for the **authoritative** list. Highlights from `src/cli/command-registry.ts`:
344
+
345
+ ```
346
+ cm, codymaster → CLI entry
347
+ cm status → Task & project summary
348
+ cm task <cmd> [args...] → Task management
349
+ cm project <cmd> [args...] → Project management
350
+ cm deploy <cmd> [args...] → Deploy / rollback / history / changelog
351
+ cm dashboard [start|stop|status|open|url] → Mission Control (default :6969)
352
+ cm agent [status|memory|brain|learn] → Working memory / learnings
353
+ cm brain → Continuity + next actions
354
+ cm chain <cmd> [args...] → Skill chain execution
355
+ cm config [key] [value] → Config helper
356
+ cm open → Open dashboard in browser
357
+ cm browse … → Local Playwright browse daemon (QA)
358
+ cm guardian … → Destructive-command / path checks
359
+ cm sprint … → Sprint pipeline + .cm/sprint
360
+ cm design-studio [init|status]
361
+ cm distro validate … → Validate skill pack layout
305
362
  ```
306
- cm → Quick menu with Cody 🐹
307
- cm task add "..." → Add a task
308
- cm task list → View tasks
309
- cm status → Project health
310
- cm dashboard → Open Mission Control
311
- cm list → Browse 68+ skills
312
- cm profile → Your stats & achievements
313
- cm deploy <env> → Record deployment
314
- cm continuity index → Regenerate L0 memory indexes
315
- cm continuity budget → Show token budget allocation
316
- cm continuity bus → View context bus state
317
- cm continuity mcp → Print MCP server config
318
- cm continuity migrate → Migrate JSON → SQLite
319
- cm continuity export → Export SQLite → JSON
320
- cm resolve <uri> → Resolve any cm:// URI
321
363
 
364
+ **Memory, bus, budgets, `cm://` resolution:** use the **MCP context server** — see [docs/api/api-reference.md](docs/api/api-reference.md).
365
+
366
+ **Engineering (browse, guardian, sprint):** [docs/workflows/engineering-pipeline.md](docs/workflows/engineering-pipeline.md) · [docs/architecture/servers-and-mcp.md](docs/architecture/servers-and-mcp.md)
367
+
368
+ ```bash
322
369
  # OpenViking backend (optional — semantic vector search)
323
370
  pip install openviking && openviking start
324
371
  # Then set storage.backend: viking in .cm/config.yaml
@@ -349,8 +396,9 @@ pip install openviking && openviking start
349
396
  ## 📚 Resources
350
397
 
351
398
  - 🌍 [Website](https://cody.todyle.com) — Overview & demos
352
- - 📖 [Documentation](https://cody.todyle.com/docs) — Full deep-dive
353
- - 🛠️ [Skills Reference](skills/) — Browse all 68+ SKILL.md files
399
+ - 📖 [Documentation (site)](https://cody.todyle.com/docs) — Hosted deep-dive
400
+ - 📘 [Documentation (repo)](docs/index.md) — Markdown source; run `npm run docs:dev` for VitePress
401
+ - 🛠️ [Skills Reference](skills/) — Browse **56** bundled `cm-*` SKILL.md packs (profiles/installer can add more)
354
402
  - 📖 [Our Story](https://cody.todyle.com/story) — Why this exists
355
403
 
356
404
  ---
@@ -361,11 +409,13 @@ pip install openviking && openviking start
361
409
  2. Fork → Create `skills/cm-your-skill/SKILL.md`
362
410
  3. Submit a Pull Request
363
411
 
412
+ CI runs `npm ci` and `npm run test:gate:kit` on pushes and pull requests (see `.github/workflows/ci.yml`).
413
+
364
414
  ---
365
415
 
366
416
  <div align="center">
367
417
 
368
- *MIT License — Free to use, modify, and distribute.* `<br/>`
418
+ *ISC License — Free to use, modify, and distribute.* <br/>
369
419
  **Built with ❤️ for the vibe coding community.**
370
420
 
371
421
  *"CodyMaster" = "Code Đi" (Vietnamese: "Go code!") — just start building.*
@@ -0,0 +1,251 @@
1
+ "use strict";
2
+ /**
3
+ * Local HTTP browse daemon (Playwright + Express). Bearer auth.
4
+ * Refs: POST /refs/refresh tags interactive elements with data-cm-ref.
5
+ */
6
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
7
+ if (k2 === undefined) k2 = k;
8
+ var desc = Object.getOwnPropertyDescriptor(m, k);
9
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
10
+ desc = { enumerable: true, get: function() { return m[k]; } };
11
+ }
12
+ Object.defineProperty(o, k2, desc);
13
+ }) : (function(o, m, k, k2) {
14
+ if (k2 === undefined) k2 = k;
15
+ o[k2] = m[k];
16
+ }));
17
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
18
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
19
+ }) : function(o, v) {
20
+ o["default"] = v;
21
+ });
22
+ var __importStar = (this && this.__importStar) || (function () {
23
+ var ownKeys = function(o) {
24
+ ownKeys = Object.getOwnPropertyNames || function (o) {
25
+ var ar = [];
26
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
27
+ return ar;
28
+ };
29
+ return ownKeys(o);
30
+ };
31
+ return function (mod) {
32
+ if (mod && mod.__esModule) return mod;
33
+ var result = {};
34
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
35
+ __setModuleDefault(result, mod);
36
+ return result;
37
+ };
38
+ })();
39
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
40
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
41
+ return new (P || (P = Promise))(function (resolve, reject) {
42
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
43
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
44
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
45
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
46
+ });
47
+ };
48
+ var __importDefault = (this && this.__importDefault) || function (mod) {
49
+ return (mod && mod.__esModule) ? mod : { "default": mod };
50
+ };
51
+ Object.defineProperty(exports, "__esModule", { value: true });
52
+ exports.BrowseDaemon = void 0;
53
+ const express_1 = __importDefault(require("express"));
54
+ function createRing(max) {
55
+ const buf = [];
56
+ return {
57
+ push(item) {
58
+ buf.push(item);
59
+ while (buf.length > max)
60
+ buf.shift();
61
+ },
62
+ snapshot: () => [...buf],
63
+ };
64
+ }
65
+ class BrowseDaemon {
66
+ constructor(opts) {
67
+ this.opts = opts;
68
+ this.app = (0, express_1.default)();
69
+ this.httpServer = null;
70
+ this.browser = null;
71
+ this.context = null;
72
+ this.page = null;
73
+ this.consoleBuf = createRing(200);
74
+ this.networkBuf = createRing(200);
75
+ this.refMap = {};
76
+ this.app.use(express_1.default.json({ limit: '2mb' }));
77
+ this.app.use(this.authMiddleware.bind(this));
78
+ this.routes();
79
+ }
80
+ authMiddleware(req, res, next) {
81
+ if (req.path === '/health')
82
+ return next();
83
+ const h = req.headers.authorization || '';
84
+ const want = `Bearer ${this.opts.token}`;
85
+ if (h !== want) {
86
+ res.status(401).json({ error: 'unauthorized' });
87
+ return;
88
+ }
89
+ next();
90
+ }
91
+ routes() {
92
+ this.app.get('/health', (_req, res) => {
93
+ res.json({ ok: true, hasPage: !!this.page });
94
+ });
95
+ this.app.post('/session/start', (req, res) => __awaiter(this, void 0, void 0, function* () {
96
+ var _a, _b, _c;
97
+ try {
98
+ const headless = (_c = (_b = (_a = req.body) === null || _a === void 0 ? void 0 : _a.headless) !== null && _b !== void 0 ? _b : this.opts.headless) !== null && _c !== void 0 ? _c : true;
99
+ const pw = yield Promise.resolve().then(() => __importStar(require('playwright')));
100
+ this.browser = yield pw.chromium.launch({ headless });
101
+ this.context = yield this.browser.newContext();
102
+ this.page = yield this.context.newPage();
103
+ this.page.on('console', (msg) => {
104
+ this.consoleBuf.push({
105
+ type: msg.type(),
106
+ text: msg.text(),
107
+ ts: new Date().toISOString(),
108
+ });
109
+ });
110
+ this.context.on('response', (response) => {
111
+ try {
112
+ this.networkBuf.push({
113
+ url: response.url(),
114
+ method: response.request().method(),
115
+ status: response.status(),
116
+ ts: new Date().toISOString(),
117
+ });
118
+ }
119
+ catch (_a) {
120
+ /* ignore */
121
+ }
122
+ });
123
+ res.json({ ok: true });
124
+ }
125
+ catch (e) {
126
+ res.status(500).json({ error: e.message });
127
+ }
128
+ }));
129
+ this.app.post('/navigate', (req, res) => __awaiter(this, void 0, void 0, function* () {
130
+ var _a;
131
+ try {
132
+ const url = (_a = req.body) === null || _a === void 0 ? void 0 : _a.url;
133
+ if (!url || !this.page) {
134
+ res.status(400).json({ error: 'url required and session must be started' });
135
+ return;
136
+ }
137
+ yield this.page.goto(url, { waitUntil: 'domcontentloaded', timeout: 60000 });
138
+ res.json({ ok: true, url: this.page.url() });
139
+ }
140
+ catch (e) {
141
+ res.status(500).json({ error: e.message });
142
+ }
143
+ }));
144
+ this.app.post('/refs/refresh', (_req, res) => __awaiter(this, void 0, void 0, function* () {
145
+ try {
146
+ if (!this.page) {
147
+ res.status(400).json({ error: 'no session' });
148
+ return;
149
+ }
150
+ const mapping = yield this.page.evaluate(() => {
151
+ const sel = 'a[href],button,input,textarea,select,[role="button"],[onclick]';
152
+ const nodes = Array.from(document.querySelectorAll(sel));
153
+ const out = {};
154
+ nodes.forEach((el, i) => {
155
+ const id = `e${i + 1}`;
156
+ el.setAttribute('data-cm-ref', id);
157
+ const tag = el.tagName.toLowerCase();
158
+ const txt = (el.textContent || '').trim().slice(0, 80);
159
+ out[id] = `${tag}${txt ? `: ${txt}` : ''}`;
160
+ });
161
+ return out;
162
+ });
163
+ this.refMap = mapping;
164
+ res.json({ ok: true, refs: mapping });
165
+ }
166
+ catch (e) {
167
+ res.status(500).json({ error: e.message });
168
+ }
169
+ }));
170
+ this.app.post('/click', (req, res) => __awaiter(this, void 0, void 0, function* () {
171
+ var _a, _b;
172
+ try {
173
+ const ref = (_b = (_a = req.body) === null || _a === void 0 ? void 0 : _a.ref) === null || _b === void 0 ? void 0 : _b.replace(/^@/, '');
174
+ if (!ref || !this.page) {
175
+ res.status(400).json({ error: 'ref required' });
176
+ return;
177
+ }
178
+ yield this.page.click(`[data-cm-ref="${ref}"]`, { timeout: 15000 });
179
+ res.json({ ok: true });
180
+ }
181
+ catch (e) {
182
+ res.status(500).json({ error: e.message });
183
+ }
184
+ }));
185
+ this.app.post('/fill', (req, res) => __awaiter(this, void 0, void 0, function* () {
186
+ var _a, _b, _c;
187
+ try {
188
+ const ref = (_b = (_a = req.body) === null || _a === void 0 ? void 0 : _a.ref) === null || _b === void 0 ? void 0 : _b.replace(/^@/, '');
189
+ const value = (_c = req.body) === null || _c === void 0 ? void 0 : _c.value;
190
+ if (!ref || value === undefined || !this.page) {
191
+ res.status(400).json({ error: 'ref and value required' });
192
+ return;
193
+ }
194
+ yield this.page.fill(`[data-cm-ref="${ref}"]`, value, { timeout: 15000 });
195
+ res.json({ ok: true });
196
+ }
197
+ catch (e) {
198
+ res.status(500).json({ error: e.message });
199
+ }
200
+ }));
201
+ this.app.get('/screenshot', (_req, res) => __awaiter(this, void 0, void 0, function* () {
202
+ try {
203
+ if (!this.page) {
204
+ res.status(400).json({ error: 'no session' });
205
+ return;
206
+ }
207
+ const buf = yield this.page.screenshot({ type: 'png' });
208
+ res.setHeader('Content-Type', 'image/png');
209
+ res.send(buf);
210
+ }
211
+ catch (e) {
212
+ res.status(500).json({ error: e.message });
213
+ }
214
+ }));
215
+ this.app.get('/console', (_req, res) => {
216
+ res.json({ entries: this.consoleBuf.snapshot() });
217
+ });
218
+ this.app.get('/network', (_req, res) => {
219
+ res.json({ entries: this.networkBuf.snapshot() });
220
+ });
221
+ }
222
+ listen() {
223
+ return __awaiter(this, void 0, void 0, function* () {
224
+ var _a;
225
+ const host = this.opts.host || '127.0.0.1';
226
+ const port = (_a = this.opts.port) !== null && _a !== void 0 ? _a : 17395;
227
+ return new Promise((resolve, reject) => {
228
+ this.httpServer = this.app.listen(port, host, () => resolve());
229
+ this.httpServer.on('error', reject);
230
+ });
231
+ });
232
+ }
233
+ close() {
234
+ return __awaiter(this, void 0, void 0, function* () {
235
+ if (this.page)
236
+ yield this.page.close().catch(() => { });
237
+ if (this.context)
238
+ yield this.context.close().catch(() => { });
239
+ if (this.browser)
240
+ yield this.browser.close().catch(() => { });
241
+ this.page = null;
242
+ this.context = null;
243
+ this.browser = null;
244
+ if (this.httpServer) {
245
+ yield new Promise((r) => this.httpServer.close(() => r()));
246
+ this.httpServer = null;
247
+ }
248
+ });
249
+ }
250
+ }
251
+ exports.BrowseDaemon = BrowseDaemon;
@@ -0,0 +1,26 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.registerAllCommands = registerAllCommands;
4
+ const agent_1 = require("./commands/agent");
5
+ const dashboard_1 = require("./commands/dashboard");
6
+ const project_1 = require("./commands/project");
7
+ const skill_chain_1 = require("./commands/skill-chain");
8
+ const system_1 = require("./commands/system");
9
+ const task_1 = require("./commands/task");
10
+ const engineering_1 = require("./commands/engineering");
11
+ const design_studio_1 = require("./commands/design-studio");
12
+ const distro_1 = require("./commands/distro");
13
+ /**
14
+ * Registers all CLI commands with the provided program instance.
15
+ */
16
+ function registerAllCommands(program) {
17
+ (0, agent_1.registerAgentCommands)(program);
18
+ (0, dashboard_1.registerDashboardCommands)(program);
19
+ (0, project_1.registerProjectCommands)(program);
20
+ (0, skill_chain_1.registerSkillChainCommands)(program);
21
+ (0, system_1.registerSystemCommands)(program);
22
+ (0, task_1.registerTaskCommands)(program);
23
+ (0, engineering_1.registerEngineeringCommands)(program);
24
+ (0, design_studio_1.registerDesignStudioCommands)(program);
25
+ (0, distro_1.registerDistroCommands)(program);
26
+ }
@@ -0,0 +1,120 @@
1
+ "use strict";
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.registerAgentCommands = registerAgentCommands;
13
+ const continuity_1 = require("../../continuity");
14
+ const box_1 = require("../../ui/box");
15
+ const theme_1 = require("../../ui/theme");
16
+ const cli_utils_1 = require("../../utils/cli-utils");
17
+ function registerAgentCommands(program) {
18
+ program
19
+ .command('agent [cmd] [args...]')
20
+ .alias('a')
21
+ .description('Agent management (status|memory|brain|learn)')
22
+ .action((cmd, args) => {
23
+ switch (cmd) {
24
+ case 'status':
25
+ case 'st':
26
+ agentStatus();
27
+ break;
28
+ case 'memory':
29
+ case 'mem':
30
+ agentMemory();
31
+ break;
32
+ case 'brain':
33
+ case 'br':
34
+ agentBrain();
35
+ break;
36
+ case 'learn':
37
+ agentLearn(args.join(' '));
38
+ break;
39
+ default: agentStatus();
40
+ }
41
+ });
42
+ program
43
+ .command('brain')
44
+ .alias('br')
45
+ .description('Show AI brain/working memory')
46
+ .action(() => agentBrain());
47
+ }
48
+ function agentStatus() {
49
+ const summary = (0, continuity_1.getContinuityStatus)(process.cwd());
50
+ if (!summary.initialized) {
51
+ console.log((0, box_1.renderResult)('warning', 'No active CodyMaster brain initialized in this directory.', [
52
+ (0, theme_1.dim)('Run `cm init` to start.')
53
+ ]));
54
+ return;
55
+ }
56
+ console.log((0, box_1.renderCommandHeader)('Agent Status: Hamster v4.6', '🐹'));
57
+ console.log((0, theme_1.brand)(' 🧠 Memory Index:'));
58
+ console.log((0, theme_1.dim)(` Iterations: ${summary.iteration}`));
59
+ console.log((0, theme_1.dim)(` Current Goal: ${summary.activeGoal}`));
60
+ console.log((0, theme_1.dim)(` Current Phase: ${summary.phase}`));
61
+ console.log((0, theme_1.dim)(` Tasks Completed: ${summary.completedCount}`));
62
+ console.log((0, theme_1.dim)(` Active Blockers: ${summary.blockerCount}`));
63
+ console.log(`\n ${(0, theme_1.brand)('📊 Activity Summary:')}`);
64
+ console.log((0, theme_1.dim)(` Learnings: ${summary.learningCount}`));
65
+ console.log((0, theme_1.dim)(` Decisions: ${summary.decisionCount}`));
66
+ console.log();
67
+ }
68
+ function agentMemory() {
69
+ const learnings = (0, continuity_1.getLearnings)(process.cwd()).slice(0, 5);
70
+ if (learnings.length === 0) {
71
+ console.log((0, box_1.renderResult)('info', 'No memories stored yet.'));
72
+ return;
73
+ }
74
+ console.log((0, box_1.renderCommandHeader)('Agent Memory (Latest)', '🧠'));
75
+ learnings.forEach((l) => {
76
+ console.log(` ${(0, theme_1.success)('●')} ${(0, theme_1.brand)(l.whatFailed)}`);
77
+ console.log((0, theme_1.dim)(` ${l.howToPrevent} (${(0, cli_utils_1.formatTimeAgoCli)(l.timestamp)})`));
78
+ });
79
+ console.log();
80
+ }
81
+ function agentBrain() {
82
+ const state = (0, continuity_1.readContinuityState)(process.cwd());
83
+ if (!state) {
84
+ console.log((0, box_1.renderResult)('warning', 'Brain not initialized.'));
85
+ return;
86
+ }
87
+ console.log((0, box_1.renderCommandHeader)(`Agent Brain: ${state.project}`, '🧠'));
88
+ console.log((0, theme_1.brand)(` Goal: ${state.activeGoal}`));
89
+ console.log((0, theme_1.dim)(` Phase: ${state.currentPhase} (Iter ${state.currentIteration})`));
90
+ console.log(`\n ${(0, theme_1.brand)('Next Actions:')}`);
91
+ state.nextActions.slice(0, 5).forEach((act, idx) => {
92
+ console.log(` ${idx + 1}. ${act}`);
93
+ });
94
+ if (state.activeBlockers.length > 0) {
95
+ console.log(`\n ${(0, theme_1.warning)('Blockers:')}`);
96
+ state.activeBlockers.forEach((b) => console.log(` ⚠️ ${b}`));
97
+ }
98
+ console.log();
99
+ }
100
+ function agentLearn(content) {
101
+ return __awaiter(this, void 0, void 0, function* () {
102
+ var _a;
103
+ if (!content) {
104
+ console.log((0, box_1.renderResult)('error', 'Please provide a learning to record.'));
105
+ return;
106
+ }
107
+ const state = (0, continuity_1.readContinuityState)(process.cwd());
108
+ const learning = {
109
+ whatFailed: content,
110
+ whyFailed: 'Manual entry',
111
+ howToPrevent: 'Recorded via CLI',
112
+ timestamp: new Date().toISOString(),
113
+ agent: 'CLI User',
114
+ taskId: ((_a = state === null || state === void 0 ? void 0 : state.currentTask) === null || _a === void 0 ? void 0 : _a.id) || 'manual',
115
+ module: 'system'
116
+ };
117
+ (0, continuity_1.addLearning)(process.cwd(), learning);
118
+ console.log((0, box_1.renderResult)('success', 'Learning recorded in brain.'));
119
+ });
120
+ }