couchloop-eq-mcp 1.1.4 → 1.1.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 (63) hide show
  1. package/dist/clients/shrinkChatClient.d.ts +4 -4
  2. package/dist/index.js +80 -5
  3. package/dist/index.js.map +1 -1
  4. package/dist/tools/check-versions.d.ts +7 -7
  5. package/dist/tools/checkpoint.d.ts +2 -19
  6. package/dist/tools/checkpoint.d.ts.map +1 -1
  7. package/dist/tools/checkpoint.js +68 -2
  8. package/dist/tools/checkpoint.js.map +1 -1
  9. package/dist/tools/comprehensive-code-review.d.ts +78 -0
  10. package/dist/tools/comprehensive-code-review.d.ts.map +1 -0
  11. package/dist/tools/comprehensive-code-review.js +177 -0
  12. package/dist/tools/comprehensive-code-review.js.map +1 -0
  13. package/dist/tools/comprehensive-package-audit.d.ts +75 -0
  14. package/dist/tools/comprehensive-package-audit.d.ts.map +1 -0
  15. package/dist/tools/comprehensive-package-audit.js +151 -0
  16. package/dist/tools/comprehensive-package-audit.js.map +1 -0
  17. package/dist/tools/detect-build-context.d.ts +59 -0
  18. package/dist/tools/detect-build-context.d.ts.map +1 -0
  19. package/dist/tools/detect-build-context.js +80 -0
  20. package/dist/tools/detect-build-context.js.map +1 -0
  21. package/dist/tools/generate-upgrade-report.d.ts +85 -0
  22. package/dist/tools/generate-upgrade-report.d.ts.map +1 -0
  23. package/dist/tools/generate-upgrade-report.js +102 -0
  24. package/dist/tools/generate-upgrade-report.js.map +1 -0
  25. package/dist/tools/index-full.d.ts +1355 -0
  26. package/dist/tools/index-full.d.ts.map +1 -0
  27. package/dist/tools/index-full.js +611 -0
  28. package/dist/tools/index-full.js.map +1 -0
  29. package/dist/tools/index.d.ts +27 -1018
  30. package/dist/tools/index.d.ts.map +1 -1
  31. package/dist/tools/index.js +29 -554
  32. package/dist/tools/index.js.map +1 -1
  33. package/dist/tools/insight.d.ts +25 -6
  34. package/dist/tools/insight.d.ts.map +1 -1
  35. package/dist/tools/insight.js +2 -1
  36. package/dist/tools/insight.js.map +1 -1
  37. package/dist/tools/prevent-ai-errors.d.ts +85 -0
  38. package/dist/tools/prevent-ai-errors.d.ts.map +1 -0
  39. package/dist/tools/prevent-ai-errors.js +97 -0
  40. package/dist/tools/prevent-ai-errors.js.map +1 -0
  41. package/dist/tools/primary-tools.d.ts +430 -0
  42. package/dist/tools/primary-tools.d.ts.map +1 -0
  43. package/dist/tools/primary-tools.js +294 -0
  44. package/dist/tools/primary-tools.js.map +1 -0
  45. package/dist/tools/sendMessage.d.ts.map +1 -1
  46. package/dist/tools/sendMessage.js +10 -7
  47. package/dist/tools/sendMessage.js.map +1 -1
  48. package/dist/tools/smart-context.d.ts +66 -0
  49. package/dist/tools/smart-context.d.ts.map +1 -0
  50. package/dist/tools/smart-context.js +167 -0
  51. package/dist/tools/smart-context.js.map +1 -0
  52. package/dist/types/checkpoint.d.ts +26 -1
  53. package/dist/types/checkpoint.d.ts.map +1 -1
  54. package/dist/types/checkpoint.js +17 -0
  55. package/dist/types/checkpoint.js.map +1 -1
  56. package/dist/types/journey.d.ts +6 -6
  57. package/dist/types/session.d.ts +3 -3
  58. package/dist/utils/sanitize.d.ts +24 -0
  59. package/dist/utils/sanitize.d.ts.map +1 -0
  60. package/dist/utils/sanitize.js +117 -0
  61. package/dist/utils/sanitize.js.map +1 -0
  62. package/dist/workflows/index.d.ts +1 -1
  63. package/package.json +1 -1
@@ -0,0 +1,430 @@
1
+ /**
2
+ * MCP Tools - Public API
3
+ *
4
+ * This module exports only the PRIMARY tools that users should see.
5
+ * All granular tools are internal engines used by these primary tools.
6
+ *
7
+ * PUBLIC TOOLS (5):
8
+ * 1. conversation - Therapeutic AI conversation with governance
9
+ * 2. code_review - Complete code analysis (security, quality, AI errors)
10
+ * 3. package_audit - Complete dependency audit (validation, versions, upgrades)
11
+ * 4. remember - Smart context capture (checkpoints, insights, decisions)
12
+ * 5. protect - File protection and safety features
13
+ */
14
+ import { handleComprehensiveCodeReview } from './comprehensive-code-review.js';
15
+ import { handleComprehensivePackageAudit } from './comprehensive-package-audit.js';
16
+ import { handleSmartContext } from './smart-context.js';
17
+ export declare function setupTools(): Promise<({
18
+ definition: {
19
+ name: string;
20
+ description: string;
21
+ annotations: {
22
+ readOnlyHint: boolean;
23
+ destructiveHint: boolean;
24
+ openWorldHint: boolean;
25
+ };
26
+ inputSchema: {
27
+ type: string;
28
+ properties: {
29
+ message: {
30
+ type: string;
31
+ description: string;
32
+ };
33
+ action: {
34
+ type: string;
35
+ enum: string[];
36
+ description: string;
37
+ };
38
+ journey: {
39
+ type: string;
40
+ description: string;
41
+ };
42
+ session_id: {
43
+ type: string;
44
+ description: string;
45
+ };
46
+ };
47
+ required: string[];
48
+ };
49
+ };
50
+ handler: (args: Record<string, unknown>) => Promise<unknown>;
51
+ } | {
52
+ definition: {
53
+ name: string;
54
+ description: string;
55
+ annotations: {
56
+ readOnlyHint: boolean;
57
+ destructiveHint: boolean;
58
+ openWorldHint: boolean;
59
+ };
60
+ inputSchema: {
61
+ type: string;
62
+ properties: {
63
+ code: {
64
+ type: string;
65
+ description: string;
66
+ };
67
+ language: {
68
+ type: string;
69
+ description: string;
70
+ };
71
+ auto_fix: {
72
+ type: string;
73
+ description: string;
74
+ };
75
+ };
76
+ required: string[];
77
+ };
78
+ };
79
+ handler: typeof handleComprehensiveCodeReview;
80
+ } | {
81
+ definition: {
82
+ name: string;
83
+ description: string;
84
+ annotations: {
85
+ readOnlyHint: boolean;
86
+ destructiveHint: boolean;
87
+ openWorldHint: boolean;
88
+ };
89
+ inputSchema: {
90
+ type: string;
91
+ properties: {
92
+ packages: {
93
+ type: string;
94
+ items: {
95
+ type: string;
96
+ };
97
+ description: string;
98
+ };
99
+ registry: {
100
+ type: string;
101
+ enum: string[];
102
+ description: string;
103
+ };
104
+ };
105
+ required: string[];
106
+ };
107
+ };
108
+ handler: typeof handleComprehensivePackageAudit;
109
+ } | {
110
+ definition: {
111
+ name: string;
112
+ description: string;
113
+ annotations: {
114
+ readOnlyHint: boolean;
115
+ destructiveHint: boolean;
116
+ openWorldHint: boolean;
117
+ };
118
+ inputSchema: {
119
+ type: string;
120
+ properties: {
121
+ content: {
122
+ type: string;
123
+ description: string;
124
+ };
125
+ type: {
126
+ type: string;
127
+ enum: string[];
128
+ description: string;
129
+ };
130
+ tags: {
131
+ type: string;
132
+ items: {
133
+ type: string;
134
+ };
135
+ description: string;
136
+ };
137
+ action: {
138
+ type: string;
139
+ enum: string[];
140
+ description: string;
141
+ };
142
+ session_id: {
143
+ type: string;
144
+ description: string;
145
+ };
146
+ };
147
+ required: string[];
148
+ };
149
+ };
150
+ handler: (args: Record<string, unknown>) => Promise<{
151
+ error: string;
152
+ details?: any;
153
+ } | {
154
+ insights: {
155
+ id: string;
156
+ createdAt: Date;
157
+ tags: string[];
158
+ userId: string;
159
+ sessionId: string | null;
160
+ content: string;
161
+ }[];
162
+ count: number;
163
+ } | {
164
+ success: boolean;
165
+ type: "checkpoint" | "pattern" | "insight" | "decision" | "requirement" | "constraint" | "conversation";
166
+ message: string;
167
+ error?: undefined;
168
+ } | {
169
+ success: boolean;
170
+ error: string;
171
+ type?: undefined;
172
+ message?: undefined;
173
+ } | {
174
+ checkpoints: {
175
+ error: string;
176
+ details?: any;
177
+ } | {
178
+ session_id: string;
179
+ session_created: boolean;
180
+ checkpoints: {
181
+ id: string;
182
+ createdAt: Date;
183
+ sessionId: string;
184
+ stepId: string;
185
+ key: string;
186
+ value: unknown;
187
+ }[];
188
+ count: number;
189
+ };
190
+ insights: {
191
+ error: string;
192
+ details?: any;
193
+ } | {
194
+ insights: {
195
+ id: string;
196
+ createdAt: Date;
197
+ tags: string[];
198
+ userId: string;
199
+ sessionId: string | null;
200
+ content: string;
201
+ }[];
202
+ count: number;
203
+ };
204
+ user_context: {
205
+ error: string;
206
+ details?: any;
207
+ } | {
208
+ user: {
209
+ id: string;
210
+ externalId: string;
211
+ isTestAccount: boolean;
212
+ createdAt: Date;
213
+ updatedAt: Date;
214
+ preferences: {
215
+ timezone?: string;
216
+ preferredJourneyLength?: "short" | "medium" | "long";
217
+ } | null;
218
+ } | undefined;
219
+ recent_insights: never[];
220
+ recent_sessions: never[];
221
+ active_session: null;
222
+ } | {
223
+ user: {
224
+ id: string;
225
+ preferences: {
226
+ timezone?: string;
227
+ preferredJourneyLength?: "short" | "medium" | "long";
228
+ } | null;
229
+ created_at: Date;
230
+ };
231
+ recent_insights: {
232
+ id: string;
233
+ createdAt: Date;
234
+ tags: string[];
235
+ userId: string;
236
+ sessionId: string | null;
237
+ content: string;
238
+ }[];
239
+ recent_sessions: import("./insight.js").RecentSession[];
240
+ active_session: {
241
+ id: string;
242
+ updatedAt: Date;
243
+ userId: string;
244
+ journeyId: string | null;
245
+ status: "active" | "paused" | "completed" | "abandoned";
246
+ currentStep: number;
247
+ startedAt: Date;
248
+ lastActiveAt: Date;
249
+ completedAt: Date | null;
250
+ metadata: unknown;
251
+ threadId: string | null;
252
+ lastSyncedAt: Date | null;
253
+ } | undefined;
254
+ };
255
+ }>;
256
+ } | {
257
+ definition: {
258
+ name: string;
259
+ description: string;
260
+ annotations: {
261
+ readOnlyHint: boolean;
262
+ destructiveHint: boolean;
263
+ openWorldHint: boolean;
264
+ };
265
+ inputSchema: {
266
+ type: string;
267
+ properties: {
268
+ action: {
269
+ type: string;
270
+ enum: string[];
271
+ description: string;
272
+ };
273
+ path: {
274
+ type: string;
275
+ description: string;
276
+ };
277
+ operation: {
278
+ type: string;
279
+ enum: string[];
280
+ description: string;
281
+ };
282
+ backup_id: {
283
+ type: string;
284
+ description: string;
285
+ };
286
+ };
287
+ required: string[];
288
+ };
289
+ };
290
+ handler: (args: Record<string, unknown>) => Promise<{
291
+ error: string;
292
+ details?: any;
293
+ } | {
294
+ success: boolean;
295
+ operation_id: string;
296
+ allowed: boolean;
297
+ message: string;
298
+ violations: import("../types/file-protection.js").ProtectionViolation[];
299
+ recommendation: string;
300
+ action_required: string;
301
+ requires_approval?: undefined;
302
+ severity?: undefined;
303
+ suggested_backup?: undefined;
304
+ reason?: undefined;
305
+ status?: undefined;
306
+ operation_details?: undefined;
307
+ next_steps?: undefined;
308
+ safety_measures?: undefined;
309
+ error?: undefined;
310
+ details?: undefined;
311
+ } | {
312
+ success: boolean;
313
+ operation_id: string;
314
+ allowed: boolean;
315
+ requires_approval: boolean;
316
+ message: string;
317
+ violations: import("../types/file-protection.js").ProtectionViolation[];
318
+ severity: "medium" | "low" | "high" | "critical";
319
+ recommendation: string;
320
+ suggested_backup: string;
321
+ action_required?: undefined;
322
+ reason?: undefined;
323
+ status?: undefined;
324
+ operation_details?: undefined;
325
+ next_steps?: undefined;
326
+ safety_measures?: undefined;
327
+ error?: undefined;
328
+ details?: undefined;
329
+ } | {
330
+ success: boolean;
331
+ operation_id: string;
332
+ message: string;
333
+ reason: string;
334
+ allowed?: undefined;
335
+ violations?: undefined;
336
+ recommendation?: undefined;
337
+ action_required?: undefined;
338
+ requires_approval?: undefined;
339
+ severity?: undefined;
340
+ suggested_backup?: undefined;
341
+ status?: undefined;
342
+ operation_details?: undefined;
343
+ next_steps?: undefined;
344
+ safety_measures?: undefined;
345
+ error?: undefined;
346
+ details?: undefined;
347
+ } | {
348
+ success: boolean;
349
+ operation_id: string;
350
+ allowed: boolean;
351
+ status: string;
352
+ message: string;
353
+ operation_details: {
354
+ type: "delete" | "overwrite" | "move";
355
+ path: string;
356
+ target_path: string | null;
357
+ backup_path: string | null;
358
+ };
359
+ next_steps: string[];
360
+ safety_measures: {
361
+ backup_created: boolean;
362
+ backup_location: string;
363
+ rollback_available: boolean;
364
+ operation_logged: boolean;
365
+ };
366
+ violations?: undefined;
367
+ recommendation?: undefined;
368
+ action_required?: undefined;
369
+ requires_approval?: undefined;
370
+ severity?: undefined;
371
+ suggested_backup?: undefined;
372
+ reason?: undefined;
373
+ error?: undefined;
374
+ details?: undefined;
375
+ } | {
376
+ success: boolean;
377
+ protection_status: {
378
+ code_freeze_mode: boolean;
379
+ protected_patterns: string[];
380
+ forbidden_paths: string[];
381
+ critical_system_files: string[];
382
+ };
383
+ backup_stats: {
384
+ total_backups: number;
385
+ total_size_mb: number;
386
+ oldest_backup: Date | undefined;
387
+ newest_backup: Date | undefined;
388
+ disk_usage_percent: number;
389
+ };
390
+ protection_report: {
391
+ code_freeze_enabled: boolean;
392
+ operations_logged: number;
393
+ protected_items_count: number;
394
+ recent_violations_count: number;
395
+ };
396
+ } | {
397
+ success: boolean;
398
+ backup_count: number;
399
+ backups: {
400
+ id: string;
401
+ original_path: string;
402
+ backup_path: string;
403
+ timestamp: Date;
404
+ file_size_kb: number;
405
+ operation: "delete" | "overwrite" | "move";
406
+ reason: string | null;
407
+ }[];
408
+ } | {
409
+ success: boolean;
410
+ message: string;
411
+ backup_id: any;
412
+ restored_path?: undefined;
413
+ backup_path?: undefined;
414
+ timestamp?: undefined;
415
+ } | {
416
+ success: boolean;
417
+ message: string;
418
+ restored_path: string;
419
+ backup_id: any;
420
+ backup_path: string;
421
+ timestamp: Date;
422
+ } | {
423
+ success: boolean;
424
+ message: string;
425
+ status: string;
426
+ effect: string;
427
+ }>;
428
+ })[]>;
429
+ export { handleComprehensiveCodeReview, handleComprehensivePackageAudit, handleSmartContext, };
430
+ //# sourceMappingURL=primary-tools.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"primary-tools.d.ts","sourceRoot":"","sources":["../../src/tools/primary-tools.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAKH,OAAO,EAAE,6BAA6B,EAAE,MAAM,gCAAgC,CAAC;AAC/E,OAAO,EAAE,+BAA+B,EAAE,MAAM,kCAAkC,CAAC;AACnF,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAwRxD,wBAAsB,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBApOR,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBAiIvB,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBAgEvB,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MA8C9C;AAGD,OAAO,EACL,6BAA6B,EAC7B,+BAA+B,EAC/B,kBAAkB,GACnB,CAAC"}