@jgamaraalv/ts-dev-kit 2.3.0 → 3.0.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.
@@ -5,14 +5,14 @@
5
5
  "url": "https://github.com/jgamaraalv"
6
6
  },
7
7
  "metadata": {
8
- "description": "TypeScript fullstack development agents and skills for Claude Code"
8
+ "description": "15 agents and 21 skills for TypeScript fullstack development with Claude Code"
9
9
  },
10
10
  "plugins": [
11
11
  {
12
12
  "name": "ts-dev-kit",
13
13
  "source": "./",
14
- "description": "13 specialized agents and 16 skills for TypeScript fullstack development",
15
- "version": "2.2.0",
14
+ "description": "15 specialized agents and 21 skills for TypeScript fullstack development",
15
+ "version": "3.0.0",
16
16
  "author": {
17
17
  "name": "jgamaraalv"
18
18
  },
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ts-dev-kit",
3
- "version": "2.2.0",
4
- "description": "13 specialized agents and 16 skills for TypeScript fullstack development with Fastify, Next.js, PostgreSQL, Redis, and more.",
3
+ "version": "3.0.0",
4
+ "description": "15 specialized agents and 21 skills for TypeScript fullstack development with Fastify, Next.js, PostgreSQL, Redis, and more.",
5
5
  "author": {
6
6
  "name": "jgamaraalv",
7
7
  "url": "https://github.com/jgamaraalv"
package/CHANGELOG.md CHANGED
@@ -5,6 +5,58 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [3.0.0] - 2026-02-27
9
+
10
+ ### Added
11
+
12
+ - `/codebase-adapter` skill: surgically adapts plugin agent/skill files to the host project on installation — updates domain area tables, skill maps, MCP references, quality gate commands, and package names without touching workflow logic
13
+ - `/core-web-vitals` skill: LCP, INP, CLS reference covering thresholds, field vs lab tooling, diagnosis guides, and optimization patterns; includes `scripts/visualize.py` for generating interactive HTML reports from metric values or Lighthouse JSON output
14
+ - `/debug` skill: end-to-end debugging workflow with multi-layer triage, single/multi-layer execution modes, and agent dispatch templates for backend, frontend, queue, and E2E layers
15
+ - `/generate-prd` skill: produces structured Product Requirements Documents from feature descriptions or user stories
16
+ - `/generate-task` skill: breaks PRD features into granular, agent-ready task files with acceptance criteria, affected packages, and quality gate commands
17
+ - Dynamic context injection (`!`command`` syntax) to `/conventional-commits`: staged diff summary, full staged diff (up to 300 lines), and recent commit log are pre-injected before Claude receives the prompt
18
+ - Dynamic context injection to `/debug`: last 10 git commits and working tree status are pre-injected at invocation time to accelerate triage
19
+ - Dynamic context injection to `/codebase-adapter`: working directory, detected lockfile, installed agents, configured MCP servers, and `package.json` are pre-injected to reduce manual discovery
20
+ - `allowed-tools` frontmatter to `/conventional-commits`, `/debug`, `/codebase-adapter`, and `/core-web-vitals` — whitelists the shell commands needed for dynamic injection and script execution
21
+ - `scripts/` subdirectory convention for skills that bundle executable tools (Python, bash)
22
+
23
+ ### Changed
24
+
25
+ - Renamed skill `/task` → `/execute-task` (update any project references or task files that invoke this command)
26
+
27
+ ### Breaking Changes
28
+
29
+ - `/task` slash command removed; use `/execute-task` instead
30
+
31
+ ## [2.3.0] - 2026-02-26
32
+
33
+ ### Added
34
+
35
+ - `/tanstack-query` skill: TanStack Query v5 (React Query) reference covering `useQuery`, `useMutation`, `useInfiniteQuery`, `QueryClient`, SSR/hydration with Next.js, optimistic updates, cache invalidation, and TypeScript patterns
36
+
37
+ ## [2.2.0] - 2026-02-26
38
+
39
+ ### Changed
40
+
41
+ - Enforce mandatory agent delegation in all `/execute-task` execution modes — tasks are always dispatched to specialized agents; direct implementation by the orchestrator is no longer permitted
42
+
43
+ ## [2.1.0] - 2026-02-25
44
+
45
+ ### Added
46
+
47
+ - Baseline capture phase to `/execute-task`: records the state of quality gates before any changes
48
+ - Post-change verification phase to `/execute-task`: re-runs quality gates after the fix and diffs against baseline to confirm no regressions were introduced
49
+
50
+ ## [2.0.0] - 2026-02-24
51
+
52
+ ### Changed
53
+
54
+ - Make all 15 agents fully repository-agnostic: agents now discover project conventions dynamically from `CLAUDE.md`, `package.json`, and the codebase — no hardcoded paths, package names, or workspace commands remain in any agent definition
55
+
56
+ ### Breaking Changes
57
+
58
+ - Any project-specific overrides embedded directly in agent files are no longer applied; configure project context in your project's `CLAUDE.md` instead
59
+
8
60
  ## [1.2.1] - 2026-02-24
9
61
 
10
62
  ### Fixed
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # ts-dev-kit
2
2
 
3
- > 15 specialized agents + 14 curated skills for TypeScript fullstack development
3
+ > 15 specialized agents + 21 curated skills for TypeScript fullstack development
4
4
 
5
5
  [![npm version](https://img.shields.io/npm/v/@jgamaraalv/ts-dev-kit)](https://www.npmjs.com/package/@jgamaraalv/ts-dev-kit)
6
6
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
@@ -30,48 +30,92 @@
30
30
  | typescript-pro | Generics, type inference, conditional types |
31
31
  | ux-optimizer | User flows, form UX, friction reduction |
32
32
 
33
- ### Skills (14)
34
-
35
- | Skill | Slug | Domain |
36
- | ---------------------- | ------------------------- | -------------------------------------------- |
37
- | BullMQ | `/bullmq` | Redis job queues, workers, flows, schedulers |
38
- | Composition Patterns | `/composition-patterns` | React compound components, render props |
39
- | Conventional Commits | `/conventional-commits` | Commit message spec, types, SemVer |
40
- | Docker | `/docker` | Dockerfiles, compose, optimization, security |
41
- | Drizzle ORM | `/drizzle-pg` | PostgreSQL ORM schemas, queries, migrations |
42
- | Fastify Best Practices | `/fastify-best-practices` | Routes, plugins, hooks, validation |
43
- | ioredis | `/ioredis` | Redis client, pipelines, Pub/Sub, Cluster |
44
- | Next.js Best Practices | `/nextjs-best-practices` | App Router, RSC, data patterns |
45
- | OWASP Security Review | `/owasp-security-review` | Top 10:2025 vulnerability checklist |
46
- | PostgreSQL | `/postgresql` | Queries, schemas, indexes, JSONB |
47
- | React Best Practices | `/react-best-practices` | React 19 performance, rendering |
48
- | Service Worker | `/service-worker` | PWA caching, push notifications |
49
- | TypeScript Conventions | `/typescript-conventions` | Strict config, patterns, best practices |
50
- | UI/UX Guidelines | `/ui-ux-guidelines` | Accessibility, layout, forms |
33
+ ### Skills (21)
34
+
35
+ | Skill | Slug | Domain |
36
+ | ---------------------- | ------------------------- | ------------------------------------------------- |
37
+ | BullMQ | `/bullmq` | Redis job queues, workers, flows, schedulers |
38
+ | Codebase Adapter | `/codebase-adapter` | Adapt plugin to your project on installation |
39
+ | Composition Patterns | `/composition-patterns` | React compound components, render props |
40
+ | Conventional Commits | `/conventional-commits` | Commit message spec, types, SemVer — with live staged diff |
41
+ | Core Web Vitals | `/core-web-vitals` | LCP, INP, CLS reference + HTML report generator |
42
+ | Debug | `/debug` | Full-stack debugging workflow, multi-agent triage |
43
+ | Docker | `/docker` | Dockerfiles, compose, optimization, security |
44
+ | Drizzle ORM | `/drizzle-pg` | PostgreSQL ORM schemas, queries, migrations |
45
+ | Execute Task | `/execute-task` | Orchestrate agents to implement a task file |
46
+ | Fastify Best Practices | `/fastify-best-practices` | Routes, plugins, hooks, validation |
47
+ | Generate PRD | `/generate-prd` | Product Requirements Documents from descriptions |
48
+ | Generate Task | `/generate-task` | Break PRD features into agent-ready task files |
49
+ | ioredis | `/ioredis` | Redis client, pipelines, Pub/Sub, Cluster |
50
+ | Next.js Best Practices | `/nextjs-best-practices` | App Router, RSC, data patterns |
51
+ | OWASP Security Review | `/owasp-security-review` | Top 10:2025 vulnerability checklist |
52
+ | PostgreSQL | `/postgresql` | Queries, schemas, indexes, JSONB |
53
+ | React Best Practices | `/react-best-practices` | React 19 performance, rendering |
54
+ | Service Worker | `/service-worker` | PWA caching, push notifications |
55
+ | TanStack Query | `/tanstack-query` | React Query v5, caching, SSR/hydration |
56
+ | TypeScript Conventions | `/typescript-conventions` | Strict config, patterns, best practices |
57
+ | UI/UX Guidelines | `/ui-ux-guidelines` | Accessibility, layout, forms |
51
58
 
52
59
  ---
53
60
 
54
- ## Installation
61
+ ## Workflow
62
+
63
+ This is the recommended end-to-end flow — from a blank project to a committed feature:
55
64
 
56
- ### Method 1: skills.sh (works with Claude Code, Cursor, Windsurf)
65
+ ### 1. Install the plugin
57
66
 
58
67
  ```bash
59
- # Install all skills
60
- npx skills add jgamaraalv/ts-dev-kit
68
+ /plugin marketplace add jgamaraalv/ts-dev-kit
69
+ /plugin install ts-dev-kit@ts-dev-kit
70
+ ```
61
71
 
62
- # List available skills
63
- npx skills add jgamaraalv/ts-dev-kit --list
72
+ ### 2. Adapt to your project (recommended)
64
73
 
65
- # Install a specific skill
66
- npx skills add jgamaraalv/ts-dev-kit --skill fastify-best-practices
74
+ Run once after installing to align agents and skills with your actual stack, package names, paths, and MCPs:
67
75
 
68
- # Install globally
69
- npx skills add jgamaraalv/ts-dev-kit --global
76
+ ```
77
+ /codebase-adapter
70
78
  ```
71
79
 
72
- > **Note:** skills.sh installs skills only, not agents.
80
+ The skill reads your `package.json`, lockfile, `.claude/agents/`, and MCP config, then surgically patches the plugin's agent and skill files to match your project — without touching any workflow logic.
81
+
82
+ ### 3. Define what to build
83
+
84
+ Generate a PRD from a description:
85
+
86
+ ```
87
+ /generate-prd Add a user notification system that sends emails and in-app alerts
88
+ ```
89
+
90
+ Then break it into agent-ready task files:
91
+
92
+ ```
93
+ /generate-task
94
+ ```
95
+
96
+ This produces structured task files with acceptance criteria, affected packages, quality gate commands, and a suggested agent.
97
+
98
+ ### 4. Execute the task
99
+
100
+ ```
101
+ /execute-task tasks/notifications-api.md
102
+ ```
103
+
104
+ The skill picks the right execution mode (single-agent or multi-agent), dispatches the appropriate agents, and runs quality gates (typecheck, lint, test) before declaring the task done.
73
105
 
74
- ### Method 2: Claude Code Plugin (agents + skills)
106
+ ### 5. Commit
107
+
108
+ ```
109
+ /conventional-commits
110
+ ```
111
+
112
+ The skill pre-injects your staged diff and the last 8 commits so Claude sees the actual changes before suggesting a message — no copy-pasting needed.
113
+
114
+ ---
115
+
116
+ ## Installation
117
+
118
+ ### Method 1: Claude Code Plugin (agents + skills)
75
119
 
76
120
  ```bash
77
121
  /plugin marketplace add jgamaraalv/ts-dev-kit
@@ -84,6 +128,21 @@ Or via CLI:
84
128
  claude plugin install ts-dev-kit --scope user
85
129
  ```
86
130
 
131
+ ### Method 2: skills.sh (skills only — works with Claude Code, Cursor, Windsurf)
132
+
133
+ ```bash
134
+ # Install all skills
135
+ npx skills add jgamaraalv/ts-dev-kit
136
+
137
+ # Install a specific skill
138
+ npx skills add jgamaraalv/ts-dev-kit --skill fastify-best-practices
139
+
140
+ # Install globally
141
+ npx skills add jgamaraalv/ts-dev-kit --global
142
+ ```
143
+
144
+ > **Note:** skills.sh installs skills only, not agents.
145
+
87
146
  ### Method 3: npm
88
147
 
89
148
  ```bash
@@ -104,12 +163,14 @@ claude --plugin-dir ./ts-dev-kit
104
163
 
105
164
  Some agents and skills reference external MCP tools for documentation lookup, browser debugging, E2E testing, and web fetching. These are **optional** — skills degrade gracefully without them — but installing them unlocks the full experience.
106
165
 
107
- | MCP Server | Used By | Purpose |
108
- | ------------- | ---------------------------------------- | ------------------------------------ |
109
- | context7 | Most skills (doc lookup) | Query up-to-date library docs |
110
- | playwright | playwright-expert, debugger, test-generator | Browser automation and E2E testing |
111
- | chrome-devtools | debugger | Frontend debugging, screenshots |
112
- | firecrawl | task skill | Web fetching and scraping |
166
+ | MCP Server | Used by | Purpose |
167
+ | --------------- | ------------------------------------------------ | ------------------------------------ |
168
+ | context7 | Most skills (doc lookup) | Query up-to-date library docs |
169
+ | playwright | playwright-expert, debugger, test-generator | Browser automation and E2E testing |
170
+ | chrome-devtools | debugger | Frontend debugging, screenshots |
171
+ | firecrawl | execute-task | Web fetching and scraping |
172
+ | sentry | debugger, debug skill | Error tracking and stack traces |
173
+ | posthog | debugger | User impact and error frequency |
113
174
 
114
175
  ### Installing as Claude Code plugins
115
176
 
@@ -136,26 +197,21 @@ claude mcp add firecrawl --env FIRECRAWL_API_KEY=your-key -- npx -y firecrawl-mc
136
197
 
137
198
  ---
138
199
 
139
- ## Customizing for Your Project
140
-
141
- This kit ships with a project orchestration template at `docs/rules/orchestration.md.template`. It defines quality gates, workspace commands, and dependency ordering that you can adapt to your own monorepo or project.
200
+ ## Dynamic Context Injection
142
201
 
143
- To use it:
202
+ Several skills use the `!`command`` syntax to pre-inject live data before Claude receives the prompt. This means Claude already has the real context when it starts — no manual copy-pasting required.
144
203
 
145
- 1. Copy the template into your project:
146
- ```bash
147
- cp node_modules/ts-dev-kit/docs/rules/orchestration.md.template \
148
- .claude/rules/orchestration.md
149
- ```
150
- 2. Open `.claude/rules/orchestration.md` and replace the `@myapp/*` placeholders with your actual workspace package names.
151
- 3. Update the dependency graph to match your monorepo structure.
152
- 4. Adjust the quality gate commands to match your project's tooling (e.g., swap `yarn` for `pnpm` or `npm`).
204
+ | Skill | What gets injected |
205
+ | ----- | ------------------ |
206
+ | `/conventional-commits` | Staged diff summary, full staged diff, last 8 commit messages |
207
+ | `/debug` | Last 10 git commits, working tree status |
208
+ | `/codebase-adapter` | Working directory, lockfile, installed agents, MCP servers, `package.json` |
153
209
 
154
210
  ---
155
211
 
156
212
  ## Tech Stack Covered
157
213
 
158
- TypeScript, Fastify 5, Next.js (App Router), React 19, PostgreSQL, Redis (ioredis), BullMQ, Drizzle ORM, Docker, Playwright, WCAG 2.1
214
+ TypeScript, Fastify 5, Next.js (App Router), React 19, PostgreSQL 16, Redis (ioredis), BullMQ, Drizzle ORM, TanStack Query v5, Docker, Playwright, Service Workers, Core Web Vitals, WCAG 2.1, OWASP Top 10:2025, Tailwind CSS v4
159
215
 
160
216
  ---
161
217
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@jgamaraalv/ts-dev-kit",
3
- "version": "2.3.0",
4
- "description": "Claude Code plugin: 13 agents + 16 skills for TypeScript fullstack development",
3
+ "version": "3.0.0",
4
+ "description": "Claude Code plugin: 15 agents + 21 skills for TypeScript fullstack development",
5
5
  "author": "jgamaraalv",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -0,0 +1,237 @@
1
+ ---
2
+ name: codebase-adapter
3
+ description: "Adapts ts-dev-kit plugin files to the host project where it is installed. Use when: (1) installing ts-dev-kit in a new project for the first time, (2) project tech stack or structure has changed, (3) agents reference wrong paths, unavailable skills, or missing MCPs, (4) the user says 'adapt the plugin', 'configure ts-dev-kit for this project', 'sync plugin to this codebase', or 'update plugin context'. Surgically edits specific sections in plugin skills and agent definitions — domain area tables, skill/MCP references, quality gate commands, project paths, and package names — without touching any workflow logic, execution protocols, or dispatch patterns."
4
+ disable-model-invocation: true
5
+ argument-hint: "[optional: path to project root — defaults to current directory]"
6
+ allowed-tools: Bash(ls *), Bash(cat *), Bash(node *), Bash(python3 *)
7
+ ---
8
+
9
+ <system>
10
+ You are a plugin configuration specialist. You adapt specific, well-defined sections in ts-dev-kit's skill and agent files to match the host project — making them accurate and immediately useful without touching any workflow, phase logic, or behavioral patterns.
11
+ </system>
12
+
13
+ <context>
14
+ **User-provided path:** $ARGUMENTS
15
+
16
+ **Pre-injected project snapshot (verify in phase 2 — do not skip discovery):**
17
+
18
+ Working directory: !`pwd`
19
+
20
+ Lockfile detected: !`ls bun.lock pnpm-lock.yaml yarn.lock package-lock.json 2>/dev/null | head -1 || echo "none"`
21
+
22
+ Agents installed: !`ls .claude/agents/ 2>/dev/null | tr '\n' ' ' || echo "(not found)"`
23
+
24
+ MCP servers configured: !`python3 -c "import json; s=json.load(open('.claude/settings.json')); print(', '.join(s.get('mcpServers',{}).keys()) or '(none)')" 2>/dev/null || echo "(not found)"`
25
+
26
+ package.json:
27
+ !`cat package.json 2>/dev/null || echo "(not found)"`
28
+ </context>
29
+
30
+ <boundaries>
31
+ **You MAY edit:**
32
+ - `<domain_areas>` table in `execute-task` — agent names and key skills per sub-area
33
+ - `<skill_map>` in `execute-task` — which skills map to which sub-areas
34
+ - `<available_mcps>` in `execute-task` — only MCPs actually configured in this project
35
+ - `skills:` frontmatter list in agent definitions
36
+ - Quality gate command examples in agent bodies (e.g., `yarn workspace @myapp/api test`)
37
+ - Project path references in agent bodies (e.g., `apps/api/src/routes/`)
38
+ - Package name references in agent bodies (e.g., `@myapp/api`, `@myapp/shared`)
39
+ - Tech-specific import/version notes in agent bodies (Zod v3 vs v4, ESM flag)
40
+ - Workspace command pattern in `generate-task` (e.g., `yarn workspace <name>` → `pnpm --filter <name>`)
41
+
42
+ **You MUST NOT change:**
43
+ - Any `<phase_*>` logic or step sequences
44
+ - Dispatch protocols, decomposition rules, execution mode decisions
45
+ - Core agent principles, role descriptions, or behavior narratives
46
+ - Output template formats or section headers
47
+ - Skill descriptions or their trigger conditions
48
+ - XML tag structures (`<workflow>`, `<domain_areas>`, `<skill_map>`, etc.)
49
+ </boundaries>
50
+
51
+ <workflow>
52
+
53
+ <phase_1_locate_plugin>
54
+ Find the plugin root. Try in order:
55
+ 1. `skills/execute-task/SKILL.md` exists in current directory → user is inside the ts-dev-kit repo.
56
+ 2. `node_modules/@jgamaraalv/ts-dev-kit/` → installed via npm.
57
+ 3. Search upward and in siblings for a directory containing `plugin.json` with `"name": "ts-dev-kit"`.
58
+
59
+ Store the resolved plugin root. All edits in phases 3–5 use paths relative to it.
60
+ </phase_1_locate_plugin>
61
+
62
+ <phase_2_project_discovery>
63
+ Determine the target project root (`$ARGUMENTS` if provided, otherwise current working directory).
64
+
65
+ Discover with Read, Glob, Grep — verify everything, assume nothing.
66
+
67
+ **Package manager** — detect from lockfile: `bun.lock` → bun, `pnpm-lock.yaml` → pnpm, `yarn.lock` → yarn, `package-lock.json` → npm.
68
+
69
+ **Monorepo** — check for `workspaces` in `package.json`, `pnpm-workspace.yaml`, or `turbo.json`. Record workspace names and their paths.
70
+
71
+ **Tech stack** — read `package.json` dependencies in root and each workspace:
72
+ - HTTP framework: Fastify, Express, Hono, Elysia, or none
73
+ - ORM/DB: Drizzle, Prisma, Kysely + database type (PostgreSQL, MySQL, SQLite)
74
+ - Frontend: Next.js (detect App Router via `app/` directory), Vite + React, or none
75
+ - Validation: Zod (check version — v3 imports `from "zod"`, v4 imports `from "zod/v4"`), Valibot
76
+ - Queue: BullMQ, or none
77
+ - Cache: ioredis, @upstash/redis, or none
78
+ - Testing: Vitest or Jest; Playwright or Cypress
79
+ - Docker: check for `Dockerfile` or `docker-compose.yml`
80
+
81
+ **Project paths** (verify with Glob — record exact paths):
82
+ - Backend source root (e.g., `apps/api/src/`, `src/`)
83
+ - Routes/handlers directory
84
+ - DB schema + migrations directory
85
+ - DB client file (search for database connection setup)
86
+ - Redis client file (search for Redis instantiation)
87
+ - Frontend source root (e.g., `apps/web/`, `src/`)
88
+ - Shared package: directory path and package name (e.g., `packages/shared/`, `@acme/shared`)
89
+
90
+ **Quality gates** — read `scripts` from each workspace's `package.json`:
91
+ - typecheck, lint, test, build command names
92
+ - Compose the full run command per workspace (e.g., `pnpm --filter @acme/api typecheck`)
93
+
94
+ **Available skills** — list directories in `[plugin-root]/skills/`
95
+
96
+ **Available agents** — list files in `[plugin-root]/.claude/agents/`
97
+
98
+ **Available MCPs** — read `.claude/settings.json` in project root (and `~/.claude/settings.json` as fallback). Extract `mcpServers` keys.
99
+ </phase_2_project_discovery>
100
+
101
+ <phase_3_adapt_execute_task>
102
+ Edit `[plugin-root]/skills/execute-task/SKILL.md`.
103
+
104
+ **`<domain_areas>` block (lines between the opening and closing tags)**
105
+
106
+ Rebuild the Backend and Frontend tables:
107
+ - "Agent type" column: only include agents whose `.md` file exists in `[plugin-root]/.claude/agents/`
108
+ - "Key skills" column: only include skills whose directory exists in `[plugin-root]/skills/` AND are relevant to the discovered tech stack
109
+ - Remove rows for sub-areas with no matching tech (e.g., remove "Queues" row if BullMQ is absent; remove "Pages/routing" row if no frontend framework is detected)
110
+ - Keep the "When" column text unchanged
111
+ - Keep the surrounding narrative text and the Cross-cutting specialists table unchanged
112
+
113
+ **`<skill_map>` block**
114
+
115
+ Update each sub-area's skill list:
116
+ - Remove skills not present in `[plugin-root]/skills/`
117
+ - Remove skills not relevant to discovered tech (e.g., remove `/bullmq` if BullMQ not installed)
118
+ - Keep the exact slash-command format (e.g., `/drizzle-pg`, `/fastify-best-practices`)
119
+
120
+ **`<available_mcps>` block**
121
+
122
+ Replace the bullet list with only MCPs found in `mcpServers`. Keep the same format: `- [name] — [one-line purpose]`. If context7 is configured, always keep its usage instructions below the list intact.
123
+
124
+ **`<required_skills>` example block**
125
+
126
+ Update the example `Skill()` calls to reflect the project's actual primary backend skills (e.g., replace `fastify-best-practices` if Fastify is not the framework).
127
+ </phase_3_adapt_execute_task>
128
+
129
+ <phase_4_adapt_agents>
130
+ For each file in `[plugin-root]/.claude/agents/`:
131
+
132
+ **`skills:` frontmatter list**
133
+ Remove skills not installed in `[plugin-root]/skills/` or not relevant to the discovered tech stack. Do not add skills not already listed. If all skills remain valid, skip this file.
134
+
135
+ **Quality gate command examples**
136
+ Find patterns like `yarn workspace @myapp/api test` or `yarn workspace @myapp/api tsc`. Replace with the actual workspace run command composed in phase 2. Use real workspace package names where known.
137
+
138
+ **Project path references**
139
+ Find and replace generic placeholder paths with actual discovered paths:
140
+ | Placeholder | Replace with |
141
+ |-------------|-------------|
142
+ | `apps/api/src/` | actual backend source root |
143
+ | `apps/api/src/routes/` | actual routes directory |
144
+ | `apps/api/src/lib/db.ts` | actual DB client file path |
145
+ | `apps/api/src/lib/redis.ts` | actual Redis client file path |
146
+ | `packages/shared/src/` | actual shared package source path |
147
+
148
+ **Package name references**
149
+ Replace placeholder names with actual package names:
150
+ | Placeholder | Replace with |
151
+ |-------------|-------------|
152
+ | `@myapp/api` | actual API workspace package name |
153
+ | `@myapp/shared` | actual shared workspace package name |
154
+
155
+ **Tech-specific notes**
156
+ - Zod import: update to match discovered version (`from "zod"` for v3, `from "zod/v4"` for v4)
157
+ - ESM flag: match `"type": "module"` presence in the workspace's `package.json`
158
+
159
+ Skip any agent where none of the above patterns are found — do not force edits.
160
+ </phase_4_adapt_agents>
161
+
162
+ <phase_5_adapt_generate_task>
163
+ Edit `[plugin-root]/skills/generate-task/SKILL.md`.
164
+
165
+ Find the workspace command pattern example (text like `yarn workspace <name> <script>`, `pnpm --filter <name> <script>`). Replace all occurrences with the actual package manager syntax discovered in phase 2. Use `<name>` and `<script>` as placeholders where the real values would vary.
166
+ </phase_5_adapt_generate_task>
167
+
168
+ <phase_6_update_claude_md>
169
+ Append a "## Claude Code Workflow Architecture" section to the project's `CLAUDE.md` (located at the project root). If `CLAUDE.md` does not exist, create it with only this section. If the section already exists, replace it in-place with the updated version.
170
+
171
+ Use the data already gathered in phases 1–2 to fill in the values:
172
+
173
+ **Agent count** — count `.md` files in the project's `.claude/agents/` directory (this includes both plugin-installed agents and any locally defined agents).
174
+
175
+ **Skill count** — count directories in the project's `.claude/skills/` directory (this includes both plugin-installed skills and any locally defined skills).
176
+
177
+ **agent-memory** — check whether `agent-memory/` exists at the project root. If it does, count its subdirectories and note which agents are excluded (agents without a matching subdirectory).
178
+
179
+ **Paths** — use the actual plugin-root-relative paths discovered in phase 2 (e.g., real `skills/`, `agents/`, `.claude/` locations).
180
+
181
+ Generate the section using this template, substituting bracketed placeholders with real values:
182
+
183
+ ```markdown
184
+ ## Claude Code Workflow Architecture
185
+
186
+ ### Content Layout
187
+
188
+ \`\`\`
189
+ .claude/
190
+ agents/ ← [AGENT_COUNT] agent definitions (markdown, YAML frontmatter)
191
+ skills/ ← [SKILL_COUNT] skill directories (symlinked from skills/)
192
+ settings.local.json ← Permission allowlist for Claude Code
193
+
194
+ .claude-plugin/
195
+ plugin.json ← Claude Code plugin manifest
196
+ marketplace.json ← Marketplace listing metadata
197
+
198
+ agents/ ← Published copy of .claude/agents (included in npm package)
199
+ [AGENT_MEMORY_LINE]
200
+ skills/ ← [SKILL_COUNT] skill directories (each has SKILL.md + optional references/ and scripts/)
201
+ \`\`\`
202
+
203
+ ### Agent Definitions (\`.claude/agents/*.md\`)
204
+
205
+ Each agent is a single markdown file with YAML frontmatter:
206
+
207
+ \`\`\`yaml
208
+ ---
209
+ name: agent-name
210
+ color: named-color # Visual identification in Claude Code UI
211
+ description: "..."
212
+ skills: # Optional — skills loaded when agent is invoked
213
+ - skill-slug
214
+ ---
215
+ \`\`\`
216
+
217
+ Body contains: role description, core principles, workflow steps, quality gates, output format, and a reference to \`agent-memory/<name>/MEMORY.md\`.
218
+
219
+ ### Skill Definitions (\`skills/<name>/\`)
220
+
221
+ Each skill directory contains:
222
+ - \`SKILL.md\` — main content with YAML frontmatter (\`name\`, \`description\`, optional \`argument-hint\`, optional \`allowed-tools\`)
223
+ - \`references/\` — deep-dive sub-files linked from SKILL.md
224
+ - \`scripts/\` — optional executables Claude can run (Python, bash) for visual output or automation
225
+ ```
226
+
227
+ Where `[AGENT_MEMORY_LINE]` is:
228
+ - If `agent-memory/` exists: `agent-memory/ ← [SUBDIR_COUNT] persistent memory directories (one per agent[EXCLUSION_NOTE])`
229
+ - `[EXCLUSION_NOTE]` = `, excluded: [list agents without a subdirectory]` if any are missing, otherwise omit
230
+ - If `agent-memory/` does not exist: omit that line entirely
231
+ </phase_6_update_claude_md>
232
+
233
+ <phase_7_report>
234
+ Produce the completion report using the template in [template.md](template.md).
235
+ </phase_7_report>
236
+
237
+ </workflow>
@@ -0,0 +1,25 @@
1
+ ## Codebase Adapter — Completed
2
+
3
+ **Project**: [name] | [monorepo / single package] | [package manager]
4
+ **Plugin root**: [resolved path]
5
+
6
+ ### Files edited
7
+ | File | Sections changed |
8
+ |------|-----------------|
9
+ | skills/execute-task/SKILL.md | domain_areas, skill_map, available_mcps |
10
+ | .claude/agents/api-builder.md | paths, package names, quality gates |
11
+ | ... | ... |
12
+
13
+ ### Files skipped
14
+ | File | Reason |
15
+ |------|--------|
16
+ | .claude/agents/docker-expert.md | No Docker files found |
17
+ | ... | ... |
18
+
19
+ ### Discoveries
20
+ - **Backend**: [framework] at [path], package [name]
21
+ - **Frontend**: [framework] at [path], package [name]
22
+ - **Shared**: [name] at [path]
23
+ - **Quality gates**: [pm] commands — [typecheck / lint / test / build]
24
+ - **MCPs configured**: [list or "none"]
25
+ - **Skills available**: [N] skills | **Agents available**: [N] agents
@@ -1,8 +1,20 @@
1
1
  ---
2
2
  name: conventional-commits
3
3
  description: "Write, review, and validate commit messages following the Conventional Commits v1.0.0 specification. Use when: (1) crafting a git commit message for any change, (2) reviewing or correcting an existing commit message, (3) choosing the right commit type for a change, (4) deciding how to mark a breaking change, (5) writing multi-line commits with body and footers, or (6) understanding how commits map to SemVer bumps (PATCH/MINOR/MAJOR). Covers all standard types: feat, fix, docs, chore, refactor, perf, test, build, ci, style, revert."
4
+ allowed-tools: Bash(git *)
4
5
  ---
5
6
 
7
+ <live_context>
8
+ **Staged changes (summary):**
9
+ !`git diff --cached --stat 2>/dev/null || echo "(nothing staged)"`
10
+
11
+ **Staged diff:**
12
+ !`git diff --cached 2>/dev/null | head -300 || echo "(nothing staged)"`
13
+
14
+ **Recent commits (style reference):**
15
+ !`git log --oneline -8 2>/dev/null || echo "(no commits yet)"`
16
+ </live_context>
17
+
6
18
  ## Table of Contents
7
19
 
8
20
  - [Format](#format)