@softspark/ai-toolkit 1.2.1 → 1.3.1

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 (143) hide show
  1. package/AGENTS.md +5 -29
  2. package/CHANGELOG.md +31 -0
  3. package/README.md +114 -17
  4. package/app/.claude-plugin/plugin.json +1 -1
  5. package/app/ARCHITECTURE.md +35 -19
  6. package/app/agents/ai-engineer.md +47 -5
  7. package/app/agents/fact-checker.md +1 -1
  8. package/app/agents/llm-ops-engineer.md +2 -2
  9. package/app/agents/{mcp-server-architect.md → mcp-specialist.md} +124 -18
  10. package/app/agents/mcp-testing-engineer.md +2 -2
  11. package/app/agents/nlp-engineer.md +1 -1
  12. package/app/agents/orchestrator.md +3 -4
  13. package/app/agents/project-planner.md +1 -1
  14. package/app/agents/technical-researcher.md +71 -21
  15. package/app/hooks/commit-quality.sh +53 -0
  16. package/app/hooks/governance-capture.sh +77 -0
  17. package/app/hooks/guard-config.sh +46 -0
  18. package/app/hooks/mcp-health.sh +53 -0
  19. package/app/hooks/pre-compact-save.sh +34 -0
  20. package/app/hooks/session-context.sh +60 -0
  21. package/app/hooks.json +60 -0
  22. package/app/mcp-templates/README.md +105 -0
  23. package/app/mcp-templates/brave-search.json +13 -0
  24. package/app/mcp-templates/cloudflare.json +14 -0
  25. package/app/mcp-templates/context7.json +10 -0
  26. package/app/mcp-templates/custom-template.json +13 -0
  27. package/app/mcp-templates/datadog.json +15 -0
  28. package/app/mcp-templates/docker.json +10 -0
  29. package/app/mcp-templates/fetch.json +10 -0
  30. package/app/mcp-templates/filesystem.json +10 -0
  31. package/app/mcp-templates/git.json +10 -0
  32. package/app/mcp-templates/github.json +13 -0
  33. package/app/mcp-templates/google-drive.json +15 -0
  34. package/app/mcp-templates/google-maps.json +13 -0
  35. package/app/mcp-templates/grafana.json +14 -0
  36. package/app/mcp-templates/linear.json +13 -0
  37. package/app/mcp-templates/memory.json +10 -0
  38. package/app/mcp-templates/notion.json +13 -0
  39. package/app/mcp-templates/postgres.json +10 -0
  40. package/app/mcp-templates/puppeteer.json +10 -0
  41. package/app/mcp-templates/redis.json +13 -0
  42. package/app/mcp-templates/sentry.json +14 -0
  43. package/app/mcp-templates/sequential-thinking.json +10 -0
  44. package/app/mcp-templates/slack.json +14 -0
  45. package/app/mcp-templates/sqlite.json +10 -0
  46. package/app/mcp-templates/supabase.json +14 -0
  47. package/app/mcp-templates/vercel.json +13 -0
  48. package/app/plugins/research-pack/README.md +1 -1
  49. package/app/plugins/research-pack/plugin.json +1 -1
  50. package/app/rules/claude-toolkit-rules.md +1 -1
  51. package/app/rules/common/coding-style.md +52 -0
  52. package/app/rules/common/git-workflow.md +45 -0
  53. package/app/rules/common/performance.md +49 -0
  54. package/app/rules/common/security.md +59 -0
  55. package/app/rules/common/testing.md +53 -0
  56. package/app/rules/cpp/coding-style.md +55 -0
  57. package/app/rules/cpp/frameworks.md +55 -0
  58. package/app/rules/cpp/patterns.md +57 -0
  59. package/app/rules/cpp/security.md +61 -0
  60. package/app/rules/cpp/testing.md +58 -0
  61. package/app/rules/csharp/coding-style.md +54 -0
  62. package/app/rules/csharp/frameworks.md +60 -0
  63. package/app/rules/csharp/patterns.md +61 -0
  64. package/app/rules/csharp/security.md +60 -0
  65. package/app/rules/csharp/testing.md +58 -0
  66. package/app/rules/dart/coding-style.md +61 -0
  67. package/app/rules/dart/frameworks.md +59 -0
  68. package/app/rules/dart/patterns.md +62 -0
  69. package/app/rules/dart/security.md +60 -0
  70. package/app/rules/dart/testing.md +60 -0
  71. package/app/rules/golang/coding-style.md +50 -0
  72. package/app/rules/golang/frameworks.md +56 -0
  73. package/app/rules/golang/patterns.md +52 -0
  74. package/app/rules/golang/security.md +61 -0
  75. package/app/rules/golang/testing.md +54 -0
  76. package/app/rules/java/coding-style.md +56 -0
  77. package/app/rules/java/frameworks.md +54 -0
  78. package/app/rules/java/patterns.md +59 -0
  79. package/app/rules/java/security.md +60 -0
  80. package/app/rules/java/testing.md +55 -0
  81. package/app/rules/kotlin/coding-style.md +56 -0
  82. package/app/rules/kotlin/frameworks.md +54 -0
  83. package/app/rules/kotlin/patterns.md +54 -0
  84. package/app/rules/kotlin/security.md +62 -0
  85. package/app/rules/kotlin/testing.md +56 -0
  86. package/app/rules/php/coding-style.md +53 -0
  87. package/app/rules/php/frameworks.md +57 -0
  88. package/app/rules/php/patterns.md +63 -0
  89. package/app/rules/php/security.md +61 -0
  90. package/app/rules/php/testing.md +60 -0
  91. package/app/rules/python/coding-style.md +52 -0
  92. package/app/rules/python/frameworks.md +53 -0
  93. package/app/rules/python/patterns.md +53 -0
  94. package/app/rules/python/security.md +58 -0
  95. package/app/rules/python/testing.md +52 -0
  96. package/app/rules/ruby/coding-style.md +56 -0
  97. package/app/rules/ruby/frameworks.md +56 -0
  98. package/app/rules/ruby/patterns.md +61 -0
  99. package/app/rules/ruby/security.md +61 -0
  100. package/app/rules/ruby/testing.md +63 -0
  101. package/app/rules/rust/coding-style.md +52 -0
  102. package/app/rules/rust/frameworks.md +59 -0
  103. package/app/rules/rust/patterns.md +58 -0
  104. package/app/rules/rust/security.md +64 -0
  105. package/app/rules/rust/testing.md +54 -0
  106. package/app/rules/swift/coding-style.md +55 -0
  107. package/app/rules/swift/frameworks.md +63 -0
  108. package/app/rules/swift/patterns.md +63 -0
  109. package/app/rules/swift/security.md +63 -0
  110. package/app/rules/swift/testing.md +60 -0
  111. package/app/rules/typescript/coding-style.md +51 -0
  112. package/app/rules/typescript/frameworks.md +51 -0
  113. package/app/rules/typescript/patterns.md +51 -0
  114. package/app/rules/typescript/security.md +55 -0
  115. package/app/rules/typescript/testing.md +52 -0
  116. package/app/skills/app-builder/SKILL.md +1 -1
  117. package/app/skills/brand-voice/SKILL.md +92 -0
  118. package/app/skills/council/SKILL.md +133 -0
  119. package/app/skills/introspect/SKILL.md +125 -0
  120. package/bin/ai-toolkit.js +103 -2
  121. package/kb/reference/agents-catalog.md +10 -13
  122. package/kb/reference/architecture-overview.md +29 -6
  123. package/kb/reference/commands-catalog.md +4 -4
  124. package/kb/reference/competitive-features-implementation.md +677 -0
  125. package/kb/reference/extension-api.md +175 -0
  126. package/kb/reference/hooks-catalog.md +90 -14
  127. package/kb/reference/language-rules.md +167 -0
  128. package/kb/reference/manifest-install.md +165 -0
  129. package/kb/reference/mcp-templates.md +110 -0
  130. package/kb/reference/skills-catalog.md +9 -6
  131. package/llms-full.txt +1511 -59
  132. package/llms.txt +8 -3
  133. package/package.json +2 -2
  134. package/scripts/inject_hook_cli.py +330 -0
  135. package/scripts/install.py +241 -7
  136. package/scripts/install_steps/ai_tools.py +63 -1
  137. package/scripts/install_steps/detect_language.py +50 -0
  138. package/scripts/install_steps/install_state.py +117 -0
  139. package/scripts/install_steps/symlinks.py +20 -0
  140. package/scripts/mcp_manager.py +206 -0
  141. package/app/agents/mcp-expert.md +0 -228
  142. package/app/agents/rag-engineer.md +0 -201
  143. package/app/agents/research-synthesizer.md +0 -138
package/AGENTS.md CHANGED
@@ -36,7 +36,7 @@ gemini --system "$(cat .claude/agents/backend-specialist.md)" "implement the API
36
36
 
37
37
  ### `ai-engineer`
38
38
 
39
- AI/ML integration specialist. Use for LLM integration, vector databases, RAG pipelines, embeddings, and AI agent orchestration. Triggers: ai, ml, llm, embedding, vector, rag, agent, openai, anthropic.
39
+ AI/ML integration specialist. Use for LLM integration, vector databases, RAG pipelines, embeddings, AI agent orchestration, document indexing, semantic search, hybrid retrieval, and answer generation. Triggers: ai, ml, llm, embedding, vector, rag, agent, openai, anthropic, search, retrieval, indexing, chunking, reranking.
40
40
 
41
41
  **Tools:** `Read, Write, Edit, Bash, Grep, Glob`
42
42
 
@@ -210,19 +210,11 @@ LLM operations expert. Use for LLM caching, fallback strategies, cost optimizati
210
210
 
211
211
  ---
212
212
 
213
- ### `mcp-expert`
213
+ ### `mcp-specialist`
214
214
 
215
- MCP integration expert. Use for configuring MCP clients, integrations, troubleshooting MCP connections. Triggers: mcp config, mcp integration, mcp connection, claude desktop, mcp client.
215
+ MCP server design, implementation, client configuration, and integration troubleshooting. Triggers: mcp, model context protocol, json-rpc, sse, stdio, mcp server, mcp config, mcp integration, mcp connection, claude desktop, mcp client.
216
216
 
217
- **Tools:** `Read, Write, Edit, Bash`
218
-
219
- ---
220
-
221
- ### `mcp-server-architect`
222
-
223
- MCP server design and implementation expert. Use for creating MCP servers, JSON-RPC transport, tool definitions, protocol compliance. Triggers: mcp, model context protocol, json-rpc, sse, stdio, mcp server.
224
-
225
- **Tools:** `Read, Write, Edit, Bash`
217
+ **Tools:** `Read, Write, Edit, Bash, Grep, Glob`
226
218
 
227
219
  ---
228
220
 
@@ -330,22 +322,6 @@ Test automation and QA specialist. Use for E2E testing, API testing, performance
330
322
 
331
323
  ---
332
324
 
333
- ### `rag-engineer`
334
-
335
- RAG systems expert. Use for document indexing, semantic search, hybrid retrieval, CRAG, multi-hop reasoning, and answer generation. Triggers: rag, search, retrieval, indexing, embedding, vector, chunking, reranking.
336
-
337
- **Tools:** `Read, Write, Edit, Bash`
338
-
339
- ---
340
-
341
- ### `research-synthesizer`
342
-
343
- Multi-source research coordination and synthesis specialist. Trigger words: synthesize, aggregate, report, executive summary, gap analysis, conflict resolution, findings, research, investigate, multi-source, cross-reference, research planning
344
-
345
- **Tools:** `Read, Write, Edit, Bash, Grep, Glob`
346
-
347
- ---
348
-
349
325
  ### `search-specialist`
350
326
 
351
327
  Information retrieval and search optimization specialist. Trigger words: search, query, semantic search, information retrieval, relevance, ranking, search optimization
@@ -396,7 +372,7 @@ Technical authority for code quality, architecture patterns, and stack decisions
396
372
 
397
373
  ### `technical-researcher`
398
374
 
399
- Deep technical investigation specialist. Trigger words: technical research, feasibility study, root cause analysis, API investigation, compatibility research, comparison matrix
375
+ Deep technical investigation and multi-source research synthesis specialist. Trigger words: technical research, feasibility study, root cause analysis, API investigation, compatibility research, comparison matrix, synthesize, aggregate, report, executive summary, gap analysis, findings, multi-source, cross-reference
400
376
 
401
377
  **Tools:** `Read, Write, Edit, Bash, Grep, Glob`
402
378
 
package/CHANGELOG.md CHANGED
@@ -7,6 +7,37 @@ Versioning follows [Semantic Versioning](https://semver.org/).
7
7
 
8
8
  ---
9
9
 
10
+ ## v1.3.1 — Patch (2026-04-07)
11
+
12
+ ### Fixed
13
+ - **Orphaned symlinks**: `install` and `update` now auto-clean broken agent/skill symlinks when components are removed or merged. Previously required manual `doctor --fix`.
14
+ - **`--auto-detect` without `--local`**: Now auto-adds `--local` with warning instead of scanning `$HOME` for language markers.
15
+ - **Session hooks concurrency**: `session-context.sh` writes per-session file (`${SESSION_ID}.json`) instead of single `current-context.json`. `pre-compact-save.sh` includes session ID in filename to avoid collisions.
16
+ - **Language rules injection**: `install --local --auto-detect` now actually injects detected language rules into project `.claude/CLAUDE.md` via `<!-- TOOLKIT:language-rules -->` markers.
17
+
18
+ ---
19
+
20
+ ## v1.3.0 — Competitive Features Release (2026-04-07)
21
+
22
+ ### Added
23
+ - **Language Rules System**: 70 language-specific coding rules across 13 languages (TypeScript, Python, Go, Rust, Java, Kotlin, Swift, Dart, C#, PHP, C++, Ruby) + 5 common rules. 5 categories per language: coding-style, testing, patterns, frameworks, security.
24
+ - **MCP Templates**: 25 ready-to-use MCP server configuration templates (GitHub, PostgreSQL, Slack, Sentry, Context7, etc.) with CLI management (`ai-toolkit mcp add/list/show/remove`).
25
+ - **Extension API**: `inject-hook` / `remove-hook` commands for external tools to inject hooks into settings.json with unique `_source` tags. Parallels existing `inject-rule` / `remove-rule`.
26
+ - **Manifest-Driven Install**: Module-level install granularity (`--modules`), language auto-detection (`--auto-detect`), install state tracking (`~/.ai-toolkit/state.json`), `status` and `update` commands.
27
+ - **6 new hooks**: `guard-config.sh` (config file protection), `mcp-health.sh` (MCP server health check), `governance-capture.sh` (security audit logging), `commit-quality.sh` (conventional commits advisory), `session-context.sh` (environment snapshot), `pre-compact-save.sh` (pre-compaction backup).
28
+ - **`/council` skill**: 4-perspective decision evaluation (Advocate, Critic, Pragmatist, User-Proxy) for architectural decisions.
29
+ - **`/introspect` skill**: Agent self-debugging with 7 failure pattern classification and recovery actions.
30
+ - **`brand-voice` knowledge skill**: Anti-trope list preventing generic LLM rhetoric, auto-loaded when writing documentation.
31
+ - **KB reference docs**: extension-api.md, language-rules.md, mcp-templates.md, manifest-install.md.
32
+
33
+ ### Changed
34
+ - Agent count: 47 → 44 (merged 3 overlapping pairs: rag-engineer into ai-engineer, research-synthesizer into technical-researcher, mcp-expert + mcp-server-architect into mcp-specialist)
35
+ - Hook count: 14 → 20 global hooks across 12 lifecycle events
36
+ - Skill count: 87 → 90 (28 task + 30 hybrid + 32 knowledge)
37
+ - Updated hooks-catalog.md, skills-catalog.md with new entries
38
+
39
+ ---
40
+
10
41
  ## [1.2.1] - 2026-04-03
11
42
 
12
43
  ### Changed
package/README.md CHANGED
@@ -1,12 +1,12 @@
1
1
  # ai-toolkit
2
2
 
3
- > Professional-grade AI coding toolkit with multi-platform support. Machine-enforced safety, 87 skills, 47 agents, expanded lifecycle hooks, persona presets, experimental opt-in plugin packs, and benchmark tooling — works with Claude, Cursor, Windsurf, Copilot, Gemini, Cline, Roo Code, Aider, and Augment, ready in 60 seconds.
3
+ > Professional-grade AI coding toolkit with multi-platform support. Machine-enforced safety, 90 skills, 44 agents, expanded lifecycle hooks, persona presets, experimental opt-in plugin packs, and benchmark tooling — works with Claude, Cursor, Windsurf, Copilot, Gemini, Cline, Roo Code, Aider, and Augment, ready in 60 seconds.
4
4
 
5
5
  [![CI](https://github.com/softspark/ai-toolkit/actions/workflows/ci.yml/badge.svg)](https://github.com/softspark/ai-toolkit/actions/workflows/ci.yml)
6
6
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)
7
- [![Skills](https://img.shields.io/badge/skills-87-brightgreen)](app/skills/)
8
- [![Agents](https://img.shields.io/badge/agents-47-blue)](app/agents/)
9
- [![Tests](https://img.shields.io/badge/tests-310%20passing-success)](tests/)
7
+ [![Skills](https://img.shields.io/badge/skills-90-brightgreen)](app/skills/)
8
+ [![Agents](https://img.shields.io/badge/agents-44-blue)](app/agents/)
9
+ [![Tests](https://img.shields.io/badge/tests-327%20passing-success)](tests/)
10
10
 
11
11
  ---
12
12
 
@@ -21,7 +21,7 @@ ai-toolkit install
21
21
  npx @softspark/ai-toolkit install
22
22
  ```
23
23
 
24
- **That's it.** Claude Code picks up 87 skills, 47 agents, quality hooks, and the safety constitution automatically.
24
+ **That's it.** Claude Code picks up 90 skills, 44 agents, quality hooks, and the safety constitution automatically.
25
25
 
26
26
  ### Update
27
27
 
@@ -133,10 +133,10 @@ Replaces all symlinks with real files, inlines rules into CLAUDE.md, copies cons
133
133
  | Component | Count | Description |
134
134
  |-----------|-------|-------------|
135
135
  | `skills/` (task) | 28 | Slash commands: `/commit`, `/build`, `/deploy`, `/test`, `/skill-audit`, ... |
136
- | `skills/` (hybrid) | 28 | Slash commands with agent knowledge base |
137
- | `skills/` (knowledge) | 31 | Domain knowledge auto-loaded by agents |
138
- | `agents/` | 47 | Specialized agents across 10 categories |
139
- | `hooks/` | 15 global + 5 skill-scoped | Quality gates, path safety, CLAUDE.md enforcement, notifications, prompt governance, subagent lifecycle, session-end handoff, usage tracking |
136
+ | `skills/` (hybrid) | 30 | Slash commands with agent knowledge base |
137
+ | `skills/` (knowledge) | 32 | Domain knowledge auto-loaded by agents |
138
+ | `agents/` | 44 | Specialized agents across 10 categories |
139
+ | `hooks/` | 21 global + 5 skill-scoped | Quality gates, path safety, CLAUDE.md enforcement, notifications, prompt governance, subagent lifecycle, session-end handoff, usage tracking, config protection, MCP health, governance audit |
140
140
  | `plugins/` | 11 experimental opt-in packs | Domain bundles for security, research, frontend, enterprise, and 6 language packs (not part of the default install) |
141
141
  | `output-styles/` | 1 style | System prompt output style overrides (e.g. Golden Rules) |
142
142
  | `constitution.md` | 5 articles | Machine-enforced safety rules |
@@ -150,21 +150,22 @@ Replaces all symlinks with real files, inlines rules into CLAUDE.md, copies cons
150
150
  ```
151
151
  ai-toolkit/
152
152
  ├── app/
153
- │ ├── agents/ # 47 agent definitions
153
+ │ ├── agents/ # 44 agent definitions
154
154
  │ │ ├── orchestrator.md
155
155
  │ │ ├── backend-specialist.md
156
156
  │ │ ├── security-architect.md
157
- │ │ └── ... (44 more)
158
- │ ├── skills/ # 87 skills (task / hybrid / knowledge)
157
+ │ │ └── ... (41 more)
158
+ │ ├── skills/ # 90 skills (task / hybrid / knowledge)
159
159
  │ │ ├── commit/ # /commit slash command
160
160
  │ │ ├── review/ # /review slash command
161
161
  │ │ ├── clean-code/ # knowledge skill (auto-loaded)
162
- │ │ └── ... (82 more)
162
+ │ │ └── ... (87 more)
163
163
  │ ├── rules/ # Auto-injected into your CLAUDE.md
164
164
  │ ├── hooks/ # Hook scripts (copied to ~/.ai-toolkit/hooks/)
165
165
  │ │ ├── session-start.sh # MANDATORY reminder + session context
166
166
  │ │ ├── guard-destructive.sh # Block rm -rf, DROP TABLE, etc.
167
167
  │ │ ├── guard-path.sh # Block wrong-user path hallucination
168
+ │ │ ├── guard-config.sh # Block edits to linter/formatter configs
168
169
  │ │ ├── user-prompt-submit.sh # Prompt governance reminder
169
170
  │ │ ├── quality-check.sh # Multi-language lint on stop
170
171
  │ │ ├── quality-gate.sh # Block task completion on errors
@@ -172,8 +173,13 @@ ai-toolkit/
172
173
  │ │ ├── subagent-start.sh # Subagent scope reminder
173
174
  │ │ ├── subagent-stop.sh # Subagent completion checklist
174
175
  │ │ ├── pre-compact.sh # Save context before compaction
176
+ │ │ ├── pre-compact-save.sh # Timestamped backup before compaction
175
177
  │ │ ├── session-end.sh # Session handoff snapshot
176
- │ │ └── post-tool-use.sh # Lightweight feedback after edits
178
+ │ │ ├── post-tool-use.sh # Lightweight feedback after edits
179
+ │ │ ├── mcp-health.sh # MCP server availability check
180
+ │ │ ├── governance-capture.sh # Security-sensitive op logging
181
+ │ │ ├── commit-quality.sh # Conventional commit advisory
182
+ │ │ └── session-context.sh # Environment snapshot on start
177
183
  │ ├── hooks.json # Hook definitions (merged into settings.json)
178
184
  │ ├── plugins/ # Experimental plugin packs (opt-in, not part of default install)
179
185
  │ ├── output-styles/ # System prompt output style overrides
@@ -235,6 +241,8 @@ ai-toolkit/
235
241
  | `/repeat` | Autonomous loop with safety controls (Ralph Wiggum pattern) | medium |
236
242
  | `/mem-search` | Search past coding sessions via natural language (memory-pack) | medium |
237
243
  | `/persona` | Switch engineering persona at runtime (session-scoped) | low |
244
+ | `/council` | 4-perspective decision evaluation (Advocate, Critic, Pragmatist, User-Proxy) | high |
245
+ | `/introspect` | Agent self-debugging with 7 failure pattern classification and recovery actions | medium |
238
246
 
239
247
  ### `/workflow` Types
240
248
 
@@ -256,6 +264,17 @@ ai-toolkit/
256
264
  /workflow proactive-troubleshooting # Warning / trend analysis
257
265
  ```
258
266
 
267
+ ### Multi-Agent Skill Selection
268
+
269
+ ```
270
+ Need multi-agent coordination?
271
+ ├── Know your domains? → /orchestrate (ad-hoc, 3-6 agents)
272
+ ├── Have a known pattern? → /workflow <type> (15 templates)
273
+ ├── Need consensus/map-reduce? → /swarm <mode>
274
+ ├── Want Agent Teams API? → /teams (experimental)
275
+ └── Executing a plan? → /subagent-development
276
+ ```
277
+
259
278
  ---
260
279
 
261
280
  ## Unique Differentiators
@@ -271,23 +290,29 @@ Unlike other toolkits that put safety rules in documentation only, ai-toolkit en
271
290
 
272
291
  Hook logic lives in `app/hooks/*.sh` — not inline JSON one-liners. Scripts are copied to `~/.ai-toolkit/hooks/` on install and referenced from `~/.claude/settings.json`. Easy to read, debug, and extend.
273
292
 
274
- **12 lifecycle events / 15 global hook entries:**
293
+ **12 lifecycle events / 21 global hook entries:**
275
294
 
276
295
  | Event | Script | Action |
277
296
  |-------|--------|--------|
278
297
  | SessionStart | `session-start.sh` | MANDATORY rules reminder + session context + instincts |
298
+ | SessionStart | `mcp-health.sh` | Check MCP server command availability (non-blocking warning) |
299
+ | SessionStart | `session-context.sh` | Capture environment snapshot (pwd, git branch, versions) to `~/.ai-toolkit/sessions/current-context.json` |
279
300
  | Notification | *(inline)* | macOS desktop notification |
280
301
  | PreToolUse | `guard-destructive.sh` | Block `rm -rf`, `DROP TABLE`, etc. |
281
302
  | PreToolUse | `guard-path.sh` | Block wrong-user path hallucination |
303
+ | PreToolUse | `guard-config.sh` | Block edits to linter/formatter config files unless explicitly requested |
304
+ | PreToolUse | `commit-quality.sh` | Advisory validation of git commit messages (conventional commits, length, no WIP) |
282
305
  | UserPromptSubmit | `user-prompt-submit.sh` | Prompt governance reminder for planning, research, and safe execution |
283
306
  | UserPromptSubmit | `track-usage.sh` | Record skill invocations to local stats |
284
307
  | PostToolUse | `post-tool-use.sh` | Lightweight validation reminders after edits |
308
+ | PostToolUse | `governance-capture.sh` | Log security-sensitive operations to `~/.ai-toolkit/governance.log` (JSONL) |
285
309
  | Stop | `quality-check.sh` | Multi-language lint (ruff/tsc/phpstan/dart/go) |
286
310
  | Stop | `save-session.sh` | Persist session context for cross-session continuity |
287
311
  | TaskCompleted | `quality-gate.sh` | Block task completion on lint/type errors |
288
312
  | SubagentStart | `subagent-start.sh` | Narrow-scope reminder for spawned subagents |
289
313
  | SubagentStop | `subagent-stop.sh` | Completion checklist for subagent handoff |
290
314
  | PreCompact | `pre-compact.sh` | Smart compaction: prioritized context (instincts > tasks > git state > decisions) |
315
+ | PreCompact | `pre-compact-save.sh` | Save timestamped context backup before compaction to `~/.ai-toolkit/compactions/` |
291
316
  | SessionEnd | `session-end.sh` | Persist a session-end handoff note |
292
317
  | TeammateIdle | *(inline)* | Completeness reminder |
293
318
 
@@ -430,6 +455,67 @@ Agents follow a research-before-action protocol enforced via rules:
430
455
 
431
456
  ---
432
457
 
458
+ ## MCP Templates
459
+
460
+ 25 ready-to-use MCP server configuration templates. Install any with a single command:
461
+
462
+ ```bash
463
+ ai-toolkit mcp add github slack # add GitHub + Slack MCP servers
464
+ ai-toolkit mcp list # browse all 25 templates
465
+ ai-toolkit mcp show postgres # inspect config before adding
466
+ ```
467
+
468
+ Templates include: GitHub, PostgreSQL, Slack, Sentry, Context7, Brave Search, Supabase, Cloudflare, Vercel, and 16 more. Each is a validated JSON config fragment merged into `.mcp.json`.
469
+
470
+ ---
471
+
472
+ ## Language Rules
473
+
474
+ 70 language-specific coding rules across 13 languages: TypeScript, Python, Go, Rust, Java, Kotlin, Swift, Dart, C#, PHP, C++, Ruby, plus 5 common rules. Each language has 5 rule categories: coding-style, testing, patterns, frameworks, security.
475
+
476
+ ```bash
477
+ ai-toolkit install --local --auto-detect # detect project language, install matching rules
478
+ ai-toolkit install --local --lang typescript # explicit language selection
479
+ ai-toolkit install --local --lang go,python # multiple languages
480
+ ```
481
+
482
+ Rules are injected into `CLAUDE.md` and auto-updated on `ai-toolkit update`.
483
+
484
+ ---
485
+
486
+ ## Extension API
487
+
488
+ Generic API for external tools to inject rules and hooks into the toolkit:
489
+
490
+ ```bash
491
+ # Rules — injected into CLAUDE.md with HTML markers
492
+ ai-toolkit inject-rule ./jira-rules.md # idempotent, source-tagged block
493
+ ai-toolkit remove-rule jira-rules
494
+
495
+ # Hooks — injected into settings.json with _source tags
496
+ ai-toolkit inject-hook ./my-hooks.json # idempotent, _source tagged
497
+ ai-toolkit remove-hook my-hooks
498
+ ```
499
+
500
+ Injection is idempotent — re-running updates only the marked block, never touching content outside it. See [`kb/reference/extension-api.md`](kb/reference/extension-api.md).
501
+
502
+ ---
503
+
504
+ ## Manifest Install
505
+
506
+ Module-level install granularity. Install only what you need:
507
+
508
+ ```bash
509
+ ai-toolkit install --modules core,agents,rules-typescript
510
+ ai-toolkit install --auto-detect # detect project language and pick modules
511
+ ai-toolkit status # show installed modules and versions
512
+ ai-toolkit update # incremental re-install (only changed modules)
513
+ ```
514
+
515
+ Install state is tracked in `~/.ai-toolkit/state.json`. See [`kb/reference/manifest-install.md`](kb/reference/manifest-install.md).
516
+
517
+ ---
518
+
433
519
  ## Plugin Packs (Opt-in)
434
520
 
435
521
  11 experimental plugin packs — domain bundles not part of the default install. Each pack bundles agents, skills, hooks, and/or rules for a specific domain.
@@ -456,8 +542,8 @@ All packs have `status: experimental`. Each has a `plugin.json` manifest and `RE
456
542
 
457
543
  | Feature | ai-toolkit | everything-claude-code | wshobson/agents | ruflo |
458
544
  |---------|---------------|----------------------|-----------------|-------|
459
- | Skills | 85 | 100+ | 146 | 20+ |
460
- | Agents | 47 | 30+ | 112 | 20+ |
545
+ | Skills | 90 | 100+ | 146 | 20+ |
546
+ | Agents | 44 | 30+ | 112 | 20+ |
461
547
  | Machine-enforced constitution | **Yes** | No (docs only) | No | No |
462
548
  | Skill-scoped lifecycle hooks | **Yes** | No | No | No |
463
549
  | Effort-based model budgeting | **Yes** | No | No | No |
@@ -595,6 +681,14 @@ Usage: ai-toolkit <command> [options]
595
681
  | `reset --local` | Wipe all project-local configs and recreate from scratch (clean slate) |
596
682
  | `add-rule <rule.md> [name]` | Register rule in `~/.ai-toolkit/rules/` — auto-applied on every `update` |
597
683
  | `remove-rule <name> [dir]` | Unregister rule from `~/.ai-toolkit/rules/` and remove its block from `CLAUDE.md` |
684
+ | `inject-hook <file.json>` | Inject external hooks into settings.json (idempotent, `_source` tagged) |
685
+ | `remove-hook <name>` | Remove injected hooks by source name |
686
+ | `mcp list` | List available MCP server templates (25 templates) |
687
+ | `mcp add <name> [names...]` | Add MCP server template(s) to `.mcp.json` |
688
+ | `mcp show <name>` | Show MCP template config details |
689
+ | `mcp remove <name>` | Remove MCP server from `.mcp.json` |
690
+ | `status` | Show installed modules and version |
691
+ | `update` | Re-install with saved modules (incremental) |
598
692
  | `validate` | Verify toolkit integrity (`--strict` for CI-grade, warnings = errors) |
599
693
  | `doctor` | Diagnose install health, hooks, quick-win assets, and artifact drift |
600
694
  | `doctor --fix` | Auto-repair broken symlinks, missing hooks, stale artifacts |
@@ -637,6 +731,9 @@ ai-toolkit install --persona backend-lead # persona preset: backend-lead | front
637
731
  ai-toolkit install --local # also set up project-local configs (CLAUDE.md, settings, constitution, Copilot, Cline, Roo, Aider, Git Hooks, MCP Defaults)
638
732
  ai-toolkit update --local # re-apply + refresh project-local configs
639
733
  ai-toolkit install --list # dry-run: show what would be applied
734
+ ai-toolkit install --modules core,agents,rules-typescript # selective module install
735
+ ai-toolkit install --auto-detect # detect project language and install matching rules
736
+ ai-toolkit install --lang typescript # explicit language for rules install
640
737
  ```
641
738
 
642
739
  ---
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-toolkit",
3
- "description": "Professional-grade Claude Code toolkit: 87 skills, 47 agents, persona presets, skill security auditor, expanded lifecycle hooks, experimental opt-in plugin packs, benchmark harvesting, and multi-tool support.",
3
+ "description": "Professional-grade Claude Code toolkit: 90 skills, 44 agents, persona presets, skill security auditor, expanded lifecycle hooks, experimental opt-in plugin packs, benchmark harvesting, and multi-tool support.",
4
4
  "version": "1.2.1",
5
5
  "author": {
6
6
  "name": "SoftSpark",
@@ -6,13 +6,13 @@ Universal multi-agent system for software development. Works across all reposito
6
6
 
7
7
  | Component | Count |
8
8
  |-----------|-------|
9
- | Agents | 47 |
10
- | Skills | 87 |
11
- | Hooks | 12 events / 15 entries (SessionStart, Notification, PreToolUse ×2, UserPromptSubmit ×2, PostToolUse, Stop ×2, TaskCompleted, TeammateIdle, SubagentStart, SubagentStop, PreCompact, SessionEnd) |
9
+ | Agents | 44 |
10
+ | Skills | 90 |
11
+ | Hooks | 12 events / 21 entries (SessionStart, Notification, PreToolUse ×2, UserPromptSubmit ×2, PostToolUse, Stop ×2, TaskCompleted, TeammateIdle, SubagentStart, SubagentStop, PreCompact, SessionEnd) |
12
12
 
13
13
  ---
14
14
 
15
- ## Agents (47)
15
+ ## Agents (44)
16
16
 
17
17
  ### Orchestration & Planning (4)
18
18
  | Agent | Model | Purpose |
@@ -31,16 +31,15 @@ Universal multi-agent system for software development. Works across all reposito
31
31
  | `game-developer` | opus | Unity, Godot, Unreal, Phaser |
32
32
  | `database-architect` | opus | Schema design, migrations, query optimization, operations |
33
33
 
34
- ### AI/ML (7)
34
+ ### AI/ML (6)
35
35
  | Agent | Model | Purpose |
36
36
  |-------|-------|---------|
37
- | `ai-engineer` | opus | LLM integration, vector search |
37
+ | `ai-engineer` | opus | LLM integration, vector search, RAG pipelines |
38
38
  | `ml-engineer` | opus | Model training, MLOps |
39
39
  | `nlp-engineer` | opus | NLP pipelines, text processing |
40
40
  | `data-scientist` | opus | Statistics, analysis, visualization |
41
41
  | `data-analyst` | sonnet | SQL, analytics, reporting |
42
42
  | `prompt-engineer` | opus | Prompt design, optimization |
43
- | `rag-engineer` | opus | RAG pipelines, retrieval |
44
43
 
45
44
  ### Quality & Security (6)
46
45
  | Agent | Model | Purpose |
@@ -62,12 +61,11 @@ Universal multi-agent system for software development. Works across all reposito
62
61
  | `performance-optimizer` | opus | Performance tuning |
63
62
  | `llm-ops-engineer` | opus | LLM operations, monitoring |
64
63
 
65
- ### Research & Documentation (6)
64
+ ### Research & Documentation (5)
66
65
  | Agent | Model | Purpose |
67
66
  |-------|-------|---------|
68
67
  | `explorer-agent` | sonnet | Codebase discovery (READ-ONLY) |
69
- | `research-synthesizer` | opus | Research coordination, synthesis, reports |
70
- | `technical-researcher` | opus | Deep technical investigation |
68
+ | `technical-researcher` | opus | Deep technical investigation, research synthesis |
71
69
  | `search-specialist` | sonnet | Search optimization |
72
70
  | `fact-checker` | sonnet | Verification, source checking |
73
71
  | `documenter` | sonnet | Documentation, KB management, SOPs, API docs |
@@ -86,11 +84,10 @@ Universal multi-agent system for software development. Works across all reposito
86
84
  | `night-watchman` | sonnet | Autonomous maintenance: dependency updates, dead code |
87
85
  | `chaos-monkey` | opus | Resilience testing: fault injection, failure verification |
88
86
 
89
- ### MCP (3)
87
+ ### MCP (2)
90
88
  | Agent | Model | Purpose |
91
89
  |-------|-------|---------|
92
- | `mcp-expert` | opus | MCP protocol expertise |
93
- | `mcp-server-architect` | opus | MCP server design |
90
+ | `mcp-specialist` | opus | MCP server design, client config, troubleshooting |
94
91
  | `mcp-testing-engineer` | sonnet | MCP testing |
95
92
 
96
93
  ### Specialist (4)
@@ -103,7 +100,7 @@ Universal multi-agent system for software development. Works across all reposito
103
100
 
104
101
  ---
105
102
 
106
- ## Skills (87)
103
+ ## Skills (90)
107
104
 
108
105
  ### Task Skills (28)
109
106
  | Skill | Slash Command | Purpose |
@@ -137,7 +134,7 @@ Universal multi-agent system for software development. Works across all reposito
137
134
  | `prd-to-issues` | `/prd-to-issues` | Break PRD into GitHub issues with vertical slices and HITL/AFK tagging |
138
135
  | `skill-audit` | `/skill-audit` | Scan skills and agents for security risks, dangerous patterns, secrets |
139
136
 
140
- ### Hybrid Skills (28)
137
+ ### Hybrid Skills (30)
141
138
  | Skill | Slash Command | Purpose |
142
139
  |-------|---------------|---------|
143
140
  | `explore` | `/explore` | Codebase exploration and tech stack discovery |
@@ -168,8 +165,10 @@ Universal multi-agent system for software development. Works across all reposito
168
165
  | `repeat` | `/repeat` | Autonomous loop with safety controls (Ralph Wiggum pattern) |
169
166
  | `mem-search` | `/mem-search` | Search past coding sessions via natural language (memory-pack) |
170
167
  | `persona` | `/persona` | Switch engineering persona at runtime (backend-lead, frontend-lead, devops-eng, junior-dev) |
168
+ | `council` | `/council` | 4-perspective decision evaluation (Advocate, Critic, Pragmatist, User-Proxy) with synthesis |
169
+ | `introspect` | `/introspect` | Agent self-debugging: classify failure pattern, suggest recovery action, emit introspection report |
171
170
 
172
- ### Knowledge Skills - Development (15)
171
+ ### Knowledge Skills - Development (16)
173
172
  | Skill | Purpose |
174
173
  |-------|---------|
175
174
  | `app-builder` | Project scaffolding, tech stack |
@@ -187,6 +186,7 @@ Universal multi-agent system for software development. Works across all reposito
187
186
  | `kotlin-patterns` | Coroutines, DSLs, sealed classes, Ktor, MockK |
188
187
  | `swift-patterns` | Protocol-oriented, SwiftUI, async/await, SPM |
189
188
  | `ruby-patterns` | Blocks, Rails conventions, RSpec, ActiveRecord |
189
+ | `brand-voice` | Anti-trope list, voice principles, LLM rhetoric prevention |
190
190
 
191
191
  ### Knowledge Skills - Infrastructure (6)
192
192
  | Skill | Purpose |
@@ -245,7 +245,7 @@ Phase 2: IMPLEMENTATION
245
245
  | Bug Fix | debugger | backend/frontend, test-engineer |
246
246
  | Performance | performance-optimizer | database-architect |
247
247
  | Security | security-auditor | code-reviewer |
248
- | Research | research-synthesizer | technical-researcher, search-specialist |
248
+ | Research | technical-researcher | search-specialist, fact-checker |
249
249
  | Documentation | documenter | explorer-agent |
250
250
 
251
251
  ---
@@ -255,9 +255,9 @@ Phase 2: IMPLEMENTATION
255
255
  ```
256
256
  .claude/
257
257
  ├── ARCHITECTURE.md # This file
258
- ├── agents/ # Agent definitions (47)
258
+ ├── agents/ # Agent definitions (44)
259
259
  ├── hooks.json # Quality gate hooks (multi-language)
260
- ├── skills/ # All skills: task, hybrid, knowledge (87)
260
+ ├── skills/ # All skills: task, hybrid, knowledge (90)
261
261
  ├── output-styles/ # System prompt output style overrides (e.g. golden-rules)
262
262
  ├── constitution.md # Immutable safety rules (5 articles)
263
263
  └── settings.local.json # Local settings + Agent Teams config
@@ -297,6 +297,22 @@ Lead Session (You)
297
297
 
298
298
  ---
299
299
 
300
+ ## Extension Points
301
+
302
+ ### MCP Templates (25)
303
+ `app/plugins/mcp-templates/` ships 25 ready-to-use MCP server config templates (filesystems, databases, GitHub, Slack, etc.). Opt-in via `ai-toolkit install --modules mcp-templates` or activated automatically with `--profile strict|full`.
304
+
305
+ ### Language Rules (70 files, 13 languages)
306
+ `app/rules/` contains per-language coding rules injected into `CLAUDE.md`. Supported languages: TypeScript, Python, Go, Rust, Java, Kotlin, Swift, Dart, C#, PHP, C++, Ruby, and common (shared). Auto-detected from project files via `--auto-detect` or selected with `--modules rules-<lang>`.
307
+
308
+ ### Extension API (`inject-hook`)
309
+ The `inject_section_cli.py` script provides a stable marker-based injection API. Any tool can add sections to `CLAUDE.md`, `constitution.md`, or `ARCHITECTURE.md` without overwriting user content, using `<!-- TOOLKIT:START:<id> -->` / `<!-- TOOLKIT:END:<id> -->` markers.
310
+
311
+ ### Manifest Install (`--modules`, `--auto-detect`)
312
+ `manifest.json` defines all installable components as named modules. Install individual modules with `ai-toolkit install --modules <name>` or let the installer detect which language rules to add based on project files (e.g. `package.json` → `rules-typescript`, `go.mod` → `rules-golang`).
313
+
314
+ ---
315
+
300
316
  ## Principles
301
317
 
302
318
  1. **Universal**: No project-specific references
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  name: ai-engineer
3
- description: "AI/ML integration specialist. Use for LLM integration, vector databases, RAG pipelines, embeddings, and AI agent orchestration. Triggers: ai, ml, llm, embedding, vector, rag, agent, openai, anthropic."
3
+ description: "AI/ML integration specialist. Use for LLM integration, vector databases, RAG pipelines, embeddings, AI agent orchestration, document indexing, semantic search, hybrid retrieval, and answer generation. Triggers: ai, ml, llm, embedding, vector, rag, agent, openai, anthropic, search, retrieval, indexing, chunking, reranking."
4
4
  tools: Read, Write, Edit, Bash, Grep, Glob
5
5
  model: opus
6
6
  color: blue
7
- skills: clean-code, rag-patterns
7
+ skills: clean-code, rag-patterns, api-patterns
8
8
  ---
9
9
 
10
10
  # AI Engineer
11
11
 
12
- AI/ML integration specialist for production systems.
12
+ AI/ML integration specialist for production systems, including RAG pipeline design and retrieval optimization.
13
13
 
14
14
  ## Expertise
15
15
  - LLM integration (OpenAI, Anthropic, local models)
@@ -17,6 +17,9 @@ AI/ML integration specialist for production systems.
17
17
  - RAG pipelines and retrieval optimization
18
18
  - Embedding models and fine-tuning
19
19
  - AI agent orchestration
20
+ - Document indexing and semantic search
21
+ - Hybrid retrieval (dense + sparse)
22
+ - CRAG, HyDE, and multi-hop reasoning
20
23
 
21
24
  ## Responsibilities
22
25
 
@@ -38,6 +41,19 @@ AI/ML integration specialist for production systems.
38
41
  - Caching strategies
39
42
  - Fallback and error handling
40
43
 
44
+ ### Document Indexing Pipeline
45
+ - Chunking strategies (semantic, fixed-size, sliding window)
46
+ - Embedding model selection (OpenAI, Ollama/nomic-embed-text)
47
+ - Vector store optimization (Qdrant)
48
+ - Metadata enrichment and frontmatter normalization
49
+
50
+ ### Retrieval Optimization
51
+ - Hybrid search (dense + sparse with RRF fusion)
52
+ - Query expansion and rewriting
53
+ - Multi-hop retrieval for complex queries
54
+ - Corrective RAG (CRAG) for relevance validation
55
+ - Answer generation with citation and source attribution
56
+
41
57
  ## Decision Framework
42
58
 
43
59
  ### Model Selection
@@ -56,6 +72,33 @@ AI/ML integration specialist for production systems.
56
72
  | Multilingual | multilingual-e5-large |
57
73
  | Cost-sensitive | local sentence-transformers |
58
74
 
75
+ ## RAG-MCP MCP Tools Reference
76
+
77
+ | Category | Tools |
78
+ |----------|-------|
79
+ | **Core** | `smart_query` (90% of queries), `hybrid_search_kb`, `get_document` |
80
+ | **Agentic** | `crag_search` (vague queries), `multi_hop_search` (complex reasoning) |
81
+ | **Admin** | `make evaluate-rag`, `make knowledge-gaps`, `make index`, `make stats` |
82
+
83
+ ### Tool Selection Guide
84
+
85
+ ```python
86
+ # Default - auto-routing, use 90% of time
87
+ smart_query(query="rate limiting configuration", limit=10)
88
+
89
+ # Vague/fuzzy queries - self-correcting
90
+ crag_search(query="jak to skonfigurować", max_retries=2, relevance_threshold=0.4)
91
+
92
+ # Complex multi-step reasoning
93
+ multi_hop_search(query="nginx vs varnish for Magento cache", max_hops=3)
94
+
95
+ # Raw hybrid search
96
+ hybrid_search_kb(query="specific keyword", service="nginx", limit=10)
97
+
98
+ # Full document content
99
+ get_document(path="kb/reference/architecture.md")
100
+ ```
101
+
59
102
  ## KB Integration
60
103
  ```python
61
104
  smart_query("LLM integration patterns")
@@ -124,5 +167,4 @@ For large documentation tasks, hand off to `documenter` agent.
124
167
  ## Limitations
125
168
 
126
169
  - **LLM operations** → Use `llm-ops-engineer`
127
- - **MCP server** → Use `mcp-server-architect`
128
- - **RAG optimization** → Use `rag-engineer`
170
+ - **MCP server** → Use `mcp-specialist`
@@ -168,5 +168,5 @@ kb_references:
168
168
  ## Limitations
169
169
 
170
170
  - **Implementation** → Use appropriate specialist agent
171
- - **Research** → Use `rag-engineer` for technical details
171
+ - **Research** → Use `ai-engineer` for technical details
172
172
  - **Documentation updates** → Use `documenter`
@@ -232,6 +232,6 @@ For large documentation tasks, hand off to `documenter` agent.
232
232
 
233
233
  ## Limitations
234
234
 
235
- - **RAG retrieval** → Use `rag-engineer`
236
- - **MCP server** → Use `mcp-server-architect`
235
+ - **RAG retrieval** → Use `ai-engineer`
236
+ - **MCP server** → Use `mcp-specialist`
237
237
  - **Security** → Use `security-auditor`