couchloop-eq-mcp 2.0.2 → 2.0.4

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 (89) hide show
  1. package/README.md +11 -12
  2. package/dist/clients/shrinkChatClient.d.ts +38 -38
  3. package/dist/db/client.d.ts +11 -19
  4. package/dist/db/client.d.ts.map +1 -1
  5. package/dist/db/client.js +30 -62
  6. package/dist/db/client.js.map +1 -1
  7. package/dist/index.js +8 -5
  8. package/dist/index.js.map +1 -1
  9. package/dist/resources/journey-status.d.ts.map +1 -1
  10. package/dist/resources/journey-status.js +10 -12
  11. package/dist/resources/journey-status.js.map +1 -1
  12. package/dist/resources/session-summary.d.ts.map +1 -1
  13. package/dist/resources/session-summary.js +33 -33
  14. package/dist/resources/session-summary.js.map +1 -1
  15. package/dist/resources/user-context.d.ts.map +1 -1
  16. package/dist/resources/user-context.js +26 -41
  17. package/dist/resources/user-context.js.map +1 -1
  18. package/dist/server/http-mcp.js +2 -2
  19. package/dist/server/index.d.ts.map +1 -1
  20. package/dist/server/index.js +8 -9
  21. package/dist/server/index.js.map +1 -1
  22. package/dist/server/sse.d.ts.map +1 -1
  23. package/dist/server/sse.js +17 -17
  24. package/dist/server/sse.js.map +1 -1
  25. package/dist/tools/check-versions.d.ts +7 -7
  26. package/dist/tools/checkpoint.d.ts +1 -8
  27. package/dist/tools/checkpoint.d.ts.map +1 -1
  28. package/dist/tools/checkpoint.js +47 -49
  29. package/dist/tools/checkpoint.js.map +1 -1
  30. package/dist/tools/couchloop-v2.d.ts.map +1 -1
  31. package/dist/tools/couchloop-v2.js +15 -4
  32. package/dist/tools/couchloop-v2.js.map +1 -1
  33. package/dist/tools/detect-build-context.d.ts +1 -1
  34. package/dist/tools/generate-upgrade-report.d.ts +2 -2
  35. package/dist/tools/guard.d.ts +3 -3
  36. package/dist/tools/index.d.ts +2 -4
  37. package/dist/tools/index.d.ts.map +1 -1
  38. package/dist/tools/index.js +2 -4
  39. package/dist/tools/index.js.map +1 -1
  40. package/dist/tools/insight.d.ts +10 -49
  41. package/dist/tools/insight.d.ts.map +1 -1
  42. package/dist/tools/insight.js +78 -91
  43. package/dist/tools/insight.js.map +1 -1
  44. package/dist/tools/intent-router.d.ts.map +1 -1
  45. package/dist/tools/intent-router.js +12 -7
  46. package/dist/tools/intent-router.js.map +1 -1
  47. package/dist/tools/journey.d.ts +5 -5
  48. package/dist/tools/journey.d.ts.map +1 -1
  49. package/dist/tools/journey.js +47 -39
  50. package/dist/tools/journey.js.map +1 -1
  51. package/dist/tools/pre-review-code.d.ts +2 -2
  52. package/dist/tools/prevent-ai-errors.d.ts +3 -3
  53. package/dist/tools/primary-tools.d.ts +37 -190
  54. package/dist/tools/primary-tools.d.ts.map +1 -1
  55. package/dist/tools/primary-tools.js +204 -302
  56. package/dist/tools/primary-tools.js.map +1 -1
  57. package/dist/tools/protect-files.d.ts +1 -1
  58. package/dist/tools/sendMessage.d.ts.map +1 -1
  59. package/dist/tools/sendMessage.js +52 -38
  60. package/dist/tools/sendMessage.js.map +1 -1
  61. package/dist/tools/session-manager.d.ts.map +1 -1
  62. package/dist/tools/session-manager.js +88 -70
  63. package/dist/tools/session-manager.js.map +1 -1
  64. package/dist/tools/session.d.ts +7 -86
  65. package/dist/tools/session.d.ts.map +1 -1
  66. package/dist/tools/session.js +68 -72
  67. package/dist/tools/session.js.map +1 -1
  68. package/dist/tools/smart-context.d.ts +1 -1
  69. package/dist/tools/status.d.ts +9 -2
  70. package/dist/tools/status.d.ts.map +1 -1
  71. package/dist/tools/status.js +113 -64
  72. package/dist/tools/status.js.map +1 -1
  73. package/dist/tools/verify.d.ts +4 -4
  74. package/dist/tools/verify.js.map +1 -1
  75. package/dist/types/auth.d.ts +2 -2
  76. package/dist/types/checkpoint.d.ts +4 -4
  77. package/dist/types/file-protection.d.ts +2 -2
  78. package/dist/types/insight.d.ts +10 -10
  79. package/dist/types/journey.d.ts +40 -12
  80. package/dist/types/journey.d.ts.map +1 -1
  81. package/dist/types/journey.js +2 -0
  82. package/dist/types/journey.js.map +1 -1
  83. package/dist/types/session.d.ts +10 -10
  84. package/dist/workflows/engine.d.ts +2 -2
  85. package/dist/workflows/engine.d.ts.map +1 -1
  86. package/dist/workflows/engine.js +81 -82
  87. package/dist/workflows/engine.js.map +1 -1
  88. package/dist/workflows/index.d.ts +4 -4
  89. package/package.json +2 -10
@@ -2,25 +2,28 @@
2
2
  * MCP Tools - Public API
3
3
  *
4
4
  * This module exports only the PRIMARY tools that users should see.
5
- * All granular tools are internal engines used by these primary tools.
5
+ * Consolidated from 10 4 tools for clarity and reduced LLM misrouting.
6
6
  *
7
- * PUBLIC TOOLS (10):
8
- * 0. couchloop - Intent router (discoverability layer for loose commands)
9
- * 1. guard - Invisible per-turn governance (called automatically by companion skill)
10
- * 2. verify - Pre-delivery verification (catches AI hallucinations, validates packages)
11
- * 2. status - Dashboard (session progress, history, context, protection)
12
- * 3. conversation - AI conversation with guided journeys and session memory
13
- * 4. brainstorm - Dev thinking partner (reflective questioning, architecture, trade-offs)
14
- * 5. code_review - Complete code analysis (security, quality, AI errors)
15
- * 6. package_audit - Complete dependency audit (validation, versions, upgrades)
16
- * 7. remember - Smart context capture (checkpoints, insights, decisions)
17
- * 8. protect - File protection and safety features
7
+ * PUBLIC TOOLS (4):
8
+ * 1. memory - HERO: save & recall insights, checkpoints, decisions (Supabase-backed)
9
+ * 2. conversation - Emotional support, guided journeys, crisis detection (shrink-chat backend)
10
+ * 3. review - Unified: code review + package audit + pre-delivery verification
11
+ * 4. status - Dashboard (session progress, history, context, preferences)
12
+ *
13
+ * INTERNAL (auto-triggered, not user-facing):
14
+ * - guard - Per-response governance (runs in withPolicy wrapper)
15
+ *
16
+ * REMOVED:
17
+ * - couchloop - Router added latency; LLMs route directly with good descriptions
18
+ * - brainstorm - Returned static system prompt; LLMs brainstorm natively
19
+ * - protect - Broken on Railway (read-only /app filesystem)
18
20
  */
19
21
  import { handleComprehensiveCodeReview } from './comprehensive-code-review.js';
20
22
  import { handleComprehensivePackageAudit } from './comprehensive-package-audit.js';
21
23
  import { handleSmartContext } from './smart-context.js';
22
24
  import { type PolicyContext } from '../policy/index.js';
23
25
  export declare function setupTools(): Promise<({
26
+ handler: (args: Record<string, unknown>, _routedVia?: PolicyContext["routedVia"]) => Promise<import("../policy/types.js").NormalizedToolResponse<unknown>>;
24
27
  definition: {
25
28
  name: string;
26
29
  description: string;
@@ -33,12 +36,9 @@ export declare function setupTools(): Promise<({
33
36
  inputSchema: {
34
37
  type: string;
35
38
  properties: {
36
- intent: {
37
- type: string;
38
- description: string;
39
- };
40
- context: {
39
+ check: {
41
40
  type: string;
41
+ enum: string[];
42
42
  description: string;
43
43
  };
44
44
  session_id: {
@@ -49,7 +49,6 @@ export declare function setupTools(): Promise<({
49
49
  required: string[];
50
50
  };
51
51
  };
52
- handler: typeof import("./couchloop-v2.js").couchloopV2Handler;
53
52
  } | {
54
53
  handler: (args: Record<string, unknown>, _routedVia?: PolicyContext["routedVia"]) => Promise<import("../policy/types.js").NormalizedToolResponse<unknown>>;
55
54
  definition: {
@@ -64,110 +63,37 @@ export declare function setupTools(): Promise<({
64
63
  inputSchema: {
65
64
  type: string;
66
65
  properties: {
67
- type: {
68
- type: string;
69
- enum: string[];
70
- description: string;
71
- };
72
66
  content: {
73
67
  type: string;
74
68
  description: string;
75
69
  };
76
- language: {
70
+ action: {
77
71
  type: string;
72
+ enum: string[];
78
73
  description: string;
79
74
  };
80
- registry: {
75
+ type: {
81
76
  type: string;
82
77
  enum: string[];
83
78
  description: string;
84
79
  };
85
- context: {
80
+ tags: {
86
81
  type: string;
82
+ items: {
83
+ type: string;
84
+ };
87
85
  description: string;
88
86
  };
89
- };
90
- required: string[];
91
- };
92
- };
93
- } | {
94
- handler: (args: Record<string, unknown>, _routedVia?: PolicyContext["routedVia"]) => Promise<import("../policy/types.js").NormalizedToolResponse<unknown>>;
95
- definition: {
96
- name: string;
97
- description: string;
98
- annotations: {
99
- readOnlyHint: boolean;
100
- destructiveHint: boolean;
101
- idempotentHint: boolean;
102
- openWorldHint: boolean;
103
- };
104
- inputSchema: {
105
- type: string;
106
- properties: {
107
- check: {
87
+ session_id: {
108
88
  type: string;
109
- enum: string[];
110
89
  description: string;
111
90
  };
112
- session_id: {
91
+ auth: {
113
92
  type: string;
114
93
  description: string;
115
94
  };
116
95
  };
117
- required: string[];
118
- };
119
- };
120
- } | {
121
- handler: (args: Record<string, unknown>, _routedVia?: PolicyContext["routedVia"]) => Promise<import("../policy/types.js").NormalizedToolResponse<unknown>>;
122
- definition: {
123
- readonly name: "guard";
124
- readonly description: string;
125
- readonly annotations: {
126
- readonly readOnlyHint: true;
127
- readonly destructiveHint: false;
128
- readonly idempotentHint: true;
129
- readonly openWorldHint: false;
130
- };
131
- readonly inputSchema: {
132
- readonly type: "object";
133
- readonly properties: {
134
- readonly response: {
135
- readonly type: "string";
136
- readonly description: "Draft response to evaluate";
137
- };
138
- readonly conversation: {
139
- readonly type: "array";
140
- readonly items: {
141
- readonly type: "object";
142
- readonly properties: {
143
- readonly role: {
144
- readonly type: "string";
145
- readonly enum: readonly ["user", "assistant"];
146
- };
147
- readonly content: {
148
- readonly type: "string";
149
- };
150
- };
151
- readonly required: readonly ["role", "content"];
152
- };
153
- readonly description: "Recent conversation history";
154
- };
155
- readonly domain: {
156
- readonly type: "string";
157
- readonly enum: readonly ["dev", "clinical", "auto"];
158
- readonly description: "Governance domain. 'auto' detects from context.";
159
- };
160
- readonly session_id: {
161
- readonly type: "string";
162
- readonly description: "Session ID for audit trail";
163
- };
164
- readonly mode: {
165
- readonly type: "string";
166
- readonly enum: readonly ["enforce", "shadow", "bypass"];
167
- readonly description: "Governance mode";
168
- };
169
- };
170
- readonly required: readonly ["response"];
96
+ required: never[];
171
97
  };
172
98
  };
173
99
  } | {
@@ -188,37 +114,20 @@ export declare function setupTools(): Promise<({
188
114
  type: string;
189
115
  description: string;
190
116
  };
191
- session_id: {
117
+ action: {
192
118
  type: string;
119
+ enum: string[];
193
120
  description: string;
194
121
  };
195
- };
196
- required: string[];
197
- };
198
- };
199
- } | {
200
- handler: (args: Record<string, unknown>, _routedVia?: PolicyContext["routedVia"]) => Promise<import("../policy/types.js").NormalizedToolResponse<unknown>>;
201
- definition: {
202
- name: string;
203
- description: string;
204
- annotations: {
205
- readOnlyHint: boolean;
206
- destructiveHint: boolean;
207
- idempotentHint: boolean;
208
- openWorldHint: boolean;
209
- };
210
- inputSchema: {
211
- type: string;
212
- properties: {
213
- code: {
122
+ journey: {
214
123
  type: string;
215
124
  description: string;
216
125
  };
217
- language: {
126
+ session_id: {
218
127
  type: string;
219
128
  description: string;
220
129
  };
221
- auto_fix: {
130
+ auth: {
222
131
  type: string;
223
132
  description: string;
224
133
  };
@@ -240,94 +149,32 @@ export declare function setupTools(): Promise<({
240
149
  inputSchema: {
241
150
  type: string;
242
151
  properties: {
243
- packages: {
244
- type: string;
245
- items: {
246
- type: string;
247
- };
248
- description: string;
249
- };
250
- registry: {
152
+ mode: {
251
153
  type: string;
252
154
  enum: string[];
253
155
  description: string;
254
156
  };
255
- };
256
- required: string[];
257
- };
258
- };
259
- } | {
260
- handler: (args: Record<string, unknown>, _routedVia?: PolicyContext["routedVia"]) => Promise<import("../policy/types.js").NormalizedToolResponse<unknown>>;
261
- definition: {
262
- name: string;
263
- description: string;
264
- annotations: {
265
- readOnlyHint: boolean;
266
- destructiveHint: boolean;
267
- idempotentHint: boolean;
268
- openWorldHint: boolean;
269
- };
270
- inputSchema: {
271
- type: string;
272
- properties: {
273
157
  content: {
274
158
  type: string;
275
159
  description: string;
276
160
  };
277
- type: {
278
- type: string;
279
- enum: string[];
280
- description: string;
281
- };
282
- tags: {
161
+ packages: {
283
162
  type: string;
284
163
  items: {
285
164
  type: string;
286
165
  };
287
166
  description: string;
288
167
  };
289
- action: {
290
- type: string;
291
- enum: string[];
292
- description: string;
293
- };
294
- session_id: {
295
- type: string;
296
- description: string;
297
- };
298
- };
299
- required: string[];
300
- };
301
- };
302
- } | {
303
- handler: (args: Record<string, unknown>, _routedVia?: PolicyContext["routedVia"]) => Promise<import("../policy/types.js").NormalizedToolResponse<unknown>>;
304
- definition: {
305
- name: string;
306
- description: string;
307
- annotations: {
308
- readOnlyHint: boolean;
309
- destructiveHint: boolean;
310
- idempotentHint: boolean;
311
- openWorldHint: boolean;
312
- };
313
- inputSchema: {
314
- type: string;
315
- properties: {
316
- action: {
317
- type: string;
318
- enum: string[];
319
- description: string;
320
- };
321
- path: {
168
+ language: {
322
169
  type: string;
323
170
  description: string;
324
171
  };
325
- operation: {
172
+ registry: {
326
173
  type: string;
327
174
  enum: string[];
328
175
  description: string;
329
176
  };
330
- backup_id: {
177
+ auto_fix: {
331
178
  type: string;
332
179
  description: string;
333
180
  };
@@ -1 +1 @@
1
- {"version":3,"file":"primary-tools.d.ts","sourceRoot":"","sources":["../../src/tools/primary-tools.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAWH,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;AAexD,OAAO,EAAqB,KAAK,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAmY3E,wBAAsB,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBAZV,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,eAAe,aAAa,CAAC,WAAW,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBAAhE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,eAAe,aAAa,CAAC,WAAW,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;oBAAhE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,eAAe,aAAa,CAAC,WAAW,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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