@a-company/paradigm 3.46.0 → 5.4.0

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 (169) hide show
  1. package/dist/{accept-orchestration-ZUWQUHSK.js → accept-orchestration-GX2YRWM4.js} +5 -5
  2. package/dist/{add-VSPZ6FM4.js → add-FZRKEGH4.js} +1 -1
  3. package/dist/agent-WERIO2XV.js +523 -0
  4. package/dist/agent-loader-SJPJJS33.js +36 -0
  5. package/dist/{agents-suggest-65SER5IS.js → agents-suggest-DNSYJ6IA.js} +1 -1
  6. package/dist/{aggregate-SV3VGEIL.js → aggregate-H57K7PNV.js} +1 -1
  7. package/dist/{assess-UHBDYIK7.js → assess-4WVXZLZQ.js} +2 -2
  8. package/dist/{auto-24ICVUH4.js → auto-QFS5NHQU.js} +1 -1
  9. package/dist/{beacon-3SJV4DAP.js → beacon-KXZXYQHX.js} +1 -1
  10. package/dist/{calibration-WWHK73WU.js → calibration-V46G7JTY.js} +2 -2
  11. package/dist/{check-OLI6AUS6.js → check-OWAIWV23.js} +1 -1
  12. package/dist/{chunk-RP6TZYGE.js → chunk-2IO7JAG2.js} +1 -1
  13. package/dist/chunk-2T6BTYBN.js +712 -0
  14. package/dist/{chunk-CDMAMDSG.js → chunk-5VKJBNJL.js} +13 -5
  15. package/dist/{chunk-KB4XJWE3.js → chunk-6N3JTACN.js} +98 -437
  16. package/dist/{chunk-ZMQA6SCO.js → chunk-7HRBT23N.js} +631 -231
  17. package/dist/chunk-7N7GSU6K.js +34 -0
  18. package/dist/chunk-A2L4TSLZ.js +526 -0
  19. package/dist/{chunk-P7XSBJE3.js → chunk-ABVQGRF7.js} +1 -1
  20. package/dist/{chunk-HIKKOCXY.js → chunk-EI32ZBE6.js} +1 -1
  21. package/dist/{chunk-QIOCFXDQ.js → chunk-EKGMAM62.js} +1 -1
  22. package/dist/chunk-EZ3GOCYC.js +132 -0
  23. package/dist/{chunk-DS5QY37M.js → chunk-GTR2TBIJ.js} +247 -15
  24. package/dist/chunk-ICSLIPUS.js +1128 -0
  25. package/dist/{chunk-QDXI2DHR.js → chunk-J2JEQRT3.js} +1 -1
  26. package/dist/{chunk-AKIMFN6I.js → chunk-JASGXLK3.js} +2 -2
  27. package/dist/{chunk-J4E6K5MG.js → chunk-LSRABQIY.js} +25 -1
  28. package/dist/chunk-MCMOGQMU.js +145 -0
  29. package/dist/{chunk-ZXMDA7VB.js → chunk-PDX44BCA.js} +1 -6
  30. package/dist/{chunk-2SKXFXIT.js → chunk-S3ORKP3V.js} +10 -15
  31. package/dist/chunk-TAIJOFOE.js +124 -0
  32. package/dist/{chunk-FS3WTUHY.js → chunk-TXESEO7Y.js} +6 -6
  33. package/dist/{chunk-7COU5S2Z.js → chunk-VL67H5IC.js} +1 -1
  34. package/dist/{chunk-QWA26UNO.js → chunk-WQITYKHM.js} +7 -7
  35. package/dist/{chunk-MW5DMGBB.js → chunk-YMDLDELF.js} +114 -55
  36. package/dist/{claude-63ISJAZK.js → claude-FRRWJSTJ.js} +1 -1
  37. package/dist/{claude-cli-ABML5RHX.js → claude-cli-XJLK2X4L.js} +1 -1
  38. package/dist/{claude-code-JRLMRPTO.js → claude-code-HTBA4XRB.js} +1 -1
  39. package/dist/{claude-code-teams-CAJBEFIZ.js → claude-code-teams-T4SP24MD.js} +1 -1
  40. package/dist/{conductor-HLWYWUVH.js → conductor-PGPDVIVE.js} +1 -1
  41. package/dist/{config-schema-3YNIFJCJ.js → config-schema-EA4XALGG.js} +4 -2
  42. package/dist/{constellation-FAGT45TU.js → constellation-A26CCGQS.js} +1 -1
  43. package/dist/{context-audit-557EO6PK.js → context-audit-RLO3ETRP.js} +8 -5
  44. package/dist/{cost-XEBADYFT.js → cost-BGM32XJU.js} +1 -1
  45. package/dist/{cost-UD3WPEKZ.js → cost-VI46A4XL.js} +1 -1
  46. package/dist/{cursor-cli-QUOOF2N4.js → cursor-cli-JVEZGHWQ.js} +1 -1
  47. package/dist/{cursorrules-3TKZ4E4R.js → cursorrules-HLIKJJZT.js} +1 -1
  48. package/dist/decision-loader-WWCLIQPJ.js +20 -0
  49. package/dist/{delete-RRK4RL6Y.js → delete-KBRPQLPC.js} +2 -2
  50. package/dist/{diff-IP5CIARP.js → diff-RQLLNAFI.js} +5 -5
  51. package/dist/{discipline-5F5OVTXB.js → discipline-FA4OZXIS.js} +1 -1
  52. package/dist/{dist-UXWV4OKX.js → dist-34NA5RS5.js} +1 -1
  53. package/dist/{dist-5QE2BB2B-X6DYVSUL.js → dist-5QE2BB2B-5S3T6Y3T.js} +1 -1
  54. package/dist/{dist-CM3MVWWW.js → dist-77JDTVAY.js} +1 -0
  55. package/dist/{dist-POMVY6WP.js → dist-QK4SQAK7.js} +1 -1
  56. package/dist/{dist-3RVKEJRT.js → dist-TA6LSC2Q.js} +1 -1
  57. package/dist/docs-J2BTKRVU.js +155 -0
  58. package/dist/docs-PBZB7LYP.js +89 -0
  59. package/dist/{doctor-GKZJU7QG.js → doctor-ULBOHEIC.js} +3 -3
  60. package/dist/{drift-YGT4LJ7Q.js → drift-R5NRKFHI.js} +1 -1
  61. package/dist/{echo-A6HD5UP7.js → echo-O2LY7CC2.js} +1 -1
  62. package/dist/{edit-4CLNN5JG.js → edit-R2HNLMOG.js} +2 -2
  63. package/dist/event-25OJKDCE.js +31 -0
  64. package/dist/{export-T7CMMJIB.js → export-IWVL7XLF.js} +1 -1
  65. package/dist/{flow-UFMPVOEM.js → flow-CRRVV3O3.js} +2 -2
  66. package/dist/{global-HHUJSBG5.js → global-3NG5JXUB.js} +1 -1
  67. package/dist/graduate-USAWGBJM.js +160 -0
  68. package/dist/{graph-YYUXI3F7.js → graph-VHUMAAS6.js} +2 -2
  69. package/dist/{graph-server-ZPXRSGCW.js → graph-server-YL22VBBN.js} +1 -1
  70. package/dist/{habits-RG5SVKXP.js → habits-OL5NGPXO.js} +3 -3
  71. package/dist/{history-CETCSUCP.js → history-WOWC573W.js} +1 -1
  72. package/dist/{hooks-TCUHQMPF.js → hooks-HFWSCGPV.js} +2 -2
  73. package/dist/index.js +302 -188
  74. package/dist/{integrity-MK2OP5TA.js → integrity-IHO4FZTS.js} +1 -1
  75. package/dist/{integrity-checker-J7YXRTBT.js → integrity-checker-PSKJA5SB.js} +1 -0
  76. package/dist/journal-loader-5EYSBFFY.js +18 -0
  77. package/dist/{lint-HYWGS3JJ.js → lint-K6CJGGPH.js} +1 -1
  78. package/dist/{list-IUCYPGMK.js → list-4YK7QKFF.js} +1 -1
  79. package/dist/{list-BTLFHSRC.js → list-ENR7Q4CR.js} +2 -2
  80. package/dist/{lore-loader-VTEEZDX3.js → lore-loader-7NO6N6FT.js} +4 -1
  81. package/dist/{lore-server-NOOAHKJX.js → lore-server-UNJY5KC3.js} +1 -1
  82. package/dist/{manual-AFJ2J2V3.js → manual-G6FISID5.js} +1 -1
  83. package/dist/mcp.js +3917 -356
  84. package/dist/{migrate-FQVGQNXZ.js → migrate-LS45DNEV.js} +2 -2
  85. package/dist/{migrate-assessments-JP6Q5KME.js → migrate-assessments-RGH4O6IX.js} +2 -2
  86. package/dist/nomination-engine-HDWMN4IO.js +42 -0
  87. package/dist/notebook-YWIYGEHV.js +155 -0
  88. package/dist/{orchestrate-A226N6FC.js → orchestrate-XZA33TJC.js} +5 -5
  89. package/dist/{peers-RFQCWVLV.js → peers-DEOUIZM6.js} +1 -1
  90. package/dist/persona-UHAHIVST.js +390 -0
  91. package/dist/{pipeline-3G2FRAKM.js → pipeline-L4HCSBGN.js} +1 -1
  92. package/dist/{platform-server-H7Y6Q7O4.js → platform-server-2D6S6YTK.js} +412 -18
  93. package/dist/{plugin-update-checker-HMRPGY5Z.js → plugin-update-checker-ELOEEQYS.js} +1 -0
  94. package/dist/{portal-check-FF5EKZE5.js → portal-check-NPYGII2D.js} +2 -2
  95. package/dist/{portal-compliance-VU4NIFEN.js → portal-compliance-J7DGAPFX.js} +2 -2
  96. package/dist/{probe-7JK7IDNI.js → probe-MHL5HQZ2.js} +3 -3
  97. package/dist/{promote-XO63XMAN.js → promote-F6ZYZZAL.js} +2 -2
  98. package/dist/{providers-YNFSL6HK.js → providers-GK7PB2OL.js} +2 -2
  99. package/dist/{quiz-I75NU2QQ.js → quiz-M66SC7F7.js} +1 -1
  100. package/dist/{record-46CLR4OG.js → record-RA4WR2BO.js} +2 -2
  101. package/dist/{reindex-WIJMCJ4A.js → reindex-65H4WULU.js} +3 -2
  102. package/dist/{remember-4EUZKIIB.js → remember-HBWJ655S.js} +1 -1
  103. package/dist/{retag-KC4JVRLE.js → retag-3OLCVDEQ.js} +2 -2
  104. package/dist/{review-Q7M4CRB5.js → review-27ATYTD2.js} +2 -2
  105. package/dist/review-57QMURZV.js +334 -0
  106. package/dist/{ripple-RI3LOT6R.js → ripple-JPBXP5I3.js} +1 -1
  107. package/dist/{sentinel-UOIGJWHH.js → sentinel-4XIG4STA.js} +2 -2
  108. package/dist/{sentinel-bridge-APDXYAZS.js → sentinel-bridge-MDUXTQRL.js} +2 -2
  109. package/dist/{serve-KKEHE44G.js → serve-EFVRS4GA.js} +2 -2
  110. package/dist/{serve-22A4XOIG.js → serve-INL7SNBK.js} +2 -2
  111. package/dist/{serve-2YJ6D2Y6.js → serve-KBSE36PL.js} +4 -4
  112. package/dist/{server-JV6UFGWZ.js → server-54SKYFFY.js} +2 -2
  113. package/dist/{server-RDLQ3DK7.js → server-XUOIO7E6.js} +1 -1
  114. package/dist/{setup-YNZJQLW7.js → setup-EDS27WUR.js} +1 -1
  115. package/dist/{setup-M2ZKLKNN.js → setup-KO5AFC4K.js} +2 -2
  116. package/dist/{shift-LNMKFYLR.js → shift-VFG23DLA.js} +16 -16
  117. package/dist/{show-P7GYO43X.js → show-5PV5KFJE.js} +2 -2
  118. package/dist/{show-PKZMYKRN.js → show-NQKYX6WQ.js} +1 -1
  119. package/dist/{snapshot-Y3COXK4T.js → snapshot-BK4RBPCG.js} +1 -1
  120. package/dist/{spawn-SSXZX45U.js → spawn-AW6GDECS.js} +3 -3
  121. package/dist/{status-KLHALGW4.js → status-WGIAQODY.js} +1 -1
  122. package/dist/{summary-5NQNOD3F.js → summary-NIRABMF5.js} +2 -2
  123. package/dist/{sweep-EZU3GU6S.js → sweep-QMHNSIY5.js} +2 -2
  124. package/dist/{switch-WYUMVNA5.js → switch-6EJPZDIA.js} +1 -1
  125. package/dist/{symphony-6K3HD7AW.js → symphony-4OCY36AI.js} +5 -5
  126. package/dist/{symphony-YCHBYN3E.js → symphony-B75X2MME.js} +2 -2
  127. package/dist/{symphony-peers-HSY3RI3S.js → symphony-peers-2ZQYLRNI.js} +1 -1
  128. package/dist/{symphony-peers-APOGJPF4.js → symphony-peers-OL7F6M5S.js} +1 -0
  129. package/dist/{symphony-relay-GTAJRCVF.js → symphony-relay-UJYUXN65.js} +28 -1
  130. package/dist/{sync-ZM4Q3R4U.js → sync-VEHUH4OA.js} +3 -3
  131. package/dist/{sync-llms-JIPP3XX4.js → sync-llms-YHCFIE6X.js} +2 -2
  132. package/dist/{task-loader-7M2FCBX6.js → task-loader-LDYWQSLM.js} +1 -0
  133. package/dist/{team-HGLJXWQG.js → team-7HG7XK5C.js} +6 -6
  134. package/dist/{test-WTR5Q33E.js → test-566CP5KC.js} +1 -1
  135. package/dist/{thread-3WM7KKID.js → thread-N754I4D5.js} +1 -1
  136. package/dist/{timeline-ANC7LVDL.js → timeline-M3CICQFE.js} +2 -2
  137. package/dist/{triage-IZ4MDYNB.js → triage-HHYGT3HY.js} +1 -1
  138. package/dist/{tutorial-GC6QL4US.js → tutorial-KD22SUNO.js} +1 -1
  139. package/dist/university-content/courses/.purpose +66 -0
  140. package/dist/university-content/courses/para-401.json +146 -0
  141. package/dist/university-content/courses/para-501.json +67 -0
  142. package/dist/university-content/courses/para-601.json +690 -0
  143. package/dist/university-content/plsat/.purpose +6 -0
  144. package/dist/university-content/plsat/v2.0.json +2 -2
  145. package/dist/university-content/plsat/v3.0.json +563 -3
  146. package/dist/university-content/reference.json +91 -0
  147. package/dist/university-ui/assets/{index-tfi5xN4Q.js → index-C6bH_6xu.js} +2 -2
  148. package/dist/university-ui/assets/{index-tfi5xN4Q.js.map → index-C6bH_6xu.js.map} +1 -1
  149. package/dist/university-ui/index.html +1 -1
  150. package/dist/{upgrade-ANX3LVSA.js → upgrade-H5PF32BW.js} +2 -2
  151. package/dist/{validate-GD5XWILV.js → validate-CNKEKO6A.js} +1 -1
  152. package/dist/{validate-ITC5D6QG.js → validate-MB5ULIHS.js} +1 -1
  153. package/dist/{validate-ZVPNN4FL.js → validate-QH3LADM6.js} +1 -1
  154. package/dist/{watch-X64UK7K4.js → watch-2TKP5PVL.js} +3 -3
  155. package/dist/{watch-ERBEJUJW.js → watch-ZF4ML6CD.js} +2 -2
  156. package/dist/{wisdom-L2WC7J62.js → wisdom-AATMGNFA.js} +1 -1
  157. package/dist/work-log-loader-5L45XNYZ.js +14 -0
  158. package/dist/{workspace-UIUTHZTD.js → workspace-6E6OSRNU.js} +4 -4
  159. package/package.json +1 -1
  160. package/platform-ui/dist/assets/DocsSection-ByAgPzWV.js +1 -0
  161. package/platform-ui/dist/assets/DocsSection-CjdO6R-u.css +1 -0
  162. package/platform-ui/dist/assets/{GitSection-BD3Ze06e.js → GitSection-BLovj9yT.js} +1 -1
  163. package/platform-ui/dist/assets/{GraphSection-SglITfSs.js → GraphSection-C5PCPUFl.js} +1 -1
  164. package/platform-ui/dist/assets/{LoreSection-bR5Km4Fd.js → LoreSection-BftejTla.js} +1 -1
  165. package/platform-ui/dist/assets/{SentinelSection-QSpAZArG.js → SentinelSection-CnYcasN7.js} +1 -1
  166. package/platform-ui/dist/assets/{SymphonySection-CobYJgvg.js → SymphonySection-BpmqCHeK.js} +1 -1
  167. package/platform-ui/dist/assets/{index-DbxeSMkV.js → index-G9JnWEs_.js} +10 -10
  168. package/platform-ui/dist/index.html +1 -1
  169. package/dist/dist-PSF5CP4I.js +0 -7294
@@ -10,7 +10,7 @@ async function graphCommand(path, options) {
10
10
  const shouldOpen = options.open !== false;
11
11
  console.log(chalk.cyan("\nStarting Symbol Graph...\n"));
12
12
  try {
13
- const { startGraphServer } = await import("./graph-server-ZPXRSGCW.js");
13
+ const { startGraphServer } = await import("./graph-server-YL22VBBN.js");
14
14
  console.log(chalk.gray(`Project: ${projectDir}`));
15
15
  console.log(chalk.gray(`Port: ${port}`));
16
16
  console.log();
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  indexCommand
4
- } from "./chunk-7COU5S2Z.js";
4
+ } from "./chunk-VL67H5IC.js";
5
5
  import {
6
6
  getDefaultPremiseContent
7
7
  } from "./chunk-ZGUAAVMA.js";
@@ -19,7 +19,7 @@ import {
19
19
  detectIDE,
20
20
  loadParadigmFiles,
21
21
  syncToIDE
22
- } from "./chunk-KB4XJWE3.js";
22
+ } from "./chunk-6N3JTACN.js";
23
23
  import {
24
24
  log
25
25
  } from "./chunk-4NCFWYGG.js";
@@ -5,7 +5,7 @@ import {
5
5
  import {
6
6
  getProvider,
7
7
  initializeProviders
8
- } from "./chunk-FS3WTUHY.js";
8
+ } from "./chunk-TXESEO7Y.js";
9
9
  import {
10
10
  loadAgentsManifest
11
11
  } from "./chunk-PMXRGPRQ.js";
@@ -614,6 +614,7 @@ var AgentSpawner = class {
614
614
  agent: agentName,
615
615
  task,
616
616
  status: "success",
617
+ completionVerified: false,
617
618
  outputs: {
618
619
  artifacts: [],
619
620
  symbols: context.symbols,
@@ -681,6 +682,29 @@ var AgentSpawner = class {
681
682
  if (this.budgetTracker) {
682
683
  this.budgetTracker.recordUsage(agentName, relay.metrics.tokens_used, model);
683
684
  }
685
+ if (relay.status === "success") {
686
+ const hasArtifacts = relay.outputs.artifacts.length > 0;
687
+ const hasDecisions = relay.outputs.decisions.length > 0;
688
+ const hasHandoff = !!relay.handoff;
689
+ const didFileWork = relay.metrics.files_written > 0;
690
+ const isArchitect = agentName === "architect";
691
+ const isBuilder = agentName === "builder";
692
+ if (isBuilder && !didFileWork && !hasHandoff) {
693
+ relay.status = "partial";
694
+ } else if (!hasArtifacts && !hasDecisions && !hasHandoff && !didFileWork) {
695
+ relay.status = "partial";
696
+ }
697
+ relay.completionVerified = true;
698
+ if (relay.status === "partial" && !isArchitect) {
699
+ if (options.onMessage) {
700
+ options.onMessage({
701
+ type: "text",
702
+ content: `[completion-check] Agent "${agentName}" downgraded from success \u2192 partial: no meaningful output detected.`,
703
+ timestamp: (/* @__PURE__ */ new Date()).toISOString()
704
+ });
705
+ }
706
+ }
707
+ }
684
708
  if (this.auditLogger) {
685
709
  const agentLog = {
686
710
  name: agentName,
@@ -0,0 +1,145 @@
1
+ #!/usr/bin/env node
2
+ import {
3
+ __esm,
4
+ __export
5
+ } from "./chunk-7N7GSU6K.js";
6
+
7
+ // ../paradigm-mcp/src/utils/journal-loader.ts
8
+ var journal_loader_exports = {};
9
+ __export(journal_loader_exports, {
10
+ getJournalStats: () => getJournalStats,
11
+ loadAllJournalEntries: () => loadAllJournalEntries,
12
+ loadJournalEntries: () => loadJournalEntries,
13
+ loadJournalEntry: () => loadJournalEntry,
14
+ recordJournalEntry: () => recordJournalEntry
15
+ });
16
+ import * as fs from "fs";
17
+ import * as path from "path";
18
+ import * as yaml from "js-yaml";
19
+ function getJournalDir(agentId) {
20
+ const home = process.env.HOME || process.env.USERPROFILE || "";
21
+ return path.join(home, ".paradigm", "agents", agentId, "journal");
22
+ }
23
+ function generateJournalId() {
24
+ const now = /* @__PURE__ */ new Date();
25
+ const date = now.toISOString().slice(0, 10);
26
+ const time = now.toISOString().slice(11, 19).replace(/:/g, "");
27
+ const counter = String(Math.floor(Math.random() * 999) + 1).padStart(3, "0");
28
+ return `LJ-${date}-${time}-${counter}`;
29
+ }
30
+ function recordJournalEntry(agentId, entry) {
31
+ const now = /* @__PURE__ */ new Date();
32
+ const id = generateJournalId();
33
+ const full = {
34
+ id,
35
+ agent: agentId,
36
+ timestamp: now.toISOString(),
37
+ ...entry
38
+ };
39
+ const dir = getJournalDir(agentId);
40
+ fs.mkdirSync(dir, { recursive: true });
41
+ const filePath = path.join(dir, `${id}.yaml`);
42
+ fs.writeFileSync(filePath, yaml.dump(full, { lineWidth: 120, noRefs: true }), "utf8");
43
+ return full;
44
+ }
45
+ function loadJournalEntries(agentId, filter) {
46
+ const dir = getJournalDir(agentId);
47
+ if (!fs.existsSync(dir)) return [];
48
+ const entries = [];
49
+ const files = fs.readdirSync(dir).filter((f) => f.endsWith(".yaml"));
50
+ for (const file of files) {
51
+ try {
52
+ const content = fs.readFileSync(path.join(dir, file), "utf8");
53
+ const entry = yaml.load(content);
54
+ if (entry && entry.id) {
55
+ entries.push(entry);
56
+ }
57
+ } catch {
58
+ }
59
+ }
60
+ let filtered = entries;
61
+ if (filter?.trigger) {
62
+ filtered = filtered.filter((e) => e.trigger === filter.trigger);
63
+ }
64
+ if (filter?.project) {
65
+ filtered = filtered.filter((e) => e.project === filter.project);
66
+ }
67
+ if (filter?.transferable !== void 0) {
68
+ filtered = filtered.filter((e) => e.transferable === filter.transferable);
69
+ }
70
+ if (filter?.tag) {
71
+ filtered = filtered.filter((e) => e.tags?.some((t) => t.startsWith(filter.tag)));
72
+ }
73
+ if (filter?.dateFrom) {
74
+ filtered = filtered.filter((e) => e.timestamp >= filter.dateFrom);
75
+ }
76
+ if (filter?.dateTo) {
77
+ filtered = filtered.filter((e) => e.timestamp <= filter.dateTo);
78
+ }
79
+ filtered.sort((a, b) => b.timestamp.localeCompare(a.timestamp));
80
+ if (filter?.limit) {
81
+ filtered = filtered.slice(0, filter.limit);
82
+ }
83
+ return filtered;
84
+ }
85
+ function loadJournalEntry(agentId, id) {
86
+ const dir = getJournalDir(agentId);
87
+ const filePath = path.join(dir, `${id}.yaml`);
88
+ if (!fs.existsSync(filePath)) return null;
89
+ const content = fs.readFileSync(filePath, "utf8");
90
+ return yaml.load(content);
91
+ }
92
+ function loadAllJournalEntries(filter) {
93
+ const home = process.env.HOME || process.env.USERPROFILE || "";
94
+ const agentsDir = path.join(home, ".paradigm", "agents");
95
+ if (!fs.existsSync(agentsDir)) return [];
96
+ const entries = [];
97
+ const agents = fs.readdirSync(agentsDir, { withFileTypes: true }).filter((d) => d.isDirectory());
98
+ for (const agentDir of agents) {
99
+ if (filter?.agent && agentDir.name !== filter.agent) continue;
100
+ const agentEntries = loadJournalEntries(agentDir.name, filter);
101
+ entries.push(...agentEntries);
102
+ }
103
+ entries.sort((a, b) => b.timestamp.localeCompare(a.timestamp));
104
+ if (filter?.limit) {
105
+ return entries.slice(0, filter.limit);
106
+ }
107
+ return entries;
108
+ }
109
+ function getJournalStats(agentId) {
110
+ const entries = loadJournalEntries(agentId);
111
+ const byTrigger = {};
112
+ const byProject = {};
113
+ let transferableCount = 0;
114
+ for (const e of entries) {
115
+ byTrigger[e.trigger] = (byTrigger[e.trigger] || 0) + 1;
116
+ byProject[e.project] = (byProject[e.project] || 0) + 1;
117
+ if (e.transferable) transferableCount++;
118
+ }
119
+ return {
120
+ total: entries.length,
121
+ byTrigger,
122
+ byProject,
123
+ transferableCount,
124
+ recentInsights: entries.slice(0, 5).map((e) => ({
125
+ id: e.id,
126
+ trigger: e.trigger,
127
+ insight: e.insight.slice(0, 200),
128
+ timestamp: e.timestamp
129
+ }))
130
+ };
131
+ }
132
+ var init_journal_loader = __esm({
133
+ "../paradigm-mcp/src/utils/journal-loader.ts"() {
134
+ }
135
+ });
136
+
137
+ export {
138
+ recordJournalEntry,
139
+ loadJournalEntries,
140
+ loadJournalEntry,
141
+ loadAllJournalEntries,
142
+ getJournalStats,
143
+ journal_loader_exports,
144
+ init_journal_loader
145
+ };
@@ -1,16 +1,11 @@
1
1
  #!/usr/bin/env node
2
- var __getOwnPropNames = Object.getOwnPropertyNames;
3
2
  var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
4
3
  get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
5
4
  }) : x)(function(x) {
6
5
  if (typeof require !== "undefined") return require.apply(this, arguments);
7
6
  throw Error('Dynamic require of "' + x + '" is not supported');
8
7
  });
9
- var __commonJS = (cb, mod) => function __require2() {
10
- return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
11
- };
12
8
 
13
9
  export {
14
- __require,
15
- __commonJS
10
+ __require
16
11
  };
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  detectIDE,
4
4
  getAdapter
5
- } from "./chunk-KB4XJWE3.js";
5
+ } from "./chunk-6N3JTACN.js";
6
6
  import {
7
7
  parseParadigmConfig
8
8
  } from "./chunk-YO6DVTL7.js";
@@ -13,6 +13,7 @@ import {
13
13
  // src/commands/doctor/index.ts
14
14
  import * as fs from "fs";
15
15
  import * as path from "path";
16
+ import * as yaml from "js-yaml";
16
17
  import chalk from "chalk";
17
18
  async function doctorCommand(options = {}) {
18
19
  const cwd = options.rootDir || process.cwd();
@@ -245,8 +246,7 @@ async function doctorCommand(options = {}) {
245
246
  if (fs.existsSync(configPath)) {
246
247
  try {
247
248
  const configContent = fs.readFileSync(configPath, "utf8");
248
- const { parse } = await import("./dist-PSF5CP4I.js");
249
- const config = parse(configContent);
249
+ const config = yaml.load(configContent);
250
250
  const purposeRequired = config?.["purpose-required"];
251
251
  if (purposeRequired && Array.isArray(purposeRequired)) {
252
252
  const missingDirs = [];
@@ -314,8 +314,7 @@ async function doctorCommand(options = {}) {
314
314
  if (fs.existsSync(portalPath)) {
315
315
  try {
316
316
  const portalContent = fs.readFileSync(portalPath, "utf8");
317
- const { parse } = await import("./dist-PSF5CP4I.js");
318
- const portal = parse(portalContent);
317
+ const portal = yaml.load(portalContent);
319
318
  if (portal?.version && portal?.gates) {
320
319
  const gateCount = Object.keys(portal.gates || {}).length;
321
320
  const routeCount = Object.keys(portal.routes || {}).length;
@@ -343,7 +342,7 @@ async function doctorCommand(options = {}) {
343
342
  }
344
343
  if (fs.existsSync(portalPath)) {
345
344
  try {
346
- const { checkPortalCompliance, getComplianceSummary } = await import("./portal-compliance-VU4NIFEN.js");
345
+ const { checkPortalCompliance, getComplianceSummary } = await import("./portal-compliance-J7DGAPFX.js");
347
346
  const complianceReport = await checkPortalCompliance(cwd);
348
347
  const summary = getComplianceSummary(complianceReport);
349
348
  results.push({
@@ -359,8 +358,7 @@ async function doctorCommand(options = {}) {
359
358
  if (fs.existsSync(flowsPath)) {
360
359
  try {
361
360
  const flowsContent = fs.readFileSync(flowsPath, "utf8");
362
- const { parse } = await import("./dist-PSF5CP4I.js");
363
- const flows = parse(flowsContent);
361
+ const flows = yaml.load(flowsContent);
364
362
  if (flows?.version && flows?.flows) {
365
363
  const flowCount = Object.keys(flows.flows || {}).length;
366
364
  const emptyFlows = Object.entries(flows.flows || {}).filter(
@@ -449,8 +447,7 @@ async function doctorCommand(options = {}) {
449
447
  if (fs.existsSync(quizDir)) {
450
448
  for (const file of fs.readdirSync(quizDir).filter((f) => f.endsWith(".yaml"))) {
451
449
  try {
452
- const { parse } = await import("./dist-PSF5CP4I.js");
453
- const quiz = parse(fs.readFileSync(path.join(quizDir, file), "utf8"));
450
+ const quiz = yaml.load(fs.readFileSync(path.join(quizDir, file), "utf8"));
454
451
  if (quiz?.questions) {
455
452
  for (const q of quiz.questions) {
456
453
  if (q.choices && q.correct && !(q.correct in q.choices)) {
@@ -466,8 +463,7 @@ async function doctorCommand(options = {}) {
466
463
  if (fs.existsSync(pathDir)) {
467
464
  for (const file of fs.readdirSync(pathDir).filter((f) => f.endsWith(".yaml"))) {
468
465
  try {
469
- const { parse } = await import("./dist-PSF5CP4I.js");
470
- const lp = parse(fs.readFileSync(path.join(pathDir, file), "utf8"));
466
+ const lp = yaml.load(fs.readFileSync(path.join(pathDir, file), "utf8"));
471
467
  if (lp?.steps) {
472
468
  for (const step of lp.steps) {
473
469
  if (step.content && !step.content.startsWith("plsat:")) {
@@ -551,8 +547,7 @@ async function doctorCommand(options = {}) {
551
547
  if (fs.existsSync(habitsPath)) {
552
548
  try {
553
549
  const habitsContent = fs.readFileSync(habitsPath, "utf8");
554
- const { parse } = await import("./dist-PSF5CP4I.js");
555
- const habits = parse(habitsContent);
550
+ const habits = yaml.load(habitsContent);
556
551
  if (habits?.version && Array.isArray(habits?.habits)) {
557
552
  const enabled = habits.habits.filter((h) => h.enabled !== false).length;
558
553
  results.push({
@@ -633,7 +628,7 @@ async function doctorCommand(options = {}) {
633
628
  }
634
629
  }
635
630
  }
636
- const { runContextAudit } = await import("./context-audit-557EO6PK.js");
631
+ const { runContextAudit } = await import("./context-audit-RLO3ETRP.js");
637
632
  const contextResults = await runContextAudit(cwd, { quiet });
638
633
  let contextErrorCount = 0;
639
634
  let contextWarnCount = 0;
@@ -0,0 +1,124 @@
1
+ #!/usr/bin/env node
2
+
3
+ // ../paradigm-mcp/src/utils/work-log-loader.ts
4
+ import * as fs from "fs";
5
+ import * as path from "path";
6
+ import * as yaml from "js-yaml";
7
+ var WORK_LOG_DIR = ".paradigm/work-log";
8
+ function generateWorkLogId(agent) {
9
+ const now = /* @__PURE__ */ new Date();
10
+ const date = now.toISOString().slice(0, 10);
11
+ const sanitized = agent.toLowerCase().replace(/[^a-z0-9-]/g, "-").slice(0, 20);
12
+ const counter = String(Math.floor(Math.random() * 999) + 1).padStart(3, "0");
13
+ return `WL-${sanitized}-${date}-${counter}`;
14
+ }
15
+ function getDateDir(rootDir, date) {
16
+ return path.join(rootDir, WORK_LOG_DIR, date);
17
+ }
18
+ function recordWorkLog(rootDir, entry) {
19
+ const now = /* @__PURE__ */ new Date();
20
+ const date = now.toISOString().slice(0, 10);
21
+ const id = generateWorkLogId(entry.agent);
22
+ const full = {
23
+ id,
24
+ timestamp: now.toISOString(),
25
+ ...entry
26
+ };
27
+ const dir = getDateDir(rootDir, date);
28
+ fs.mkdirSync(dir, { recursive: true });
29
+ const filePath = path.join(dir, `${id}.yaml`);
30
+ fs.writeFileSync(filePath, yaml.dump(full, { lineWidth: 120, noRefs: true }), "utf8");
31
+ return full;
32
+ }
33
+ function loadWorkLogEntries(rootDir, filter) {
34
+ const baseDir = path.join(rootDir, WORK_LOG_DIR);
35
+ if (!fs.existsSync(baseDir)) return [];
36
+ const entries = [];
37
+ const dateDirs = fs.readdirSync(baseDir, { withFileTypes: true }).filter((d) => d.isDirectory() && /^\d{4}-\d{2}-\d{2}$/.test(d.name)).map((d) => d.name).sort().reverse();
38
+ for (const dateDir of dateDirs) {
39
+ if (filter?.dateFrom && dateDir < filter.dateFrom) continue;
40
+ if (filter?.dateTo && dateDir > filter.dateTo) continue;
41
+ const dirPath = path.join(baseDir, dateDir);
42
+ const files = fs.readdirSync(dirPath).filter((f) => f.endsWith(".yaml"));
43
+ for (const file of files) {
44
+ try {
45
+ const content = fs.readFileSync(path.join(dirPath, file), "utf8");
46
+ const entry = yaml.load(content);
47
+ if (entry && entry.id) {
48
+ entries.push(entry);
49
+ }
50
+ } catch {
51
+ }
52
+ }
53
+ }
54
+ let filtered = entries;
55
+ if (filter?.agent) {
56
+ filtered = filtered.filter((e) => e.agent === filter.agent);
57
+ }
58
+ if (filter?.outcome) {
59
+ filtered = filtered.filter((e) => e.outcome === filter.outcome);
60
+ }
61
+ if (filter?.task_ref) {
62
+ filtered = filtered.filter((e) => e.task_ref === filter.task_ref);
63
+ }
64
+ if (filter?.symbol) {
65
+ filtered = filtered.filter((e) => e.symbols_touched?.includes(filter.symbol));
66
+ }
67
+ filtered.sort((a, b) => b.timestamp.localeCompare(a.timestamp));
68
+ if (filter?.limit) {
69
+ filtered = filtered.slice(0, filter.limit);
70
+ }
71
+ return filtered;
72
+ }
73
+ function loadWorkLogEntry(rootDir, id) {
74
+ const baseDir = path.join(rootDir, WORK_LOG_DIR);
75
+ if (!fs.existsSync(baseDir)) return null;
76
+ const match = id.match(/WL-[^-]+-(\d{4}-\d{2}-\d{2})-/);
77
+ if (match) {
78
+ const filePath = path.join(baseDir, match[1], `${id}.yaml`);
79
+ if (fs.existsSync(filePath)) {
80
+ const content = fs.readFileSync(filePath, "utf8");
81
+ return yaml.load(content);
82
+ }
83
+ }
84
+ const dateDirs = fs.readdirSync(baseDir, { withFileTypes: true }).filter((d) => d.isDirectory());
85
+ for (const dir of dateDirs) {
86
+ const filePath = path.join(baseDir, dir.name, `${id}.yaml`);
87
+ if (fs.existsSync(filePath)) {
88
+ const content = fs.readFileSync(filePath, "utf8");
89
+ return yaml.load(content);
90
+ }
91
+ }
92
+ return null;
93
+ }
94
+ function getWorkLogSummary(rootDir, days = 7) {
95
+ const cutoff = /* @__PURE__ */ new Date();
96
+ cutoff.setDate(cutoff.getDate() - days);
97
+ const dateFrom = cutoff.toISOString().slice(0, 10);
98
+ const entries = loadWorkLogEntries(rootDir, { dateFrom });
99
+ const byOutcome = { pass: 0, fail: 0, partial: 0, blocked: 0 };
100
+ const byAgent = {};
101
+ for (const e of entries) {
102
+ byOutcome[e.outcome] = (byOutcome[e.outcome] || 0) + 1;
103
+ byAgent[e.agent] = (byAgent[e.agent] || 0) + 1;
104
+ }
105
+ return {
106
+ total: entries.length,
107
+ byOutcome,
108
+ byAgent,
109
+ recentEntries: entries.slice(0, 10).map((e) => ({
110
+ id: e.id,
111
+ agent: e.agent,
112
+ summary: e.summary,
113
+ outcome: e.outcome,
114
+ timestamp: e.timestamp
115
+ }))
116
+ };
117
+ }
118
+
119
+ export {
120
+ recordWorkLog,
121
+ loadWorkLogEntries,
122
+ loadWorkLogEntry,
123
+ getWorkLogSummary
124
+ };
@@ -136,32 +136,32 @@ async function initializeProviders(rootDir) {
136
136
  if (initialized) return;
137
137
  const dir = rootDir || process.cwd();
138
138
  try {
139
- const { ClaudeAgentProvider } = await import("./claude-63ISJAZK.js");
139
+ const { ClaudeAgentProvider } = await import("./claude-FRRWJSTJ.js");
140
140
  registerProvider(new ClaudeAgentProvider());
141
141
  } catch {
142
142
  }
143
143
  try {
144
- const { ClaudeCodeTeamsProvider } = await import("./claude-code-teams-CAJBEFIZ.js");
144
+ const { ClaudeCodeTeamsProvider } = await import("./claude-code-teams-T4SP24MD.js");
145
145
  registerProvider(new ClaudeCodeTeamsProvider(dir));
146
146
  } catch {
147
147
  }
148
148
  try {
149
- const { ClaudeCodeTaskProvider } = await import("./claude-code-JRLMRPTO.js");
149
+ const { ClaudeCodeTaskProvider } = await import("./claude-code-HTBA4XRB.js");
150
150
  registerProvider(new ClaudeCodeTaskProvider(dir));
151
151
  } catch {
152
152
  }
153
153
  try {
154
- const { CursorCliProvider } = await import("./cursor-cli-QUOOF2N4.js");
154
+ const { CursorCliProvider } = await import("./cursor-cli-JVEZGHWQ.js");
155
155
  registerProvider(new CursorCliProvider());
156
156
  } catch {
157
157
  }
158
158
  try {
159
- const { ClaudeCliProvider } = await import("./claude-cli-ABML5RHX.js");
159
+ const { ClaudeCliProvider } = await import("./claude-cli-XJLK2X4L.js");
160
160
  registerProvider(new ClaudeCliProvider());
161
161
  } catch {
162
162
  }
163
163
  try {
164
- const { ManualProvider } = await import("./manual-AFJ2J2V3.js");
164
+ const { ManualProvider } = await import("./manual-G6FISID5.js");
165
165
  registerProvider(new ManualProvider(dir));
166
166
  } catch {
167
167
  }
@@ -8,7 +8,7 @@ import {
8
8
  } from "./chunk-ZGUAAVMA.js";
9
9
  import {
10
10
  cliBuildGraphState
11
- } from "./chunk-QDXI2DHR.js";
11
+ } from "./chunk-J2JEQRT3.js";
12
12
 
13
13
  // src/commands/scan/navigator.ts
14
14
  import * as fs from "fs";
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  AgentSpawner,
4
4
  extractSymbols
5
- } from "./chunk-J4E6K5MG.js";
5
+ } from "./chunk-LSRABQIY.js";
6
6
  import {
7
7
  AuditLogger
8
8
  } from "./chunk-PBHIFAL4.js";
@@ -12,10 +12,6 @@ import {
12
12
  import {
13
13
  loadAgentsManifest
14
14
  } from "./chunk-PMXRGPRQ.js";
15
- import {
16
- extractDeclaredGates,
17
- loadPortalConfig
18
- } from "./chunk-MW5DMGBB.js";
19
15
  import {
20
16
  calculateCost
21
17
  } from "./chunk-5JGJACDU.js";
@@ -24,6 +20,10 @@ import {
24
20
  getReferencesTo,
25
21
  searchSymbols
26
22
  } from "./chunk-ZGUAAVMA.js";
23
+ import {
24
+ extractDeclaredGates,
25
+ loadPortalConfig
26
+ } from "./chunk-YMDLDELF.js";
27
27
 
28
28
  // src/core/orchestrator.ts
29
29
  import { minimatch } from "minimatch";
@@ -566,7 +566,7 @@ var Orchestrator = class {
566
566
  let preflightResult;
567
567
  if (options.pmGovernance?.enabled) {
568
568
  try {
569
- const { aggregateFromDirectory } = await import("./dist-UXWV4OKX.js");
569
+ const { aggregateFromDirectory } = await import("./dist-34NA5RS5.js");
570
570
  const aggregation = await aggregateFromDirectory(this.rootDir);
571
571
  const index = buildSymbolIndex(aggregation);
572
572
  preflightResult = runPreflight(task, this.rootDir, index);
@@ -593,7 +593,7 @@ var Orchestrator = class {
593
593
  }
594
594
  if (options.pmGovernance?.enabled && preflightResult) {
595
595
  try {
596
- const { aggregateFromDirectory } = await import("./dist-UXWV4OKX.js");
596
+ const { aggregateFromDirectory } = await import("./dist-34NA5RS5.js");
597
597
  const aggregation = await aggregateFromDirectory(this.rootDir);
598
598
  const index = buildSymbolIndex(aggregation);
599
599
  const filesModified = [];