agent-issues 0.0.119 → 0.0.126

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 (172) hide show
  1. package/dist/build-info.json +3 -0
  2. package/dist/cli.js +97746 -26
  3. package/kanban/dist/assets/index-CIAg6qj5.css +1 -0
  4. package/kanban/dist/assets/index-DaYQjJS7.js +920 -0
  5. package/kanban/dist/index.html +13 -0
  6. package/package.json +12 -11
  7. package/site/dist/assets/index-D6NM1iDo.js +4533 -0
  8. package/site/dist/index.html +1 -1
  9. package/skills/agent-issues-operating-contract.md +1 -1
  10. package/skills/{ai-wayfinder → ai-pioneer}/SKILL.md +9 -9
  11. package/skills/recipes/README.md +2 -2
  12. package/skills/recipes/{wayfinder-map.md → pioneer-map.md} +2 -2
  13. package/skills/recipes/{wayfinder-ticket.md → pioneer-ticket.md} +2 -2
  14. package/dist/agent-installer.d.ts +0 -49
  15. package/dist/agent-installer.js +0 -171
  16. package/dist/agent-installer.js.map +0 -1
  17. package/dist/auth-session.d.ts +0 -40
  18. package/dist/auth-session.js +0 -107
  19. package/dist/auth-session.js.map +0 -1
  20. package/dist/body-backfill.d.ts +0 -26
  21. package/dist/body-backfill.js +0 -219
  22. package/dist/body-backfill.js.map +0 -1
  23. package/dist/build-mode.d.ts +0 -1
  24. package/dist/build-mode.js +0 -1
  25. package/dist/build-mode.js.map +0 -1
  26. package/dist/cli/commands/auth.d.ts +0 -61
  27. package/dist/cli/commands/auth.js +0 -134
  28. package/dist/cli/commands/auth.js.map +0 -1
  29. package/dist/cli/commands/backfill.d.ts +0 -8
  30. package/dist/cli/commands/backfill.js +0 -36
  31. package/dist/cli/commands/backfill.js.map +0 -1
  32. package/dist/cli/commands/comments.d.ts +0 -34
  33. package/dist/cli/commands/comments.js +0 -124
  34. package/dist/cli/commands/comments.js.map +0 -1
  35. package/dist/cli/commands/context.d.ts +0 -13
  36. package/dist/cli/commands/context.js +0 -156
  37. package/dist/cli/commands/context.js.map +0 -1
  38. package/dist/cli/commands/entities.d.ts +0 -91
  39. package/dist/cli/commands/entities.js +0 -420
  40. package/dist/cli/commands/entities.js.map +0 -1
  41. package/dist/cli/commands/export.d.ts +0 -20
  42. package/dist/cli/commands/export.js +0 -98
  43. package/dist/cli/commands/export.js.map +0 -1
  44. package/dist/cli/commands/fallback.d.ts +0 -6
  45. package/dist/cli/commands/fallback.js +0 -10
  46. package/dist/cli/commands/fallback.js.map +0 -1
  47. package/dist/cli/commands/handoff.d.ts +0 -1
  48. package/dist/cli/commands/handoff.js +0 -2
  49. package/dist/cli/commands/handoff.js.map +0 -1
  50. package/dist/cli/commands/installers.d.ts +0 -37
  51. package/dist/cli/commands/installers.js +0 -78
  52. package/dist/cli/commands/installers.js.map +0 -1
  53. package/dist/cli/commands/kanban.d.ts +0 -8
  54. package/dist/cli/commands/kanban.js +0 -83
  55. package/dist/cli/commands/kanban.js.map +0 -1
  56. package/dist/cli/commands/meta.d.ts +0 -14
  57. package/dist/cli/commands/meta.js +0 -33
  58. package/dist/cli/commands/meta.js.map +0 -1
  59. package/dist/cli/commands/plan-entries.d.ts +0 -30
  60. package/dist/cli/commands/plan-entries.js +0 -94
  61. package/dist/cli/commands/plan-entries.js.map +0 -1
  62. package/dist/cli/commands/site.d.ts +0 -29
  63. package/dist/cli/commands/site.js +0 -89
  64. package/dist/cli/commands/site.js.map +0 -1
  65. package/dist/cli/commands/sql.d.ts +0 -6
  66. package/dist/cli/commands/sql.js +0 -21
  67. package/dist/cli/commands/sql.js.map +0 -1
  68. package/dist/cli/commands/synchronize.d.ts +0 -12
  69. package/dist/cli/commands/synchronize.js +0 -31
  70. package/dist/cli/commands/synchronize.js.map +0 -1
  71. package/dist/cli/commands/tenants.d.ts +0 -29
  72. package/dist/cli/commands/tenants.js +0 -101
  73. package/dist/cli/commands/tenants.js.map +0 -1
  74. package/dist/cli/index.d.ts +0 -4
  75. package/dist/cli/index.js +0 -120
  76. package/dist/cli/index.js.map +0 -1
  77. package/dist/cli/renderers.d.ts +0 -250
  78. package/dist/cli/renderers.js +0 -286
  79. package/dist/cli/renderers.js.map +0 -1
  80. package/dist/cli/shared.d.ts +0 -97
  81. package/dist/cli/shared.js +0 -192
  82. package/dist/cli/shared.js.map +0 -1
  83. package/dist/cli.d.ts +0 -11
  84. package/dist/cli.js.map +0 -1
  85. package/dist/context-cli.d.ts +0 -16
  86. package/dist/context-cli.js +0 -131
  87. package/dist/context-cli.js.map +0 -1
  88. package/dist/daemon/daemon-lifecycle.d.ts +0 -1
  89. package/dist/daemon/daemon-lifecycle.js +0 -2
  90. package/dist/daemon/daemon-lifecycle.js.map +0 -1
  91. package/dist/daemon/daemon-main.d.ts +0 -14
  92. package/dist/daemon/daemon-main.js +0 -30
  93. package/dist/daemon/daemon-main.js.map +0 -1
  94. package/dist/daemon/local-daemon-store.d.ts +0 -21
  95. package/dist/daemon/local-daemon-store.js +0 -31
  96. package/dist/daemon/local-daemon-store.js.map +0 -1
  97. package/dist/entity-projection.d.ts +0 -141
  98. package/dist/entity-projection.js +0 -147
  99. package/dist/entity-projection.js.map +0 -1
  100. package/dist/entra-device-login.d.ts +0 -12
  101. package/dist/entra-device-login.js +0 -40
  102. package/dist/entra-device-login.js.map +0 -1
  103. package/dist/export-files.d.ts +0 -24
  104. package/dist/export-files.js +0 -230
  105. package/dist/export-files.js.map +0 -1
  106. package/dist/export-markdown.d.ts +0 -24
  107. package/dist/export-markdown.js +0 -343
  108. package/dist/export-markdown.js.map +0 -1
  109. package/dist/help.d.ts +0 -112
  110. package/dist/help.js +0 -1430
  111. package/dist/help.js.map +0 -1
  112. package/dist/kanban/assets.d.ts +0 -3
  113. package/dist/kanban/assets.js +0 -37
  114. package/dist/kanban/assets.js.map +0 -1
  115. package/dist/kanban/index.d.ts +0 -1
  116. package/dist/kanban/index.js +0 -2
  117. package/dist/kanban/index.js.map +0 -1
  118. package/dist/kanban/server.d.ts +0 -28
  119. package/dist/kanban/server.js +0 -118
  120. package/dist/kanban/server.js.map +0 -1
  121. package/dist/mcp-installer.d.ts +0 -32
  122. package/dist/mcp-installer.js +0 -118
  123. package/dist/mcp-installer.js.map +0 -1
  124. package/dist/mcp-server/index.d.ts +0 -11
  125. package/dist/mcp-server/index.js +0 -504
  126. package/dist/mcp-server/index.js.map +0 -1
  127. package/dist/mcp-server/index.test.d.ts +0 -1
  128. package/dist/mcp-server/index.test.js +0 -746
  129. package/dist/mcp-server/index.test.js.map +0 -1
  130. package/dist/mcp-server/mcp-tool-audit.d.ts +0 -6
  131. package/dist/mcp-server/mcp-tool-audit.js +0 -47
  132. package/dist/mcp-server/mcp-tool-audit.js.map +0 -1
  133. package/dist/mcp-server/stdio.d.ts +0 -2
  134. package/dist/mcp-server/stdio.js +0 -7
  135. package/dist/mcp-server/stdio.js.map +0 -1
  136. package/dist/mcp.d.ts +0 -2
  137. package/dist/mcp.js +0 -19
  138. package/dist/mcp.js.map +0 -1
  139. package/dist/open-storage-driver.d.ts +0 -53
  140. package/dist/open-storage-driver.js +0 -71
  141. package/dist/open-storage-driver.js.map +0 -1
  142. package/dist/open-synchronize-stores.d.ts +0 -24
  143. package/dist/open-synchronize-stores.js +0 -34
  144. package/dist/open-synchronize-stores.js.map +0 -1
  145. package/dist/project-identity.d.ts +0 -23
  146. package/dist/project-identity.js +0 -121
  147. package/dist/project-identity.js.map +0 -1
  148. package/dist/runtime-access-boundary.d.ts +0 -7
  149. package/dist/runtime-access-boundary.js +0 -182
  150. package/dist/runtime-access-boundary.js.map +0 -1
  151. package/dist/service-discovery.d.ts +0 -10
  152. package/dist/service-discovery.js +0 -64
  153. package/dist/service-discovery.js.map +0 -1
  154. package/dist/site/assets.d.ts +0 -4
  155. package/dist/site/assets.js +0 -46
  156. package/dist/site/assets.js.map +0 -1
  157. package/dist/site/cloud-events-relay.d.ts +0 -18
  158. package/dist/site/cloud-events-relay.js +0 -78
  159. package/dist/site/cloud-events-relay.js.map +0 -1
  160. package/dist/site/index.d.ts +0 -1
  161. package/dist/site/index.js +0 -2
  162. package/dist/site/index.js.map +0 -1
  163. package/dist/site/server.d.ts +0 -42
  164. package/dist/site/server.js +0 -320
  165. package/dist/site/server.js.map +0 -1
  166. package/dist/skill-installer.d.ts +0 -35
  167. package/dist/skill-installer.js +0 -174
  168. package/dist/skill-installer.js.map +0 -1
  169. package/dist/vitest-setup.d.ts +0 -1
  170. package/dist/vitest-setup.js +0 -7
  171. package/dist/vitest-setup.js.map +0 -1
  172. package/site/dist/assets/index-DSR4mIml.js +0 -4396
@@ -1,131 +0,0 @@
1
- export function toContextSearchTermsOnly(result) {
2
- return {
3
- query: result.query,
4
- view: result.view,
5
- conflictsOnly: result.conflictsOnly,
6
- duplicateTerms: result.duplicateTerms,
7
- terms: result.terms
8
- };
9
- }
10
- export function renderContextDetails(details) {
11
- const lines = [
12
- `${details.context.title} (${details.context.key})`,
13
- `Scope: ${details.context.scopeKind} ${details.context.scopeEntityId ?? "default"} ${details.context.scopeLabel}`,
14
- `Stored in database: ${details.context.exists ? "yes" : "not yet initialized"}`,
15
- `Summary: ${details.context.summary}`,
16
- `Updated: ${details.context.updatedAt ?? "never"}`,
17
- "Terms:"
18
- ];
19
- if (details.terms.length === 0) {
20
- lines.push("none");
21
- return lines.join("\n");
22
- }
23
- for (const term of details.terms) {
24
- lines.push(`- ${term.term}: ${term.definition}`);
25
- if (term.avoid.length > 0) {
26
- lines.push(` Avoid: ${term.avoid.join(", ")}`);
27
- }
28
- }
29
- return lines.join("\n");
30
- }
31
- export function renderContextDirectory(directory) {
32
- const sharedTitle = directory.shared?.context.title ?? "Project Context";
33
- const sharedKey = directory.shared?.context.key ?? "default";
34
- const lines = [
35
- `${sharedTitle} (${sharedKey})`,
36
- "Scope: project directory",
37
- `View: ${directory.view}`,
38
- `Query: ${directory.query.length > 0 ? directory.query : "none"}`,
39
- `Conflicts only: ${directory.conflictsOnly ? "yes" : "no"}`,
40
- `Shared context stored in database: ${directory.shared?.context.exists ? "yes" : "not matched or not initialized"}`,
41
- `Shared summary: ${directory.shared?.context.summary && directory.shared.context.summary.length > 0 ? directory.shared.context.summary : "none"}`,
42
- `Shared terms: ${directory.shared?.terms.length ?? 0}`,
43
- `Initiative contexts: ${directory.initiatives.length}`,
44
- `Discovered terms: ${directory.terms.length}`,
45
- `Duplicate labels across scopes: ${directory.duplicateTerms.length}`
46
- ];
47
- if (directory.view !== "global") {
48
- lines.push("", "Initiative contexts:");
49
- }
50
- if (directory.view !== "global" && directory.initiatives.length === 0) {
51
- lines.push("none");
52
- }
53
- else if (directory.view !== "global") {
54
- for (const details of directory.initiatives) {
55
- lines.push(`- ${details.context.scopeLabel} (${details.context.key}) ${details.context.exists ? "stored" : "implicit"} terms=${details.terms.length}`);
56
- if (details.context.summary.length > 0) {
57
- lines.push(` ${details.context.summary}`);
58
- }
59
- }
60
- }
61
- lines.push("", "Discovered terms:");
62
- if (directory.terms.length === 0) {
63
- lines.push("none");
64
- return lines.join("\n");
65
- }
66
- for (const entry of directory.terms) {
67
- lines.push(...renderContextTermEntry(entry));
68
- }
69
- return lines.join("\n");
70
- }
71
- export function renderContextSearchTermsOnly(result) {
72
- const lines = [
73
- "Matching context terms",
74
- `View: ${result.view}`,
75
- `Query: ${result.query.length > 0 ? result.query : "none"}`,
76
- `Conflicts only: ${result.conflictsOnly ? "yes" : "no"}`,
77
- `Matches: ${result.terms.length}`,
78
- `Duplicate labels across scopes: ${result.duplicateTerms.length}`,
79
- "",
80
- "Terms:"
81
- ];
82
- if (result.terms.length === 0) {
83
- lines.push("none");
84
- return lines.join("\n");
85
- }
86
- for (const entry of result.terms) {
87
- lines.push(...renderContextTermEntry(entry));
88
- }
89
- return lines.join("\n");
90
- }
91
- export function renderContextOutput(details) {
92
- return "shared" in details ? renderContextDirectory(details) : renderContextDetails(details);
93
- }
94
- export function renderContextList(result) {
95
- if (result.contexts.length === 0) {
96
- return "No contexts found.";
97
- }
98
- return result.contexts
99
- .map((item) => `${item.context.key} ${item.context.scopeKind} ${item.context.scopeEntityId ?? "default"} ${item.context.exists ? "stored" : "implicit"} terms=${item.termCount} ${item.context.scopeLabel}\n ${item.context.summary}`)
100
- .join("\n");
101
- }
102
- export function renderContextTermResult(result) {
103
- return [
104
- `${result.created ? "Defined" : "Updated"} ${result.term.term} in ${result.context.title} (${result.context.key})`,
105
- result.term.definition,
106
- result.term.avoid.length > 0 ? `Avoid: ${result.term.avoid.join(", ")}` : "Avoid: none"
107
- ].join("\n");
108
- }
109
- export function renderContextForgetResult(result) {
110
- return result.removed
111
- ? `Removed ${result.term} from ${result.context.title} (${result.context.key})`
112
- : `Context term not found: ${result.term}`;
113
- }
114
- function renderContextTermEntry(entry) {
115
- const warnings = [];
116
- if (entry.hasDuplicates) {
117
- warnings.push(`defined in ${entry.sources.length} scopes`);
118
- }
119
- if (entry.hasConflictingDefinitions) {
120
- warnings.push("conflicting definitions");
121
- }
122
- const lines = [`- ${entry.term}${warnings.length > 0 ? ` [${warnings.join("; ")}]` : ""}`];
123
- for (const source of entry.sources) {
124
- lines.push(` - ${source.scopeLabel}: ${source.definition}`);
125
- if (source.avoid.length > 0) {
126
- lines.push(` Avoid: ${source.avoid.join(", ")}`);
127
- }
128
- }
129
- return lines;
130
- }
131
- //# sourceMappingURL=context-cli.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"context-cli.js","sourceRoot":"","sources":["../src/context-cli.ts"],"names":[],"mappings":"AAiBA,MAAM,UAAU,wBAAwB,CAAC,MAAmC;IAC3E,OAAO;QACN,KAAK,EAAE,MAAM,CAAC,KAAK;QACnB,IAAI,EAAE,MAAM,CAAC,IAAI;QACjB,aAAa,EAAE,MAAM,CAAC,aAAa;QACnC,cAAc,EAAE,MAAM,CAAC,cAAc;QACrC,KAAK,EAAE,MAAM,CAAC,KAAK;KACnB,CAAC;AACH,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,OAAuB;IAC3D,MAAM,KAAK,GAAG;QACb,GAAG,OAAO,CAAC,OAAO,CAAC,KAAK,KAAK,OAAO,CAAC,OAAO,CAAC,GA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,CAAC,CAAC,CAAC,KAAK,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;IAC3F,KAAK,MAAM,MAAM,IAAI,KAAK,CAAC,OAAO,EAAE,CAAC;QACpC,KAAK,CAAC,IAAI,CAAC,OAAO,MAAM,CAAC,UAAU,KAAK,MAAM,CAAC,UAAU,EAAE,CAAC,CAAC;QAC7D,IAAI,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;YAC7B,KAAK,CAAC,IAAI,CAAC,cAAc,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACrD,CAAC;IACF,CAAC;IAED,OAAO,KAAK,CAAC;AACd,CAAC"}
@@ -1 +0,0 @@
1
- export * from "@agent-issues/api-local";
@@ -1,2 +0,0 @@
1
- export * from "@agent-issues/api-local";
2
- //# sourceMappingURL=daemon-lifecycle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"daemon-lifecycle.js","sourceRoot":"","sources":["../../src/daemon/daemon-lifecycle.ts"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC"}
@@ -1,14 +0,0 @@
1
- /**
2
- * The real entrypoint a self-respawned daemon process runs (ISS190,
3
- * ADR44): `spawnLocalDaemon` (`local-daemon-store.ts`) re-invokes this same
4
- * installed CLI with a hidden flag, and `cli.ts` recognizes that flag and
5
- * calls this instead of dispatching a normal command. `createLocalDaemonServer`
6
- * itself lives in `@agent-issues/api-local` - the daemon server implementation,
7
- * not the CLI's own concern. No `authProvider` override, so the daemon mints
8
- * and persists its own token (ISS184); no explicit `buildHash`, so it reads
9
- * its own `dist/build-info.json` (ISS188). The process stays alive because
10
- * the daemon's own listening HTTP server keeps the event loop open - it only
11
- * exits via the daemon's own idle-timeout or version/db-path-mismatch
12
- * drain-then-exit.
13
- */
14
- export declare function runDaemonProcess(): void;
@@ -1,30 +0,0 @@
1
- import { createLocalDaemonServer } from "@agent-issues/api-local";
2
- /**
3
- * Parses an optional `--db <path>` out of argv (appended by `spawnLocalDaemon`
4
- * when a client requested a different db than the currently-running daemon
5
- * serves, ISS190) so a respawned daemon opens the newly-requested db from its
6
- * very first request instead of the default.
7
- */
8
- function parseDbPathArg(argv) {
9
- const flagIndex = argv.indexOf("--db");
10
- if (flagIndex === -1)
11
- return undefined;
12
- return argv[flagIndex + 1];
13
- }
14
- /**
15
- * The real entrypoint a self-respawned daemon process runs (ISS190,
16
- * ADR44): `spawnLocalDaemon` (`local-daemon-store.ts`) re-invokes this same
17
- * installed CLI with a hidden flag, and `cli.ts` recognizes that flag and
18
- * calls this instead of dispatching a normal command. `createLocalDaemonServer`
19
- * itself lives in `@agent-issues/api-local` - the daemon server implementation,
20
- * not the CLI's own concern. No `authProvider` override, so the daemon mints
21
- * and persists its own token (ISS184); no explicit `buildHash`, so it reads
22
- * its own `dist/build-info.json` (ISS188). The process stays alive because
23
- * the daemon's own listening HTTP server keeps the event loop open - it only
24
- * exits via the daemon's own idle-timeout or version/db-path-mismatch
25
- * drain-then-exit.
26
- */
27
- export function runDaemonProcess() {
28
- createLocalDaemonServer({ dbPath: parseDbPathArg(process.argv) });
29
- }
30
- //# sourceMappingURL=daemon-main.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"daemon-main.js","sourceRoot":"","sources":["../../src/daemon/daemon-main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,yBAAyB,CAAC;AAElE;;;;;GAKG;AACH,SAAS,cAAc,CAAC,IAAc;IACrC,MAAM,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;IACvC,IAAI,SAAS,KAAK,CAAC,CAAC;QAAE,OAAO,SAAS,CAAC;IACvC,OAAO,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC,CAAC;AAC5B,CAAC;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,gBAAgB;IAC/B,uBAAuB,CAAC,EAAE,MAAM,EAAE,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACnE,CAAC"}
@@ -1,21 +0,0 @@
1
- /**
2
- * Hidden argv flag a self-respawned daemon process recognizes (ISS190): the
3
- * runs the daemon instead of a normal command. Exported so core and the CLI
4
- * entrypoint agree on the exact same literal without either hardcoding it
5
- * independently.
6
- */
7
- export declare const LOCAL_DAEMON_SPAWN_FLAG = "--agent-issues-run-daemon";
8
- /**
9
- * Default `spawn` for the local daemon (ISS190, ADR44): re-invokes this
10
- * exact running script (`process.argv[1]`) as a detached, unref'd child
11
- * with the hidden daemon flag appended. Core has no knowledge of which
12
- * package's entrypoint is actually running - it doesn't need to, since
13
- * "this same install, running itself again in daemon mode" always resolves
14
- * correctly regardless of which CLI/site-server process happened to invoke
15
- * it. When `dbPath` is supplied (a client requesting a different `--db`
16
- * than the currently-running daemon serves), it's appended so the freshly
17
- * spawned daemon opens that db instead of the default.
18
- */
19
- export declare function spawnLocalDaemon(options?: {
20
- dbPath?: string;
21
- }): void;
@@ -1,31 +0,0 @@
1
- import { spawn as spawnChildProcess } from "node:child_process";
2
- /**
3
- * Hidden argv flag a self-respawned daemon process recognizes (ISS190): the
4
- * runs the daemon instead of a normal command. Exported so core and the CLI
5
- * entrypoint agree on the exact same literal without either hardcoding it
6
- * independently.
7
- */
8
- export const LOCAL_DAEMON_SPAWN_FLAG = "--agent-issues-run-daemon";
9
- /**
10
- * Default `spawn` for the local daemon (ISS190, ADR44): re-invokes this
11
- * exact running script (`process.argv[1]`) as a detached, unref'd child
12
- * with the hidden daemon flag appended. Core has no knowledge of which
13
- * package's entrypoint is actually running - it doesn't need to, since
14
- * "this same install, running itself again in daemon mode" always resolves
15
- * correctly regardless of which CLI/site-server process happened to invoke
16
- * it. When `dbPath` is supplied (a client requesting a different `--db`
17
- * than the currently-running daemon serves), it's appended so the freshly
18
- * spawned daemon opens that db instead of the default.
19
- */
20
- export function spawnLocalDaemon(options) {
21
- const entrypoint = process.argv[1];
22
- if (!entrypoint) {
23
- throw new Error("Cannot spawn the local daemon: no process entrypoint (process.argv[1]) is available.");
24
- }
25
- const args = [entrypoint, LOCAL_DAEMON_SPAWN_FLAG];
26
- if (options?.dbPath !== undefined) {
27
- args.push("--db", options.dbPath);
28
- }
29
- spawnChildProcess(process.execPath, args, { detached: true, stdio: "ignore" }).unref();
30
- }
31
- //# sourceMappingURL=local-daemon-store.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"local-daemon-store.js","sourceRoot":"","sources":["../../src/daemon/local-daemon-store.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAEhE;;;;;GAKG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAAG,2BAA2B,CAAC;AAEnE;;;;;;;;;;GAUG;AACH,MAAM,UAAU,gBAAgB,CAAC,OAA6B;IAC7D,MAAM,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACnC,IAAI,CAAC,UAAU,EAAE,CAAC;QACjB,MAAM,IAAI,KAAK,CAAC,sFAAsF,CAAC,CAAC;IACzG,CAAC;IAED,MAAM,IAAI,GAAG,CAAC,UAAU,EAAE,uBAAuB,CAAC,CAAC;IACnD,IAAI,OAAO,EAAE,MAAM,KAAK,SAAS,EAAE,CAAC;QACnC,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,OAAO,CAAC,MAAM,CAAC,CAAC;IACnC,CAAC;IAED,iBAAiB,CAAC,OAAO,CAAC,QAAQ,EAAE,IAAI,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC;AACxF,CAAC"}
@@ -1,141 +0,0 @@
1
- import type { DeleteResult, EntityDetails, EntityKind, EntityRecord, EntityRelations, EntitySummary, LinkResult, MaterializedContextRevision, MaterializedContextTermRevision, MaterializedEntityRevision, MoveResult, QueryEntityParentGroup, RelationType, StatusUpdateResult, ContextWriteResult, DefineContextTermAcknowledgement, ForgetContextTermResult, UnlinkResult } from "@agent-issues/core";
2
- export type CompactEntity = {
3
- id: string;
4
- reference: string;
5
- kind: EntityKind;
6
- status: string;
7
- title: string;
8
- };
9
- export type CompactRelation = {
10
- type: RelationType;
11
- entity: CompactEntity;
12
- };
13
- export type CompactEntityDetails = {
14
- entity: CompactEntity;
15
- incoming: CompactRelation[];
16
- outgoing: CompactRelation[];
17
- planEntries: EntityDetails["planEntries"];
18
- };
19
- export type CompactEntityList = {
20
- items: CompactEntity[];
21
- total: number;
22
- parentGroups?: Array<{
23
- parent: CompactEntity;
24
- items: CompactEntity[];
25
- }>;
26
- /** Only present for issue lists; see `QueryEntitiesResult.openBlockers`. */
27
- openBlockers?: Record<string, string[]>;
28
- };
29
- export type CompactNextWorkItem = {
30
- issue: CompactEntity;
31
- blockers: string[];
32
- unblocks: string[];
33
- };
34
- export type CompactNextWork = {
35
- initiative: CompactEntity;
36
- available: CompactNextWorkItem[];
37
- blocked: CompactNextWorkItem[];
38
- };
39
- export type CompactCreateAcknowledgement = {
40
- operation: "create";
41
- id: string;
42
- reference: string;
43
- status: string;
44
- revision: number;
45
- };
46
- export type CompactEditAcknowledgement = {
47
- operation: "edit";
48
- reference: string;
49
- revision: number;
50
- };
51
- export declare function toCompactEntity(entity: EntitySummary): CompactEntity;
52
- export declare function toCompactCreateAcknowledgement(entity: EntitySummary): CompactCreateAcknowledgement;
53
- export declare function toCompactEditAcknowledgement(entity: EntityRecord): CompactEditAcknowledgement;
54
- export declare function toCompactStatusAcknowledgement(operation: "archive" | "status", result: StatusUpdateResult): {
55
- operation: "archive" | "status";
56
- reference: string;
57
- previousStatus: string;
58
- status: string;
59
- revision: number;
60
- };
61
- export declare function toCompactDeleteAcknowledgement(result: DeleteResult): {
62
- operation: "delete";
63
- reference: string;
64
- removed: boolean;
65
- };
66
- export declare function toCompactMoveAcknowledgement(result: MoveResult): {
67
- operation: "move";
68
- reference: string;
69
- previousParentId: string | null;
70
- newParentId: string;
71
- type: "blocks" | "constrains" | "contains" | "creates" | "decomposes" | "fixes" | "handsOff" | "informs" | "owns" | "records" | "relatesTo" | "resolves" | "supersedes" | "taggedWith" | "tracks";
72
- revision: number;
73
- };
74
- export declare function toCompactLinkAcknowledgement(operation: "link" | "unlink", result: LinkResult | UnlinkResult): {
75
- operation: "link" | "unlink";
76
- fromId: string;
77
- toId: string;
78
- type: "blocks" | "constrains" | "contains" | "creates" | "decomposes" | "fixes" | "handsOff" | "informs" | "owns" | "records" | "relatesTo" | "resolves" | "supersedes" | "taggedWith" | "tracks";
79
- created: boolean;
80
- } | {
81
- operation: "link" | "unlink";
82
- fromId: string;
83
- toId: string;
84
- type: "blocks" | "constrains" | "contains" | "creates" | "decomposes" | "fixes" | "handsOff" | "informs" | "owns" | "records" | "relatesTo" | "resolves" | "supersedes" | "taggedWith" | "tracks";
85
- removed: boolean;
86
- };
87
- export declare function toCompactEntityRestoreAcknowledgement(result: MaterializedEntityRevision): {
88
- operation: "restore";
89
- id: string;
90
- revision: number;
91
- restoredFromRevision: number | null;
92
- };
93
- export declare function toCompactContextSetAcknowledgement(result: ContextWriteResult): {
94
- operation: "context-set";
95
- reference: string;
96
- revision: number;
97
- };
98
- export declare function toCompactContextDefineAcknowledgement(result: DefineContextTermAcknowledgement): {
99
- operation: "context-define";
100
- reference: string;
101
- contextReference: string;
102
- term: string;
103
- created: boolean;
104
- revision: number;
105
- };
106
- export declare function toCompactContextForgetAcknowledgement(result: ForgetContextTermResult): {
107
- operation: "context-forget";
108
- reference: string;
109
- term: string;
110
- removed: boolean;
111
- revision?: number | undefined;
112
- };
113
- export declare function toCompactContextRestoreAcknowledgement(result: MaterializedContextRevision): {
114
- operation: "context-restore";
115
- contextKey: string;
116
- revision: number;
117
- restoredFromRevision: number | null;
118
- };
119
- export declare function toCompactContextTermRestoreAcknowledgement(result: MaterializedContextTermRevision): {
120
- operation: "context-term-restore";
121
- id: string;
122
- contextKey: string;
123
- term: string;
124
- revision: number;
125
- restoredFromRevision: number | null;
126
- };
127
- export declare function toCompactEntityDetails(details: EntityDetails | EntityRelations): CompactEntityDetails;
128
- export declare function toCompactEntityList(entities: EntitySummary[], total?: number, openBlockers?: Record<string, string[]>, parentGroups?: QueryEntityParentGroup[]): CompactEntityList;
129
- export declare function toCompactNextWork(result: {
130
- initiative: EntityRecord;
131
- available: Array<{
132
- issue: EntityRecord;
133
- blockers: string[];
134
- unblocks: string[];
135
- }>;
136
- blocked: Array<{
137
- issue: EntityRecord;
138
- blockers: string[];
139
- unblocks: string[];
140
- }>;
141
- }): CompactNextWork;
@@ -1,147 +0,0 @@
1
- export function toCompactEntity(entity) {
2
- return {
3
- id: entity.id,
4
- reference: entity.reference,
5
- kind: entity.kind,
6
- status: entity.status,
7
- title: entity.title
8
- };
9
- }
10
- export function toCompactCreateAcknowledgement(entity) {
11
- return {
12
- operation: "create",
13
- id: entity.id,
14
- reference: entity.reference,
15
- status: entity.status,
16
- revision: entity.revision
17
- };
18
- }
19
- export function toCompactEditAcknowledgement(entity) {
20
- return {
21
- operation: "edit",
22
- reference: entity.reference,
23
- revision: entity.revision
24
- };
25
- }
26
- export function toCompactStatusAcknowledgement(operation, result) {
27
- return {
28
- operation,
29
- reference: result.entity.reference,
30
- previousStatus: result.previousStatus,
31
- status: result.entity.status,
32
- revision: result.entity.revision
33
- };
34
- }
35
- export function toCompactDeleteAcknowledgement(result) {
36
- return {
37
- operation: "delete",
38
- reference: result.entity.reference,
39
- removed: result.removed
40
- };
41
- }
42
- export function toCompactMoveAcknowledgement(result) {
43
- return {
44
- operation: "move",
45
- reference: result.entity.reference,
46
- previousParentId: result.previousParentId,
47
- newParentId: result.newParentId,
48
- type: result.relationType,
49
- revision: result.entity.revision
50
- };
51
- }
52
- export function toCompactLinkAcknowledgement(operation, result) {
53
- return {
54
- operation,
55
- fromId: result.relation.fromId,
56
- toId: result.relation.toId,
57
- type: result.relation.type,
58
- ...(operation === "link" ? { created: result.created } : { removed: result.removed })
59
- };
60
- }
61
- export function toCompactEntityRestoreAcknowledgement(result) {
62
- return {
63
- operation: "restore",
64
- id: result.entityId,
65
- revision: result.headRevision,
66
- restoredFromRevision: result.restoredFromRevision
67
- };
68
- }
69
- export function toCompactContextSetAcknowledgement(result) {
70
- return {
71
- operation: "context-set",
72
- reference: result.context.reference ?? result.context.key,
73
- revision: result.context.revision
74
- };
75
- }
76
- export function toCompactContextDefineAcknowledgement(result) {
77
- return {
78
- operation: "context-define",
79
- reference: result.term.reference,
80
- contextReference: result.context.reference ?? result.context.key,
81
- term: result.term.term,
82
- created: result.created,
83
- revision: result.term.revision
84
- };
85
- }
86
- export function toCompactContextForgetAcknowledgement(result) {
87
- return {
88
- operation: "context-forget",
89
- reference: result.context.reference ?? result.context.key,
90
- term: result.term,
91
- removed: result.removed,
92
- ...(result.currentRevision === undefined ? {} : { revision: result.currentRevision })
93
- };
94
- }
95
- export function toCompactContextRestoreAcknowledgement(result) {
96
- return {
97
- operation: "context-restore",
98
- contextKey: result.contextKey,
99
- revision: result.headRevision,
100
- restoredFromRevision: result.restoredFromRevision
101
- };
102
- }
103
- export function toCompactContextTermRestoreAcknowledgement(result) {
104
- return {
105
- operation: "context-term-restore",
106
- id: result.id,
107
- contextKey: result.contextKey,
108
- term: result.term,
109
- revision: result.headRevision,
110
- restoredFromRevision: result.restoredFromRevision
111
- };
112
- }
113
- export function toCompactEntityDetails(details) {
114
- return {
115
- entity: toCompactEntity(details.entity),
116
- incoming: details.incoming.map(({ relationType, entity }) => ({
117
- type: relationType,
118
- entity: toCompactEntity(entity)
119
- })),
120
- outgoing: details.outgoing.map(({ relationType, entity }) => ({
121
- type: relationType,
122
- entity: toCompactEntity(entity)
123
- })),
124
- planEntries: details.planEntries ?? []
125
- };
126
- }
127
- export function toCompactEntityList(entities, total = entities.length, openBlockers, parentGroups) {
128
- return {
129
- items: entities.map(toCompactEntity),
130
- total,
131
- ...(parentGroups ? { parentGroups: parentGroups.map((group) => ({ parent: toCompactEntity(group.parent), items: group.entities.map(toCompactEntity) })) } : {}),
132
- ...(openBlockers ? { openBlockers } : {})
133
- };
134
- }
135
- export function toCompactNextWork(result) {
136
- const toCompactNextWorkItem = (item) => ({
137
- issue: toCompactEntity(item.issue),
138
- blockers: item.blockers,
139
- unblocks: item.unblocks
140
- });
141
- return {
142
- initiative: toCompactEntity(result.initiative),
143
- available: result.available.map(toCompactNextWorkItem),
144
- blocked: result.blocked.map(toCompactNextWorkItem)
145
- };
146
- }
147
- //# sourceMappingURL=entity-projection.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"entity-projection.js","sourceRoot":"","sources":["../src/entity-projection.ts"],"names":[],"mappings":"AA6EA,MAAM,UAAU,eAAe,CAAC,MAAqB;IACpD,OAAO;QACN,EAAE,EAAE,MAAM,CAAC,EAAE;QACb,SAAS,EAAE,MAAM,CAAC,SAAS;QAC3B,IAAI,EAAE,MAAM,CAAC,IAAI;QACjB,MAAM,EAAE,MAAM,CAAC,MAAM;QACrB,KAAK,EAAE,MAAM,CAAC,KAAK;KACnB,CAAC;AACH,CAAC;AAED,MAAM,UAAU,8BAA8B,CAAC,MAAqB;IACnE,OAAO;QACN,SAAS,EAAE,QAAQ;QACnB,EAAE,EAAE,MAAM,CAAC,EAAE;QACb,SAAS,EAAE,MAAM,CAAC,SAAS;QAC3B,MAAM,EAAE,MAAM,CAAC,MAAM;QACrB,QAAQ,EAAE,MAAM,CAAC,QAAQ;KACzB,CAAC;AACH,CAAC;AAED,MAAM,UAAU,4BAA4B,CAAC,MAAoB;IAChE,OAAO;QACN,SAAS,EAAE,MAAM;QACjB,SAAS,EAAE,MAAM,CAAC,SAAS;QAC3B,QAAQ,EAAE,MAAM,CAAC,QAAQ;KACzB,CAAC;AACH,CAAC;AAED,MAAM,UAAU,8BAA8B,CAAC,SAA+B,EAAE,MAA0B;IACzG,OAAO;QACN,SAAS;QACT,SAAS,EAAE,MAAM,CAAC,MAAM,CAAC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CAAC,KAAK,CAAC,MAAM,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,eAAe,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC/J,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC,EAAE,YAAY,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KACzC,CAAC;AACH,CAAC;AAED,MAAM,UAAU,iBAAiB,CAAC,MAIjC;IACA,MAAM,qBAAqB,GAAG,CAAC,IAAqE,EAAuB,EAAE,CAAC,CAAC;QAC9H,KAAK,EAAE,eAAe,CAAC,IAAI,CAAC,KAAK,CAAC;QAClC,QAAQ,EAAE,IAAI,CAAC,QAAQ;QACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ;KACvB,CAAC,CAAC;IAEH,OAAO;QACN,UAAU,EAAE,eAAe,CAAC,MAAM,CAAC,UAAU,CAAC;QAC9C,SAAS,EAAE,MAAM,CAAC,SAAS,CAAC,GAAG,CAAC,qBAAqB,CAAC;QACtD,OAAO,EAAE,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,qBAAqB,CAAC;KAClD,CAAC;AACH,CAAC"}
@@ -1,12 +0,0 @@
1
- import type { DeviceCodeLoginFn } from "./cli/commands/auth.js";
2
- /**
3
- * Real Entra ID device-code login (ADR12's client-side leg). This is the
4
- * genuine HITL boundary for ISS32: it requires a human to open the printed
5
- * verification URL in a browser and enter the device code against a real
6
- * Azure app registration. Not unit-tested for that reason - see
7
- * docs/auth-entra-id-setup.md for how to obtain the tenant/client IDs this
8
- * needs, and `agent-issues auth login --help` for usage. Remote-login tests
9
- * cover everything downstream of this exchange with a fake implementation
10
- * of `DeviceCodeLoginFn`.
11
- */
12
- export declare const acquireEntraDeviceCodeSession: DeviceCodeLoginFn;
@@ -1,40 +0,0 @@
1
- import { PublicClientApplication } from "@azure/msal-node";
2
- /**
3
- * Real Entra ID device-code login (ADR12's client-side leg). This is the
4
- * genuine HITL boundary for ISS32: it requires a human to open the printed
5
- * verification URL in a browser and enter the device code against a real
6
- * Azure app registration. Not unit-tested for that reason - see
7
- * docs/auth-entra-id-setup.md for how to obtain the tenant/client IDs this
8
- * needs, and `agent-issues auth login --help` for usage. Remote-login tests
9
- * cover everything downstream of this exchange with a fake implementation
10
- * of `DeviceCodeLoginFn`.
11
- */
12
- export const acquireEntraDeviceCodeSession = async ({ tenantId, clientId, onDeviceCode }) => {
13
- const app = new PublicClientApplication({
14
- auth: {
15
- clientId,
16
- authority: `https://login.microsoftonline.com/${tenantId}`
17
- }
18
- });
19
- const result = await app.acquireTokenByDeviceCode({
20
- scopes: ["User.Read"],
21
- deviceCodeCallback: (response) => {
22
- onDeviceCode(response.message);
23
- }
24
- });
25
- if (!result) {
26
- throw new Error("Entra ID device-code login did not return a token.");
27
- }
28
- const claims = result.idTokenClaims;
29
- const userId = claims.oid ?? result.uniqueId;
30
- const resolvedTenantId = claims.tid ?? result.tenantId ?? tenantId;
31
- const expiresAt = (result.expiresOn ?? new Date(Date.now() + 60 * 60 * 1000)).toISOString();
32
- return {
33
- tenantId: resolvedTenantId,
34
- userId,
35
- displayName: result.account?.name ?? claims.name,
36
- accessToken: result.accessToken,
37
- expiresAt
38
- };
39
- };
40
- //# sourceMappingURL=entra-device-login.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"entra-device-login.js","sourceRoot":"","sources":["../src/entra-device-login.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,kBAAkB,CAAC;AAI3D;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,6BAA6B,GAAsB,KAAK,EAAE,EAAE,QAAQ,EAAE,QAAQ,EAAE,YAAY,EAAE,EAAE,EAAE;IAC9G,MAAM,GAAG,GAAG,IAAI,uBAAuB,CAAC;QACvC,IAAI,EAAE;YACL,QAAQ;YACR,SAAS,EAAE,qCAAqC,QAAQ,EAAE;SAC1D;KACD,CAAC,CAAC;IAEH,MAAM,MAAM,GAAG,MAAM,GAAG,CAAC,wBAAwB,CAAC;QACjD,MAAM,EAAE,CAAC,WAAW,CAAC;QACrB,kBAAkB,EAAE,CAAC,QAAQ,EAAE,EAAE;YAChC,YAAY,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;QAChC,CAAC;KACD,CAAC,CAAC;IAEH,IAAI,CAAC,MAAM,EAAE,CAAC;QACb,MAAM,IAAI,KAAK,CAAC,oDAAoD,CAAC,CAAC;IACvE,CAAC;IAED,MAAM,MAAM,GAAG,MAAM,CAAC,aAA8D,CAAC;IACrF,MAAM,MAAM,GAAG,MAAM,CAAC,GAAG,IAAI,MAAM,CAAC,QAAQ,CAAC;IAC7C,MAAM,gBAAgB,GAAG,MAAM,CAAC,GAAG,IAAI,MAAM,CAAC,QAAQ,IAAI,QAAQ,CAAC;IACnE,MAAM,SAAS,GAAG,CAAC,MAAM,CAAC,SAAS,IAAI,IAAI,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC;IAE5F,OAAO;QACN,QAAQ,EAAE,gBAAgB;QAC1B,MAAM;QACN,WAAW,EAAE,MAAM,CAAC,OAAO,EAAE,IAAI,IAAI,MAAM,CAAC,IAAI;QAChD,WAAW,EAAE,MAAM,CAAC,WAAW;QAC/B,SAAS;KACT,CAAC;AACH,CAAC,CAAC"}
@@ -1,24 +0,0 @@
1
- import type { ContextDetails, DatabaseSnapshot, InitiativeBundle } from "@agent-issues/api-local";
2
- import type { IssueCommentRecord, PlanEntryRecord, RelationRecord, UserDirectoryRecord } from "@agent-issues/core";
3
- export type DirectoryExportResult = {
4
- mode: "directory";
5
- scope: "initiative" | "project";
6
- outputPath: string;
7
- files: string[];
8
- };
9
- export declare function writeInitiativeDirectoryExport(input: {
10
- bundle: InitiativeBundle;
11
- commentsByIssueId?: Record<string, IssueCommentRecord[]>;
12
- context: ContextDetails;
13
- outputPath: string;
14
- planEntries?: PlanEntryRecord[];
15
- relations: RelationRecord[];
16
- users?: UserDirectoryRecord[];
17
- force?: boolean;
18
- }): DirectoryExportResult;
19
- export declare function writeProjectDirectoryExport(input: {
20
- commentsByIssueId?: Record<string, IssueCommentRecord[]>;
21
- snapshot: DatabaseSnapshot;
22
- outputPath: string;
23
- force?: boolean;
24
- }): DirectoryExportResult;