task-o-matic 0.0.3 → 0.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 (105) hide show
  1. package/README.md +96 -40
  2. package/dist/commands/tasks/create.d.ts +3 -0
  3. package/dist/commands/tasks/create.d.ts.map +1 -0
  4. package/dist/commands/tasks/create.js +58 -0
  5. package/dist/commands/tasks/delete.d.ts +3 -0
  6. package/dist/commands/tasks/delete.d.ts.map +1 -0
  7. package/dist/commands/tasks/delete.js +40 -0
  8. package/dist/commands/tasks/document.d.ts +5 -0
  9. package/dist/commands/tasks/document.d.ts.map +1 -0
  10. package/dist/commands/tasks/document.js +118 -0
  11. package/dist/commands/tasks/enhance.d.ts +3 -0
  12. package/dist/commands/tasks/enhance.d.ts.map +1 -0
  13. package/dist/commands/tasks/enhance.js +86 -0
  14. package/dist/commands/tasks/execute.d.ts +3 -0
  15. package/dist/commands/tasks/execute.d.ts.map +1 -0
  16. package/dist/commands/tasks/execute.js +33 -0
  17. package/dist/commands/tasks/index.d.ts +16 -0
  18. package/dist/commands/tasks/index.d.ts.map +1 -0
  19. package/dist/commands/tasks/index.js +31 -0
  20. package/dist/commands/tasks/list.d.ts +3 -0
  21. package/dist/commands/tasks/list.d.ts.map +1 -0
  22. package/dist/commands/tasks/list.js +27 -0
  23. package/dist/commands/tasks/next.d.ts +3 -0
  24. package/dist/commands/tasks/next.d.ts.map +1 -0
  25. package/dist/commands/tasks/next.js +44 -0
  26. package/dist/commands/tasks/plan.d.ts +7 -0
  27. package/dist/commands/tasks/plan.d.ts.map +1 -0
  28. package/dist/commands/tasks/plan.js +131 -0
  29. package/dist/commands/tasks/show.d.ts +3 -0
  30. package/dist/commands/tasks/show.d.ts.map +1 -0
  31. package/dist/commands/tasks/show.js +23 -0
  32. package/dist/commands/tasks/split.d.ts +3 -0
  33. package/dist/commands/tasks/split.d.ts.map +1 -0
  34. package/dist/commands/tasks/split.js +95 -0
  35. package/dist/commands/tasks/status.d.ts +3 -0
  36. package/dist/commands/tasks/status.d.ts.map +1 -0
  37. package/dist/commands/tasks/status.js +26 -0
  38. package/dist/commands/tasks/subtasks.d.ts +3 -0
  39. package/dist/commands/tasks/subtasks.d.ts.map +1 -0
  40. package/dist/commands/tasks/subtasks.js +35 -0
  41. package/dist/commands/tasks/tags.d.ts +4 -0
  42. package/dist/commands/tasks/tags.d.ts.map +1 -0
  43. package/dist/commands/tasks/tags.js +37 -0
  44. package/dist/commands/tasks/tree.d.ts +3 -0
  45. package/dist/commands/tasks/tree.d.ts.map +1 -0
  46. package/dist/commands/tasks/tree.js +20 -0
  47. package/dist/commands/tasks/update.d.ts +3 -0
  48. package/dist/commands/tasks/update.d.ts.map +1 -0
  49. package/dist/commands/tasks/update.js +35 -0
  50. package/dist/commands/tasks.d.ts.map +1 -1
  51. package/dist/commands/tasks.js +23 -686
  52. package/dist/commands/workflow.d.ts +4 -0
  53. package/dist/commands/workflow.d.ts.map +1 -0
  54. package/dist/commands/workflow.js +434 -0
  55. package/dist/index.d.ts.map +1 -1
  56. package/dist/index.js +3 -1
  57. package/dist/lib/ai-service/ai-operations.d.ts.map +1 -1
  58. package/dist/lib/ai-service/ai-operations.js +54 -22
  59. package/dist/lib/ai-service/research-tools.d.ts.map +1 -1
  60. package/dist/lib/ai-service/research-tools.js +2 -2
  61. package/dist/lib/context-builder.d.ts +2 -1
  62. package/dist/lib/context-builder.d.ts.map +1 -1
  63. package/dist/lib/context-builder.js +3 -8
  64. package/dist/lib/hooks/logger.d.ts +2 -0
  65. package/dist/lib/hooks/logger.d.ts.map +1 -0
  66. package/dist/lib/hooks/logger.js +27 -0
  67. package/dist/lib/hooks.d.ts +64 -0
  68. package/dist/lib/hooks.d.ts.map +1 -0
  69. package/dist/lib/hooks.js +60 -0
  70. package/dist/lib/index.d.ts +18 -17
  71. package/dist/lib/index.d.ts.map +1 -1
  72. package/dist/lib/index.js +3 -3
  73. package/dist/lib/prompt-builder.d.ts.map +1 -1
  74. package/dist/lib/prompt-builder.js +16 -8
  75. package/dist/lib/{storage.d.ts → storage/file-system.d.ts} +4 -3
  76. package/dist/lib/storage/file-system.d.ts.map +1 -0
  77. package/dist/lib/{storage.js → storage/file-system.js} +141 -152
  78. package/dist/lib/storage/types.d.ts +43 -0
  79. package/dist/lib/storage/types.d.ts.map +1 -0
  80. package/dist/lib/storage/types.js +2 -0
  81. package/dist/lib/task-execution.d.ts.map +1 -1
  82. package/dist/lib/task-execution.js +22 -3
  83. package/dist/prompts/workflow-assistance.d.ts +32 -0
  84. package/dist/prompts/workflow-assistance.d.ts.map +1 -0
  85. package/dist/prompts/workflow-assistance.js +130 -0
  86. package/dist/services/tasks.d.ts +4 -6
  87. package/dist/services/tasks.d.ts.map +1 -1
  88. package/dist/services/tasks.js +115 -96
  89. package/dist/services/workflow-ai-assistant.d.ts +74 -0
  90. package/dist/services/workflow-ai-assistant.d.ts.map +1 -0
  91. package/dist/services/workflow-ai-assistant.js +223 -0
  92. package/dist/test/hooks.test.d.ts +2 -0
  93. package/dist/test/hooks.test.d.ts.map +1 -0
  94. package/dist/test/hooks.test.js +58 -0
  95. package/dist/test/storage.test.js +16 -16
  96. package/dist/types/options.d.ts +35 -0
  97. package/dist/types/options.d.ts.map +1 -1
  98. package/dist/utils/ai-service-factory.d.ts +5 -5
  99. package/dist/utils/ai-service-factory.d.ts.map +1 -1
  100. package/dist/utils/ai-service-factory.js +4 -3
  101. package/dist/utils/workflow-prompts.d.ts +17 -0
  102. package/dist/utils/workflow-prompts.d.ts.map +1 -0
  103. package/dist/utils/workflow-prompts.js +88 -0
  104. package/package.json +2 -2
  105. package/dist/lib/storage.d.ts.map +0 -1
@@ -2,7 +2,6 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AIOperations = void 0;
4
4
  const ai_1 = require("ai");
5
- const context_builder_1 = require("../context-builder");
6
5
  const prompt_builder_1 = require("../prompt-builder");
7
6
  const stack_formatter_1 = require("../../utils/stack-formatter");
8
7
  const prompts_1 = require("../../prompts");
@@ -123,21 +122,27 @@ class AIOperations {
123
122
  let response;
124
123
  if (enableFilesystemTools) {
125
124
  // Use filesystem tools when enabled
126
- const model = this.modelProvider.getModel({ ...this.modelProvider.getAIConfig(), ...config });
125
+ const model = this.modelProvider.getModel({
126
+ ...this.modelProvider.getAIConfig(),
127
+ ...config,
128
+ });
127
129
  const allTools = {
128
130
  ...filesystem_tools_1.filesystemTools,
129
131
  };
130
132
  const result = await (0, ai_1.streamText)({
131
133
  model,
132
134
  tools: allTools, // Filesystem tools for project analysis
133
- system: prompts_1.PRD_PARSING_SYSTEM_PROMPT + `
135
+ system: prompts_1.PRD_PARSING_SYSTEM_PROMPT +
136
+ `
134
137
 
135
138
  You have access to filesystem tools that allow you to:
136
139
  - readFile: Read the contents of any file in the project
137
140
  - listDirectory: List contents of directories
138
141
 
139
142
  Use these tools to understand the project structure, existing code patterns, and dependencies when parsing the PRD and creating tasks.`,
140
- messages: [{ role: "user", content: userMessage || enhancedPrompt }],
143
+ messages: [
144
+ { role: "user", content: userMessage || enhancedPrompt },
145
+ ],
141
146
  maxRetries: 0,
142
147
  onChunk: streamingOptions?.onChunk
143
148
  ? ({ chunk }) => {
@@ -162,7 +167,8 @@ Use these tools to understand the project structure, existing code patterns, and
162
167
  else {
163
168
  // Use standard streamText without tools
164
169
  response = await this.streamText("", // empty prompt since we use messages
165
- config, prompts_1.PRD_PARSING_SYSTEM_PROMPT, userMessage || enhancedPrompt, streamingOptions, { maxAttempts: 1 });
170
+ config, prompts_1.PRD_PARSING_SYSTEM_PROMPT, userMessage || enhancedPrompt, streamingOptions, { maxAttempts: 1 } // Disable retries here since we're handling them at the outer level
171
+ );
166
172
  }
167
173
  // Parse JSON from response using proper typing
168
174
  const parseResult = this.jsonParser.parseJSONFromResponse(response);
@@ -252,14 +258,18 @@ Use these tools to understand the project structure, existing code patterns, and
252
258
  let response;
253
259
  if (enableFilesystemTools) {
254
260
  // Use filesystem tools when enabled
255
- const model = this.modelProvider.getModel({ ...this.modelProvider.getAIConfig(), ...config });
261
+ const model = this.modelProvider.getModel({
262
+ ...this.modelProvider.getAIConfig(),
263
+ ...config,
264
+ });
256
265
  const allTools = {
257
266
  ...filesystem_tools_1.filesystemTools,
258
267
  };
259
268
  const result = await (0, ai_1.streamText)({
260
269
  model,
261
270
  tools: allTools, // Filesystem tools for project analysis
262
- system: prompts_1.TASK_BREAKDOWN_SYSTEM_PROMPT + `
271
+ system: prompts_1.TASK_BREAKDOWN_SYSTEM_PROMPT +
272
+ `
263
273
 
264
274
  You have access to filesystem tools that allow you to:
265
275
  - readFile: Read the contents of any file in the project
@@ -291,7 +301,8 @@ Use these tools to understand the project structure, existing code, and dependen
291
301
  else {
292
302
  // Use standard streamText without tools
293
303
  response = await this.streamText("", // empty prompt since we use messages
294
- config, prompts_1.TASK_BREAKDOWN_SYSTEM_PROMPT, userMessage || prompt, streamingOptions, { maxAttempts: 1 });
304
+ config, prompts_1.TASK_BREAKDOWN_SYSTEM_PROMPT, userMessage || prompt, streamingOptions, { maxAttempts: 1 } // Disable retries here since we're handling them at the outer level
305
+ );
295
306
  }
296
307
  // Parse JSON from response using proper typing
297
308
  const parseResult = this.jsonParser.parseJSONFromResponse(response);
@@ -313,7 +324,7 @@ Use these tools to understand the project structure, existing code, and dependen
313
324
  let prdContent = "";
314
325
  // If taskId is provided, include existing documentation context
315
326
  if (taskId) {
316
- const contextBuilder = new context_builder_1.ContextBuilder();
327
+ const contextBuilder = (0, ai_service_factory_1.getContextBuilder)();
317
328
  try {
318
329
  const context = await contextBuilder.buildContext(taskId);
319
330
  if (context.documentation || context.stack || context.prdContent) {
@@ -324,7 +335,9 @@ Use these tools to understand the project structure, existing code, and dependen
324
335
  if (context.documentation) {
325
336
  contextInfo += `Documentation Available: ${context.documentation.recap}\n`;
326
337
  if (context.documentation.files.length > 0) {
327
- contextInfo += `Documentation Files: ${context.documentation.files.map((f) => f.path).join(", ")}\n`;
338
+ contextInfo += `Documentation Files: ${context.documentation.files
339
+ .map((f) => f.path)
340
+ .join(", ")}\n`;
328
341
  }
329
342
  }
330
343
  if (context.prdContent) {
@@ -358,7 +371,8 @@ Use these tools to understand the project structure, existing code, and dependen
358
371
  prompt = promptResult.prompt;
359
372
  }
360
373
  return this.streamText("", // empty prompt since we use messages
361
- config, prompts_1.TASK_ENHANCEMENT_SYSTEM_PROMPT, userMessage || prompt, streamingOptions, { maxAttempts: 1 });
374
+ config, prompts_1.TASK_ENHANCEMENT_SYSTEM_PROMPT, userMessage || prompt, streamingOptions, { maxAttempts: 1 } // Disable retries here since we're handling them at the outer level
375
+ );
362
376
  }, retryConfig, "Task enhancement");
363
377
  }
364
378
  async reworkPRD(prdContent, feedback, config, promptOverride, userMessage, streamingOptions, retryConfig, workingDirectory, // Working directory passed from service layer
@@ -402,14 +416,18 @@ Use these tools to understand the project structure, existing code, and dependen
402
416
  }
403
417
  if (enableFilesystemTools) {
404
418
  // Use filesystem tools when enabled
405
- const model = this.modelProvider.getModel({ ...this.modelProvider.getAIConfig(), ...config });
419
+ const model = this.modelProvider.getModel({
420
+ ...this.modelProvider.getAIConfig(),
421
+ ...config,
422
+ });
406
423
  const allTools = {
407
424
  ...filesystem_tools_1.filesystemTools,
408
425
  };
409
426
  const result = await (0, ai_1.streamText)({
410
427
  model,
411
428
  tools: allTools, // Filesystem tools for project analysis
412
- system: prompts_1.PRD_REWORK_SYSTEM_PROMPT + `
429
+ system: prompts_1.PRD_REWORK_SYSTEM_PROMPT +
430
+ `
413
431
 
414
432
  You have access to filesystem tools that allow you to:
415
433
  - readFile: Read the contents of any file in the project
@@ -441,12 +459,15 @@ Use these tools to understand the current project structure, existing code patte
441
459
  else {
442
460
  // Use standard streamText without tools
443
461
  return this.streamText("", // empty prompt since we use messages
444
- config, prompts_1.PRD_REWORK_SYSTEM_PROMPT, userMessage || prompt, streamingOptions, { maxAttempts: 1 });
462
+ config, prompts_1.PRD_REWORK_SYSTEM_PROMPT, userMessage || prompt, streamingOptions, { maxAttempts: 1 } // Disable retries here since we're handling them at the outer level
463
+ );
445
464
  }
446
465
  }, retryConfig, "PRD rework");
447
466
  }
448
467
  // Context7 Integration Methods
449
- async enhanceTaskWithDocumentation(taskId, taskTitle, taskDescription, stackInfo, streamingOptions, retryConfig, config, existingResearch) {
468
+ async enhanceTaskWithDocumentation(taskId, taskTitle, taskDescription, stackInfo, streamingOptions, retryConfig, config, existingResearch
469
+ // existingResearch?: (TaskDocumentation | undefined)[],
470
+ ) {
450
471
  return this.retryHandler
451
472
  .executeWithRetry(async () => {
452
473
  // Context7 integration via HTTP calls
@@ -459,12 +480,14 @@ Use these tools to understand the current project structure, existing code patte
459
480
  // Get custom research tools
460
481
  // const customResearchTools = this.researchTools.getResearchTools();
461
482
  // Build context for this operation using the actual task ID
462
- const contextBuilder = new context_builder_1.ContextBuilder();
483
+ const contextBuilder = (0, ai_service_factory_1.getContextBuilder)();
463
484
  const builtContext = await contextBuilder.buildContext("1.1");
464
485
  // Build existing research context
465
486
  const existingResearchContext = existingResearch
466
487
  ? Object.entries(existingResearch)
467
- .map(([lib, entries]) => `### ${lib}\n${entries.map((e) => `- Query: "${e.query}"`).join("\n")}`)
488
+ .map(([lib, entries]) => `### ${lib}\n${entries
489
+ .map((e) => `- Query: "${e.query}"`)
490
+ .join("\n")}`)
468
491
  .join("\n\n")
469
492
  : "No existing research available.";
470
493
  // const existingResearchContext = existingResearch
@@ -741,14 +764,19 @@ ${existingResearchContext}`,
741
764
  const prompt = `Create a concise recap of the documentation fetched for these libraries:
742
765
 
743
766
  Libraries:
744
- ${libraries.map((lib) => `- ${lib.name} (${lib.context7Id}): ${lib.reason}`).join("\n")}
767
+ ${libraries
768
+ .map((lib) => `- ${lib.name} (${lib.context7Id}): ${lib.reason}`)
769
+ .join("\n")}
745
770
 
746
771
  Documentation Contents:
747
- ${documentContents.map((doc) => `## ${doc.library}\n${doc.content.substring(0, 500)}...`).join("\n\n")}
772
+ ${documentContents
773
+ .map((doc) => `## ${doc.library}\n${doc.content.substring(0, 500)}...`)
774
+ .join("\n\n")}
748
775
 
749
776
  Please provide a 2-3 sentence summary of what documentation is available and how it relates to the task.`;
750
777
  return this.retryHandler.executeWithRetry(async () => {
751
- return this.streamText(prompt, undefined, "You are a technical writer who creates concise summaries of documentation collections.", undefined, streamingOptions, { maxAttempts: 1 });
778
+ return this.streamText(prompt, undefined, "You are a technical writer who creates concise summaries of documentation collections.", undefined, streamingOptions, { maxAttempts: 1 } // Disable retries here since we're handling them at the outer level
779
+ );
752
780
  }, retryConfig, "Documentation recap generation");
753
781
  }
754
782
  async planTask(taskContext, taskDetails, config, promptOverride, userMessage, streamingOptions, retryConfig) {
@@ -772,7 +800,10 @@ Please provide a 2-3 sentence summary of what documentation is available and how
772
800
  }
773
801
  prompt = promptResult.prompt;
774
802
  }
775
- const model = this.modelProvider.getModel({ ...this.modelProvider.getAIConfig(), ...config });
803
+ const model = this.modelProvider.getModel({
804
+ ...this.modelProvider.getAIConfig(),
805
+ ...config,
806
+ });
776
807
  // Get MCP tools and merge with filesystem tools
777
808
  const mcpTools = await this.context7Client.getMCPTools();
778
809
  const allTools = {
@@ -782,7 +813,8 @@ Please provide a 2-3 sentence summary of what documentation is available and how
782
813
  const result = (0, ai_1.streamText)({
783
814
  model,
784
815
  tools: allTools, // Context7 MCP tools + filesystem tools
785
- system: prompts_1.TASK_PLANNING_SYSTEM_PROMPT + `
816
+ system: prompts_1.TASK_PLANNING_SYSTEM_PROMPT +
817
+ `
786
818
 
787
819
  You have access to filesystem tools that allow you to:
788
820
  - readFile: Read the contents of any file in the project
@@ -1 +1 @@
1
- {"version":3,"file":"research-tools.d.ts","sourceRoot":"","sources":["../../../src/lib/ai-service/research-tools.ts"],"names":[],"mappings":"AAIA,qBAAa,aAAa;IACxB,OAAO,CAAC,OAAO,CAAsB;CAwMtC"}
1
+ {"version":3,"file":"research-tools.d.ts","sourceRoot":"","sources":["../../../src/lib/ai-service/research-tools.ts"],"names":[],"mappings":"AAKA,qBAAa,aAAa;IACxB,OAAO,CAAC,OAAO,CAAgC;CAwMhD"}
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ResearchTools = void 0;
4
- const storage_1 = require("../storage");
4
+ const ai_service_factory_1 = require("../../utils/ai-service-factory");
5
5
  class ResearchTools {
6
- storage = new storage_1.LocalStorage();
6
+ storage = (0, ai_service_factory_1.getStorage)();
7
7
  }
8
8
  exports.ResearchTools = ResearchTools;
@@ -1,9 +1,10 @@
1
1
  import { TaskContext, TaskDocumentation } from "../types";
2
+ import { TaskRepository } from "./storage/types";
2
3
  export declare class ContextBuilder {
3
4
  private storage;
4
5
  private taskOMatic;
5
6
  private initialized;
6
- constructor();
7
+ constructor(storage: TaskRepository);
7
8
  private ensureInitialized;
8
9
  /**
9
10
  * Build comprehensive context for AI operations
@@ -1 +1 @@
1
- {"version":3,"file":"context-builder.d.ts","sourceRoot":"","sources":["../../src/lib/context-builder.ts"],"names":[],"mappings":"AAEA,OAAO,EAAQ,WAAW,EAAa,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAI3E,qBAAa,cAAc;IACzB,OAAO,CAAC,OAAO,CAA6B;IAC5C,OAAO,CAAC,UAAU,CAAuB;IACzC,OAAO,CAAC,WAAW,CAAS;;IAM5B,OAAO,CAAC,iBAAiB;IAUzB;;OAEG;IACG,YAAY,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC;IA0CxD;;OAEG;IACG,sBAAsB,CAC1B,KAAK,EAAE,MAAM,EACb,WAAW,CAAC,EAAE,MAAM,EACpB,OAAO,CAAC,EAAE,MAAM,GACf,OAAO,CAAC,WAAW,CAAC;IAsBvB;;OAEG;IACH,OAAO,CAAC,cAAc;IA6CtB;;OAEG;IACH,OAAO,CAAC,oBAAoB;IAI5B;;OAEG;IACH,OAAO,CAAC,kBAAkB;IAmB1B;;OAEG;IACH,OAAO,CAAC,qBAAqB;IAgB7B;;OAEG;IACH,oBAAoB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BAAkB,CAAC,OAAO,EAAE,WAAW,GAAG,MAAM;CAmDjD"}
@@ -3,20 +3,18 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ContextBuilder = void 0;
4
4
  const fs_1 = require("fs");
5
5
  const path_1 = require("path");
6
- const storage_1 = require("./storage");
7
6
  const config_1 = require("./config");
8
7
  class ContextBuilder {
9
- storage = null;
8
+ storage;
10
9
  taskOMatic = null;
11
10
  initialized = false;
12
- constructor() {
13
- // Pure constructor - NO side effects
11
+ constructor(storage) {
12
+ this.storage = storage;
14
13
  }
15
14
  ensureInitialized() {
16
15
  if (this.initialized) {
17
16
  return;
18
17
  }
19
- this.storage = new storage_1.LocalStorage();
20
18
  this.taskOMatic = config_1.configManager.getTaskOMaticDir();
21
19
  this.initialized = true;
22
20
  }
@@ -25,9 +23,6 @@ class ContextBuilder {
25
23
  */
26
24
  async buildContext(taskId) {
27
25
  this.ensureInitialized();
28
- if (!this.storage) {
29
- throw new Error("ContextBuilder not initialized");
30
- }
31
26
  const task = await this.storage.getTask(taskId);
32
27
  if (!task) {
33
28
  throw new Error(`Task with ID ${taskId} not found`);
@@ -0,0 +1,2 @@
1
+ export declare function registerLoggerHooks(): void;
2
+ //# sourceMappingURL=logger.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"logger.d.ts","sourceRoot":"","sources":["../../../src/lib/hooks/logger.ts"],"names":[],"mappings":"AAGA,wBAAgB,mBAAmB,SA8BlC"}
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.registerLoggerHooks = registerLoggerHooks;
7
+ const hooks_1 = require("../hooks");
8
+ const chalk_1 = __importDefault(require("chalk"));
9
+ function registerLoggerHooks() {
10
+ hooks_1.hooks.on("task:created", ({ task }) => {
11
+ console.log(chalk_1.default.gray(`[Hook] Task created: ${task.title} (${task.id})`));
12
+ });
13
+ hooks_1.hooks.on("task:updated", ({ task, changes }) => {
14
+ const changedFields = Object.keys(changes).join(", ");
15
+ console.log(chalk_1.default.gray(`[Hook] Task updated: ${task.id} (Fields: ${changedFields})`));
16
+ });
17
+ hooks_1.hooks.on("task:status-changed", ({ task, oldStatus, newStatus }) => {
18
+ console.log(chalk_1.default.magenta(`[Hook] Status changed: ${task.title} -> ${oldStatus} to ${newStatus}`));
19
+ });
20
+ hooks_1.hooks.on("execution:start", ({ taskId, tool }) => {
21
+ console.log(chalk_1.default.blue(`[Hook] Execution started for ${taskId} using ${tool}`));
22
+ });
23
+ hooks_1.hooks.on("execution:end", ({ taskId, success }) => {
24
+ const status = success ? chalk_1.default.green("Success") : chalk_1.default.red("Failed");
25
+ console.log(chalk_1.default.blue(`[Hook] Execution ended for ${taskId}: ${status}`));
26
+ });
27
+ }
@@ -0,0 +1,64 @@
1
+ import { Task } from "../types";
2
+ export type TaskEventType = "task:created" | "task:updated" | "task:deleted" | "task:status-changed" | "task:progress" | "execution:start" | "execution:end" | "execution:error";
3
+ export interface TaskEventPayloads {
4
+ "task:created": {
5
+ task: Task;
6
+ };
7
+ "task:updated": {
8
+ task: Task;
9
+ changes: Partial<Task>;
10
+ };
11
+ "task:deleted": {
12
+ taskId: string;
13
+ };
14
+ "task:status-changed": {
15
+ task: Task;
16
+ oldStatus: string;
17
+ newStatus: string;
18
+ };
19
+ "task:progress": {
20
+ taskId?: string;
21
+ message: string;
22
+ type?: string;
23
+ };
24
+ "execution:start": {
25
+ taskId: string;
26
+ tool: string;
27
+ };
28
+ "execution:end": {
29
+ taskId: string;
30
+ success: boolean;
31
+ };
32
+ "execution:error": {
33
+ taskId: string;
34
+ error: Error;
35
+ };
36
+ }
37
+ export type TaskEventHandler<T extends TaskEventType> = (payload: TaskEventPayloads[T]) => Promise<void> | void;
38
+ declare class HookRegistry {
39
+ private static instance;
40
+ private listeners;
41
+ private constructor();
42
+ static getInstance(): HookRegistry;
43
+ /**
44
+ * Register a handler for a specific event type
45
+ */
46
+ on<T extends TaskEventType>(type: T, handler: TaskEventHandler<T>): void;
47
+ /**
48
+ * Remove a handler
49
+ */
50
+ off<T extends TaskEventType>(type: T, handler: TaskEventHandler<T>): void;
51
+ /**
52
+ * Emit an event to all registered handlers
53
+ * We don't await handlers to prevent blocking the main flow,
54
+ * but we catch errors to prevent crashes.
55
+ */
56
+ emit<T extends TaskEventType>(type: T, payload: TaskEventPayloads[T]): Promise<void>;
57
+ /**
58
+ * Clear all listeners (useful for testing)
59
+ */
60
+ clear(): void;
61
+ }
62
+ export declare const hooks: HookRegistry;
63
+ export {};
64
+ //# sourceMappingURL=hooks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../src/lib/hooks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAGhC,MAAM,MAAM,aAAa,GACrB,cAAc,GACd,cAAc,GACd,cAAc,GACd,qBAAqB,GACrB,eAAe,GACf,iBAAiB,GACjB,eAAe,GACf,iBAAiB,CAAC;AAGtB,MAAM,WAAW,iBAAiB;IAChC,cAAc,EAAE;QAAE,IAAI,EAAE,IAAI,CAAA;KAAE,CAAC;IAC/B,cAAc,EAAE;QAAE,IAAI,EAAE,IAAI,CAAC;QAAC,OAAO,EAAE,OAAO,CAAC,IAAI,CAAC,CAAA;KAAE,CAAC;IACvD,cAAc,EAAE;QAAE,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC;IACnC,qBAAqB,EAAE;QAAE,IAAI,EAAE,IAAI,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC;IAC5E,eAAe,EAAE;QAAE,MAAM,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IACrE,iBAAiB,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC;IACpD,eAAe,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAA;KAAE,CAAC;IACtD,iBAAiB,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,KAAK,CAAA;KAAE,CAAC;CACrD;AAGD,MAAM,MAAM,gBAAgB,CAAC,CAAC,SAAS,aAAa,IAAI,CACtD,OAAO,EAAE,iBAAiB,CAAC,CAAC,CAAC,KAC1B,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;AAE1B,cAAM,YAAY;IAChB,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAe;IACtC,OAAO,CAAC,SAAS,CAAiD;IAElE,OAAO;WAIO,WAAW,IAAI,YAAY;IAOzC;;OAEG;IACI,EAAE,CAAC,CAAC,SAAS,aAAa,EAC/B,IAAI,EAAE,CAAC,EACP,OAAO,EAAE,gBAAgB,CAAC,CAAC,CAAC,GAC3B,IAAI;IAOP;;OAEG;IACI,GAAG,CAAC,CAAC,SAAS,aAAa,EAChC,IAAI,EAAE,CAAC,EACP,OAAO,EAAE,gBAAgB,CAAC,CAAC,CAAC,GAC3B,IAAI;IAOP;;;;OAIG;IACU,IAAI,CAAC,CAAC,SAAS,aAAa,EACvC,IAAI,EAAE,CAAC,EACP,OAAO,EAAE,iBAAiB,CAAC,CAAC,CAAC,GAC5B,OAAO,CAAC,IAAI,CAAC;IAehB;;OAEG;IACI,KAAK,IAAI,IAAI;CAGrB;AAED,eAAO,MAAM,KAAK,cAA6B,CAAC"}
@@ -0,0 +1,60 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.hooks = void 0;
4
+ class HookRegistry {
5
+ static instance;
6
+ listeners;
7
+ constructor() {
8
+ this.listeners = new Map();
9
+ }
10
+ static getInstance() {
11
+ if (!HookRegistry.instance) {
12
+ HookRegistry.instance = new HookRegistry();
13
+ }
14
+ return HookRegistry.instance;
15
+ }
16
+ /**
17
+ * Register a handler for a specific event type
18
+ */
19
+ on(type, handler) {
20
+ if (!this.listeners.has(type)) {
21
+ this.listeners.set(type, new Set());
22
+ }
23
+ this.listeners.get(type).add(handler);
24
+ }
25
+ /**
26
+ * Remove a handler
27
+ */
28
+ off(type, handler) {
29
+ const handlers = this.listeners.get(type);
30
+ if (handlers) {
31
+ handlers.delete(handler);
32
+ }
33
+ }
34
+ /**
35
+ * Emit an event to all registered handlers
36
+ * We don't await handlers to prevent blocking the main flow,
37
+ * but we catch errors to prevent crashes.
38
+ */
39
+ async emit(type, payload) {
40
+ const handlers = this.listeners.get(type);
41
+ if (!handlers || handlers.size === 0)
42
+ return;
43
+ const promises = Array.from(handlers).map(async (handler) => {
44
+ try {
45
+ await handler(payload);
46
+ }
47
+ catch (error) {
48
+ console.error(`Error in hook handler for event ${type}:`, error);
49
+ }
50
+ });
51
+ await Promise.all(promises);
52
+ }
53
+ /**
54
+ * Clear all listeners (useful for testing)
55
+ */
56
+ clear() {
57
+ this.listeners.clear();
58
+ }
59
+ }
60
+ exports.hooks = HookRegistry.getInstance();
@@ -20,70 +20,71 @@
20
20
  * TaskService - Core task management operations
21
21
  * Handles creating, updating, listing, enhancing, splitting, and planning tasks
22
22
  */
23
- export { TaskService } from '../services/tasks';
23
+ export { TaskService } from "../services/tasks";
24
24
  /**
25
25
  * PRDService - Product Requirements Document parsing and processing
26
26
  * Handles PRD parsing, task extraction, and PRD improvement
27
27
  */
28
- export { PRDService } from '../services/prd';
28
+ export { PRDService } from "../services/prd";
29
29
  /**
30
30
  * Re-export all types from the types module
31
31
  * Includes Task, AIConfig, StreamingOptions, and all related interfaces
32
32
  */
33
- export * from '../types';
33
+ export * from "../types";
34
34
  /**
35
35
  * Re-export callback types
36
36
  */
37
- export type { ProgressCallback } from '../types/callbacks';
37
+ export type { ProgressCallback } from "../types/callbacks";
38
38
  /**
39
39
  * Re-export option types
40
40
  */
41
- export type { CreateTaskOptions, SplitTaskOptions, PlanTaskOptions, EnhanceTaskOptions } from '../types/options';
41
+ export type { CreateTaskOptions, SplitTaskOptions, PlanTaskOptions, EnhanceTaskOptions, } from "../types/options";
42
42
  /**
43
43
  * Factory functions for getting singleton instances of core services
44
44
  * These ensure only one instance exists throughout the application
45
45
  */
46
- export { getAIOperations, getModelProvider, getStorage, getContextBuilder, resetServiceInstances } from '../utils/ai-service-factory';
46
+ export { getAIOperations, getModelProvider, getStorage, getContextBuilder, resetServiceInstances, } from "../utils/ai-service-factory";
47
47
  /**
48
48
  * AI configuration builder utility
49
49
  */
50
- export { buildAIConfig } from '../utils/ai-config-builder';
51
- export type { AIOptions } from '../utils/ai-config-builder';
50
+ export { buildAIConfig } from "../utils/ai-config-builder";
51
+ export type { AIOptions } from "../utils/ai-config-builder";
52
52
  /**
53
53
  * LocalStorage - File-based storage abstraction for tasks and metadata
54
54
  * Note: This is Node.js file-system based and not compatible with browser environments
55
55
  */
56
- export { LocalStorage } from './storage';
56
+ export { FileSystemStorage } from "./storage/file-system";
57
+ export type { TaskRepository } from "./storage/types";
57
58
  /**
58
59
  * ConfigManager - Configuration management for task-o-matic projects
59
60
  */
60
- export { ConfigManager, configManager } from './config';
61
+ export { ConfigManager, configManager } from "./config";
61
62
  /**
62
63
  * AIOperations - AI service operations wrapper
63
64
  */
64
- export { AIOperations } from './ai-service/ai-operations';
65
+ export { AIOperations } from "./ai-service/ai-operations";
65
66
  /**
66
67
  * ModelProvider - AI model provider abstraction
67
68
  */
68
- export { ModelProvider } from './ai-service/model-provider';
69
+ export { ModelProvider } from "./ai-service/model-provider";
69
70
  /**
70
71
  * ContextBuilder - Task context assembly for AI operations
71
72
  */
72
- export { ContextBuilder } from './context-builder';
73
+ export { ContextBuilder } from "./context-builder";
73
74
  /**
74
75
  * PromptBuilder - Prompt template management
75
76
  */
76
- export { PromptBuilder } from './prompt-builder';
77
+ export { PromptBuilder } from "./prompt-builder";
77
78
  /**
78
79
  * Stack formatter utility
79
80
  */
80
- export { formatStackInfo } from '../utils/stack-formatter';
81
+ export { formatStackInfo } from "../utils/stack-formatter";
81
82
  /**
82
83
  * Streaming options builders
83
84
  */
84
- export { createStreamingOptions, createStreamingOptionsWithCustomHandlers } from '../utils/streaming-options';
85
+ export { createStreamingOptions, createStreamingOptionsWithCustomHandlers, } from "../utils/streaming-options";
85
86
  /**
86
87
  * Validation utilities
87
88
  */
88
- export { isValidAIProvider, runValidations } from './validation';
89
+ export { isValidAIProvider, runValidations } from "./validation";
89
90
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/lib/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAMH;;;GAGG;AACH,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAEhD;;;GAGG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAM7C;;;GAGG;AACH,cAAc,UAAU,CAAC;AAEzB;;GAEG;AACH,YAAY,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAE3D;;GAEG;AACH,YAAY,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,eAAe,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAMjH;;;GAGG;AACH,OAAO,EACL,eAAe,EACf,gBAAgB,EAChB,UAAU,EACV,iBAAiB,EACjB,qBAAqB,EACtB,MAAM,6BAA6B,CAAC;AAErC;;GAEG;AACH,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,YAAY,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AAM5D;;;GAGG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAEzC;;GAEG;AACH,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAExD;;GAEG;AACH,OAAO,EAAE,YAA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;AAEtD;;GAEG;AACH,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAExD;;GAEG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE1D;;GAEG;AACH,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAE5D;;GAEG;AACH,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAEnD;;GAEG;AACH,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAMjD;;GAEG;AACH,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAE3D;;GAEG;AACH,OAAO,EACL,sBAAsB,EACtB,wCAAwC,GACzC,MAAM,4BAA4B,CAAC;AAMpC;;GAEG;AACH,OAAO,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC"}
package/dist/lib/index.js CHANGED
@@ -32,7 +32,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
32
32
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
33
33
  };
34
34
  Object.defineProperty(exports, "__esModule", { value: true });
35
- exports.runValidations = exports.isValidAIProvider = exports.createStreamingOptionsWithCustomHandlers = exports.createStreamingOptions = exports.formatStackInfo = exports.PromptBuilder = exports.ContextBuilder = exports.ModelProvider = exports.AIOperations = exports.configManager = exports.ConfigManager = exports.LocalStorage = exports.buildAIConfig = exports.resetServiceInstances = exports.getContextBuilder = exports.getStorage = exports.getModelProvider = exports.getAIOperations = exports.PRDService = exports.TaskService = void 0;
35
+ exports.runValidations = exports.isValidAIProvider = exports.createStreamingOptionsWithCustomHandlers = exports.createStreamingOptions = exports.formatStackInfo = exports.PromptBuilder = exports.ContextBuilder = exports.ModelProvider = exports.AIOperations = exports.configManager = exports.ConfigManager = exports.FileSystemStorage = exports.buildAIConfig = exports.resetServiceInstances = exports.getContextBuilder = exports.getStorage = exports.getModelProvider = exports.getAIOperations = exports.PRDService = exports.TaskService = void 0;
36
36
  // ============================================================================
37
37
  // Main Services - Business Logic Layer
38
38
  // ============================================================================
@@ -81,8 +81,8 @@ Object.defineProperty(exports, "buildAIConfig", { enumerable: true, get: functio
81
81
  * LocalStorage - File-based storage abstraction for tasks and metadata
82
82
  * Note: This is Node.js file-system based and not compatible with browser environments
83
83
  */
84
- var storage_1 = require("./storage");
85
- Object.defineProperty(exports, "LocalStorage", { enumerable: true, get: function () { return storage_1.LocalStorage; } });
84
+ var file_system_1 = require("./storage/file-system");
85
+ Object.defineProperty(exports, "FileSystemStorage", { enumerable: true, get: function () { return file_system_1.FileSystemStorage; } });
86
86
  /**
87
87
  * ConfigManager - Configuration management for task-o-matic projects
88
88
  */
@@ -1 +1 @@
1
- {"version":3,"file":"prompt-builder.d.ts","sourceRoot":"","sources":["../../src/lib/prompt-builder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAMnE,MAAM,WAAW,oBAAoB;IACnC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;IACzB,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAClC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,cAAc,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;CAC7B;AAED,qBAAa,a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