@locusai/sdk 0.16.2 → 0.18.2

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 (133) hide show
  1. package/PACKAGE_GUIDE.md +269 -0
  2. package/package.json +28 -28
  3. package/dist/agent/codebase-indexer-service.d.ts +0 -17
  4. package/dist/agent/codebase-indexer-service.d.ts.map +0 -1
  5. package/dist/agent/document-fetcher.d.ts +0 -23
  6. package/dist/agent/document-fetcher.d.ts.map +0 -1
  7. package/dist/agent/git-workflow.d.ts +0 -59
  8. package/dist/agent/git-workflow.d.ts.map +0 -1
  9. package/dist/agent/index.d.ts +0 -9
  10. package/dist/agent/index.d.ts.map +0 -1
  11. package/dist/agent/review-service.d.ts +0 -21
  12. package/dist/agent/review-service.d.ts.map +0 -1
  13. package/dist/agent/reviewer-worker.d.ts +0 -42
  14. package/dist/agent/reviewer-worker.d.ts.map +0 -1
  15. package/dist/agent/task-executor.d.ts +0 -26
  16. package/dist/agent/task-executor.d.ts.map +0 -1
  17. package/dist/agent/worker-cli.d.ts +0 -6
  18. package/dist/agent/worker-cli.d.ts.map +0 -1
  19. package/dist/agent/worker-types.d.ts +0 -36
  20. package/dist/agent/worker-types.d.ts.map +0 -1
  21. package/dist/agent/worker.d.ts +0 -40
  22. package/dist/agent/worker.d.ts.map +0 -1
  23. package/dist/agent/worker.js +0 -2792
  24. package/dist/ai/__tests__/factory.test.d.ts +0 -2
  25. package/dist/ai/__tests__/factory.test.d.ts.map +0 -1
  26. package/dist/ai/claude-runner.d.ts +0 -35
  27. package/dist/ai/claude-runner.d.ts.map +0 -1
  28. package/dist/ai/claude-stream-parser.d.ts +0 -41
  29. package/dist/ai/claude-stream-parser.d.ts.map +0 -1
  30. package/dist/ai/codex-runner.d.ts +0 -38
  31. package/dist/ai/codex-runner.d.ts.map +0 -1
  32. package/dist/ai/factory.d.ts +0 -26
  33. package/dist/ai/factory.d.ts.map +0 -1
  34. package/dist/ai/index.d.ts +0 -8
  35. package/dist/ai/index.d.ts.map +0 -1
  36. package/dist/ai/runner.d.ts +0 -23
  37. package/dist/ai/runner.d.ts.map +0 -1
  38. package/dist/core/config.d.ts +0 -58
  39. package/dist/core/config.d.ts.map +0 -1
  40. package/dist/core/index.d.ts +0 -4
  41. package/dist/core/index.d.ts.map +0 -1
  42. package/dist/core/indexer.d.ts +0 -31
  43. package/dist/core/indexer.d.ts.map +0 -1
  44. package/dist/core/prompt-builder.d.ts +0 -14
  45. package/dist/core/prompt-builder.d.ts.map +0 -1
  46. package/dist/discussion/agents/facilitator-prompt.d.ts +0 -13
  47. package/dist/discussion/agents/facilitator-prompt.d.ts.map +0 -1
  48. package/dist/discussion/discussion-facilitator.d.ts +0 -67
  49. package/dist/discussion/discussion-facilitator.d.ts.map +0 -1
  50. package/dist/discussion/discussion-manager.d.ts +0 -59
  51. package/dist/discussion/discussion-manager.d.ts.map +0 -1
  52. package/dist/discussion/discussion-types.d.ts +0 -89
  53. package/dist/discussion/discussion-types.d.ts.map +0 -1
  54. package/dist/discussion/index.d.ts +0 -5
  55. package/dist/discussion/index.d.ts.map +0 -1
  56. package/dist/events.d.ts +0 -22
  57. package/dist/events.d.ts.map +0 -1
  58. package/dist/exec/context-tracker.d.ts +0 -183
  59. package/dist/exec/context-tracker.d.ts.map +0 -1
  60. package/dist/exec/event-emitter.d.ts +0 -117
  61. package/dist/exec/event-emitter.d.ts.map +0 -1
  62. package/dist/exec/events.d.ts +0 -171
  63. package/dist/exec/events.d.ts.map +0 -1
  64. package/dist/exec/exec-session.d.ts +0 -164
  65. package/dist/exec/exec-session.d.ts.map +0 -1
  66. package/dist/exec/history-manager.d.ts +0 -153
  67. package/dist/exec/history-manager.d.ts.map +0 -1
  68. package/dist/exec/index.d.ts +0 -7
  69. package/dist/exec/index.d.ts.map +0 -1
  70. package/dist/exec/types.d.ts +0 -130
  71. package/dist/exec/types.d.ts.map +0 -1
  72. package/dist/git/git-utils.d.ts +0 -31
  73. package/dist/git/git-utils.d.ts.map +0 -1
  74. package/dist/git/index.d.ts +0 -3
  75. package/dist/git/index.d.ts.map +0 -1
  76. package/dist/git/pr-service.d.ts +0 -66
  77. package/dist/git/pr-service.d.ts.map +0 -1
  78. package/dist/index-node.d.ts +0 -22
  79. package/dist/index-node.d.ts.map +0 -1
  80. package/dist/index-node.js +0 -5607
  81. package/dist/index.d.ts +0 -37
  82. package/dist/index.d.ts.map +0 -1
  83. package/dist/index.js +0 -559
  84. package/dist/modules/auth.d.ts +0 -23
  85. package/dist/modules/auth.d.ts.map +0 -1
  86. package/dist/modules/base.d.ts +0 -8
  87. package/dist/modules/base.d.ts.map +0 -1
  88. package/dist/modules/ci.d.ts +0 -8
  89. package/dist/modules/ci.d.ts.map +0 -1
  90. package/dist/modules/docs.d.ts +0 -14
  91. package/dist/modules/docs.d.ts.map +0 -1
  92. package/dist/modules/invitations.d.ts +0 -10
  93. package/dist/modules/invitations.d.ts.map +0 -1
  94. package/dist/modules/organizations.d.ts +0 -24
  95. package/dist/modules/organizations.d.ts.map +0 -1
  96. package/dist/modules/sprints.d.ts +0 -14
  97. package/dist/modules/sprints.d.ts.map +0 -1
  98. package/dist/modules/tasks.d.ts +0 -25
  99. package/dist/modules/tasks.d.ts.map +0 -1
  100. package/dist/modules/workspaces.d.ts +0 -44
  101. package/dist/modules/workspaces.d.ts.map +0 -1
  102. package/dist/orchestrator/index.d.ts +0 -85
  103. package/dist/orchestrator/index.d.ts.map +0 -1
  104. package/dist/orchestrator/types.d.ts +0 -36
  105. package/dist/orchestrator/types.d.ts.map +0 -1
  106. package/dist/planning/agents/architect.d.ts +0 -1
  107. package/dist/planning/agents/architect.d.ts.map +0 -1
  108. package/dist/planning/agents/cross-task-reviewer.d.ts +0 -1
  109. package/dist/planning/agents/cross-task-reviewer.d.ts.map +0 -1
  110. package/dist/planning/agents/planner.d.ts +0 -20
  111. package/dist/planning/agents/planner.d.ts.map +0 -1
  112. package/dist/planning/agents/sprint-organizer.d.ts +0 -1
  113. package/dist/planning/agents/sprint-organizer.d.ts.map +0 -1
  114. package/dist/planning/agents/tech-lead.d.ts +0 -1
  115. package/dist/planning/agents/tech-lead.d.ts.map +0 -1
  116. package/dist/planning/index.d.ts +0 -4
  117. package/dist/planning/index.d.ts.map +0 -1
  118. package/dist/planning/plan-manager.d.ts +0 -51
  119. package/dist/planning/plan-manager.d.ts.map +0 -1
  120. package/dist/planning/planning-meeting.d.ts +0 -34
  121. package/dist/planning/planning-meeting.d.ts.map +0 -1
  122. package/dist/planning/sprint-plan.d.ts +0 -51
  123. package/dist/planning/sprint-plan.d.ts.map +0 -1
  124. package/dist/utils/colors.d.ts +0 -62
  125. package/dist/utils/colors.d.ts.map +0 -1
  126. package/dist/utils/json-extractor.d.ts +0 -10
  127. package/dist/utils/json-extractor.d.ts.map +0 -1
  128. package/dist/utils/resolve-bin.d.ts +0 -15
  129. package/dist/utils/resolve-bin.d.ts.map +0 -1
  130. package/dist/utils/retry.d.ts +0 -8
  131. package/dist/utils/retry.d.ts.map +0 -1
  132. package/dist/utils/structured-output.d.ts +0 -14
  133. package/dist/utils/structured-output.d.ts.map +0 -1
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=factory.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"factory.test.d.ts","sourceRoot":"","sources":["../../../src/ai/__tests__/factory.test.ts"],"names":[],"mappings":""}
@@ -1,35 +0,0 @@
1
- import type { ExecEventEmitter } from "../exec/event-emitter.js";
2
- import type { StreamChunk } from "../exec/types.js";
3
- import { LogFn } from "./factory.js";
4
- import type { AiRunner } from "./runner.js";
5
- export declare class ClaudeRunner implements AiRunner {
6
- private model;
7
- private log?;
8
- private projectPath;
9
- private eventEmitter?;
10
- private currentToolName?;
11
- private activeProcess;
12
- private aborted;
13
- timeoutMs: number;
14
- constructor(projectPath: string, model?: string, log?: LogFn | undefined, timeoutMs?: number);
15
- /**
16
- * Set an event emitter to receive execution events.
17
- */
18
- setEventEmitter(emitter: ExecEventEmitter): void;
19
- /**
20
- * Abort the currently running Claude CLI process, if any.
21
- */
22
- abort(): void;
23
- run(prompt: string): Promise<string>;
24
- private withTimeout;
25
- private buildCliArgs;
26
- runStream(prompt: string): AsyncGenerator<StreamChunk, void, unknown>;
27
- /**
28
- * Emit an event corresponding to a stream chunk.
29
- */
30
- private emitEventForChunk;
31
- private executeRun;
32
- private shouldSuppressLine;
33
- private createExecutionError;
34
- }
35
- //# sourceMappingURL=claude-runner.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"claude-runner.d.ts","sourceRoot":"","sources":["../../src/ai/claude-runner.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAGpD,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AACrC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAK5C,qBAAa,YAAa,YAAW,QAAQ;IAUzC,OAAO,CAAC,KAAK;IACb,OAAO,CAAC,GAAG,CAAC;IAVd,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,YAAY,CAAC,CAAmB;IACxC,OAAO,CAAC,eAAe,CAAC,CAAS;IACjC,OAAO,CAAC,aAAa,CAA6B;IAClD,OAAO,CAAC,OAAO,CAAS;IACxB,SAAS,EAAE,MAAM,CAAC;gBAGhB,WAAW,EAAE,MAAM,EACX,KAAK,GAAE,MAAuC,EAC9C,GAAG,CAAC,EAAE,KAAK,YAAA,EACnB,SAAS,CAAC,EAAE,MAAM;IAMpB;;OAEG;IACH,eAAe,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI;IAIhD;;OAEG;IACH,KAAK,IAAI,IAAI;IAQP,GAAG,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IA+B1C,OAAO,CAAC,WAAW;IA0BnB,OAAO,CAAC,YAAY;IAgBb,SAAS,CAAC,MAAM,EAAE,MAAM,GAAG,cAAc,CAAC,WAAW,EAAE,IAAI,EAAE,OAAO,CAAC;IA6K5E;;OAEG;IACH,OAAO,CAAC,iBAAiB;IAiCzB,OAAO,CAAC,UAAU;IAkFlB,OAAO,CAAC,kBAAkB;IAO1B,OAAO,CAAC,oBAAoB;CAO7B"}
@@ -1,41 +0,0 @@
1
- import type { StreamChunk } from "../exec/types.js";
2
- import type { LogFn } from "./factory.js";
3
- export interface ClaudeStreamItem {
4
- type: string;
5
- result?: string;
6
- event?: {
7
- type: string;
8
- index?: number;
9
- delta?: {
10
- type: string;
11
- text?: string;
12
- partial_json?: string;
13
- };
14
- content_block?: {
15
- type: string;
16
- name?: string;
17
- id?: string;
18
- };
19
- };
20
- }
21
- /**
22
- * Parses Claude CLI stream-json output into typed StreamChunks.
23
- * Handles both streaming mode (returns StreamChunk) and
24
- * non-streaming mode (returns result string).
25
- */
26
- export declare class ClaudeStreamParser {
27
- private activeTools;
28
- /**
29
- * Parse a stream-json line into a StreamChunk (for streaming mode).
30
- */
31
- parseLineToChunk(line: string): StreamChunk | null;
32
- /**
33
- * Parse a stream-json line and extract the final result string (for non-streaming mode).
34
- */
35
- parseLine(line: string, log?: LogFn): string | null;
36
- private processItemToChunk;
37
- private handleEventToChunk;
38
- private processItem;
39
- private handleEvent;
40
- }
41
- //# sourceMappingURL=claude-stream-parser.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"claude-stream-parser.d.ts","sourceRoot":"","sources":["../../src/ai/claude-stream-parser.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,kBAAkB,CAAC;AAEhE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAE1C,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE;QACN,IAAI,EAAE,MAAM,CAAC;QACb,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,KAAK,CAAC,EAAE;YACN,IAAI,EAAE,MAAM,CAAC;YACb,IAAI,CAAC,EAAE,MAAM,CAAC;YACd,YAAY,CAAC,EAAE,MAAM,CAAC;SACvB,CAAC;QACF,aAAa,CAAC,EAAE;YACd,IAAI,EAAE,MAAM,CAAC;YACb,IAAI,CAAC,EAAE,MAAM,CAAC;YACd,EAAE,CAAC,EAAE,MAAM,CAAC;SACb,CAAC;KACH,CAAC;CACH;AAaD;;;;GAIG;AACH,qBAAa,kBAAkB;IAC7B,OAAO,CAAC,WAAW,CAA+C;IAElE;;OAEG;IACH,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,WAAW,GAAG,IAAI;IAWlD;;OAEG;IACH,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,IAAI;IAWnD,OAAO,CAAC,kBAAkB;IAY1B,OAAO,CAAC,kBAAkB;IAwE1B,OAAO,CAAC,WAAW;IAYnB,OAAO,CAAC,WAAW;CAYpB"}
@@ -1,38 +0,0 @@
1
- import type { ExecEventEmitter } from "../exec/event-emitter.js";
2
- import type { StreamChunk } from "../exec/types.js";
3
- import type { LogFn } from "./factory.js";
4
- import type { AiRunner } from "./runner.js";
5
- export declare class CodexRunner implements AiRunner {
6
- private projectPath;
7
- private model;
8
- private log?;
9
- private reasoningEffort?;
10
- private activeProcess;
11
- private aborted;
12
- private eventEmitter?;
13
- private currentToolName?;
14
- timeoutMs: number;
15
- constructor(projectPath: string, model?: string, log?: LogFn | undefined, reasoningEffort?: string | undefined, timeoutMs?: number);
16
- setEventEmitter(emitter: ExecEventEmitter): void;
17
- /**
18
- * Abort the currently running Codex CLI process, if any.
19
- */
20
- abort(): void;
21
- run(prompt: string): Promise<string>;
22
- private withTimeout;
23
- runStream(prompt: string): AsyncGenerator<StreamChunk, void, unknown>;
24
- private emitEventForChunk;
25
- private executeRun;
26
- private buildArgs;
27
- /**
28
- * Streams filtered output to console.
29
- * Only displays high-level status changes to reduce terminal noise.
30
- */
31
- private streamToConsole;
32
- private shouldDisplay;
33
- private readOutput;
34
- private createErrorFromOutput;
35
- private cleanupTempFile;
36
- private sleep;
37
- }
38
- //# sourceMappingURL=codex-runner.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"codex-runner.d.ts","sourceRoot":"","sources":["../../src/ai/codex-runner.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAEpD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAK5C,qBAAa,WAAY,YAAW,QAAQ;IAQxC,OAAO,CAAC,WAAW;IACnB,OAAO,CAAC,KAAK;IACb,OAAO,CAAC,GAAG,CAAC;IACZ,OAAO,CAAC,eAAe,CAAC;IAV1B,OAAO,CAAC,aAAa,CAA6B;IAClD,OAAO,CAAC,OAAO,CAAS;IACxB,OAAO,CAAC,YAAY,CAAC,CAAmB;IACxC,OAAO,CAAC,eAAe,CAAC,CAAS;IACjC,SAAS,EAAE,MAAM,CAAC;gBAGR,WAAW,EAAE,MAAM,EACnB,KAAK,GAAE,MAAsC,EAC7C,GAAG,CAAC,EAAE,KAAK,YAAA,EACX,eAAe,CAAC,EAAE,MAAM,YAAA,EAChC,SAAS,CAAC,EAAE,MAAM;IAKpB,eAAe,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI;IAIhD;;OAEG;IACH,KAAK,IAAI,IAAI;IAQP,GAAG,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IA8B1C,OAAO,CAAC,WAAW;IA0BZ,SAAS,CAAC,MAAM,EAAE,MAAM,GAAG,cAAc,CAAC,WAAW,EAAE,IAAI,EAAE,OAAO,CAAC;IA8J5E,OAAO,CAAC,iBAAiB;IA+BzB,OAAO,CAAC,UAAU;IAyDlB,OAAO,CAAC,SAAS;IAqBjB;;;OAGG;IACH,OAAO,CAAC,eAAe;IAWvB,OAAO,CAAC,aAAa;IAKrB,OAAO,CAAC,UAAU;IAYlB,OAAO,CAAC,qBAAqB;IAY7B,OAAO,CAAC,eAAe;IAQvB,OAAO,CAAC,KAAK;CAGd"}
@@ -1,26 +0,0 @@
1
- import type { AiProvider, AiRunner } from "./runner.js";
2
- export type LogFn = (message: string, level?: "info" | "success" | "warn" | "error") => void;
3
- /**
4
- * Silent no-op logger. Use as default when logging is optional.
5
- */
6
- export declare const noopLogger: LogFn;
7
- /**
8
- * Creates a worker-style logger with timestamps and agent ID prefix.
9
- * Used by SDK agent workers for structured log output.
10
- *
11
- * Output format: `[HH:mm:ss] [agent-id] ℹ message`
12
- */
13
- export declare function createWorkerLogger(agentId: string, prefix?: string): LogFn;
14
- export interface AiRunnerConfig {
15
- projectPath: string;
16
- model?: string;
17
- log?: LogFn;
18
- /** Maximum execution time in milliseconds (default: 30 minutes) */
19
- timeoutMs?: number;
20
- /** Reasoning effort level for Codex models (e.g. "low", "medium", "high") */
21
- reasoningEffort?: string;
22
- /** Maximum number of agentic turns before stopping (print mode only) */
23
- maxTurns?: number;
24
- }
25
- export declare function createAiRunner(provider: AiProvider | undefined, config: AiRunnerConfig): AiRunner;
26
- //# sourceMappingURL=factory.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"factory.d.ts","sourceRoot":"","sources":["../../src/ai/factory.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAExD,MAAM,MAAM,KAAK,GAAG,CAClB,OAAO,EAAE,MAAM,EACf,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,KAC1C,IAAI,CAAC;AAEV;;GAEG;AACH,eAAO,MAAM,UAAU,EAAE,KAExB,CAAC;AAEF;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,KAAK,CAoB1E;AAED,MAAM,WAAW,cAAc;IAC7B,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,GAAG,CAAC,EAAE,KAAK,CAAC;IACZ,mEAAmE;IACnE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,6EAA6E;IAC7E,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,wEAAwE;IACxE,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,wBAAgB,cAAc,CAC5B,QAAQ,EAAE,UAAU,GAAG,SAAS,EAChC,MAAM,EAAE,cAAc,GACrB,QAAQ,CA8BV"}
@@ -1,8 +0,0 @@
1
- export { ClaudeRunner } from "./claude-runner.js";
2
- export type { ClaudeStreamItem } from "./claude-stream-parser.js";
3
- export { ClaudeStreamParser } from "./claude-stream-parser.js";
4
- export { CodexRunner } from "./codex-runner.js";
5
- export type { AiRunnerConfig, LogFn } from "./factory.js";
6
- export { createAiRunner, createWorkerLogger, noopLogger } from "./factory.js";
7
- export type { AiProvider, AiRunner } from "./runner.js";
8
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ai/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,YAAY,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAClE,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,YAAY,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,EAAE,cAAc,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC9E,YAAY,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC"}
@@ -1,23 +0,0 @@
1
- import type { Provider } from "../core/config.js";
2
- import type { ExecEventEmitter } from "../exec/event-emitter.js";
3
- import type { StreamChunk } from "../exec/types.js";
4
- export interface AiRunner {
5
- run(prompt: string): Promise<string>;
6
- runStream(prompt: string): AsyncGenerator<StreamChunk, void, unknown>;
7
- /**
8
- * Set an event emitter to receive execution events.
9
- */
10
- setEventEmitter?(emitter: ExecEventEmitter): void;
11
- /**
12
- * Abort the currently running CLI process, if any.
13
- * Used during graceful shutdown to prevent orphaned processes.
14
- */
15
- abort(): void;
16
- /**
17
- * Maximum execution time in milliseconds.
18
- * When exceeded, the active process is killed and run() rejects.
19
- */
20
- timeoutMs?: number;
21
- }
22
- export type AiProvider = Provider;
23
- //# sourceMappingURL=runner.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["../../src/ai/runner.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAEpD,MAAM,WAAW,QAAQ;IACvB,GAAG,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IACrC,SAAS,CAAC,MAAM,EAAE,MAAM,GAAG,cAAc,CAAC,WAAW,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;IACtE;;OAEG;IACH,eAAe,CAAC,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI,CAAC;IAClD;;;OAGG;IACH,KAAK,IAAI,IAAI,CAAC;IACd;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,MAAM,UAAU,GAAG,QAAQ,CAAC"}
@@ -1,58 +0,0 @@
1
- export declare const PROVIDER: {
2
- readonly CLAUDE: "claude";
3
- readonly CODEX: "codex";
4
- };
5
- export type Provider = (typeof PROVIDER)[keyof typeof PROVIDER];
6
- export declare const CLAUDE_MODELS: {
7
- readonly OPUS: "opus";
8
- readonly SONNET: "sonnet";
9
- readonly HAIKU: "haiku";
10
- readonly OPUS_PLAN: "opusplan";
11
- readonly CLAUDE_OPUS_4_6: "claude-opus-4-6";
12
- readonly CLAUDE_SONNET_4_5: "claude-sonnet-4-5-20250929";
13
- readonly CLAUDE_SONNET_4_6: "claude-sonnet-4-6";
14
- readonly CLAUDE_HAIKU_4_5: "claude-haiku-4-5-20251001";
15
- };
16
- export type ClaudeModel = (typeof CLAUDE_MODELS)[keyof typeof CLAUDE_MODELS];
17
- export declare const CODEX_MODELS: {
18
- readonly GPT_5_3_CODEX: "gpt-5.3-codex";
19
- readonly GPT_5_3_CODEX_SPARK: "gpt-5.3-codex-spark";
20
- readonly GPT_5_CODEX_MINI: "gpt-5-codex-mini";
21
- readonly GPT_5_2_CODEX: "gpt-5.2-codex";
22
- };
23
- export type CodexModel = (typeof CODEX_MODELS)[keyof typeof CODEX_MODELS];
24
- export type ModelId = ClaudeModel | CodexModel;
25
- export declare const PROVIDER_MODELS: Record<Provider, readonly ModelId[]>;
26
- export declare const DEFAULT_MODEL: Record<Provider, ModelId>;
27
- export declare function isValidModelForProvider(provider: Provider, model: string): boolean;
28
- export declare function getModelsForProvider(provider: Provider): readonly ModelId[];
29
- export declare const LOCUS_SCHEMA_BASE_URL = "https://locusai.dev/schemas";
30
- export declare const LOCUS_SCHEMAS: {
31
- readonly config: "https://locusai.dev/schemas/config.schema.json";
32
- readonly settings: "https://locusai.dev/schemas/settings.schema.json";
33
- };
34
- export declare const LOCUS_CONFIG: {
35
- dir: string;
36
- configFile: string;
37
- settingsFile: string;
38
- indexFile: string;
39
- contextFile: string;
40
- learningsFile: string;
41
- artifactsDir: string;
42
- documentsDir: string;
43
- sessionsDir: string;
44
- reviewsDir: string;
45
- plansDir: string;
46
- discussionsDir: string;
47
- };
48
- export declare const LOCUS_GITIGNORE_PATTERNS: readonly ["# Locus AI - Session data (user-specific, can grow large)", ".locus/sessions/", "", "# Locus AI - Artifacts (local-only, user-specific)", ".locus/artifacts/", "", "# Locus AI - Review reports (generated per sprint)", ".locus/reviews/", "", "# Locus AI - Plans (generated per task)", ".locus/plans/", "", "# Locus AI - Discussions (AI discussion sessions)", ".locus/discussions/", "", "# Locus AI - Settings (contains API key, telegram config, etc.)", ".locus/settings.json", "", "# Locus AI - Configuration (contains project context, etc.)", ".locus/config.json"];
49
- export declare function getLocusPath(projectPath: string, fileName: keyof typeof LOCUS_CONFIG): string;
50
- /**
51
- * Gets the artifacts directory path for a specific agent.
52
- * Artifacts are organized by agent ID to avoid conflicts and improve organization.
53
- * @param projectPath - The project root path
54
- * @param agentId - The agent ID (can be full ID or short form)
55
- * @returns Path to the agent-specific artifacts directory
56
- */
57
- export declare function getAgentArtifactsPath(projectPath: string, agentId: string): string;
58
- //# sourceMappingURL=config.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/core/config.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,QAAQ;;;CAGX,CAAC;AAEX,MAAM,MAAM,QAAQ,GAAG,CAAC,OAAO,QAAQ,CAAC,CAAC,MAAM,OAAO,QAAQ,CAAC,CAAC;AAEhE,eAAO,MAAM,aAAa;;;;;;;;;CAShB,CAAC;AACX,MAAM,MAAM,WAAW,GAAG,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,OAAO,aAAa,CAAC,CAAC;AAE7E,eAAO,MAAM,YAAY;;;;;CAKf,CAAC;AACX,MAAM,MAAM,UAAU,GAAG,CAAC,OAAO,YAAY,CAAC,CAAC,MAAM,OAAO,YAAY,CAAC,CAAC;AAE1E,MAAM,MAAM,OAAO,GAAG,WAAW,GAAG,UAAU,CAAC;AAE/C,eAAO,MAAM,eAAe,EAAE,MAAM,CAAC,QAAQ,EAAE,SAAS,OAAO,EAAE,CAGvD,CAAC;AAEX,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,QAAQ,EAAE,OAAO,CAGnD,CAAC;AAEF,wBAAgB,uBAAuB,CACrC,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE,MAAM,GACZ,OAAO,CAET;AAED,wBAAgB,oBAAoB,CAAC,QAAQ,EAAE,QAAQ,GAAG,SAAS,OAAO,EAAE,CAE3E;AAED,eAAO,MAAM,qBAAqB,gCAAgC,CAAC;AAEnE,eAAO,MAAM,aAAa;;;CAGhB,CAAC;AAEX,eAAO,MAAM,YAAY;;;;;;;;;;;;;CAaxB,CAAC;AAIF,eAAO,MAAM,wBAAwB,gkBAqB3B,CAAC;AAEX,wBAAgB,YAAY,CAC1B,WAAW,EAAE,MAAM,EACnB,QAAQ,EAAE,MAAM,OAAO,YAAY,GAClC,MAAM,CAER;AAED;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CACnC,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,MAAM,GACd,MAAM,CASR"}
@@ -1,4 +0,0 @@
1
- export { CLAUDE_MODELS, type ClaudeModel, CODEX_MODELS, type CodexModel, DEFAULT_MODEL, getAgentArtifactsPath, getLocusPath, getModelsForProvider, isValidModelForProvider, LOCUS_CONFIG, LOCUS_GITIGNORE_PATTERNS, LOCUS_SCHEMA_BASE_URL, LOCUS_SCHEMAS, type ModelId, PROVIDER, PROVIDER_MODELS, type Provider, } from "./config.js";
2
- export { type CodebaseIndex, CodebaseIndexer } from "./indexer.js";
3
- export { PromptBuilder } from "./prompt-builder.js";
4
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,aAAa,EACb,KAAK,WAAW,EAChB,YAAY,EACZ,KAAK,UAAU,EACf,aAAa,EACb,qBAAqB,EACrB,YAAY,EACZ,oBAAoB,EACpB,uBAAuB,EACvB,YAAY,EACZ,wBAAwB,EACxB,qBAAqB,EACrB,aAAa,EACb,KAAK,OAAO,EACZ,QAAQ,EACR,eAAe,EACf,KAAK,QAAQ,GACd,MAAM,aAAa,CAAC;AACrB,OAAO,EAAE,KAAK,aAAa,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AACnE,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC"}
@@ -1,31 +0,0 @@
1
- export interface CodebaseIndex {
2
- symbols: Record<string, string[]>;
3
- responsibilities: Record<string, string>;
4
- lastIndexed: string;
5
- treeHash?: string;
6
- fileHashes?: Record<string, string>;
7
- }
8
- export declare class CodebaseIndexer {
9
- private projectPath;
10
- private indexPath;
11
- private fullReindexRatioThreshold;
12
- constructor(projectPath: string);
13
- /**
14
- * Generates a codebase index by providing the entire file tree to an AI summarizer.
15
- * Supports incremental updates - only analyzes changed files when possible.
16
- * Returns null if no changes detected (unless force=true).
17
- */
18
- index(onProgress?: (message: string) => void, treeSummarizer?: (tree: string) => Promise<CodebaseIndex>, force?: boolean): Promise<CodebaseIndex | null>;
19
- private getFileTree;
20
- loadIndex(): CodebaseIndex | null;
21
- saveIndex(index: CodebaseIndex): void;
22
- private cloneIndex;
23
- private applyIndexMetadata;
24
- private hashTree;
25
- private hashFile;
26
- private computeFileHashes;
27
- private diffFiles;
28
- private removeFilesFromIndex;
29
- private mergeIndex;
30
- }
31
- //# sourceMappingURL=indexer.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"indexer.d.ts","sourceRoot":"","sources":["../../src/core/indexer.ts"],"names":[],"mappings":"AAKA,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;IAClC,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACzC,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACrC;AAED,qBAAa,eAAe;IAC1B,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,SAAS,CAAS;IAC1B,OAAO,CAAC,yBAAyB,CAAe;gBAEpC,WAAW,EAAE,MAAM;IAK/B;;;;OAIG;IACG,KAAK,CACT,UAAU,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,EACtC,cAAc,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,aAAa,CAAC,EACzD,KAAK,UAAQ,GACZ,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC;YAoHlB,WAAW;IAgEzB,SAAS,IAAI,aAAa,GAAG,IAAI;IAWjC,SAAS,CAAC,KAAK,EAAE,aAAa,GAAG,IAAI;IAQrC,OAAO,CAAC,UAAU;IAKlB,OAAO,CAAC,kBAAkB;IAY1B,OAAO,CAAC,QAAQ;IAIhB,OAAO,CAAC,QAAQ;IAShB,OAAO,CAAC,iBAAiB;IAWzB,OAAO,CAAC,SAAS;IAkBjB,OAAO,CAAC,oBAAoB;IAiB5B,OAAO,CAAC,UAAU;CA8BnB"}
@@ -1,14 +0,0 @@
1
- import { Task } from "@locusai/shared";
2
- export declare class PromptBuilder {
3
- private projectPath;
4
- constructor(projectPath: string);
5
- build(task: Task): Promise<string>;
6
- buildGenericPrompt(query: string): Promise<string>;
7
- private getProjectContext;
8
- private getFallbackContext;
9
- private getKnowledgeBaseSection;
10
- private getLearningsContent;
11
- private getDiscussionInsightsContent;
12
- roleToText(role: Task["assigneeRole"]): string | null;
13
- }
14
- //# sourceMappingURL=prompt-builder.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"prompt-builder.d.ts","sourceRoot":"","sources":["../../src/core/prompt-builder.ts"],"names":[],"mappings":"AAEA,OAAO,EAAgB,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAKrD,qBAAa,aAAa;IACZ,OAAO,CAAC,WAAW;gBAAX,WAAW,EAAE,MAAM;IAEjC,KAAK,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC;IAuFlC,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAqCxD,OAAO,CAAC,iBAAiB;IAiBzB,OAAO,CAAC,kBAAkB;IAiB1B,OAAO,CAAC,uBAAuB;IAQ/B,OAAO,CAAC,mBAAmB;IAiB3B,OAAO,CAAC,4BAA4B;IAqDpC,UAAU,CAAC,IAAI,EAAE,IAAI,CAAC,cAAc,CAAC,GAAG,MAAM,GAAG,IAAI;CAoBtD"}
@@ -1,13 +0,0 @@
1
- import type { DiscussionInsight, DiscussionMessage } from "../discussion-types.js";
2
- export interface FacilitatorPromptInput {
3
- topic: string;
4
- projectContext: string | null;
5
- learnings: string | null;
6
- knowledgeBase: string;
7
- previousMessages: DiscussionMessage[];
8
- insights: DiscussionInsight[];
9
- isFirstMessage: boolean;
10
- }
11
- export declare function buildFacilitatorPrompt(input: FacilitatorPromptInput): string;
12
- export declare function buildSummaryPrompt(topic: string, messages: DiscussionMessage[], insights: DiscussionInsight[]): string;
13
- //# sourceMappingURL=facilitator-prompt.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"facilitator-prompt.d.ts","sourceRoot":"","sources":["../../../src/discussion/agents/facilitator-prompt.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,iBAAiB,EACjB,iBAAiB,EAClB,MAAM,wBAAwB,CAAC;AAEhC,MAAM,WAAW,sBAAsB;IACrC,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,aAAa,EAAE,MAAM,CAAC;IACtB,gBAAgB,EAAE,iBAAiB,EAAE,CAAC;IACtC,QAAQ,EAAE,iBAAiB,EAAE,CAAC;IAC9B,cAAc,EAAE,OAAO,CAAC;CACzB;AAED,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,sBAAsB,GAAG,MAAM,CAwF5E;AAED,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,MAAM,EACb,QAAQ,EAAE,iBAAiB,EAAE,EAC7B,QAAQ,EAAE,iBAAiB,EAAE,GAC5B,MAAM,CAwCR"}
@@ -1,67 +0,0 @@
1
- import type { LogFn } from "../ai/factory.js";
2
- import type { AiRunner } from "../ai/runner.js";
3
- import { Provider } from "../core/config.js";
4
- import type { StreamChunk } from "../exec/types.js";
5
- import type { DiscussionManager } from "./discussion-manager.js";
6
- import type { Discussion, DiscussionInsight } from "./discussion-types.js";
7
- export interface DiscussionFacilitatorConfig {
8
- projectPath: string;
9
- aiRunner: AiRunner;
10
- discussionManager: DiscussionManager;
11
- log?: LogFn;
12
- provider: Provider;
13
- model: string;
14
- }
15
- export interface StartDiscussionResult {
16
- discussion: Discussion;
17
- message: string;
18
- }
19
- export interface ContinueDiscussionResult {
20
- response: string;
21
- insights: DiscussionInsight[];
22
- }
23
- export declare class DiscussionFacilitator {
24
- private projectPath;
25
- private aiRunner;
26
- private discussionManager;
27
- private log;
28
- private provider;
29
- private model;
30
- constructor(config: DiscussionFacilitatorConfig);
31
- /**
32
- * Start a new discussion on a topic. Creates the discussion,
33
- * generates the AI's opening question, and saves it.
34
- */
35
- startDiscussion(topic: string): Promise<StartDiscussionResult>;
36
- /**
37
- * Continue a discussion with a user message. Runs the AI to generate
38
- * a response, extracts insights, and saves everything.
39
- * Non-streaming path for Telegram and other non-interactive consumers.
40
- */
41
- continueDiscussion(discussionId: string, userMessage: string): Promise<ContinueDiscussionResult>;
42
- /**
43
- * Continue a discussion with streaming support for CLI consumption.
44
- * Yields stream chunks in real-time and returns the final result.
45
- */
46
- continueDiscussionStream(discussionId: string, userMessage: string): AsyncGenerator<StreamChunk, ContinueDiscussionResult, unknown>;
47
- /**
48
- * Generate a final summary of the discussion, save it as the last
49
- * assistant message, and mark the discussion as completed.
50
- */
51
- summarizeDiscussion(discussionId: string): Promise<string>;
52
- /**
53
- * Extract <insight>...</insight> XML blocks from the AI response.
54
- * Returns the cleaned response text (with insight tags removed) and
55
- * the parsed insight objects.
56
- */
57
- private parseInsights;
58
- /**
59
- * Build context from project files (LOCUS.md, LEARNINGS.md).
60
- * Reuses the same logic as PromptBuilder.
61
- */
62
- private buildContext;
63
- private getProjectContext;
64
- private getLearningsContent;
65
- private getKnowledgeBaseSection;
66
- }
67
- //# sourceMappingURL=discussion-facilitator.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"discussion-facilitator.d.ts","sourceRoot":"","sources":["../../src/discussion/discussion-facilitator.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAE9C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAgB,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAKpD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AACjE,OAAO,KAAK,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAE3E,MAAM,WAAW,2BAA2B;IAC1C,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,QAAQ,CAAC;IACnB,iBAAiB,EAAE,iBAAiB,CAAC;IACrC,GAAG,CAAC,EAAE,KAAK,CAAC;IACZ,QAAQ,EAAE,QAAQ,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,qBAAqB;IACpC,UAAU,EAAE,UAAU,CAAC;IACvB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,wBAAwB;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,iBAAiB,EAAE,CAAC;CAC/B;AAED,qBAAa,qBAAqB;IAChC,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,QAAQ,CAAW;IAC3B,OAAO,CAAC,iBAAiB,CAAoB;IAC7C,OAAO,CAAC,GAAG,CAAQ;IACnB,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,KAAK,CAAS;gBAEV,MAAM,EAAE,2BAA2B;IAS/C;;;OAGG;IACG,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,qBAAqB,CAAC;IA6CpE;;;;OAIG;IACG,kBAAkB,CACtB,YAAY,EAAE,MAAM,EACpB,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC,wBAAwB,CAAC;IAsCpC;;;OAGG;IACI,wBAAwB,CAC7B,YAAY,EAAE,MAAM,EACpB,WAAW,EAAE,MAAM,GAClB,cAAc,CAAC,WAAW,EAAE,wBAAwB,EAAE,OAAO,CAAC;IAkDjE;;;OAGG;IACG,mBAAmB,CAAC,YAAY,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAwBhE;;;;OAIG;IACH,OAAO,CAAC,aAAa;IAyCrB;;;OAGG;IACH,OAAO,CAAC,YAAY;IAYpB,OAAO,CAAC,iBAAiB;IAezB,OAAO,CAAC,mBAAmB;IAiB3B,OAAO,CAAC,uBAAuB;CAMhC"}
@@ -1,59 +0,0 @@
1
- import type { Discussion, DiscussionInsight } from "./discussion-types.js";
2
- /**
3
- * Manages the lifecycle of discussions:
4
- * create, save, load, list, complete, archive, delete.
5
- */
6
- export declare class DiscussionManager {
7
- private discussionsDir;
8
- constructor(projectPath: string);
9
- /**
10
- * Create a new discussion for a given topic.
11
- */
12
- create(topic: string, model: string, provider: string): Discussion;
13
- /**
14
- * Save a discussion to disk as JSON and summary markdown.
15
- */
16
- save(discussion: Discussion): void;
17
- /**
18
- * Load a discussion by ID.
19
- */
20
- load(id: string): Discussion | null;
21
- /**
22
- * List all discussions, optionally filtered by status. Sorted newest first.
23
- */
24
- list(status?: Discussion["status"]): Discussion[];
25
- /**
26
- * Mark a discussion as completed.
27
- */
28
- complete(id: string): Discussion;
29
- /**
30
- * Mark a discussion as archived.
31
- */
32
- archive(id: string): void;
33
- /**
34
- * Delete a discussion's files entirely.
35
- */
36
- delete(id: string): void;
37
- /**
38
- * Append a message to a discussion and save.
39
- */
40
- addMessage(id: string, role: "user" | "assistant", content: string): Discussion;
41
- /**
42
- * Append an insight to a discussion and save.
43
- */
44
- addInsight(id: string, insight: DiscussionInsight): Discussion;
45
- /**
46
- * Aggregate insights across all completed discussions.
47
- */
48
- getAllInsights(): DiscussionInsight[];
49
- /**
50
- * Get the markdown content of a discussion for display.
51
- */
52
- getMarkdown(id: string): string | null;
53
- /**
54
- * Render a discussion as readable markdown.
55
- */
56
- toMarkdown(discussion: Discussion): string;
57
- private ensureDir;
58
- }
59
- //# sourceMappingURL=discussion-manager.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"discussion-manager.d.ts","sourceRoot":"","sources":["../../src/discussion/discussion-manager.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAE3E;;;GAGG;AACH,qBAAa,iBAAiB;IAC5B,OAAO,CAAC,cAAc,CAAS;gBAEnB,WAAW,EAAE,MAAM;IAI/B;;OAEG;IACH,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,UAAU;IAsBlE;;OAEG;IACH,IAAI,CAAC,UAAU,EAAE,UAAU,GAAG,IAAI;IAUlC;;OAEG;IACH,IAAI,CAAC,EAAE,EAAE,MAAM,GAAG,UAAU,GAAG,IAAI;IAenC;;OAEG;IACH,IAAI,CAAC,MAAM,CAAC,EAAE,UAAU,CAAC,QAAQ,CAAC,GAAG,UAAU,EAAE;IA6BjD;;OAEG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,GAAG,UAAU;IAahC;;OAEG;IACH,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI;IAWzB;;OAEG;IACH,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI;IAcxB;;OAEG;IACH,UAAU,CACR,EAAE,EAAE,MAAM,EACV,IAAI,EAAE,MAAM,GAAG,WAAW,EAC1B,OAAO,EAAE,MAAM,GACd,UAAU;IAiBb;;OAEG;IACH,UAAU,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,EAAE,iBAAiB,GAAG,UAAU;IAa9D;;OAEG;IACH,cAAc,IAAI,iBAAiB,EAAE;IAiBrC;;OAEG;IACH,WAAW,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI;IAMtC;;OAEG;IACH,UAAU,CAAC,UAAU,EAAE,UAAU,GAAG,MAAM;IAkD1C,OAAO,CAAC,SAAS;CAKlB"}
@@ -1,89 +0,0 @@
1
- import { z } from "zod";
2
- export declare const DiscussionMessageSchema: z.ZodObject<{
3
- role: z.ZodEnum<{
4
- user: "user";
5
- assistant: "assistant";
6
- }>;
7
- content: z.ZodString;
8
- timestamp: z.ZodNumber;
9
- }, z.core.$strip>;
10
- export declare const DiscussionInsightSchema: z.ZodObject<{
11
- id: z.ZodString;
12
- type: z.ZodEnum<{
13
- decision: "decision";
14
- requirement: "requirement";
15
- idea: "idea";
16
- concern: "concern";
17
- learning: "learning";
18
- }>;
19
- title: z.ZodString;
20
- content: z.ZodString;
21
- tags: z.ZodDefault<z.ZodArray<z.ZodString>>;
22
- createdAt: z.ZodString;
23
- }, z.core.$strip>;
24
- export declare const DiscussionSchema: z.ZodObject<{
25
- id: z.ZodString;
26
- title: z.ZodString;
27
- topic: z.ZodString;
28
- status: z.ZodDefault<z.ZodEnum<{
29
- completed: "completed";
30
- active: "active";
31
- archived: "archived";
32
- }>>;
33
- messages: z.ZodDefault<z.ZodArray<z.ZodObject<{
34
- role: z.ZodEnum<{
35
- user: "user";
36
- assistant: "assistant";
37
- }>;
38
- content: z.ZodString;
39
- timestamp: z.ZodNumber;
40
- }, z.core.$strip>>>;
41
- insights: z.ZodDefault<z.ZodArray<z.ZodObject<{
42
- id: z.ZodString;
43
- type: z.ZodEnum<{
44
- decision: "decision";
45
- requirement: "requirement";
46
- idea: "idea";
47
- concern: "concern";
48
- learning: "learning";
49
- }>;
50
- title: z.ZodString;
51
- content: z.ZodString;
52
- tags: z.ZodDefault<z.ZodArray<z.ZodString>>;
53
- createdAt: z.ZodString;
54
- }, z.core.$strip>>>;
55
- createdAt: z.ZodString;
56
- updatedAt: z.ZodString;
57
- metadata: z.ZodObject<{
58
- model: z.ZodString;
59
- provider: z.ZodString;
60
- }, z.core.$strip>;
61
- }, z.core.$strip>;
62
- export interface DiscussionMessage {
63
- role: "user" | "assistant";
64
- content: string;
65
- timestamp: number;
66
- }
67
- export interface DiscussionInsight {
68
- id: string;
69
- type: "decision" | "requirement" | "idea" | "concern" | "learning";
70
- title: string;
71
- content: string;
72
- tags: string[];
73
- createdAt: string;
74
- }
75
- export interface Discussion {
76
- id: string;
77
- title: string;
78
- topic: string;
79
- status: "active" | "completed" | "archived";
80
- messages: DiscussionMessage[];
81
- insights: DiscussionInsight[];
82
- createdAt: string;
83
- updatedAt: string;
84
- metadata: {
85
- model: string;
86
- provider: string;
87
- };
88
- }
89
- //# sourceMappingURL=discussion-types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"discussion-types.d.ts","sourceRoot":"","sources":["../../src/discussion/discussion-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,uBAAuB;;;;;;;iBAIlC,CAAC;AAEH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;iBAOlC,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAa3B,CAAC;AAMH,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,MAAM,GAAG,WAAW,CAAC;IAC3B,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,iBAAiB;IAChC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,UAAU,GAAG,aAAa,GAAG,MAAM,GAAG,SAAS,GAAG,UAAU,CAAC;IACnE,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,EAAE,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,UAAU;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,QAAQ,GAAG,WAAW,GAAG,UAAU,CAAC;IAC5C,QAAQ,EAAE,iBAAiB,EAAE,CAAC;IAC9B,QAAQ,EAAE,iBAAiB,EAAE,CAAC;IAC9B,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE;QACR,KAAK,EAAE,MAAM,CAAC;QACd,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH"}
@@ -1,5 +0,0 @@
1
- export { buildFacilitatorPrompt, buildSummaryPrompt, type FacilitatorPromptInput, } from "./agents/facilitator-prompt.js";
2
- export { type ContinueDiscussionResult, DiscussionFacilitator, type DiscussionFacilitatorConfig, type StartDiscussionResult, } from "./discussion-facilitator.js";
3
- export { DiscussionManager } from "./discussion-manager.js";
4
- export { type Discussion, type DiscussionInsight, DiscussionInsightSchema, type DiscussionMessage, DiscussionMessageSchema, DiscussionSchema, } from "./discussion-types.js";
5
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/discussion/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,sBAAsB,EACtB,kBAAkB,EAClB,KAAK,sBAAsB,GAC5B,MAAM,gCAAgC,CAAC;AACxC,OAAO,EACL,KAAK,wBAAwB,EAC7B,qBAAqB,EACrB,KAAK,2BAA2B,EAChC,KAAK,qBAAqB,GAC3B,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAC5D,OAAO,EACL,KAAK,UAAU,EACf,KAAK,iBAAiB,EACtB,uBAAuB,EACvB,KAAK,iBAAiB,EACtB,uBAAuB,EACvB,gBAAgB,GACjB,MAAM,uBAAuB,CAAC"}
package/dist/events.d.ts DELETED
@@ -1,22 +0,0 @@
1
- import { EventEmitter } from "events";
2
- import { RetryOptions } from "./utils/retry.js";
3
- export declare enum LocusEvent {
4
- TOKEN_EXPIRED = "TOKEN_EXPIRED",
5
- AUTH_ERROR = "AUTH_ERROR",
6
- REQUEST_ERROR = "REQUEST_ERROR"
7
- }
8
- export interface LocusConfig {
9
- baseUrl: string;
10
- token?: string | null;
11
- timeout?: number;
12
- retryOptions?: RetryOptions;
13
- }
14
- export declare class LocusEmitter extends EventEmitter {
15
- on(event: LocusEvent.TOKEN_EXPIRED, listener: () => void): this;
16
- on(event: LocusEvent.AUTH_ERROR, listener: (error: Error) => void): this;
17
- on(event: LocusEvent.REQUEST_ERROR, listener: (error: Error) => void): this;
18
- emit(event: LocusEvent.TOKEN_EXPIRED): boolean;
19
- emit(event: LocusEvent.AUTH_ERROR, error: Error): boolean;
20
- emit(event: LocusEvent.REQUEST_ERROR, error: Error): boolean;
21
- }
22
- //# sourceMappingURL=events.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../src/events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,QAAQ,CAAC;AAEtC,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAEhD,oBAAY,UAAU;IACpB,aAAa,kBAAkB;IAC/B,UAAU,eAAe;IACzB,aAAa,kBAAkB;CAChC;AAED,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,YAAY,CAAC;CAC7B;AAED,qBAAa,YAAa,SAAQ,YAAY;IAC5C,EAAE,CAAC,KAAK,EAAE,UAAU,CAAC,aAAa,EAAE,QAAQ,EAAE,MAAM,IAAI,GAAG,IAAI;IAC/D,EAAE,CAAC,KAAK,EAAE,UAAU,CAAC,UAAU,EAAE,QAAQ,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,GAAG,IAAI;IACxE,EAAE,CAAC,KAAK,EAAE,UAAU,CAAC,aAAa,EAAE,QAAQ,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,GAAG,IAAI;IAQ3E,IAAI,CAAC,KAAK,EAAE,UAAU,CAAC,aAAa,GAAG,OAAO;IAC9C,IAAI,CAAC,KAAK,EAAE,UAAU,CAAC,UAAU,EAAE,KAAK,EAAE,KAAK,GAAG,OAAO;IACzD,IAAI,CAAC,KAAK,EAAE,UAAU,CAAC,aAAa,EAAE,KAAK,EAAE,KAAK,GAAG,OAAO;CAI7D"}