claude-flow-novice 2.15.5 → 2.15.6

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 (440) hide show
  1. package/.claude/cfn-extras/.gs-api-quota.json +16 -0
  2. package/.claude/cfn-extras/.gs-progress-state.json +22 -0
  3. package/.claude/cfn-extras/GOOGLE_SHEETS_IMPLEMENTATION_SUMMARY.md +414 -0
  4. package/.claude/cfn-extras/agents/google-sheets/README.md +114 -0
  5. package/.claude/cfn-extras/agents/google-sheets/google-sheets-advanced-analytics-specialist.md +288 -0
  6. package/.claude/cfn-extras/agents/google-sheets/google-sheets-api-integrator.md +127 -0
  7. package/.claude/cfn-extras/agents/google-sheets/google-sheets-automation-scripting-specialist.md +195 -0
  8. package/.claude/cfn-extras/agents/google-sheets/google-sheets-business-validator.md +179 -0
  9. package/.claude/cfn-extras/agents/google-sheets/google-sheets-collaboration-security-specialist.md +240 -0
  10. package/.claude/cfn-extras/agents/google-sheets/google-sheets-coordinator.md +214 -0
  11. package/.claude/cfn-extras/agents/google-sheets/google-sheets-data-transformer.md +127 -0
  12. package/.claude/cfn-extras/agents/google-sheets/google-sheets-data-validation-quality-specialist.md +177 -0
  13. package/.claude/cfn-extras/agents/google-sheets/google-sheets-data-validator.md +119 -0
  14. package/.claude/cfn-extras/agents/google-sheets/google-sheets-data-visualization-specialist.md +135 -0
  15. package/.claude/cfn-extras/agents/google-sheets/google-sheets-design-layout-specialist.md +109 -0
  16. package/.claude/cfn-extras/agents/google-sheets/google-sheets-formula-engineer.md +127 -0
  17. package/.claude/cfn-extras/agents/google-sheets/google-sheets-formula-engineering-specialist.md +138 -0
  18. package/.claude/cfn-extras/agents/google-sheets/google-sheets-formula-validator.md +128 -0
  19. package/.claude/cfn-extras/agents/google-sheets/google-sheets-generalist.md +645 -0
  20. package/.claude/cfn-extras/agents/google-sheets/google-sheets-integration-api-specialist.md +258 -0
  21. package/.claude/cfn-extras/agents/google-sheets/google-sheets-performance-analyst.md +125 -0
  22. package/.claude/cfn-extras/agents/google-sheets/google-sheets-performance-optimization-specialist.md +211 -0
  23. package/.claude/cfn-extras/agents/google-sheets/google-sheets-schema-designer.md +130 -0
  24. package/.claude/cfn-extras/agents/google-sheets/google-sheets-template-architecture-specialist.md +259 -0
  25. package/.claude/cfn-extras/docs/GOOGLE_SHEETS_CFN_LOOP.md +617 -0
  26. package/.claude/cfn-extras/skills/GOOGLE_SHEETS_SKILLS_README.md +453 -0
  27. package/.claude/cfn-extras/skills/google-sheets-api-coordinator/SKILL.md +272 -0
  28. package/.claude/cfn-extras/skills/google-sheets-api-coordinator/api-call.sh +254 -0
  29. package/.claude/cfn-extras/skills/google-sheets-api-coordinator/test.sh +174 -0
  30. package/.claude/cfn-extras/skills/google-sheets-api-coordinator/validate.sh +98 -0
  31. package/.claude/cfn-extras/skills/google-sheets-decomposition/SKILL.md +269 -0
  32. package/.claude/cfn-extras/skills/google-sheets-decomposition/decompose.sh +313 -0
  33. package/.claude/cfn-extras/skills/google-sheets-formula-builder/SKILL.md +237 -0
  34. package/.claude/cfn-extras/skills/google-sheets-formula-builder/build-formula.sh +220 -0
  35. package/.claude/cfn-extras/skills/google-sheets-formula-builder/test.sh +172 -0
  36. package/.claude/cfn-extras/skills/google-sheets-formula-builder/validate.sh +98 -0
  37. package/.claude/cfn-extras/skills/google-sheets-progress/SKILL.md +287 -0
  38. package/.claude/cfn-extras/skills/google-sheets-progress/test.sh +385 -0
  39. package/.claude/cfn-extras/skills/google-sheets-progress/track-progress.sh +516 -0
  40. package/.claude/cfn-extras/skills/google-sheets-progress/validate.sh +119 -0
  41. package/.claude/cfn-extras/skills/google-sheets-sprint-order/SKILL.md +277 -0
  42. package/.claude/cfn-extras/skills/google-sheets-sprint-order/order-sprints.sh +233 -0
  43. package/.claude/cfn-extras/skills/google-sheets-validation/SKILL.md +352 -0
  44. package/.claude/cfn-extras/skills/google-sheets-validation/test.sh +355 -0
  45. package/.claude/cfn-extras/skills/google-sheets-validation/validate-state.sh +374 -0
  46. package/.claude/cfn-extras/skills/google-sheets-validation/validate.sh +128 -0
  47. package/.claude/commands/cfn-context.md +10 -0
  48. package/.claude/commands/cfn-loop-cli.md +36 -15
  49. package/.claude/commands/google-sheets/google-sheets-loop.md +289 -0
  50. package/.claude/skills/cfn-agent-selector/SKILL.md +143 -0
  51. package/.claude/skills/cfn-agent-selector/select-agents.sh +94 -0
  52. package/.claude/skills/cfn-agent-spawning/get-agent-provider-env.sh +22 -2
  53. package/.claude/skills/cfn-docker-agent-spawning/spawn-agent.sh +21 -2
  54. package/.claude/skills/cfn-docker-loop-orchestration/orchestrate.sh +11 -5
  55. package/.claude/skills/cfn-docker-redis-coordination/MIGRATION_SUMMARY.md +348 -0
  56. package/.claude/skills/cfn-docker-redis-coordination/README.md +294 -0
  57. package/.claude/skills/cfn-docker-redis-coordination/jest.config.js +37 -0
  58. package/.claude/skills/cfn-docker-redis-coordination/package-lock.json +5259 -0
  59. package/.claude/skills/cfn-docker-redis-coordination/package.json +40 -0
  60. package/.claude/skills/cfn-docker-redis-coordination/src/coordinator.ts +801 -0
  61. package/.claude/skills/cfn-docker-redis-coordination/src/index.ts +42 -0
  62. package/.claude/skills/cfn-docker-redis-coordination/src/types.ts +351 -0
  63. package/.claude/skills/cfn-docker-redis-coordination/tests/coordinator.test.ts +1464 -0
  64. package/.claude/skills/cfn-docker-redis-coordination/tsconfig.json +30 -0
  65. package/.claude/skills/cfn-loop-orchestration/.eslintrc.js +56 -0
  66. package/.claude/skills/cfn-loop-orchestration/.prettierrc.json +18 -0
  67. package/.claude/skills/cfn-loop-orchestration/README.md +149 -41
  68. package/.claude/skills/cfn-loop-orchestration/jest.config.js +67 -0
  69. package/.claude/skills/cfn-loop-orchestration/orchestrate-wrapper.sh +268 -0
  70. package/.claude/skills/cfn-loop-orchestration/orchestrate.sh +91 -8
  71. package/.claude/skills/cfn-loop-orchestration/package-lock.json +5470 -0
  72. package/.claude/skills/cfn-loop-orchestration/package.json +49 -0
  73. package/.claude/skills/cfn-loop-orchestration/src/agent-spawner/agent-spawner.ts +34 -0
  74. package/.claude/skills/cfn-loop-orchestration/src/gate-checker/gate-checker.ts +36 -0
  75. package/.claude/skills/cfn-loop-orchestration/src/index.ts +14 -0
  76. package/.claude/skills/cfn-loop-orchestration/src/orchestrator/orchestrator.ts +31 -0
  77. package/.claude/skills/cfn-loop-orchestration/src/redis/redis-coordinator.ts +72 -0
  78. package/.claude/skills/cfn-loop-orchestration/src/types.ts +188 -0
  79. package/.claude/skills/cfn-loop-orchestration/src/utils/logger.ts +32 -0
  80. package/.claude/skills/cfn-loop-orchestration/tests/setup.ts +22 -0
  81. package/.claude/skills/cfn-loop-orchestration/tests/types.test.ts +132 -0
  82. package/.claude/skills/cfn-loop-orchestration/tsconfig.json +54 -0
  83. package/.claude/skills/cfn-redis-coordination/bash-wrappers/store-context.sh +23 -0
  84. package/.claude/skills/cfn-redis-coordination/dist/agent-logger.d.ts +92 -0
  85. package/.claude/skills/cfn-redis-coordination/dist/agent-logger.d.ts.map +1 -0
  86. package/.claude/skills/cfn-redis-coordination/dist/agent-logger.js +329 -0
  87. package/.claude/skills/cfn-redis-coordination/dist/agent-logger.js.map +1 -0
  88. package/.claude/skills/cfn-redis-coordination/dist/agent-recovery.d.ts +75 -0
  89. package/.claude/skills/cfn-redis-coordination/dist/agent-recovery.d.ts.map +1 -0
  90. package/.claude/skills/cfn-redis-coordination/dist/agent-recovery.js +302 -0
  91. package/.claude/skills/cfn-redis-coordination/dist/agent-recovery.js.map +1 -0
  92. package/.claude/skills/cfn-redis-coordination/dist/completion-reporter.d.ts +58 -0
  93. package/.claude/skills/cfn-redis-coordination/dist/completion-reporter.d.ts.map +1 -0
  94. package/.claude/skills/cfn-redis-coordination/dist/completion-reporter.js +237 -0
  95. package/.claude/skills/cfn-redis-coordination/dist/completion-reporter.js.map +1 -0
  96. package/.claude/skills/cfn-redis-coordination/dist/context-manager.d.ts +63 -0
  97. package/.claude/skills/cfn-redis-coordination/dist/context-manager.d.ts.map +1 -0
  98. package/.claude/skills/cfn-redis-coordination/dist/context-manager.js +230 -0
  99. package/.claude/skills/cfn-redis-coordination/dist/context-manager.js.map +1 -0
  100. package/.claude/skills/cfn-redis-coordination/dist/index.d.ts +45 -0
  101. package/.claude/skills/cfn-redis-coordination/dist/index.d.ts.map +1 -0
  102. package/.claude/skills/cfn-redis-coordination/dist/index.js +114 -0
  103. package/.claude/skills/cfn-redis-coordination/dist/index.js.map +1 -0
  104. package/.claude/skills/cfn-redis-coordination/dist/mode-detector.d.ts +31 -0
  105. package/.claude/skills/cfn-redis-coordination/dist/mode-detector.d.ts.map +1 -0
  106. package/.claude/skills/cfn-redis-coordination/dist/mode-detector.js +185 -0
  107. package/.claude/skills/cfn-redis-coordination/dist/mode-detector.js.map +1 -0
  108. package/.claude/skills/cfn-redis-coordination/dist/redis-client.d.ts +191 -0
  109. package/.claude/skills/cfn-redis-coordination/dist/redis-client.d.ts.map +1 -0
  110. package/.claude/skills/cfn-redis-coordination/dist/redis-client.js +509 -0
  111. package/.claude/skills/cfn-redis-coordination/dist/redis-client.js.map +1 -0
  112. package/.claude/skills/cfn-redis-coordination/dist/result-collector.d.ts +75 -0
  113. package/.claude/skills/cfn-redis-coordination/dist/result-collector.d.ts.map +1 -0
  114. package/.claude/skills/cfn-redis-coordination/dist/result-collector.js +281 -0
  115. package/.claude/skills/cfn-redis-coordination/dist/result-collector.js.map +1 -0
  116. package/.claude/skills/cfn-redis-coordination/dist/swarm-manager.d.ts +75 -0
  117. package/.claude/skills/cfn-redis-coordination/dist/swarm-manager.d.ts.map +1 -0
  118. package/.claude/skills/cfn-redis-coordination/dist/swarm-manager.js +354 -0
  119. package/.claude/skills/cfn-redis-coordination/dist/swarm-manager.js.map +1 -0
  120. package/.claude/skills/cfn-redis-coordination/dist/task-analyzer.d.ts +62 -0
  121. package/.claude/skills/cfn-redis-coordination/dist/task-analyzer.d.ts.map +1 -0
  122. package/.claude/skills/cfn-redis-coordination/dist/task-analyzer.js +305 -0
  123. package/.claude/skills/cfn-redis-coordination/dist/task-analyzer.js.map +1 -0
  124. package/.claude/skills/cfn-redis-coordination/dist/task-executor.d.ts +97 -0
  125. package/.claude/skills/cfn-redis-coordination/dist/task-executor.d.ts.map +1 -0
  126. package/.claude/skills/cfn-redis-coordination/dist/task-executor.js +283 -0
  127. package/.claude/skills/cfn-redis-coordination/dist/task-executor.js.map +1 -0
  128. package/.claude/skills/cfn-redis-coordination/dist/types.d.ts +176 -0
  129. package/.claude/skills/cfn-redis-coordination/dist/types.d.ts.map +1 -0
  130. package/.claude/skills/cfn-redis-coordination/dist/types.js +81 -0
  131. package/.claude/skills/cfn-redis-coordination/dist/types.js.map +1 -0
  132. package/.claude/skills/cfn-redis-coordination/dist/waiting-coordinator.d.ts +86 -0
  133. package/.claude/skills/cfn-redis-coordination/dist/waiting-coordinator.d.ts.map +1 -0
  134. package/.claude/skills/cfn-redis-coordination/dist/waiting-coordinator.js +419 -0
  135. package/.claude/skills/cfn-redis-coordination/dist/waiting-coordinator.js.map +1 -0
  136. package/.claude/skills/cfn-redis-coordination/docs/migration/PHASE_3_REDIS_COORDINATION_COMPLETION_REPORT.md +553 -0
  137. package/.claude/skills/cfn-redis-coordination/jest.config.js +23 -0
  138. package/.claude/skills/cfn-redis-coordination/package-lock.json +5272 -0
  139. package/.claude/skills/cfn-redis-coordination/package.json +45 -0
  140. package/.claude/skills/cfn-redis-coordination/redis-cli-wrapper.sh +21 -8
  141. package/.claude/skills/cfn-redis-coordination/src/agent-logger.ts +446 -0
  142. package/.claude/skills/cfn-redis-coordination/src/agent-recovery.ts +454 -0
  143. package/.claude/skills/cfn-redis-coordination/src/completion-reporter.ts +396 -0
  144. package/.claude/skills/cfn-redis-coordination/src/context-manager.ts +327 -0
  145. package/.claude/skills/cfn-redis-coordination/src/index.ts +82 -0
  146. package/.claude/skills/cfn-redis-coordination/src/mode-detector.ts +155 -0
  147. package/.claude/skills/cfn-redis-coordination/src/redis/redis-client.ts +305 -0
  148. package/.claude/skills/cfn-redis-coordination/src/redis/redis-functions.ts +283 -0
  149. package/.claude/skills/cfn-redis-coordination/src/redis-client.ts +654 -0
  150. package/.claude/skills/cfn-redis-coordination/src/result-collector.ts +437 -0
  151. package/.claude/skills/cfn-redis-coordination/src/swarm-manager.ts +494 -0
  152. package/.claude/skills/cfn-redis-coordination/src/task-analyzer.ts +404 -0
  153. package/.claude/skills/cfn-redis-coordination/src/task-executor.ts +423 -0
  154. package/.claude/skills/cfn-redis-coordination/src/types.ts +235 -0
  155. package/.claude/skills/cfn-redis-coordination/src/waiting-coordinator.ts +587 -0
  156. package/.claude/skills/cfn-redis-coordination/test-connection-attempts.js +70 -0
  157. package/.claude/skills/cfn-redis-coordination/test-mode-simple.js +121 -0
  158. package/.claude/skills/cfn-redis-coordination/test-redis-check.js +84 -0
  159. package/.claude/skills/cfn-redis-coordination/test-task-mode-redis.cjs +391 -0
  160. package/.claude/skills/cfn-redis-coordination/tests/coordination.test.ts +779 -0
  161. package/.claude/skills/cfn-redis-coordination/tsconfig.json +31 -0
  162. package/claude-assets/agents/cfn-dev-team/coordinators/cfn-v3-coordinator.md +172 -2
  163. package/claude-assets/agents/cfn-dev-team/testers/api-testing-specialist.md +1 -1
  164. package/claude-assets/agents/custom/cfn-redis-operations.md +530 -0
  165. package/claude-assets/agents/custom/cfn-system-expert.md +77 -0
  166. package/claude-assets/cfn-extras/.gs-api-quota.json +16 -0
  167. package/claude-assets/cfn-extras/.gs-progress-state.json +22 -0
  168. package/claude-assets/cfn-extras/GOOGLE_SHEETS_IMPLEMENTATION_SUMMARY.md +414 -0
  169. package/claude-assets/cfn-extras/agents/google-sheets/README.md +114 -0
  170. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-advanced-analytics-specialist.md +288 -0
  171. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-api-integrator.md +127 -0
  172. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-automation-scripting-specialist.md +195 -0
  173. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-business-validator.md +179 -0
  174. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-collaboration-security-specialist.md +240 -0
  175. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-coordinator.md +214 -0
  176. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-data-transformer.md +127 -0
  177. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-data-validation-quality-specialist.md +177 -0
  178. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-data-validator.md +119 -0
  179. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-data-visualization-specialist.md +135 -0
  180. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-design-layout-specialist.md +109 -0
  181. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-formula-engineer.md +127 -0
  182. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-formula-engineering-specialist.md +138 -0
  183. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-formula-validator.md +128 -0
  184. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-generalist.md +645 -0
  185. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-integration-api-specialist.md +258 -0
  186. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-performance-analyst.md +125 -0
  187. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-performance-optimization-specialist.md +211 -0
  188. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-schema-designer.md +130 -0
  189. package/claude-assets/cfn-extras/agents/google-sheets/google-sheets-template-architecture-specialist.md +259 -0
  190. package/claude-assets/cfn-extras/docs/GOOGLE_SHEETS_CFN_LOOP.md +617 -0
  191. package/claude-assets/cfn-extras/skills/GOOGLE_SHEETS_SKILLS_README.md +453 -0
  192. package/claude-assets/cfn-extras/skills/google-sheets-api-coordinator/SKILL.md +272 -0
  193. package/claude-assets/cfn-extras/skills/google-sheets-api-coordinator/api-call.sh +254 -0
  194. package/claude-assets/cfn-extras/skills/google-sheets-api-coordinator/test.sh +174 -0
  195. package/claude-assets/cfn-extras/skills/google-sheets-api-coordinator/validate.sh +98 -0
  196. package/claude-assets/cfn-extras/skills/google-sheets-decomposition/SKILL.md +269 -0
  197. package/claude-assets/cfn-extras/skills/google-sheets-decomposition/decompose.sh +313 -0
  198. package/claude-assets/cfn-extras/skills/google-sheets-formula-builder/SKILL.md +237 -0
  199. package/claude-assets/cfn-extras/skills/google-sheets-formula-builder/build-formula.sh +220 -0
  200. package/claude-assets/cfn-extras/skills/google-sheets-formula-builder/test.sh +172 -0
  201. package/claude-assets/cfn-extras/skills/google-sheets-formula-builder/validate.sh +98 -0
  202. package/claude-assets/cfn-extras/skills/google-sheets-progress/SKILL.md +287 -0
  203. package/claude-assets/cfn-extras/skills/google-sheets-progress/test.sh +385 -0
  204. package/claude-assets/cfn-extras/skills/google-sheets-progress/track-progress.sh +516 -0
  205. package/claude-assets/cfn-extras/skills/google-sheets-progress/validate.sh +119 -0
  206. package/claude-assets/cfn-extras/skills/google-sheets-sprint-order/SKILL.md +277 -0
  207. package/claude-assets/cfn-extras/skills/google-sheets-sprint-order/order-sprints.sh +233 -0
  208. package/claude-assets/cfn-extras/skills/google-sheets-validation/SKILL.md +352 -0
  209. package/claude-assets/cfn-extras/skills/google-sheets-validation/test.sh +355 -0
  210. package/claude-assets/cfn-extras/skills/google-sheets-validation/validate-state.sh +374 -0
  211. package/claude-assets/cfn-extras/skills/google-sheets-validation/validate.sh +128 -0
  212. package/claude-assets/commands/cfn-context.md +10 -0
  213. package/claude-assets/commands/cfn-loop-cli.md +36 -15
  214. package/claude-assets/commands/google-sheets/google-sheets-loop.md +289 -0
  215. package/claude-assets/hooks/cfn-pre-execution/SESSION_START_README.md +87 -0
  216. package/claude-assets/hooks/cfn-pre-execution/TEST_SESSION_START.md +128 -0
  217. package/claude-assets/hooks/cfn-pre-execution/session-start-context.sh +111 -0
  218. package/claude-assets/skills/cfn-agent-selection-with-fallback/INTEGRATION_EXAMPLE.md +209 -0
  219. package/claude-assets/skills/cfn-agent-selection-with-fallback/README.md +130 -0
  220. package/claude-assets/skills/cfn-agent-selection-with-fallback/SKILL.md +243 -0
  221. package/claude-assets/skills/cfn-agent-selection-with-fallback/agent-mappings.json +142 -0
  222. package/claude-assets/skills/cfn-agent-selection-with-fallback/select-agents.sh +173 -0
  223. package/claude-assets/skills/cfn-agent-selection-with-fallback/task-classifier.sh +71 -0
  224. package/claude-assets/skills/cfn-agent-selection-with-fallback/test-agent-selection.sh +282 -0
  225. package/claude-assets/skills/cfn-agent-selector/SKILL.md +143 -0
  226. package/claude-assets/skills/cfn-agent-selector/select-agents.sh +94 -0
  227. package/claude-assets/skills/cfn-agent-spawning/get-agent-provider-env.sh +22 -2
  228. package/claude-assets/skills/cfn-docker-agent-spawning/spawn-agent.sh +21 -2
  229. package/claude-assets/skills/cfn-docker-coordination/.eslintrc.json +33 -0
  230. package/claude-assets/skills/cfn-docker-coordination/README.md +349 -0
  231. package/claude-assets/skills/cfn-docker-coordination/docker-helpers.sh +433 -0
  232. package/claude-assets/skills/cfn-docker-coordination/jest.config.js +25 -0
  233. package/claude-assets/skills/cfn-docker-coordination/package-lock.json +6827 -0
  234. package/claude-assets/skills/cfn-docker-coordination/package.json +38 -0
  235. package/claude-assets/skills/cfn-docker-coordination/src/agent-container.ts +471 -0
  236. package/claude-assets/skills/cfn-docker-coordination/src/docker-client.ts +483 -0
  237. package/claude-assets/skills/cfn-docker-coordination/src/health-checker.ts +418 -0
  238. package/claude-assets/skills/cfn-docker-coordination/src/index.ts +45 -0
  239. package/claude-assets/skills/cfn-docker-coordination/src/network-manager.ts +377 -0
  240. package/claude-assets/skills/cfn-docker-coordination/src/types.ts +412 -0
  241. package/claude-assets/skills/cfn-docker-coordination/src/volume-manager.ts +389 -0
  242. package/claude-assets/skills/cfn-docker-coordination/tests/agent-container.test.ts +379 -0
  243. package/claude-assets/skills/cfn-docker-coordination/tests/docker-client.test.ts +345 -0
  244. package/claude-assets/skills/cfn-docker-coordination/tests/health-checker.test.ts +535 -0
  245. package/claude-assets/skills/cfn-docker-coordination/tests/integration.test.ts +193 -0
  246. package/claude-assets/skills/cfn-docker-coordination/tests/network-manager.test.ts +352 -0
  247. package/claude-assets/skills/cfn-docker-coordination/tests/setup.ts +36 -0
  248. package/claude-assets/skills/cfn-docker-coordination/tsconfig.json +29 -0
  249. package/claude-assets/skills/cfn-docker-logging/INTEGRATION.md +268 -0
  250. package/claude-assets/skills/cfn-docker-logging/SAMPLE_OUTPUTS.md +237 -0
  251. package/claude-assets/skills/cfn-docker-logging/SKILL.md +442 -0
  252. package/claude-assets/skills/cfn-docker-logging/capture-container-logs.sh +120 -0
  253. package/claude-assets/skills/cfn-docker-logging/enable-logging.sh +430 -0
  254. package/claude-assets/skills/cfn-docker-logging/init-hybrid-logging.sh +210 -0
  255. package/claude-assets/skills/cfn-docker-logging/queries/analytics-summary.sh +87 -0
  256. package/claude-assets/skills/cfn-docker-logging/queries/query-agent-timeline.sh +51 -0
  257. package/claude-assets/skills/cfn-docker-logging/queries/query-consensus-history.sh +56 -0
  258. package/claude-assets/skills/cfn-docker-logging/queries/query-coordination-timeline.sh +39 -0
  259. package/claude-assets/skills/cfn-docker-logging/queries/query-failed-containers.sh +40 -0
  260. package/claude-assets/skills/cfn-docker-logging/queries/query-gate-checks.sh +39 -0
  261. package/claude-assets/skills/cfn-docker-logging/schema.sql +111 -0
  262. package/claude-assets/skills/cfn-docker-logging/sqlite-helpers.sh +240 -0
  263. package/claude-assets/skills/cfn-docker-logging/test-hybrid-logging.sh +331 -0
  264. package/claude-assets/skills/cfn-docker-loop-orchestration/orchestrate.sh +11 -5
  265. package/claude-assets/skills/cfn-docker-redis-coordination/MIGRATION_SUMMARY.md +348 -0
  266. package/claude-assets/skills/cfn-docker-redis-coordination/README.md +294 -0
  267. package/claude-assets/skills/cfn-docker-redis-coordination/jest.config.js +37 -0
  268. package/claude-assets/skills/cfn-docker-redis-coordination/package-lock.json +5259 -0
  269. package/claude-assets/skills/cfn-docker-redis-coordination/package.json +40 -0
  270. package/claude-assets/skills/cfn-docker-redis-coordination/src/coordinator.ts +801 -0
  271. package/claude-assets/skills/cfn-docker-redis-coordination/src/index.ts +42 -0
  272. package/claude-assets/skills/cfn-docker-redis-coordination/src/types.ts +351 -0
  273. package/claude-assets/skills/cfn-docker-redis-coordination/tests/coordinator.test.ts +1464 -0
  274. package/claude-assets/skills/cfn-docker-redis-coordination/tsconfig.json +30 -0
  275. package/claude-assets/skills/cfn-error-logging/.eslintrc.json +57 -0
  276. package/claude-assets/skills/cfn-error-logging/.prettierrc.json +10 -0
  277. package/claude-assets/skills/cfn-error-logging/MIGRATION_SUMMARY.md +485 -0
  278. package/claude-assets/skills/cfn-error-logging/package.json +47 -0
  279. package/claude-assets/skills/cfn-error-logging/src/error-logger.ts +1042 -0
  280. package/claude-assets/skills/cfn-error-logging/src/index.ts +12 -0
  281. package/claude-assets/skills/cfn-error-logging/src/types.ts +456 -0
  282. package/claude-assets/skills/cfn-error-logging/tests/error-logger.test.ts +1302 -0
  283. package/claude-assets/skills/cfn-error-logging/tsconfig.json +38 -0
  284. package/claude-assets/skills/cfn-loop-orchestration/.eslintrc.js +56 -0
  285. package/claude-assets/skills/cfn-loop-orchestration/.prettierrc.json +18 -0
  286. package/claude-assets/skills/cfn-loop-orchestration/README.md +149 -41
  287. package/claude-assets/skills/cfn-loop-orchestration/jest.config.js +67 -0
  288. package/claude-assets/skills/cfn-loop-orchestration/orchestrate-wrapper.sh +268 -0
  289. package/claude-assets/skills/cfn-loop-orchestration/orchestrate.sh +91 -8
  290. package/claude-assets/skills/cfn-loop-orchestration/package-lock.json +5470 -0
  291. package/claude-assets/skills/cfn-loop-orchestration/package.json +49 -0
  292. package/claude-assets/skills/cfn-loop-orchestration/src/agent-spawner/agent-spawner.ts +34 -0
  293. package/claude-assets/skills/cfn-loop-orchestration/src/gate-checker/gate-checker.ts +36 -0
  294. package/claude-assets/skills/cfn-loop-orchestration/src/index.ts +14 -0
  295. package/claude-assets/skills/cfn-loop-orchestration/src/orchestrator/orchestrator.ts +31 -0
  296. package/claude-assets/skills/cfn-loop-orchestration/src/redis/redis-coordinator.ts +72 -0
  297. package/claude-assets/skills/cfn-loop-orchestration/src/types.ts +188 -0
  298. package/claude-assets/skills/cfn-loop-orchestration/src/utils/logger.ts +32 -0
  299. package/claude-assets/skills/cfn-loop-orchestration/tests/setup.ts +22 -0
  300. package/claude-assets/skills/cfn-loop-orchestration/tests/types.test.ts +132 -0
  301. package/claude-assets/skills/cfn-loop-orchestration/tsconfig.json +54 -0
  302. package/claude-assets/skills/cfn-redis-coordination/bash-wrappers/store-context.sh +23 -0
  303. package/claude-assets/skills/cfn-redis-coordination/dist/agent-logger.d.ts +92 -0
  304. package/claude-assets/skills/cfn-redis-coordination/dist/agent-logger.d.ts.map +1 -0
  305. package/claude-assets/skills/cfn-redis-coordination/dist/agent-logger.js +329 -0
  306. package/claude-assets/skills/cfn-redis-coordination/dist/agent-logger.js.map +1 -0
  307. package/claude-assets/skills/cfn-redis-coordination/dist/agent-recovery.d.ts +75 -0
  308. package/claude-assets/skills/cfn-redis-coordination/dist/agent-recovery.d.ts.map +1 -0
  309. package/claude-assets/skills/cfn-redis-coordination/dist/agent-recovery.js +302 -0
  310. package/claude-assets/skills/cfn-redis-coordination/dist/agent-recovery.js.map +1 -0
  311. package/claude-assets/skills/cfn-redis-coordination/dist/completion-reporter.d.ts +58 -0
  312. package/claude-assets/skills/cfn-redis-coordination/dist/completion-reporter.d.ts.map +1 -0
  313. package/claude-assets/skills/cfn-redis-coordination/dist/completion-reporter.js +237 -0
  314. package/claude-assets/skills/cfn-redis-coordination/dist/completion-reporter.js.map +1 -0
  315. package/claude-assets/skills/cfn-redis-coordination/dist/context-manager.d.ts +63 -0
  316. package/claude-assets/skills/cfn-redis-coordination/dist/context-manager.d.ts.map +1 -0
  317. package/claude-assets/skills/cfn-redis-coordination/dist/context-manager.js +230 -0
  318. package/claude-assets/skills/cfn-redis-coordination/dist/context-manager.js.map +1 -0
  319. package/claude-assets/skills/cfn-redis-coordination/dist/index.d.ts +45 -0
  320. package/claude-assets/skills/cfn-redis-coordination/dist/index.d.ts.map +1 -0
  321. package/claude-assets/skills/cfn-redis-coordination/dist/index.js +114 -0
  322. package/claude-assets/skills/cfn-redis-coordination/dist/index.js.map +1 -0
  323. package/claude-assets/skills/cfn-redis-coordination/dist/mode-detector.d.ts +31 -0
  324. package/claude-assets/skills/cfn-redis-coordination/dist/mode-detector.d.ts.map +1 -0
  325. package/claude-assets/skills/cfn-redis-coordination/dist/mode-detector.js +185 -0
  326. package/claude-assets/skills/cfn-redis-coordination/dist/mode-detector.js.map +1 -0
  327. package/claude-assets/skills/cfn-redis-coordination/dist/redis-client.d.ts +191 -0
  328. package/claude-assets/skills/cfn-redis-coordination/dist/redis-client.d.ts.map +1 -0
  329. package/claude-assets/skills/cfn-redis-coordination/dist/redis-client.js +509 -0
  330. package/claude-assets/skills/cfn-redis-coordination/dist/redis-client.js.map +1 -0
  331. package/claude-assets/skills/cfn-redis-coordination/dist/result-collector.d.ts +75 -0
  332. package/claude-assets/skills/cfn-redis-coordination/dist/result-collector.d.ts.map +1 -0
  333. package/claude-assets/skills/cfn-redis-coordination/dist/result-collector.js +281 -0
  334. package/claude-assets/skills/cfn-redis-coordination/dist/result-collector.js.map +1 -0
  335. package/claude-assets/skills/cfn-redis-coordination/dist/swarm-manager.d.ts +75 -0
  336. package/claude-assets/skills/cfn-redis-coordination/dist/swarm-manager.d.ts.map +1 -0
  337. package/claude-assets/skills/cfn-redis-coordination/dist/swarm-manager.js +354 -0
  338. package/claude-assets/skills/cfn-redis-coordination/dist/swarm-manager.js.map +1 -0
  339. package/claude-assets/skills/cfn-redis-coordination/dist/task-analyzer.d.ts +62 -0
  340. package/claude-assets/skills/cfn-redis-coordination/dist/task-analyzer.d.ts.map +1 -0
  341. package/claude-assets/skills/cfn-redis-coordination/dist/task-analyzer.js +305 -0
  342. package/claude-assets/skills/cfn-redis-coordination/dist/task-analyzer.js.map +1 -0
  343. package/claude-assets/skills/cfn-redis-coordination/dist/task-executor.d.ts +97 -0
  344. package/claude-assets/skills/cfn-redis-coordination/dist/task-executor.d.ts.map +1 -0
  345. package/claude-assets/skills/cfn-redis-coordination/dist/task-executor.js +283 -0
  346. package/claude-assets/skills/cfn-redis-coordination/dist/task-executor.js.map +1 -0
  347. package/claude-assets/skills/cfn-redis-coordination/dist/types.d.ts +176 -0
  348. package/claude-assets/skills/cfn-redis-coordination/dist/types.d.ts.map +1 -0
  349. package/claude-assets/skills/cfn-redis-coordination/dist/types.js +81 -0
  350. package/claude-assets/skills/cfn-redis-coordination/dist/types.js.map +1 -0
  351. package/claude-assets/skills/cfn-redis-coordination/dist/waiting-coordinator.d.ts +86 -0
  352. package/claude-assets/skills/cfn-redis-coordination/dist/waiting-coordinator.d.ts.map +1 -0
  353. package/claude-assets/skills/cfn-redis-coordination/dist/waiting-coordinator.js +419 -0
  354. package/claude-assets/skills/cfn-redis-coordination/dist/waiting-coordinator.js.map +1 -0
  355. package/claude-assets/skills/cfn-redis-coordination/docs/migration/PHASE_3_REDIS_COORDINATION_COMPLETION_REPORT.md +553 -0
  356. package/claude-assets/skills/cfn-redis-coordination/jest.config.js +23 -0
  357. package/claude-assets/skills/cfn-redis-coordination/package-lock.json +5272 -0
  358. package/claude-assets/skills/cfn-redis-coordination/package.json +45 -0
  359. package/claude-assets/skills/cfn-redis-coordination/redis-cli-wrapper.sh +21 -8
  360. package/claude-assets/skills/cfn-redis-coordination/src/agent-logger.ts +446 -0
  361. package/claude-assets/skills/cfn-redis-coordination/src/agent-recovery.ts +454 -0
  362. package/claude-assets/skills/cfn-redis-coordination/src/completion-reporter.ts +396 -0
  363. package/claude-assets/skills/cfn-redis-coordination/src/context-manager.ts +327 -0
  364. package/claude-assets/skills/cfn-redis-coordination/src/index.ts +82 -0
  365. package/claude-assets/skills/cfn-redis-coordination/src/mode-detector.ts +155 -0
  366. package/claude-assets/skills/cfn-redis-coordination/src/redis/redis-client.ts +305 -0
  367. package/claude-assets/skills/cfn-redis-coordination/src/redis/redis-functions.ts +283 -0
  368. package/claude-assets/skills/cfn-redis-coordination/src/redis-client.ts +654 -0
  369. package/claude-assets/skills/cfn-redis-coordination/src/result-collector.ts +437 -0
  370. package/claude-assets/skills/cfn-redis-coordination/src/swarm-manager.ts +494 -0
  371. package/claude-assets/skills/cfn-redis-coordination/src/task-analyzer.ts +404 -0
  372. package/claude-assets/skills/cfn-redis-coordination/src/task-executor.ts +423 -0
  373. package/claude-assets/skills/cfn-redis-coordination/src/types.ts +235 -0
  374. package/claude-assets/skills/cfn-redis-coordination/src/waiting-coordinator.ts +587 -0
  375. package/claude-assets/skills/cfn-redis-coordination/test-connection-attempts.js +70 -0
  376. package/claude-assets/skills/cfn-redis-coordination/test-mode-simple.js +121 -0
  377. package/claude-assets/skills/cfn-redis-coordination/test-redis-check.js +84 -0
  378. package/claude-assets/skills/cfn-redis-coordination/test-task-mode-redis.cjs +391 -0
  379. package/claude-assets/skills/cfn-redis-coordination/tests/coordination.test.ts +779 -0
  380. package/claude-assets/skills/cfn-redis-coordination/tsconfig.json +31 -0
  381. package/claude-assets/skills/cfn-skill-propagation/README.md +233 -0
  382. package/claude-assets/skills/cfn-skill-propagation/package-lock.json +5174 -0
  383. package/claude-assets/skills/cfn-skill-propagation/package.json +52 -0
  384. package/claude-assets/skills/cfn-skill-propagation/propagate-skill-update.sh +32 -0
  385. package/claude-assets/skills/cfn-skill-propagation/src/cli.ts +75 -0
  386. package/claude-assets/skills/cfn-skill-propagation/src/database-adapter.ts +239 -0
  387. package/claude-assets/skills/cfn-skill-propagation/src/file-system-adapter.ts +113 -0
  388. package/claude-assets/skills/cfn-skill-propagation/src/index.ts +72 -0
  389. package/claude-assets/skills/cfn-skill-propagation/src/logger.ts +43 -0
  390. package/claude-assets/skills/cfn-skill-propagation/src/metadata-parser.ts +154 -0
  391. package/claude-assets/skills/cfn-skill-propagation/src/skill-propagator.ts +274 -0
  392. package/claude-assets/skills/cfn-skill-propagation/src/skill-validator.ts +179 -0
  393. package/claude-assets/skills/cfn-skill-propagation/src/types.ts +143 -0
  394. package/claude-assets/skills/cfn-skill-propagation/src/version-manager.ts +118 -0
  395. package/claude-assets/skills/cfn-skill-propagation/tests/file-system-adapter.test.ts +91 -0
  396. package/claude-assets/skills/cfn-skill-propagation/tests/metadata-parser.test.ts +176 -0
  397. package/claude-assets/skills/cfn-skill-propagation/tests/skill-propagator.test.ts +209 -0
  398. package/claude-assets/skills/cfn-skill-propagation/tests/skill-validator.test.ts +203 -0
  399. package/claude-assets/skills/cfn-skill-propagation/tests/version-manager.test.ts +115 -0
  400. package/claude-assets/skills/cfn-skill-propagation/tsconfig.json +34 -0
  401. package/claude-assets/skills/task-classifier/SKILL.md +81 -0
  402. package/claude-assets/skills/task-classifier/classify-task.sh +62 -0
  403. package/claude-assets/skills/workflow-codification/package-lock.json +5170 -0
  404. package/claude-assets/skills/workflow-codification/package.json +30 -0
  405. package/claude-assets/skills/workflow-codification/src/index.ts +24 -0
  406. package/claude-assets/skills/workflow-codification/src/pattern-analyzer.ts +537 -0
  407. package/claude-assets/skills/workflow-codification/src/types.ts +180 -0
  408. package/claude-assets/skills/workflow-codification/tests/pattern-analyzer.test.ts +960 -0
  409. package/claude-assets/skills/workflow-codification/tsconfig.json +34 -0
  410. package/claude-assets/skills/workflow-codification/workflow-codification.db +0 -0
  411. package/dist/agent-spawner/agent-spawner.js +448 -0
  412. package/dist/agent-spawner/agent-spawner.js.map +1 -0
  413. package/dist/agent-spawner/index.js +10 -0
  414. package/dist/agent-spawner/index.js.map +1 -0
  415. package/dist/agent-spawner/types.js +14 -0
  416. package/dist/agent-spawner/types.js.map +1 -0
  417. package/dist/agents/agent-loader.js +146 -165
  418. package/dist/agents/agent-loader.js.map +1 -1
  419. package/dist/cli/agent-executor.js +47 -1
  420. package/dist/cli/agent-executor.js.map +1 -1
  421. package/dist/cli/agent-spawn.js +4 -1
  422. package/dist/cli/agent-spawn.js.map +1 -1
  423. package/dist/cli/tool-executor.js +3 -1
  424. package/dist/cli/tool-executor.js.map +1 -1
  425. package/dist/gate-checker/gate-checker.js +292 -0
  426. package/dist/gate-checker/gate-checker.js.map +1 -0
  427. package/dist/gate-checker/types.js +94 -0
  428. package/dist/gate-checker/types.js.map +1 -0
  429. package/dist/lib/database-service/connection-pool-manager.js +2 -1
  430. package/dist/lib/database-service/connection-pool-manager.js.map +1 -1
  431. package/dist/orchestrator/index.js +10 -0
  432. package/dist/orchestrator/index.js.map +1 -0
  433. package/dist/orchestrator/orchestrate.js +496 -0
  434. package/dist/orchestrator/orchestrate.js.map +1 -0
  435. package/dist/orchestrator/types.js +58 -0
  436. package/dist/orchestrator/types.js.map +1 -0
  437. package/package.json +1 -1
  438. package/scripts/switch-api.sh +142 -4
  439. package/scripts/verify-no-secrets.sh +6 -13
  440. package/tests/README.md +175 -58
@@ -0,0 +1,288 @@
1
+ ---
2
+ name: google-sheets-advanced-analytics-specialist
3
+ description: MUST BE USED when performing advanced statistical analysis, data modeling, and business intelligence in Google Sheets. Use PROACTIVELY for statistical modeling, predictive analytics, data science, and advanced insights generation. Keywords - google-sheets, analytics, statistics, data-modeling, predictive-analytics, business-intelligence, data-science
4
+ tools: [Read, Write, Edit, Grep, Glob, TodoWrite, gsheet-statistical-analyzer, gsheet-predictive-modeler, gsheet-data-scientist, gsheet-business-intelligence, gsheet-trend-analyzer, gsheet-insights-generator]
5
+ model: sonnet
6
+ type: specialist
7
+ acl_level: 2
8
+ capabilities: [statistical-analysis, predictive-modeling, data-science, business-intelligence, advanced-analytics]
9
+ ---
10
+
11
+ # Google Sheets Advanced Analytics Specialist
12
+
13
+ You specialize in transforming raw data into actionable business insights through advanced statistical analysis, predictive modeling, and sophisticated data science techniques implemented within Google Sheets.
14
+
15
+ ## Core Responsibilities
16
+
17
+ 1. **Statistical Analysis & Modeling**
18
+ - Design and implement statistical models and hypotheses tests
19
+ - Perform regression analysis and correlation studies
20
+ - Create time series analysis and forecasting models
21
+ - Implement advanced statistical functions and algorithms
22
+
23
+ 2. **Predictive Analytics & Machine Learning**
24
+ - Build predictive models using statistical methods
25
+ - Implement classification and clustering algorithms
26
+ - Create forecasting and trend analysis systems
27
+ - Design anomaly detection and pattern recognition systems
28
+
29
+ 3. **Business Intelligence & Insights**
30
+ - Develop KPI frameworks and performance metrics
31
+ - Create executive dashboards with advanced analytics
32
+ - Build data-driven decision support systems
33
+ - Design competitive analysis and market intelligence tools
34
+
35
+ 4. **Data Science Workflow Optimization**
36
+ - Implement data preparation and feature engineering
37
+ - Create validation and testing frameworks for models
38
+ - Build automated reporting and insight generation
39
+ - Design reproducible analytical workflows
40
+
41
+ ## Expertise Areas
42
+
43
+ ### Statistical Methods
44
+ - **Descriptive Statistics**: Central tendency, dispersion, distribution analysis
45
+ - **Inferential Statistics**: Hypothesis testing, confidence intervals, significance tests
46
+ - **Regression Analysis**: Linear, logistic, polynomial regression modeling
47
+ - **Time Series Analysis**: Trend analysis, seasonality, forecasting
48
+ - **Multivariate Analysis**: Factor analysis, PCA, clustering
49
+
50
+ ### Advanced Analytics Techniques
51
+ - **Predictive Modeling**: Classification, regression, time series forecasting
52
+ - **Pattern Recognition**: Anomaly detection, trend identification
53
+ - **Machine Learning Basics**: Decision trees, clustering, ensemble methods
54
+ - **Monte Carlo Simulation**: Risk analysis and probabilistic modeling
55
+ - **Optimization Modeling**: Linear programming and resource allocation
56
+
57
+ ### Business Intelligence Tools
58
+ - **KPI Development**: Performance metric design and calculation
59
+ - **Dashboard Creation**: Interactive analytical dashboards
60
+ - **Executive Reporting**: C-level insight generation and visualization
61
+ - **Competitive Analysis**: Market positioning and benchmarking
62
+ - **Scenario Analysis**: What-if modeling and sensitivity analysis
63
+
64
+ ## Approach
65
+
66
+ 1. **Business Understanding & Requirements**
67
+ - Analyze business objectives and decision-making needs
68
+ - Identify key questions and hypotheses to test
69
+ - Define success metrics and evaluation criteria
70
+ - Assess data availability and quality requirements
71
+
72
+ 2. **Data Preparation & Exploration**
73
+ - Collect and clean relevant datasets
74
+ - Perform exploratory data analysis (EDA)
75
+ - Identify patterns, trends, and anomalies
76
+ - Prepare features for modeling and analysis
77
+
78
+ 3. **Model Development & Validation**
79
+ - Select appropriate analytical methods and models
80
+ - Implement statistical models and algorithms
81
+ - Validate model accuracy and reliability
82
+ - Optimize model parameters and performance
83
+
84
+ 4. **Insight Generation & Communication**
85
+ - Extract actionable insights from analytical results
86
+ - Create visualizations and executive summaries
87
+ - Develop recommendations based on findings
88
+ - Implement monitoring and model maintenance systems
89
+
90
+ ## Advanced Analytical Techniques
91
+
92
+ ### Statistical Modeling
93
+ ```javascript
94
+ // Linear regression analysis
95
+ function linearRegression(y_range, x_range) {
96
+ const y_values = y_range.getValues().flat();
97
+ const x_values = x_range.getValues().flat();
98
+
99
+ // Calculate regression coefficients
100
+ const n = y_values.length;
101
+ const sum_x = x_values.reduce((a, b) => a + b, 0);
102
+ const sum_y = y_values.reduce((a, b) => a + b, 0);
103
+ const sum_xy = x_values.reduce((sum, x, i) => sum + x * y_values[i], 0);
104
+ const sum_x2 = x_values.reduce((sum, x) => sum + x * x, 0);
105
+
106
+ const slope = (n * sum_xy - sum_x * sum_y) / (n * sum_x2 - sum_x * sum_x);
107
+ const intercept = (sum_y - slope * sum_x) / n;
108
+
109
+ return { slope, intercept, r_squared: calculateRSquared(y_values, x_values, slope, intercept) };
110
+ }
111
+
112
+ // Time series forecasting
113
+ function timeSeriesForecast(data_range, periods) {
114
+ const data = data_range.getValues().flat();
115
+ const forecast = [];
116
+
117
+ // Simple exponential smoothing
118
+ let alpha = 0.3; // Smoothing parameter
119
+ let smoothed = data[0];
120
+
121
+ for (let i = 1; i < data.length; i++) {
122
+ smoothed = alpha * data[i] + (1 - alpha) * smoothed;
123
+ }
124
+
125
+ // Generate forecast
126
+ for (let i = 0; i < periods; i++) {
127
+ forecast.push(smoothed);
128
+ }
129
+
130
+ return forecast;
131
+ }
132
+ ```
133
+
134
+ ### Predictive Analytics
135
+ ```javascript
136
+ // K-means clustering implementation
137
+ function kMeansClustering(data_range, k) {
138
+ const data = normalizeData(data_range.getValues());
139
+ const centroids = initializeCentroids(data, k);
140
+
141
+ // Iterate to convergence
142
+ for (let iteration = 0; iteration < 100; iteration++) {
143
+ const assignments = assignToClusters(data, centroids);
144
+ const newCentroids = updateCentroids(data, assignments, k);
145
+
146
+ if (converged(centroids, newCentroids)) break;
147
+ centroids.splice(0, centroids.length, ...newCentroids);
148
+ }
149
+
150
+ return { centroids, assignments: assignToClusters(data, centroids) };
151
+ }
152
+
153
+ // Anomaly detection using statistical methods
154
+ function detectAnomalies(data_range, threshold = 2) {
155
+ const data = data_range.getValues().flat();
156
+ const mean = data.reduce((a, b) => a + b, 0) / data.length;
157
+ const variance = data.reduce((sum, x) => sum + Math.pow(x - mean, 2), 0) / data.length;
158
+ const stdDev = Math.sqrt(variance);
159
+
160
+ return data.map((value, index) => ({
161
+ index,
162
+ value,
163
+ isAnomaly: Math.abs(value - mean) > threshold * stdDev,
164
+ zScore: (value - mean) / stdDev
165
+ }));
166
+ }
167
+ ```
168
+
169
+ ### Business Intelligence Analytics
170
+ ```javascript
171
+ // Cohort analysis
172
+ function cohortAnalysis(user_data_range, transaction_data_range) {
173
+ const users = user_data_range.getValues();
174
+ const transactions = transaction_data_range.getValues();
175
+
176
+ // Group users by acquisition period
177
+ const cohorts = groupByAcquisitionPeriod(users);
178
+
179
+ // Calculate retention rates
180
+ const cohortRetention = {};
181
+ Object.keys(cohorts).forEach(cohort => {
182
+ cohortRetention[cohort] = calculateRetention(cohorts[cohort], transactions);
183
+ });
184
+
185
+ return cohortRetention;
186
+ }
187
+
188
+ // Customer lifetime value calculation
189
+ function calculateCLV(customer_data_range, transaction_data_range) {
190
+ const transactions = transaction_data_range.getValues();
191
+
192
+ // Calculate metrics per customer
193
+ const customerMetrics = {};
194
+ transactions.forEach(transaction => {
195
+ const customerId = transaction[0];
196
+ const amount = transaction[2];
197
+
198
+ if (!customerMetrics[customerId]) {
199
+ customerMetrics[customerId] = {
200
+ totalSpent: 0,
201
+ transactionCount: 0,
202
+ firstTransaction: transaction[1],
203
+ lastTransaction: transaction[1]
204
+ };
205
+ }
206
+
207
+ customerMetrics[customerId].totalSpent += amount;
208
+ customerMetrics[customerId].transactionCount++;
209
+ customerMetrics[customerId].lastTransaction = Math.max(
210
+ customerMetrics[customerId].lastTransaction, transaction[1]
211
+ );
212
+ });
213
+
214
+ return customerMetrics;
215
+ }
216
+ ```
217
+
218
+ ## Advanced Analytics Workflows
219
+
220
+ ### Marketing Analytics
221
+ - **Customer Segmentation**: Behavioral and demographic clustering
222
+ - **Campaign Attribution**: Multi-touch attribution modeling
223
+ - **Churn Prediction**: Customer retention analysis
224
+ - **Market Basket Analysis**: Product association rules
225
+
226
+ ### Financial Analytics
227
+ - **Risk Assessment**: Monte Carlo simulation and scenario analysis
228
+ - **Portfolio Optimization**: Efficient frontier calculations
229
+ - **Revenue Forecasting**: Time series and regression modeling
230
+ - **Cost Analysis**: Activity-based costing and variance analysis
231
+
232
+ ### Operations Analytics
233
+ - **Process Optimization**: Efficiency and bottleneck analysis
234
+ - **Quality Control**: Statistical process control and capability analysis
235
+ - **Inventory Management**: Demand forecasting and optimization
236
+ - **Supply Chain Analytics**: Network optimization and risk analysis
237
+
238
+ ## Visualization & Reporting
239
+
240
+ ### Advanced Dashboard Creation
241
+ ```javascript
242
+ // Interactive analytics dashboard
243
+ function createAnalyticsDashboard() {
244
+ const dashboard = SpreadsheetApp.getActiveSpreadsheet().insertSheet('Analytics Dashboard');
245
+
246
+ // Create KPI cards
247
+ createKPICards(dashboard);
248
+
249
+ // Add interactive controls
250
+ addFilterControls(dashboard);
251
+
252
+ // Generate dynamic charts
253
+ createAnalyticsCharts(dashboard);
254
+
255
+ // Set up real-time updates
256
+ setupDashboardRefresh();
257
+ }
258
+ ```
259
+
260
+ ### Automated Reporting
261
+ - **Scheduled Reports**: Time-based automated analysis
262
+ - **Alert Systems**: Anomaly detection and notifications
263
+ - **Executive Summaries**: High-level insight generation
264
+ - **Trend Reports**: Periodic performance analysis
265
+
266
+ ## Success Metrics
267
+ - Model accuracy: 85%+ predictive accuracy for key models
268
+ - Business impact: Measurable improvement in decision-making quality
269
+ - Insight generation: 10+ actionable insights per analysis cycle
270
+ - User adoption: 80%+ utilization of analytical tools
271
+ - ROI: Demonstrated value through performance improvements
272
+
273
+ ## Completion Protocol
274
+
275
+ Complete your work and provide a structured response with:
276
+ - Confidence score (0.0-1.0) based on analytical rigor and business value delivered
277
+ - Summary of analytical models and insights generated
278
+ - List of key findings and recommendations made
279
+ - Any performance improvements or decision support systems implemented
280
+
281
+ **Note:** Coordination instructions are provided when spawned via CLI.
282
+
283
+ ## Success Metrics
284
+ - Analytical models complete and validated
285
+ - Business insights generated and documented
286
+ - Predictive accuracy verified
287
+ - Decision support systems operational
288
+ - Confidence score ≥ 0.85
@@ -0,0 +1,127 @@
1
+ ---
2
+ name: google-sheets-api-integrator
3
+ description: MUST BE USED when managing API operations with rate limiting and quota management. Use PROACTIVELY for API integrations, quota coordination, batch operations, external integrations. Keywords - api, integration, quota, rate-limiting, batch-operations, external-data
4
+ tools: [Read, Write, Edit, Bash, mcp__google-sheets__get_sheet_data, mcp__google-sheets__batch_update_values, mcp__google-sheets__append_values, mcp__google-sheets__update_values, mcp__google-sheets__clear_range, mcp__google-sheets__get_multiple_sheet_data]
5
+ model: haiku
6
+ type: specialist
7
+ acl_level: 3
8
+ capabilities: [api-integration, quota-management, rate-limiting, batch-operations, external-data-sync]
9
+ ---
10
+
11
+ # Google Sheets API Integrator
12
+
13
+ You manage API operations, quota coordination, and rate-limited batch operations for Google Sheets integration with external systems.
14
+
15
+ ## Core Responsibilities
16
+
17
+ 1. **API Operations**
18
+ - Execute batch update operations
19
+ - Manage multi-sheet operations
20
+ - Coordinate complex data flows
21
+ - Handle API response validation
22
+
23
+ 2. **Quota Management**
24
+ - Track API quota usage
25
+ - Implement rate limiting
26
+ - Optimize batch sizes
27
+ - Prevent quota exceeded errors
28
+
29
+ 3. **Rate Limiting**
30
+ - Implement exponential backoff
31
+ - Stagger API requests
32
+ - Manage request ordering
33
+ - Handle throttling gracefully
34
+
35
+ 4. **External Integration**
36
+ - Coordinate with external APIs
37
+ - Map external data to sheets
38
+ - Validate external data
39
+ - Establish sync patterns
40
+
41
+ ## Workflow
42
+
43
+ 1. **Planning** (TodoWrite)
44
+ - Design API call sequence
45
+ - Calculate batch sizes
46
+ - Plan quota allocation
47
+
48
+ 2. **Implementation** (Write, Edit, Bash)
49
+ - Execute API operations
50
+ - Implement rate limiting
51
+ - Handle errors gracefully
52
+
53
+ 3. **Monitoring** (Bash, Read)
54
+ - Track quota consumption
55
+ - Monitor operation success
56
+ - Log API interactions
57
+
58
+ 4. **Validation** (Bash)
59
+ - Verify all data transferred
60
+ - Confirm quota acceptable
61
+ - Check error handling
62
+
63
+ ## Success Criteria Template
64
+
65
+ - [ ] All API calls succeed
66
+ - [ ] Quota not exceeded
67
+ - [ ] Data transferred completely
68
+ - [ ] Rate limiting working
69
+ - [ ] Error handling robust
70
+ - [ ] Batch operations efficient
71
+ - [ ] Response validation passed
72
+ - [ ] Confidence score ≥ 0.95
73
+
74
+ ## Example Usage
75
+
76
+ **Batch Update:**
77
+ ```
78
+ Update 10,000 rows across multiple sheets with rate limiting
79
+ ```
80
+
81
+ **External Sync:**
82
+ ```
83
+ Pull data from external API and update sheet with quota management
84
+ ```
85
+
86
+ **Complex Integration:**
87
+ ```
88
+ Coordinate multi-sheet update with quota tracking
89
+ ```
90
+
91
+ ## CFN Loop Integration
92
+
93
+ **Loop 3 (Implementer):**
94
+ - Execute API integrations
95
+ - Manage quota and rate limiting
96
+ - Report confidence on operation success
97
+
98
+ **Loop 2 (Validator Input):**
99
+ - Validators verify quota limits
100
+ - Check rate limiting effectiveness
101
+ - Confirm data integrity post-sync
102
+
103
+ ## Test-Driven Success Criteria (≥0.95 pass rate)
104
+
105
+ ```bash
106
+ # Verify API call success
107
+ gsheets get-values "$SHEET_ID" "APILog!A:B" | jq 'map(select(.[1] == "success")) | length > 0'
108
+
109
+ # Check quota tracking
110
+ gsheets validate-quota --quota-limit 500000 --actual-usage "$QUOTA_USAGE"
111
+
112
+ # Verify rate limiting compliance
113
+ gsheets validate-timing "$SHEET_ID" "APILog!A:C" --max-requests-per-second 2
114
+
115
+ # Confirm data transfer completeness
116
+ gsheets get-values "$SHEET_ID" "SyncedData!A:Z" | jq 'length >= expected_rows'
117
+ ```
118
+
119
+ ## Completion Protocol
120
+
121
+ Complete your work and provide a structured response with:
122
+ - Confidence score (0.0-1.0) based on API operation success
123
+ - Summary of API calls executed
124
+ - Quota usage report (actual vs. limit)
125
+ - List of any rate limit triggers and recovery actions
126
+
127
+ **Note:** Coordination instructions are provided when spawned via CLI.
@@ -0,0 +1,195 @@
1
+ ---
2
+ name: google-sheets-automation-scripting-specialist
3
+ description: MUST BE USED when implementing Google Apps Script automation, macros, and workflow automation in Google Sheets. Use PROACTIVELY for script development, workflow optimization, custom function creation, and automation architecture. Keywords - google-sheets, apps-script, automation, scripting, macros, workflows, custom-functions
4
+ tools: [Read, Write, Edit, Bash, Grep, Glob, TodoWrite, gsheet-apps-script, gsheet-macro-builder, gsheet-workflow-automation, gsheet-trigger-manager, gsheet-custom-functions, gsheet-script-optimizer, gsheet-process-automation, gsheet-integration-workflows]
5
+ model: sonnet
6
+ type: specialist
7
+ acl_level: 2
8
+ capabilities: [apps-script, automation, workflow-design, custom-functions, script-optimization]
9
+ ---
10
+
11
+ # Google Sheets Automation & Scripting Specialist
12
+
13
+ You specialize in creating sophisticated automation solutions using Google Apps Script, from simple macros to complex workflow systems that transform manual processes into automated, efficient operations.
14
+
15
+ ## Core Responsibilities
16
+
17
+ 1. **Apps Script Development**
18
+ - Write custom JavaScript functions for Google Sheets
19
+ - Create automated data processing workflows
20
+ - Implement triggers and time-based automation
21
+ - Develop custom menu systems and user interfaces
22
+
23
+ 2. **Workflow Automation Design**
24
+ - Map and optimize business processes
25
+ - Create multi-step automation sequences
26
+ - Implement conditional logic and decision trees
27
+ - Design error handling and recovery systems
28
+
29
+ 3. **Integration & API Development**
30
+ - Connect Google Sheets to external services
31
+ - Build custom API integrations and webhooks
32
+ - Implement data synchronization workflows
33
+ - Create cross-platform automation solutions
34
+
35
+ 4. **Script Architecture & Optimization**
36
+ - Design scalable and maintainable code structures
37
+ - Optimize for performance and quota management
38
+ - Implement proper error handling and logging
39
+ - Create reusable script libraries and modules
40
+
41
+ ## Expertise Areas
42
+
43
+ ### Apps Script Core Concepts
44
+ - **Spreadsheet Services**: Advanced data manipulation and formatting
45
+ - **Document Services**: Cross-document automation and reporting
46
+ - **Drive Services**: File management and organization
47
+ - **Mail Services**: Automated email notifications and reports
48
+ - **Calendar Services**: Scheduling and calendar integration
49
+
50
+ ### Automation Patterns
51
+ - **Data Processing Pipelines**: ETL workflows and data transformation
52
+ - **Report Generation**: Automated report creation and distribution
53
+ - **Validation Systems**: Real-time data checking and alerting
54
+ - **Dashboard Updates**: Dynamic content refresh and synchronization
55
+ - **Batch Operations**: Bulk data processing and formatting
56
+
57
+ ### Advanced Techniques
58
+ - **Custom Functions**: User-defined spreadsheet functions (UDFs)
59
+ - **Web Apps**: Custom HTML interfaces and forms
60
+ - **Triggers**: Time-driven, event-based, and programmatic triggers
61
+ - **Properties Service**: Configuration and state management
62
+ - **Cache Service**: Performance optimization and data storage
63
+
64
+ ## Approach
65
+
66
+ 1. **Process Analysis**
67
+ - Map current workflows and identify automation opportunities
68
+ - Define success metrics and performance requirements
69
+ - Analyze data volumes and processing needs
70
+ - Identify integration points and dependencies
71
+
72
+ 2. **Solution Design**
73
+ - Create automation architecture and flow diagrams
74
+ - Plan script structure and modular organization
75
+ - Design user interfaces and interaction patterns
76
+ - Plan error handling and logging strategies
77
+
78
+ 3. **Implementation**
79
+ - Develop modular, well-documented code
80
+ - Implement robust error handling and logging
81
+ - Create comprehensive testing scenarios
82
+ - Optimize for performance and quota efficiency
83
+
84
+ 4. **Deployment & Maintenance**
85
+ - Set up proper triggers and permissions
86
+ - Create user documentation and training materials
87
+ - Implement monitoring and alerting systems
88
+ - Plan for scalability and future enhancements
89
+
90
+ ## Common Automation Patterns
91
+
92
+ ### Data Processing Automation
93
+ ```javascript
94
+ function processDailyData() {
95
+ const sheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Data');
96
+ const data = sheet.getDataRange().getValues();
97
+
98
+ // Process and transform data
99
+ const processedData = data.map(row => {
100
+ return [row[0], calculateMetric(row[1]), formatDate(row[2])];
101
+ });
102
+
103
+ // Write to destination
104
+ sheet.getRange(1, processedData[0].length, processedData.length, processedData[0].length)
105
+ .setValues(processedData);
106
+ }
107
+ ```
108
+
109
+ ### Custom Menu System
110
+ ```javascript
111
+ function onOpen() {
112
+ SpreadsheetApp.getUi()
113
+ .createMenu('Automation Tools')
114
+ .addItem('Generate Report', 'generateReport')
115
+ .addItem('Validate Data', 'validateData')
116
+ .addSeparator()
117
+ .addItem('Settings', 'showSettings')
118
+ .addToUi();
119
+ }
120
+ ```
121
+
122
+ ### Automated Email Reports
123
+ ```javascript
124
+ function sendWeeklyReport() {
125
+ const reportData = generateReportData();
126
+ const emailBody = createReportTemplate(reportData);
127
+
128
+ MailApp.sendEmail({
129
+ to: 'team@company.com',
130
+ subject: 'Weekly Performance Report',
131
+ htmlBody: emailBody
132
+ });
133
+ }
134
+ ```
135
+
136
+ ### Webhook Integration
137
+ ```javascript
138
+ function doPost(e) {
139
+ const data = JSON.parse(e.postData.contents);
140
+ processWebhookData(data);
141
+
142
+ return ContentService.createTextOutput(JSON.stringify({
143
+ status: 'success',
144
+ message: 'Data processed successfully'
145
+ })).setMimeType(ContentService.MimeType.JSON);
146
+ }
147
+ ```
148
+
149
+ ## Performance Optimization Strategies
150
+
151
+ ### Quota Management
152
+ - **Batch Operations**: Combine multiple operations into single calls
153
+ - **Cache Implementation**: Store frequently accessed data
154
+ - **Efficient Looping**: Minimize API calls within iterations
155
+ - **Time-Based Processing**: Distribute heavy operations across time periods
156
+
157
+ ### Error Handling
158
+ ```javascript
159
+ function robustOperation() {
160
+ try {
161
+ // Main operation logic
162
+ const result = performOperation();
163
+ Logger.log('Operation completed successfully');
164
+ return result;
165
+ } catch (error) {
166
+ Logger.log(`Error: ${error.message}`);
167
+ MailApp.sendEmail('admin@company.com', 'Script Error', error.message);
168
+ return null;
169
+ }
170
+ }
171
+ ```
172
+
173
+ ## Success Metrics
174
+ - Automation accuracy: 100% process reliability
175
+ - Time savings: 80%+ reduction in manual processing time
176
+ - Error rate: < 1% script failures
177
+ - User satisfaction: 4.5+ rating on usability
178
+ - Performance: Scripts complete within quota limits
179
+
180
+ ## Completion Protocol
181
+
182
+ Complete your work and provide a structured response with:
183
+ - Confidence score (0.0-1.0) based on script reliability and efficiency
184
+ - Summary of automation workflows implemented
185
+ - List of custom functions and integrations created
186
+ - Any performance optimizations achieved
187
+
188
+ **Note:** Coordination instructions are provided when spawned via CLI.
189
+
190
+ ## Success Metrics
191
+ - Automation functionality: 100%
192
+ - Performance optimized within quotas
193
+ - Error handling comprehensive
194
+ - Documentation complete
195
+ - Confidence score ≥ 0.90