@a-company/paradigm 3.46.0 → 5.3.3

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 (166) 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-HYKC2LAK.js +387 -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-7N7GSU6K.js +34 -0
  17. package/dist/chunk-A2L4TSLZ.js +526 -0
  18. package/dist/{chunk-P7XSBJE3.js → chunk-ABVQGRF7.js} +1 -1
  19. package/dist/{chunk-HIKKOCXY.js → chunk-EI32ZBE6.js} +1 -1
  20. package/dist/{chunk-QIOCFXDQ.js → chunk-EKGMAM62.js} +1 -1
  21. package/dist/chunk-EZ3GOCYC.js +132 -0
  22. package/dist/chunk-GGMI6C2L.js +1075 -0
  23. package/dist/{chunk-DS5QY37M.js → chunk-GTR2TBIJ.js} +247 -15
  24. package/dist/{chunk-QDXI2DHR.js → chunk-J2JEQRT3.js} +1 -1
  25. package/dist/{chunk-AKIMFN6I.js → chunk-JASGXLK3.js} +2 -2
  26. package/dist/{chunk-J4E6K5MG.js → chunk-LSRABQIY.js} +25 -1
  27. package/dist/chunk-MCMOGQMU.js +145 -0
  28. package/dist/{chunk-ZXMDA7VB.js → chunk-PDX44BCA.js} +1 -6
  29. package/dist/{chunk-2SKXFXIT.js → chunk-S3ORKP3V.js} +10 -15
  30. package/dist/{chunk-ZMQA6SCO.js → chunk-S6MZ2IEX.js} +628 -228
  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-LVLRPBAW.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 +290 -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 +3764 -359
  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-Q4XSXFKT.js +40 -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-PMD57BEG.js} +264 -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-HRA2AUS6.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-FLTFTM3P.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 +608 -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/{upgrade-ANX3LVSA.js → upgrade-H5PF32BW.js} +2 -2
  148. package/dist/{validate-GD5XWILV.js → validate-CNKEKO6A.js} +1 -1
  149. package/dist/{validate-ITC5D6QG.js → validate-MB5ULIHS.js} +1 -1
  150. package/dist/{validate-ZVPNN4FL.js → validate-QH3LADM6.js} +1 -1
  151. package/dist/{watch-X64UK7K4.js → watch-2TKP5PVL.js} +3 -3
  152. package/dist/{watch-ERBEJUJW.js → watch-ZF4ML6CD.js} +2 -2
  153. package/dist/{wisdom-L2WC7J62.js → wisdom-AATMGNFA.js} +1 -1
  154. package/dist/work-log-loader-5L45XNYZ.js +14 -0
  155. package/dist/{workspace-UIUTHZTD.js → workspace-6E6OSRNU.js} +4 -4
  156. package/package.json +1 -1
  157. package/platform-ui/dist/assets/DocsSection-ByAgPzWV.js +1 -0
  158. package/platform-ui/dist/assets/DocsSection-CjdO6R-u.css +1 -0
  159. package/platform-ui/dist/assets/{GitSection-BD3Ze06e.js → GitSection-BLovj9yT.js} +1 -1
  160. package/platform-ui/dist/assets/{GraphSection-SglITfSs.js → GraphSection-C5PCPUFl.js} +1 -1
  161. package/platform-ui/dist/assets/{LoreSection-bR5Km4Fd.js → LoreSection-BftejTla.js} +1 -1
  162. package/platform-ui/dist/assets/{SentinelSection-QSpAZArG.js → SentinelSection-CnYcasN7.js} +1 -1
  163. package/platform-ui/dist/assets/{SymphonySection-CobYJgvg.js → SymphonySection-BpmqCHeK.js} +1 -1
  164. package/platform-ui/dist/assets/{index-DbxeSMkV.js → index-G9JnWEs_.js} +10 -10
  165. package/platform-ui/dist/index.html +1 -1
  166. package/dist/dist-PSF5CP4I.js +0 -7294
@@ -1,18 +1,18 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  BackgroundOrchestrator
4
- } from "./chunk-QWA26UNO.js";
5
- import "./chunk-J4E6K5MG.js";
4
+ } from "./chunk-WQITYKHM.js";
5
+ import "./chunk-LSRABQIY.js";
6
6
  import "./chunk-PBHIFAL4.js";
7
- import "./chunk-FS3WTUHY.js";
7
+ import "./chunk-TXESEO7Y.js";
8
8
  import "./chunk-6QC3YGB6.js";
9
9
  import "./chunk-PMXRGPRQ.js";
10
- import "./chunk-MW5DMGBB.js";
11
10
  import "./chunk-5JGJACDU.js";
12
11
  import "./chunk-ZGUAAVMA.js";
13
12
  import "./chunk-EDOAWN7J.js";
14
13
  import "./chunk-IRKUEJVW.js";
15
- import "./chunk-ZXMDA7VB.js";
14
+ import "./chunk-YMDLDELF.js";
15
+ import "./chunk-PDX44BCA.js";
16
16
 
17
17
  // src/commands/team/accept-orchestration.ts
18
18
  import * as path from "path";
@@ -4,7 +4,7 @@ import {
4
4
  saveNote,
5
5
  saveQuiz
6
6
  } from "./chunk-GT5QGC2H.js";
7
- import "./chunk-ZXMDA7VB.js";
7
+ import "./chunk-PDX44BCA.js";
8
8
 
9
9
  // src/commands/university/add.ts
10
10
  import chalk from "chalk";
@@ -0,0 +1,387 @@
1
+ #!/usr/bin/env node
2
+ import {
3
+ log
4
+ } from "./chunk-4NCFWYGG.js";
5
+ import "./chunk-PDX44BCA.js";
6
+
7
+ // src/commands/agent/index.ts
8
+ import * as fs from "fs";
9
+ import * as path from "path";
10
+ import * as os from "os";
11
+ import chalk from "chalk";
12
+ import * as yaml from "js-yaml";
13
+ var GLOBAL_AGENTS_DIR = path.join(os.homedir(), ".paradigm", "agents");
14
+ var PROJECT_AGENTS_DIR = ".paradigm/agents";
15
+ var AGENT_EXT = ".agent";
16
+ var DEFAULT_PERSONALITIES = {
17
+ architect: { style: "deliberate", risk: "conservative", verbosity: "detailed" },
18
+ builder: { style: "rapid", risk: "balanced", verbosity: "concise" },
19
+ tester: { style: "methodical", risk: "conservative", verbosity: "concise" },
20
+ reviewer: { style: "deliberate", risk: "conservative", verbosity: "detailed" },
21
+ security: { style: "methodical", risk: "conservative", verbosity: "detailed" }
22
+ };
23
+ async function agentListCommand(options = {}) {
24
+ const cwd = process.cwd();
25
+ const tracker = log.command("agent-list").start("Listing agent profiles", { cwd });
26
+ const profiles = [];
27
+ if (!options.project && fs.existsSync(GLOBAL_AGENTS_DIR)) {
28
+ try {
29
+ const files = fs.readdirSync(GLOBAL_AGENTS_DIR).filter((f) => f.endsWith(AGENT_EXT));
30
+ for (const file of files) {
31
+ try {
32
+ const content = fs.readFileSync(path.join(GLOBAL_AGENTS_DIR, file), "utf-8");
33
+ const p = yaml.load(content);
34
+ if (p?.id) profiles.push(p);
35
+ } catch {
36
+ }
37
+ }
38
+ } catch {
39
+ }
40
+ }
41
+ const projectDir = path.join(cwd, PROJECT_AGENTS_DIR);
42
+ if (!options.global && fs.existsSync(projectDir)) {
43
+ try {
44
+ const files = fs.readdirSync(projectDir).filter((f) => f.endsWith(AGENT_EXT));
45
+ for (const file of files) {
46
+ try {
47
+ const content = fs.readFileSync(path.join(projectDir, file), "utf-8");
48
+ const p = yaml.load(content);
49
+ if (p?.id) {
50
+ const idx = profiles.findIndex((e) => e.id === p.id);
51
+ if (idx >= 0) profiles[idx] = p;
52
+ else profiles.push(p);
53
+ }
54
+ } catch {
55
+ }
56
+ }
57
+ } catch {
58
+ }
59
+ }
60
+ if (options.json) {
61
+ console.log(JSON.stringify({ count: profiles.length, agents: profiles.map(summarize) }, null, 2));
62
+ tracker.success(`Found ${profiles.length} agents`);
63
+ return;
64
+ }
65
+ console.log(chalk.blue("\n\u250C\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510"));
66
+ console.log(chalk.blue("\u2502") + chalk.white.bold(" paradigm agent list ") + chalk.blue("\u2502"));
67
+ console.log(chalk.blue("\u2502") + chalk.gray(" Persistent agent identity profiles ") + chalk.blue("\u2502"));
68
+ console.log(chalk.blue("\u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518\n"));
69
+ if (profiles.length === 0) {
70
+ console.log(chalk.yellow(" No .agent profiles found."));
71
+ console.log(chalk.gray(" Create one: paradigm agent create <id> --global\n"));
72
+ tracker.success("No agents found");
73
+ return;
74
+ }
75
+ for (const p of profiles) {
76
+ const expertise = (p.expertise || []).sort((a, b) => b.confidence - a.confidence);
77
+ const topSymbols = expertise.slice(0, 3).map(
78
+ (e) => `${e.symbol} (${(e.confidence * 100).toFixed(0)}%)`
79
+ ).join(", ") || chalk.gray("none yet");
80
+ console.log(` ${chalk.white.bold(p.id)} \u2014 ${chalk.gray(p.role)}`);
81
+ console.log(` Style: ${p.personality?.style || "?"} | Risk: ${p.personality?.risk || "?"} | Verbosity: ${p.personality?.verbosity || "?"}`);
82
+ console.log(` Top expertise: ${topSymbols}`);
83
+ console.log(` Projects: ${Object.keys(p.contexts || {}).join(", ") || chalk.gray("none")}`);
84
+ console.log("");
85
+ }
86
+ tracker.success(`Listed ${profiles.length} agents`);
87
+ }
88
+ async function agentShowCommand(id, options = {}) {
89
+ const cwd = process.cwd();
90
+ const tracker = log.command("agent-show").start(`Showing agent ${id}`, { cwd });
91
+ const profile = loadProfile(cwd, id);
92
+ if (!profile) {
93
+ if (options.json) {
94
+ console.log(JSON.stringify({ error: `Agent "${id}" not found` }));
95
+ } else {
96
+ console.log(chalk.red(`
97
+ Agent "${id}" not found.`));
98
+ console.log(chalk.gray(` Create: paradigm agent create ${id} --global
99
+ `));
100
+ }
101
+ tracker.error(`Agent ${id} not found`);
102
+ return;
103
+ }
104
+ if (options.json) {
105
+ console.log(JSON.stringify(profile, null, 2));
106
+ tracker.success(`Showed agent ${id}`);
107
+ return;
108
+ }
109
+ console.log(chalk.blue("\n\u250C\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510"));
110
+ console.log(chalk.blue("\u2502") + chalk.white.bold(` Agent: ${id}`.padEnd(50)) + chalk.blue("\u2502"));
111
+ console.log(chalk.blue("\u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518\n"));
112
+ console.log(` ${chalk.white.bold("Role:")} ${profile.role}`);
113
+ console.log(` ${chalk.white.bold("Description:")} ${profile.description}`);
114
+ console.log(` ${chalk.white.bold("Version:")} ${profile.version}`);
115
+ console.log(` ${chalk.white.bold("Created:")} ${profile.created}`);
116
+ console.log(` ${chalk.white.bold("Updated:")} ${profile.updated}`);
117
+ console.log("");
118
+ if (profile.personality) {
119
+ const p = profile.personality;
120
+ console.log(` ${chalk.white.bold("Personality")}`);
121
+ console.log(` Style: ${p.style} | Risk: ${p.risk} | Verbosity: ${p.verbosity}`);
122
+ console.log("");
123
+ }
124
+ const expertise = (profile.expertise || []).sort((a, b) => b.confidence - a.confidence);
125
+ if (expertise.length > 0) {
126
+ console.log(` ${chalk.white.bold("Expertise")} (${expertise.length} symbols)`);
127
+ console.log(` ${"Symbol".padEnd(30)} ${"Confidence".padEnd(12)} ${"Sessions".padEnd(10)} Last Touch`);
128
+ console.log(` ${"-".repeat(70)}`);
129
+ for (const e of expertise.slice(0, 20)) {
130
+ const conf = `${(e.confidence * 100).toFixed(0)}%`.padEnd(12);
131
+ const sessions = String(e.sessions).padEnd(10);
132
+ const date = e.lastTouch ? e.lastTouch.split("T")[0] : "\u2014";
133
+ console.log(` ${e.symbol.padEnd(30)} ${conf} ${sessions} ${date}`);
134
+ }
135
+ if (expertise.length > 20) {
136
+ console.log(chalk.gray(` ... and ${expertise.length - 20} more`));
137
+ }
138
+ console.log("");
139
+ } else {
140
+ console.log(chalk.gray(" No expertise recorded. Run `paradigm agent sync` to bootstrap from lore.\n"));
141
+ }
142
+ const patterns = profile.transferable || [];
143
+ if (patterns.length > 0) {
144
+ console.log(` ${chalk.white.bold("Transferable Patterns")} (${patterns.length})`);
145
+ for (const p of patterns) {
146
+ console.log(` ${p.id}: ${(p.successRate * 100).toFixed(0)}% success \u2014 ${p.description}`);
147
+ console.log(chalk.gray(` Learned in: ${p.learnedIn} | Applied in: ${p.appliedIn.join(", ") || "none"}`));
148
+ }
149
+ console.log("");
150
+ }
151
+ const contexts = Object.entries(profile.contexts || {});
152
+ if (contexts.length > 0) {
153
+ console.log(` ${chalk.white.bold("Project Contexts")} (${contexts.length})`);
154
+ for (const [name, ctx] of contexts) {
155
+ console.log(` ${chalk.white(name)}: ${ctx.sessionsInProject || 0} sessions, last active ${ctx.lastActive?.split("T")[0] || "\u2014"}`);
156
+ if (ctx.defaultModel) console.log(` Model: ${ctx.defaultModel}`);
157
+ if (ctx.focus?.length) console.log(` Focus: ${ctx.focus.join(", ")}`);
158
+ }
159
+ console.log("");
160
+ }
161
+ const perms = profile.permissions;
162
+ if (perms) {
163
+ console.log(` ${chalk.white.bold("Permissions")}`);
164
+ if (perms.paths?.read?.length) console.log(` Read: ${perms.paths.read.join(", ")}`);
165
+ if (perms.paths?.write?.length) console.log(` Write: ${perms.paths.write.join(", ")}`);
166
+ if (perms.paths?.deny?.length) console.log(` Deny: ${chalk.red(perms.paths.deny.join(", "))}`);
167
+ if (perms.tools?.allow?.length) console.log(` Tools allow: ${perms.tools.allow.join(", ")}`);
168
+ if (perms.tools?.deny?.length) console.log(` Tools deny: ${chalk.red(perms.tools.deny.join(", "))}`);
169
+ if (perms.dangerous_actions?.length) console.log(` Requires approval: ${perms.dangerous_actions.join(", ")}`);
170
+ console.log("");
171
+ }
172
+ tracker.success(`Showed agent ${id}`);
173
+ }
174
+ async function agentCreateCommand(id, options = {}) {
175
+ const cwd = process.cwd();
176
+ const scope = options.global ? "global" : "project";
177
+ const tracker = log.command("agent-create").start(`Creating agent ${id} (${scope})`, { cwd });
178
+ const dir = scope === "global" ? GLOBAL_AGENTS_DIR : path.join(cwd, PROJECT_AGENTS_DIR);
179
+ if (!fs.existsSync(dir)) {
180
+ fs.mkdirSync(dir, { recursive: true });
181
+ }
182
+ const filePath = path.join(dir, `${id}${AGENT_EXT}`);
183
+ if (fs.existsSync(filePath)) {
184
+ console.log(chalk.yellow(`
185
+ Agent "${id}" already exists at ${filePath}`));
186
+ console.log(chalk.gray(" Use `paradigm agent show` to view.\n"));
187
+ tracker.error("Agent already exists");
188
+ return;
189
+ }
190
+ const now = (/* @__PURE__ */ new Date()).toISOString();
191
+ const personality = DEFAULT_PERSONALITIES[id] || { style: "deliberate", risk: "balanced", verbosity: "concise" };
192
+ const profile = {
193
+ id,
194
+ role: options.role || `${id.charAt(0).toUpperCase() + id.slice(1)} agent`,
195
+ description: options.description || `Persistent identity for the ${id} agent role`,
196
+ version: "1.0.0",
197
+ personality,
198
+ expertise: [],
199
+ transferable: [],
200
+ contexts: {},
201
+ created: now,
202
+ updated: now
203
+ };
204
+ if (options.denyPaths) {
205
+ const denyPatterns = options.denyPaths.split(",").map((p) => p.trim());
206
+ profile.permissions = {
207
+ paths: { deny: denyPatterns }
208
+ };
209
+ }
210
+ const content = yaml.dump(profile, { lineWidth: 120, noRefs: true, sortKeys: false });
211
+ fs.writeFileSync(filePath, content, "utf-8");
212
+ console.log(chalk.green(`
213
+ \u2713 Created agent "${id}" at ${filePath}`));
214
+ console.log(chalk.gray(` Run \`paradigm agent sync\` to bootstrap expertise from lore.
215
+ `));
216
+ tracker.success(`Created agent ${id}`);
217
+ }
218
+ async function agentSyncCommand(id, options = {}) {
219
+ const cwd = process.cwd();
220
+ const tracker = log.command("agent-sync").start(`Syncing expertise for ${id}`, { cwd });
221
+ const lorePath = path.join(cwd, ".paradigm", "lore", "entries");
222
+ if (!fs.existsSync(lorePath)) {
223
+ console.log(chalk.yellow("\n No lore directory found. Nothing to sync from.\n"));
224
+ tracker.error("No lore found");
225
+ return;
226
+ }
227
+ let profile = loadProfile(cwd, id);
228
+ if (!profile) {
229
+ if (options.dryRun) {
230
+ console.log(chalk.yellow(`
231
+ Agent "${id}" not found. Would create with --no-dry-run.
232
+ `));
233
+ tracker.success("Dry run \u2014 would create");
234
+ return;
235
+ }
236
+ const scope = fs.existsSync(path.join(GLOBAL_AGENTS_DIR, `${id}${AGENT_EXT}`)) ? "global" : "project";
237
+ const dir = scope === "global" ? GLOBAL_AGENTS_DIR : path.join(cwd, PROJECT_AGENTS_DIR);
238
+ if (!fs.existsSync(dir)) fs.mkdirSync(dir, { recursive: true });
239
+ const now = (/* @__PURE__ */ new Date()).toISOString();
240
+ const personality = DEFAULT_PERSONALITIES[id] || { style: "deliberate", risk: "balanced", verbosity: "concise" };
241
+ profile = {
242
+ id,
243
+ role: `${id.charAt(0).toUpperCase() + id.slice(1)} agent`,
244
+ description: `Persistent identity for the ${id} agent role`,
245
+ version: "1.0.0",
246
+ personality,
247
+ expertise: [],
248
+ transferable: [],
249
+ contexts: {},
250
+ created: now,
251
+ updated: now
252
+ };
253
+ }
254
+ const expertise = profile.expertise || [];
255
+ let entriesProcessed = 0;
256
+ const symbolsUpdated = /* @__PURE__ */ new Set();
257
+ const loreEntries = scanLoreDir(lorePath);
258
+ for (const entry of loreEntries) {
259
+ if (!entry.symbols_touched || entry.symbols_touched.length === 0) continue;
260
+ entriesProcessed++;
261
+ for (const symbol of entry.symbols_touched) {
262
+ symbolsUpdated.add(symbol);
263
+ const existing = expertise.find((e) => e.symbol === symbol);
264
+ if (existing) {
265
+ existing.sessions++;
266
+ existing.lastTouch = entry.timestamp || existing.lastTouch;
267
+ if (entry.confidence != null) {
268
+ existing.confidence = 0.7 * existing.confidence + 0.3 * entry.confidence;
269
+ }
270
+ } else {
271
+ expertise.push({
272
+ symbol,
273
+ confidence: entry.confidence ?? 0.5,
274
+ sessions: 1,
275
+ lastTouch: entry.timestamp || (/* @__PURE__ */ new Date()).toISOString()
276
+ });
277
+ }
278
+ }
279
+ }
280
+ profile.expertise = expertise;
281
+ if (options.json) {
282
+ console.log(JSON.stringify({
283
+ agentId: id,
284
+ entriesProcessed,
285
+ symbolsUpdated: symbolsUpdated.size,
286
+ dryRun: !!options.dryRun,
287
+ topExpertise: expertise.sort((a, b) => b.confidence - a.confidence).slice(0, 10)
288
+ }, null, 2));
289
+ } else {
290
+ console.log(chalk.blue(`
291
+ Syncing expertise for "${id}" from ${entriesProcessed} lore entries...`));
292
+ console.log(` ${chalk.green("\u2713")} ${symbolsUpdated.size} symbols updated`);
293
+ console.log(` ${chalk.green("\u2713")} ${entriesProcessed} entries processed`);
294
+ if (expertise.length > 0) {
295
+ console.log(`
296
+ Top expertise:`);
297
+ for (const e of expertise.sort((a, b) => b.confidence - a.confidence).slice(0, 5)) {
298
+ console.log(` ${e.symbol}: ${(e.confidence * 100).toFixed(0)}% (${e.sessions} sessions)`);
299
+ }
300
+ }
301
+ }
302
+ if (!options.dryRun) {
303
+ profile.updated = (/* @__PURE__ */ new Date()).toISOString();
304
+ const projectPath = path.join(cwd, PROJECT_AGENTS_DIR, `${id}${AGENT_EXT}`);
305
+ const globalPath = path.join(GLOBAL_AGENTS_DIR, `${id}${AGENT_EXT}`);
306
+ const scope = fs.existsSync(projectPath) ? "project" : "global";
307
+ const dir = scope === "global" ? GLOBAL_AGENTS_DIR : path.join(cwd, PROJECT_AGENTS_DIR);
308
+ if (!fs.existsSync(dir)) fs.mkdirSync(dir, { recursive: true });
309
+ const filePath = scope === "global" ? globalPath : projectPath;
310
+ fs.writeFileSync(filePath, yaml.dump(profile, { lineWidth: 120, noRefs: true, sortKeys: false }), "utf-8");
311
+ if (!options.json) {
312
+ console.log(chalk.green(`
313
+ \u2713 Saved to ${filePath}
314
+ `));
315
+ }
316
+ } else if (!options.json) {
317
+ console.log(chalk.yellow("\n Dry run \u2014 no changes written.\n"));
318
+ }
319
+ tracker.success(`Synced ${symbolsUpdated.size} symbols from ${entriesProcessed} entries`);
320
+ }
321
+ function loadProfile(rootDir, id) {
322
+ const projectPath = path.join(rootDir, PROJECT_AGENTS_DIR, `${id}${AGENT_EXT}`);
323
+ if (fs.existsSync(projectPath)) {
324
+ try {
325
+ return yaml.load(fs.readFileSync(projectPath, "utf-8"));
326
+ } catch {
327
+ }
328
+ }
329
+ const globalPath = path.join(GLOBAL_AGENTS_DIR, `${id}${AGENT_EXT}`);
330
+ if (fs.existsSync(globalPath)) {
331
+ try {
332
+ return yaml.load(fs.readFileSync(globalPath, "utf-8"));
333
+ } catch {
334
+ }
335
+ }
336
+ return null;
337
+ }
338
+ function summarize(p) {
339
+ return {
340
+ id: p.id,
341
+ role: p.role,
342
+ personality: p.personality,
343
+ expertiseCount: (p.expertise || []).length,
344
+ topExpertise: (p.expertise || []).sort((a, b) => b.confidence - a.confidence).slice(0, 3).map((e) => ({
345
+ symbol: e.symbol,
346
+ confidence: parseFloat(e.confidence.toFixed(2))
347
+ })),
348
+ projectContexts: Object.keys(p.contexts || {}),
349
+ transferableCount: (p.transferable || []).length
350
+ };
351
+ }
352
+ function scanLoreDir(lorePath) {
353
+ const entries = [];
354
+ try {
355
+ const items = fs.readdirSync(lorePath, { withFileTypes: true });
356
+ for (const item of items) {
357
+ if (!item.isDirectory()) continue;
358
+ const dayDir = path.join(lorePath, item.name);
359
+ try {
360
+ const files = fs.readdirSync(dayDir).filter((f) => f.endsWith(".yaml") || f.endsWith(".yml"));
361
+ for (const file of files) {
362
+ try {
363
+ const content = fs.readFileSync(path.join(dayDir, file), "utf-8");
364
+ const data = yaml.load(content);
365
+ if (data?.symbols_touched && Array.isArray(data.symbols_touched)) {
366
+ entries.push({
367
+ symbols_touched: data.symbols_touched,
368
+ confidence: typeof data.confidence === "number" ? data.confidence : void 0,
369
+ timestamp: data.timestamp || item.name
370
+ });
371
+ }
372
+ } catch {
373
+ }
374
+ }
375
+ } catch {
376
+ }
377
+ }
378
+ } catch {
379
+ }
380
+ return entries;
381
+ }
382
+ export {
383
+ agentCreateCommand,
384
+ agentListCommand,
385
+ agentShowCommand,
386
+ agentSyncCommand
387
+ };
@@ -0,0 +1,36 @@
1
+ #!/usr/bin/env node
2
+ import {
3
+ buildProfileEnrichment,
4
+ checkPathPermission,
5
+ checkToolPermission,
6
+ computeIntegrityHash,
7
+ createAgentProfile,
8
+ init_agent_loader,
9
+ loadAgentProfile,
10
+ loadAllAgentProfiles,
11
+ mergeAgentProfileWithManifest,
12
+ queryExpertise,
13
+ saveAgentProfile,
14
+ syncExpertiseFromLore,
15
+ updateExpertiseFromAssessment,
16
+ updateExpertiseFromLore,
17
+ verifyIntegrity
18
+ } from "./chunk-A2L4TSLZ.js";
19
+ import "./chunk-7N7GSU6K.js";
20
+ init_agent_loader();
21
+ export {
22
+ buildProfileEnrichment,
23
+ checkPathPermission,
24
+ checkToolPermission,
25
+ computeIntegrityHash,
26
+ createAgentProfile,
27
+ loadAgentProfile,
28
+ loadAllAgentProfiles,
29
+ mergeAgentProfileWithManifest,
30
+ queryExpertise,
31
+ saveAgentProfile,
32
+ syncExpertiseFromLore,
33
+ updateExpertiseFromAssessment,
34
+ updateExpertiseFromLore,
35
+ verifyIntegrity
36
+ };
@@ -5,7 +5,7 @@ import {
5
5
  import {
6
6
  loadAgentsManifest
7
7
  } from "./chunk-PMXRGPRQ.js";
8
- import "./chunk-ZXMDA7VB.js";
8
+ import "./chunk-PDX44BCA.js";
9
9
 
10
10
  // src/commands/team/agents-suggest.ts
11
11
  import chalk from "chalk";
@@ -8,7 +8,7 @@ import {
8
8
  } from "./chunk-ZGUAAVMA.js";
9
9
  import "./chunk-EDOAWN7J.js";
10
10
  import "./chunk-IRKUEJVW.js";
11
- import "./chunk-ZXMDA7VB.js";
11
+ import "./chunk-PDX44BCA.js";
12
12
 
13
13
  // src/commands/premise/aggregate.ts
14
14
  import * as fs from "fs";
@@ -2,8 +2,8 @@
2
2
  import {
3
3
  addAssessment,
4
4
  loadLoreEntry
5
- } from "./chunk-QIOCFXDQ.js";
6
- import "./chunk-ZXMDA7VB.js";
5
+ } from "./chunk-EKGMAM62.js";
6
+ import "./chunk-PDX44BCA.js";
7
7
 
8
8
  // src/commands/lore/assess.ts
9
9
  import chalk from "chalk";
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  getDisciplineScanPatterns
4
4
  } from "./chunk-UPLDI7CN.js";
5
- import "./chunk-ZXMDA7VB.js";
5
+ import "./chunk-PDX44BCA.js";
6
6
 
7
7
  // src/commands/scan/auto.ts
8
8
  import * as fs from "fs";
@@ -10,7 +10,7 @@ import "./chunk-IRKUEJVW.js";
10
10
  import {
11
11
  log
12
12
  } from "./chunk-4NCFWYGG.js";
13
- import "./chunk-ZXMDA7VB.js";
13
+ import "./chunk-PDX44BCA.js";
14
14
 
15
15
  // src/commands/beacon.ts
16
16
  import * as fs from "fs";
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  loadLoreEntries
4
- } from "./chunk-QIOCFXDQ.js";
5
- import "./chunk-ZXMDA7VB.js";
4
+ } from "./chunk-EKGMAM62.js";
5
+ import "./chunk-PDX44BCA.js";
6
6
 
7
7
  // src/commands/lore/calibration.ts
8
8
  import chalk from "chalk";
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import "./chunk-ZXMDA7VB.js";
2
+ import "./chunk-PDX44BCA.js";
3
3
 
4
4
  // src/commands/plugin/check.ts
5
5
  import * as fs from "fs";
@@ -8,7 +8,7 @@ import {
8
8
  syncToIDE,
9
9
  writeMcpConfig,
10
10
  writeNestedContexts
11
- } from "./chunk-KB4XJWE3.js";
11
+ } from "./chunk-6N3JTACN.js";
12
12
  import {
13
13
  log
14
14
  } from "./chunk-4NCFWYGG.js";