@codemieai/code 0.0.36 → 0.0.38

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 (233) hide show
  1. package/README.md +33 -0
  2. package/dist/agents/codemie-code/tools/assistant-invocation.d.ts.map +1 -1
  3. package/dist/agents/codemie-code/tools/assistant-invocation.js +2 -2
  4. package/dist/agents/codemie-code/tools/assistant-invocation.js.map +1 -1
  5. package/dist/agents/core/BaseAgentAdapter.d.ts.map +1 -1
  6. package/dist/agents/core/BaseAgentAdapter.js +23 -9
  7. package/dist/agents/core/BaseAgentAdapter.js.map +1 -1
  8. package/dist/agents/core/extension/BaseExtensionInstaller.d.ts.map +1 -1
  9. package/dist/agents/core/extension/BaseExtensionInstaller.js +11 -4
  10. package/dist/agents/core/extension/BaseExtensionInstaller.js.map +1 -1
  11. package/dist/agents/core/session/BaseProcessor.d.ts +22 -1
  12. package/dist/agents/core/session/BaseProcessor.d.ts.map +1 -1
  13. package/dist/agents/plugins/claude/claude-acp.plugin.d.ts +5 -0
  14. package/dist/agents/plugins/claude/claude-acp.plugin.d.ts.map +1 -1
  15. package/dist/agents/plugins/claude/claude-acp.plugin.js +12 -2
  16. package/dist/agents/plugins/claude/claude-acp.plugin.js.map +1 -1
  17. package/dist/agents/plugins/claude/claude.plugin.d.ts +11 -0
  18. package/dist/agents/plugins/claude/claude.plugin.d.ts.map +1 -1
  19. package/dist/agents/plugins/claude/claude.plugin.js +59 -2
  20. package/dist/agents/plugins/claude/claude.plugin.js.map +1 -1
  21. package/dist/agents/plugins/claude/claude.session.d.ts +5 -0
  22. package/dist/agents/plugins/claude/claude.session.d.ts.map +1 -1
  23. package/dist/agents/plugins/claude/claude.session.js +101 -2
  24. package/dist/agents/plugins/claude/claude.session.js.map +1 -1
  25. package/dist/agents/plugins/claude/plugin/.claude-plugin/plugin.json +1 -1
  26. package/dist/agents/plugins/claude/plugin/commands/README.md +103 -22
  27. package/dist/agents/plugins/claude/plugin/commands/memory-refresh.md +329 -18
  28. package/dist/agents/plugins/claude/session/processors/claude.conversations-processor.d.ts +0 -1
  29. package/dist/agents/plugins/claude/session/processors/claude.conversations-processor.d.ts.map +1 -1
  30. package/dist/agents/plugins/claude/session/processors/claude.conversations-processor.js +13 -19
  31. package/dist/agents/plugins/claude/session/processors/claude.conversations-processor.js.map +1 -1
  32. package/dist/agents/plugins/claude/session/processors/claude.metrics-processor.d.ts.map +1 -1
  33. package/dist/agents/plugins/claude/session/processors/claude.metrics-processor.js +29 -4
  34. package/dist/agents/plugins/claude/session/processors/claude.metrics-processor.js.map +1 -1
  35. package/dist/cli/commands/assistants/chat.js +9 -6
  36. package/dist/cli/commands/assistants/chat.js.map +1 -1
  37. package/dist/cli/commands/assistants/constants.d.ts +2 -6
  38. package/dist/cli/commands/assistants/constants.d.ts.map +1 -1
  39. package/dist/cli/commands/assistants/constants.js +2 -5
  40. package/dist/cli/commands/assistants/constants.js.map +1 -1
  41. package/dist/cli/commands/assistants/index.d.ts.map +1 -1
  42. package/dist/cli/commands/assistants/index.js +1 -11
  43. package/dist/cli/commands/assistants/index.js.map +1 -1
  44. package/dist/cli/commands/assistants/setup/configuration/actions.d.ts +30 -0
  45. package/dist/cli/commands/assistants/setup/configuration/actions.d.ts.map +1 -0
  46. package/dist/cli/commands/assistants/setup/configuration/actions.js +63 -0
  47. package/dist/cli/commands/assistants/setup/configuration/actions.js.map +1 -0
  48. package/dist/cli/commands/assistants/setup/configuration/constants.d.ts +49 -0
  49. package/dist/cli/commands/assistants/setup/configuration/constants.d.ts.map +1 -0
  50. package/dist/cli/commands/assistants/setup/configuration/constants.js +56 -0
  51. package/dist/cli/commands/assistants/setup/configuration/constants.js.map +1 -0
  52. package/dist/cli/commands/assistants/setup/configuration/index.d.ts +9 -0
  53. package/dist/cli/commands/assistants/setup/configuration/index.d.ts.map +1 -0
  54. package/dist/cli/commands/assistants/setup/configuration/index.js +8 -0
  55. package/dist/cli/commands/assistants/setup/configuration/index.js.map +1 -0
  56. package/dist/cli/commands/assistants/setup/configuration/selection.d.ts +12 -0
  57. package/dist/cli/commands/assistants/setup/configuration/selection.d.ts.map +1 -0
  58. package/dist/cli/commands/assistants/setup/configuration/selection.js +94 -0
  59. package/dist/cli/commands/assistants/setup/configuration/selection.js.map +1 -0
  60. package/dist/cli/commands/assistants/setup/configuration/types.d.ts +22 -0
  61. package/dist/cli/commands/assistants/setup/configuration/types.d.ts.map +1 -0
  62. package/dist/cli/commands/assistants/setup/configuration/types.js +2 -0
  63. package/dist/cli/commands/assistants/setup/configuration/types.js.map +1 -0
  64. package/dist/cli/commands/assistants/setup/configuration/ui.d.ts +9 -0
  65. package/dist/cli/commands/assistants/setup/configuration/ui.d.ts.map +1 -0
  66. package/dist/cli/commands/assistants/setup/configuration/ui.js +86 -0
  67. package/dist/cli/commands/assistants/setup/configuration/ui.js.map +1 -0
  68. package/dist/cli/commands/assistants/setup/constants.d.ts +26 -0
  69. package/dist/cli/commands/assistants/setup/constants.d.ts.map +1 -0
  70. package/dist/cli/commands/assistants/setup/constants.js +21 -0
  71. package/dist/cli/commands/assistants/setup/constants.js.map +1 -0
  72. package/dist/cli/commands/assistants/setup/data.d.ts +30 -0
  73. package/dist/cli/commands/assistants/setup/data.d.ts.map +1 -0
  74. package/dist/cli/commands/assistants/setup/data.js +125 -0
  75. package/dist/cli/commands/assistants/setup/data.js.map +1 -0
  76. package/dist/cli/commands/assistants/setup/generators/claude-agent-generator.d.ts.map +1 -0
  77. package/dist/cli/commands/assistants/{generators → setup/generators}/claude-agent-generator.js +6 -2
  78. package/dist/cli/commands/assistants/setup/generators/claude-agent-generator.js.map +1 -0
  79. package/dist/cli/commands/assistants/setup/generators/claude-skill-generator.d.ts +12 -0
  80. package/dist/cli/commands/assistants/setup/generators/claude-skill-generator.d.ts.map +1 -0
  81. package/dist/cli/commands/assistants/setup/generators/claude-skill-generator.js +94 -0
  82. package/dist/cli/commands/assistants/setup/generators/claude-skill-generator.js.map +1 -0
  83. package/dist/cli/commands/assistants/setup/helpers.d.ts +27 -0
  84. package/dist/cli/commands/assistants/setup/helpers.d.ts.map +1 -0
  85. package/dist/cli/commands/assistants/setup/helpers.js +94 -0
  86. package/dist/cli/commands/assistants/setup/helpers.js.map +1 -0
  87. package/dist/cli/commands/assistants/setup/index.d.ts +17 -0
  88. package/dist/cli/commands/assistants/setup/index.d.ts.map +1 -0
  89. package/dist/cli/commands/assistants/setup/index.js +193 -0
  90. package/dist/cli/commands/assistants/setup/index.js.map +1 -0
  91. package/dist/cli/commands/assistants/setup/manualConfiguration/actions.d.ts +47 -0
  92. package/dist/cli/commands/assistants/setup/manualConfiguration/actions.d.ts.map +1 -0
  93. package/dist/cli/commands/assistants/setup/manualConfiguration/actions.js +140 -0
  94. package/dist/cli/commands/assistants/setup/manualConfiguration/actions.js.map +1 -0
  95. package/dist/cli/commands/assistants/setup/manualConfiguration/constants.d.ts +56 -0
  96. package/dist/cli/commands/assistants/setup/manualConfiguration/constants.d.ts.map +1 -0
  97. package/dist/cli/commands/assistants/setup/manualConfiguration/constants.js +61 -0
  98. package/dist/cli/commands/assistants/setup/manualConfiguration/constants.js.map +1 -0
  99. package/dist/cli/commands/assistants/setup/manualConfiguration/index.d.ts +12 -0
  100. package/dist/cli/commands/assistants/setup/manualConfiguration/index.d.ts.map +1 -0
  101. package/dist/cli/commands/assistants/setup/manualConfiguration/index.js +48 -0
  102. package/dist/cli/commands/assistants/setup/manualConfiguration/index.js.map +1 -0
  103. package/dist/cli/commands/assistants/setup/manualConfiguration/interactive-prompt.d.ts +6 -0
  104. package/dist/cli/commands/assistants/setup/manualConfiguration/interactive-prompt.d.ts.map +1 -0
  105. package/dist/cli/commands/assistants/setup/manualConfiguration/interactive-prompt.js +90 -0
  106. package/dist/cli/commands/assistants/setup/manualConfiguration/interactive-prompt.js.map +1 -0
  107. package/dist/cli/commands/assistants/setup/manualConfiguration/types.d.ts +37 -0
  108. package/dist/cli/commands/assistants/setup/manualConfiguration/types.d.ts.map +1 -0
  109. package/dist/cli/commands/assistants/setup/manualConfiguration/types.js +2 -0
  110. package/dist/cli/commands/assistants/setup/manualConfiguration/types.js.map +1 -0
  111. package/dist/cli/commands/assistants/setup/manualConfiguration/ui.d.ts +6 -0
  112. package/dist/cli/commands/assistants/setup/manualConfiguration/ui.d.ts.map +1 -0
  113. package/dist/cli/commands/assistants/setup/manualConfiguration/ui.js +103 -0
  114. package/dist/cli/commands/assistants/setup/manualConfiguration/ui.js.map +1 -0
  115. package/dist/cli/commands/assistants/setup/selection/actions.d.ts +31 -0
  116. package/dist/cli/commands/assistants/setup/selection/actions.d.ts.map +1 -0
  117. package/dist/cli/commands/assistants/setup/selection/actions.js +321 -0
  118. package/dist/cli/commands/assistants/setup/selection/actions.js.map +1 -0
  119. package/dist/cli/commands/assistants/setup/selection/constants.d.ts +79 -0
  120. package/dist/cli/commands/assistants/setup/selection/constants.d.ts.map +1 -0
  121. package/dist/cli/commands/assistants/setup/selection/constants.js +90 -0
  122. package/dist/cli/commands/assistants/setup/selection/constants.js.map +1 -0
  123. package/dist/cli/commands/assistants/setup/selection/index.d.ts +25 -0
  124. package/dist/cli/commands/assistants/setup/selection/index.d.ts.map +1 -0
  125. package/dist/cli/commands/assistants/setup/selection/index.js +127 -0
  126. package/dist/cli/commands/assistants/setup/selection/index.js.map +1 -0
  127. package/dist/cli/commands/assistants/setup/selection/interactive-prompt.d.ts +20 -0
  128. package/dist/cli/commands/assistants/setup/selection/interactive-prompt.d.ts.map +1 -0
  129. package/dist/cli/commands/assistants/setup/selection/interactive-prompt.js +328 -0
  130. package/dist/cli/commands/assistants/setup/selection/interactive-prompt.js.map +1 -0
  131. package/dist/cli/commands/assistants/setup/selection/types.d.ts +27 -0
  132. package/dist/cli/commands/assistants/setup/selection/types.d.ts.map +1 -0
  133. package/dist/cli/commands/assistants/setup/selection/types.js +2 -0
  134. package/dist/cli/commands/assistants/setup/selection/types.js.map +1 -0
  135. package/dist/cli/commands/assistants/setup/selection/ui.d.ts +11 -0
  136. package/dist/cli/commands/assistants/setup/selection/ui.d.ts.map +1 -0
  137. package/dist/cli/commands/assistants/setup/selection/ui.js +189 -0
  138. package/dist/cli/commands/assistants/setup/selection/ui.js.map +1 -0
  139. package/dist/cli/commands/assistants/setup/selection/utils.d.ts +36 -0
  140. package/dist/cli/commands/assistants/setup/selection/utils.d.ts.map +1 -0
  141. package/dist/cli/commands/assistants/setup/selection/utils.js +55 -0
  142. package/dist/cli/commands/assistants/setup/selection/utils.js.map +1 -0
  143. package/dist/cli/commands/assistants/setup/summary/index.d.ts +16 -0
  144. package/dist/cli/commands/assistants/setup/summary/index.d.ts.map +1 -0
  145. package/dist/cli/commands/assistants/setup/summary/index.js +48 -0
  146. package/dist/cli/commands/assistants/setup/summary/index.js.map +1 -0
  147. package/dist/cli/commands/hook.d.ts +72 -0
  148. package/dist/cli/commands/hook.d.ts.map +1 -1
  149. package/dist/cli/commands/hook.js +290 -110
  150. package/dist/cli/commands/hook.js.map +1 -1
  151. package/dist/cli/commands/log/cleaner.d.ts +37 -0
  152. package/dist/cli/commands/log/cleaner.d.ts.map +1 -0
  153. package/dist/cli/commands/log/cleaner.js +218 -0
  154. package/dist/cli/commands/log/cleaner.js.map +1 -0
  155. package/dist/cli/commands/log/filter.d.ts +55 -0
  156. package/dist/cli/commands/log/filter.d.ts.map +1 -0
  157. package/dist/cli/commands/log/filter.js +128 -0
  158. package/dist/cli/commands/log/filter.js.map +1 -0
  159. package/dist/cli/commands/log/follower.d.ts +36 -0
  160. package/dist/cli/commands/log/follower.d.ts.map +1 -0
  161. package/dist/cli/commands/log/follower.js +151 -0
  162. package/dist/cli/commands/log/follower.js.map +1 -0
  163. package/dist/cli/commands/log/formatter.d.ts +76 -0
  164. package/dist/cli/commands/log/formatter.d.ts.map +1 -0
  165. package/dist/cli/commands/log/formatter.js +261 -0
  166. package/dist/cli/commands/log/formatter.js.map +1 -0
  167. package/dist/cli/commands/log/index.d.ts +6 -0
  168. package/dist/cli/commands/log/index.d.ts.map +1 -0
  169. package/dist/cli/commands/log/index.js +400 -0
  170. package/dist/cli/commands/log/index.js.map +1 -0
  171. package/dist/cli/commands/log/parser.d.ts +20 -0
  172. package/dist/cli/commands/log/parser.d.ts.map +1 -0
  173. package/dist/cli/commands/log/parser.js +111 -0
  174. package/dist/cli/commands/log/parser.js.map +1 -0
  175. package/dist/cli/commands/log/reader.d.ts +66 -0
  176. package/dist/cli/commands/log/reader.d.ts.map +1 -0
  177. package/dist/cli/commands/log/reader.js +364 -0
  178. package/dist/cli/commands/log/reader.js.map +1 -0
  179. package/dist/cli/commands/log/types.d.ts +100 -0
  180. package/dist/cli/commands/log/types.d.ts.map +1 -0
  181. package/dist/cli/commands/log/types.js +5 -0
  182. package/dist/cli/commands/log/types.js.map +1 -0
  183. package/dist/cli/commands/profile/display.d.ts +1 -0
  184. package/dist/cli/commands/profile/display.d.ts.map +1 -1
  185. package/dist/cli/commands/profile/display.js +10 -2
  186. package/dist/cli/commands/profile/display.js.map +1 -1
  187. package/dist/cli/commands/profile/index.js +58 -22
  188. package/dist/cli/commands/profile/index.js.map +1 -1
  189. package/dist/cli/commands/setup.d.ts.map +1 -1
  190. package/dist/cli/commands/setup.js +143 -24
  191. package/dist/cli/commands/setup.js.map +1 -1
  192. package/dist/cli/index.js +2 -0
  193. package/dist/cli/index.js.map +1 -1
  194. package/dist/env/types.d.ts +10 -1
  195. package/dist/env/types.d.ts.map +1 -1
  196. package/dist/env/types.js.map +1 -1
  197. package/dist/index.d.ts +5 -0
  198. package/dist/index.d.ts.map +1 -1
  199. package/dist/index.js +10 -0
  200. package/dist/index.js.map +1 -1
  201. package/dist/providers/plugins/sso/session/SessionSyncer.d.ts +5 -0
  202. package/dist/providers/plugins/sso/session/SessionSyncer.d.ts.map +1 -1
  203. package/dist/providers/plugins/sso/session/SessionSyncer.js +102 -3
  204. package/dist/providers/plugins/sso/session/SessionSyncer.js.map +1 -1
  205. package/dist/providers/plugins/sso/session/processors/conversations/conversation-sync-processor.d.ts +0 -1
  206. package/dist/providers/plugins/sso/session/processors/conversations/conversation-sync-processor.d.ts.map +1 -1
  207. package/dist/providers/plugins/sso/session/processors/conversations/conversation-sync-processor.js +25 -48
  208. package/dist/providers/plugins/sso/session/processors/conversations/conversation-sync-processor.js.map +1 -1
  209. package/dist/providers/plugins/sso/session/processors/metrics/metrics-sync-processor.d.ts.map +1 -1
  210. package/dist/providers/plugins/sso/session/processors/metrics/metrics-sync-processor.js +8 -34
  211. package/dist/providers/plugins/sso/session/processors/metrics/metrics-sync-processor.js.map +1 -1
  212. package/dist/utils/config.d.ts +35 -8
  213. package/dist/utils/config.d.ts.map +1 -1
  214. package/dist/utils/config.js +243 -33
  215. package/dist/utils/config.js.map +1 -1
  216. package/dist/utils/logger.d.ts +8 -0
  217. package/dist/utils/logger.d.ts.map +1 -1
  218. package/dist/utils/logger.js +42 -0
  219. package/dist/utils/logger.js.map +1 -1
  220. package/dist/utils/native-installer.d.ts +1 -0
  221. package/dist/utils/native-installer.d.ts.map +1 -1
  222. package/dist/utils/native-installer.js +21 -7
  223. package/dist/utils/native-installer.js.map +1 -1
  224. package/package.json +2 -2
  225. package/dist/agents/plugins/claude/plugin/commands/memory-add.md +0 -325
  226. package/dist/agents/plugins/claude/plugin/commands/memory-init.md +0 -18
  227. package/dist/cli/commands/assistants/generators/claude-agent-generator.d.ts.map +0 -1
  228. package/dist/cli/commands/assistants/generators/claude-agent-generator.js.map +0 -1
  229. package/dist/cli/commands/assistants/list.d.ts +0 -11
  230. package/dist/cli/commands/assistants/list.d.ts.map +0 -1
  231. package/dist/cli/commands/assistants/list.js +0 -323
  232. package/dist/cli/commands/assistants/list.js.map +0 -1
  233. /package/dist/cli/commands/assistants/{generators → setup/generators}/claude-agent-generator.d.ts +0 -0
@@ -0,0 +1,36 @@
1
+ /**
2
+ * Selection Helper Utilities
3
+ *
4
+ * Handles choice building, filtering, sorting, and display formatting
5
+ */
6
+ import type { Assistant, AssistantBase } from 'codemie-sdk';
7
+ import type { ProviderProfile } from '../../../../../env/types.js';
8
+ export interface AssistantChoice {
9
+ name: string;
10
+ value: string;
11
+ short: string;
12
+ checked: boolean;
13
+ }
14
+ /**
15
+ * Build display info for assistant choice
16
+ */
17
+ export declare function buildAssistantDisplayInfo(assistant: Assistant): string;
18
+ /**
19
+ * Create assistant choices for selection prompt
20
+ */
21
+ export declare function createAssistantChoices(assistants: (Assistant | AssistantBase)[], registeredIds: Set<string>): AssistantChoice[];
22
+ /**
23
+ * Display message when no assistants are found
24
+ */
25
+ export declare function displayNoAssistantsMessage(options: {
26
+ project?: string;
27
+ allProjects?: boolean;
28
+ }, config: ProviderProfile): void;
29
+ /**
30
+ * Get project filter from options or config
31
+ */
32
+ export declare function getProjectFilter(options: {
33
+ project?: string;
34
+ allProjects?: boolean;
35
+ }, config: ProviderProfile): string | undefined;
36
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../../src/cli/commands/assistants/setup/selection/utils.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAGtD,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,OAAO,CAAC;CAClB;AAED;;GAEG;AACH,wBAAgB,yBAAyB,CAAC,SAAS,EAAE,SAAS,GAAG,MAAM,CAStE;AAED;;GAEG;AACH,wBAAgB,sBAAsB,CACpC,UAAU,EAAE,CAAC,SAAS,GAAG,aAAa,CAAC,EAAE,EACzC,aAAa,EAAE,GAAG,CAAC,MAAM,CAAC,GACzB,eAAe,EAAE,CAanB;AAED;;GAEG;AACH,wBAAgB,0BAA0B,CACxC,OAAO,EAAE;IAAE,OAAO,CAAC,EAAE,MAAM,CAAC;IAAC,WAAW,CAAC,EAAE,OAAO,CAAA;CAAE,EACpD,MAAM,EAAE,eAAe,GACtB,IAAI,CAQN;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAC9B,OAAO,EAAE;IAAE,OAAO,CAAC,EAAE,MAAM,CAAC;IAAC,WAAW,CAAC,EAAE,OAAO,CAAA;CAAE,EACpD,MAAM,EAAE,eAAe,GACtB,MAAM,GAAG,SAAS,CAKpB"}
@@ -0,0 +1,55 @@
1
+ /**
2
+ * Selection Helper Utilities
3
+ *
4
+ * Handles choice building, filtering, sorting, and display formatting
5
+ */
6
+ import chalk from 'chalk';
7
+ import { MESSAGES } from '../../../../../cli/commands/assistants/constants.js';
8
+ /**
9
+ * Build display info for assistant choice
10
+ */
11
+ export function buildAssistantDisplayInfo(assistant) {
12
+ const project = assistant.project;
13
+ const projectName = project && typeof project === 'object' ? project.name : project;
14
+ const projectInfo = projectName ? chalk.dim(` [${projectName}]`) : '';
15
+ const firstLine = assistant.name + projectInfo;
16
+ const descriptionInfo = assistant.description ? chalk.dim(`\n ${assistant.description}`) : '';
17
+ return firstLine + descriptionInfo;
18
+ }
19
+ /**
20
+ * Create assistant choices for selection prompt
21
+ */
22
+ export function createAssistantChoices(assistants, registeredIds) {
23
+ return assistants.map(assistant => {
24
+ const a = assistant;
25
+ const isRegistered = registeredIds.has(a.id);
26
+ const displayName = buildAssistantDisplayInfo(a);
27
+ return {
28
+ name: displayName,
29
+ value: a.id,
30
+ short: a.name,
31
+ checked: isRegistered
32
+ };
33
+ });
34
+ }
35
+ /**
36
+ * Display message when no assistants are found
37
+ */
38
+ export function displayNoAssistantsMessage(options, config) {
39
+ console.log(chalk.yellow(MESSAGES.SETUP.NO_ASSISTANTS));
40
+ const filterProject = options.project || config.codeMieProject;
41
+ if (filterProject && !options.allProjects) {
42
+ console.log(chalk.dim(MESSAGES.SETUP.FILTERED_BY_PROJECT(chalk.cyan(filterProject))));
43
+ console.log(chalk.dim(`Try ${chalk.cyan(MESSAGES.SETUP.TRY_ALL_PROJECTS)}${MESSAGES.SETUP.HINT_TRY_ALL}`));
44
+ }
45
+ }
46
+ /**
47
+ * Get project filter from options or config
48
+ */
49
+ export function getProjectFilter(options, config) {
50
+ if (options.allProjects) {
51
+ return undefined;
52
+ }
53
+ return options.project || config.codeMieProject;
54
+ }
55
+ //# sourceMappingURL=utils.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../../../src/cli/commands/assistants/setup/selection/utils.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,QAAQ,EAAE,MAAM,wCAAwC,CAAC;AASlE;;GAEG;AACH,MAAM,UAAU,yBAAyB,CAAC,SAAoB;IAC5D,MAAM,OAAO,GAAG,SAAS,CAAC,OAAO,CAAC;IAClC,MAAM,WAAW,GAAG,OAAO,IAAI,OAAO,OAAO,KAAK,QAAQ,CAAC,CAAC,CAAE,OAA4B,CAAC,IAAI,CAAC,CAAC,CAAC,OAA6B,CAAC;IAChI,MAAM,WAAW,GAAG,WAAW,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,KAAK,WAAW,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IACtE,MAAM,SAAS,GAAG,SAAS,CAAC,IAAI,GAAG,WAAW,CAAC;IAE/C,MAAM,eAAe,GAAG,SAAS,CAAC,WAAW,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,QAAQ,SAAS,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IAEhG,OAAO,SAAS,GAAG,eAAe,CAAC;AACrC,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,sBAAsB,CACpC,UAAyC,EACzC,aAA0B;IAE1B,OAAO,UAAU,CAAC,GAAG,CAAC,SAAS,CAAC,EAAE;QAChC,MAAM,CAAC,GAAG,SAAsB,CAAC;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summary Display Functions
3
+ *
4
+ * Functions for displaying registration summaries and currently registered assistants
5
+ */
6
+ import type { Assistant } from 'codemie-sdk';
7
+ import type { CodemieAssistant, ProviderProfile } from '../../../../../env/types.js';
8
+ /**
9
+ * Display summary of changes
10
+ */
11
+ export declare function displaySummary(toRegister: Assistant[], toUnregister: CodemieAssistant[], profileName: string, config: ProviderProfile): void;
12
+ /**
13
+ * Display currently registered assistants
14
+ */
15
+ export declare function displayCurrentlyRegistered(config: ProviderProfile): void;
16
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/cli/commands/assistants/setup/summary/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,KAAK,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAKxE;;GAEG;AACH,wBAAgB,cAAc,CAC5B,UAAU,EAAE,SAAS,EAAE,EACvB,YAAY,EAAE,gBAAgB,EAAE,EAChC,WAAW,EAAE,MAAM,EACnB,MAAM,EAAE,eAAe,GACtB,IAAI,CAMN;AAED;;GAEG;AACH,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,eAAe,GAAG,IAAI,CA8BxE"}
@@ -0,0 +1,48 @@
1
+ /**
2
+ * Summary Display Functions
3
+ *
4
+ * Functions for displaying registration summaries and currently registered assistants
5
+ */
6
+ import chalk from 'chalk';
7
+ import { MESSAGES } from '../../../../../cli/commands/assistants/constants.js';
8
+ import { REGISTRATION_MODE } from '../../../../../cli/commands/assistants/setup/manualConfiguration/constants.js';
9
+ import { COLOR } from '../constants.js';
10
+ /**
11
+ * Display summary of changes
12
+ */
13
+ export function displaySummary(toRegister, toUnregister, profileName, config) {
14
+ const totalChanges = toRegister.length + toUnregister.length;
15
+ console.log(chalk.green(MESSAGES.SETUP.SUMMARY_UPDATED(totalChanges)));
16
+ console.log(chalk.dim(MESSAGES.SETUP.SUMMARY_PROFILE(profileName)));
17
+ displayCurrentlyRegistered(config);
18
+ }
19
+ /**
20
+ * Display currently registered assistants
21
+ */
22
+ export function displayCurrentlyRegistered(config) {
23
+ if (!config.codemieAssistants || config.codemieAssistants.length === 0) {
24
+ return;
25
+ }
26
+ const purpleColor = chalk.rgb(COLOR.PURPLE.r, COLOR.PURPLE.g, COLOR.PURPLE.b);
27
+ const purpleLine = purpleColor('─'.repeat(60));
28
+ console.log('');
29
+ console.log(purpleLine);
30
+ console.log(chalk.bold('Registered assistants:'));
31
+ console.log('');
32
+ config.codemieAssistants.forEach((assistant) => {
33
+ const mode = assistant.registrationMode || REGISTRATION_MODE.AGENT;
34
+ // Build location info based on registration mode
35
+ let locationInfo = '';
36
+ if (mode === REGISTRATION_MODE.AGENT) {
37
+ locationInfo = chalk.dim(` (@${assistant.slug} in code or claude)`);
38
+ }
39
+ else if (mode === REGISTRATION_MODE.SKILL) {
40
+ locationInfo = chalk.dim(` (/${assistant.slug} in claude or @${assistant.slug} in code)`);
41
+ }
42
+ console.log(` • ${purpleColor(assistant.slug)} - ${assistant.name}${locationInfo}`);
43
+ });
44
+ console.log('');
45
+ console.log(purpleLine);
46
+ console.log('');
47
+ }
48
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/cli/commands/assistants/setup/summary/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,QAAQ,EAAE,MAAM,wCAAwC,CAAC;AAClE,OAAO,EAAE,iBAAiB,EAAE,MAAM,kEAAkE,CAAC;AACrG,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAExC;;GAEG;AACH,MAAM,UAAU,cAAc,CAC5B,UAAuB,EACvB,YAAgC,EAChC,WAAmB,EACnB,MAAuB;IAEvB,MAAM,YAAY,GAAG,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AAK,EAAE,CAAC;YACrC,YAAY,GAAG,KAAK,CAAC,GAAG,CAAC,MAAM,SAAS,CAAC,IAAI,qBAAqB,CAAC,CAAC;QACtE,CAAC;aAAM,IAAI,IAAI,KAAK,iBAAiB,CAAC,KAAK,EAAE,CAAC;YAC5C,YAAY,GAAG,KAAK,CAAC,GAAG,CAAC,MAAM,SAAS,CAAC,IAAI,kBAAkB,SAAS,CAAC,IAAI,WAAW,CAAC,CAAC;QAC5F,CAAC;QAED,OAAO,CAAC,GAAG,CAAC,OAAO,WAAW,CAAC,SAAS,CAAC,IAAI,CAAC,MAAM,SAAS,CAAC,IAAI,GAAG,YAAY,EAAE,CAAC,CAAC;IACvF,CAAC,CAAC,CAAC;IAEH,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IAChB,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;IACxB,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;AAClB,CAAC"}
@@ -1,4 +1,76 @@
1
1
  import { Command } from 'commander';
2
+ import type { BaseHookEvent } from '../../agents/core/types.js';
3
+ /**
4
+ * Hook event handlers for agent lifecycle events
5
+ * Called by agent plugin hooks via stdin JSON
6
+ *
7
+ * This is a unified hook handler that routes based on hook_event_name
8
+ * from the JSON payload. All agent hooks send their event type.
9
+ */
10
+ /**
11
+ * SessionStart event
12
+ */
13
+ export interface SessionStartEvent extends BaseHookEvent {
14
+ hook_event_name: 'SessionStart';
15
+ source: string;
16
+ }
17
+ /**
18
+ * SessionEnd event
19
+ */
20
+ export interface SessionEndEvent extends BaseHookEvent {
21
+ hook_event_name: 'SessionEnd';
22
+ reason: string;
23
+ cwd: string;
24
+ }
25
+ /**
26
+ * SubagentStop event
27
+ */
28
+ export interface SubagentStopEvent extends BaseHookEvent {
29
+ hook_event_name: 'SubagentStop';
30
+ agent_id: string;
31
+ agent_transcript_path: string;
32
+ stop_hook_active: boolean;
33
+ cwd: string;
34
+ }
35
+ /**
36
+ * Configuration for hook event processing
37
+ * Used for programmatic API usage (when not using environment variables)
38
+ */
39
+ export interface HookProcessingConfig {
40
+ /** Agent name (e.g., 'claude', 'gemini') */
41
+ agentName: string;
42
+ /** CodeMie session ID */
43
+ sessionId: string;
44
+ /** Provider name (e.g., 'ai-run-sso') */
45
+ provider?: string;
46
+ /** API base URL */
47
+ apiBaseUrl?: string;
48
+ /** SSO cookies for authentication */
49
+ cookies?: string;
50
+ /** API key for localhost development */
51
+ apiKey?: string;
52
+ /** Client type identifier (e.g., 'vscode-codemie', 'codemie-cli') */
53
+ clientType?: string;
54
+ /** Client version */
55
+ version?: string;
56
+ /** Profile name for logging */
57
+ profileName?: string;
58
+ /** Project name */
59
+ project?: string;
60
+ /** Model name */
61
+ model?: string;
62
+ /** SSO URL for credential loading */
63
+ ssoUrl?: string;
64
+ }
65
+ /**
66
+ * Process a hook event programmatically
67
+ * Main entry point for programmatic API usage (e.g., VSCode plugin)
68
+ *
69
+ * @param event - Hook event to process
70
+ * @param config - Optional configuration object (if not provided, reads from environment variables)
71
+ * @throws Error if event processing fails and config is provided
72
+ */
73
+ export declare function processEvent(event: BaseHookEvent, config?: HookProcessingConfig): Promise<void>;
2
74
  /**
3
75
  * Create unified hook command
4
76
  * Routes to appropriate handler based on hook_event_name in JSON payload
@@ -1 +1 @@
1
- {"version":3,"file":"hook.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/hook.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AA45BpC;;;GAGG;AACH,wBAAgB,iBAAiB,IAAI,OAAO,CAqH3C"}
1
+ {"version":3,"file":"hook.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/hook.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAIpC,OAAO,KAAK,EAAE,aAAa,EAAqC,MAAM,4BAA4B,CAAC;AAGnG;;;;;;GAMG;AAEH;;GAEG;AACH,MAAM,WAAW,iBAA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