@mrciphersmith/keryx 0.2.137 → 0.2.140
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.
- package/dist/cli.js +244 -21
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -51141,7 +51141,7 @@ import path47 from "path";
|
|
|
51141
51141
|
// package.json
|
|
51142
51142
|
var package_default = {
|
|
51143
51143
|
name: "@mrciphersmith/keryx",
|
|
51144
|
-
version: "0.2.
|
|
51144
|
+
version: "0.2.140",
|
|
51145
51145
|
description: "Version-controlled project context for AI coding agents: code graph, architecture wiki, project memory, relevant tests, quality signals, and task flows.",
|
|
51146
51146
|
private: false,
|
|
51147
51147
|
publishConfig: {
|
|
@@ -91315,9 +91315,23 @@ class LiveMarkdownBlock {
|
|
|
91315
91315
|
init_config_dir();
|
|
91316
91316
|
import { existsSync as existsSync33 } from "fs";
|
|
91317
91317
|
import path192 from "path";
|
|
91318
|
-
var THEME_NAMES = [
|
|
91318
|
+
var THEME_NAMES = [
|
|
91319
|
+
"groknight",
|
|
91320
|
+
"tokyonight",
|
|
91321
|
+
"keryx",
|
|
91322
|
+
"midnight",
|
|
91323
|
+
"nord",
|
|
91324
|
+
"ember",
|
|
91325
|
+
"violet",
|
|
91326
|
+
"grokday",
|
|
91327
|
+
"paper",
|
|
91328
|
+
"frost",
|
|
91329
|
+
"sand",
|
|
91330
|
+
"mint"
|
|
91331
|
+
];
|
|
91319
91332
|
var THEME_IDS = ["auto", ...THEME_NAMES];
|
|
91320
91333
|
var DEFAULT_THEME_ID = "groknight";
|
|
91334
|
+
var LIGHT_THEME_NAMES = new Set(["grokday", "paper", "frost", "sand", "mint"]);
|
|
91321
91335
|
var THEMES = {
|
|
91322
91336
|
groknight: {
|
|
91323
91337
|
name: "groknight",
|
|
@@ -91358,7 +91372,7 @@ var THEMES = {
|
|
|
91358
91372
|
highlight: "#292e42",
|
|
91359
91373
|
border: "#3b4261",
|
|
91360
91374
|
text: "#c0caf5",
|
|
91361
|
-
muted: "#
|
|
91375
|
+
muted: "#737da8",
|
|
91362
91376
|
user: "#a9b1d6",
|
|
91363
91377
|
assistant: "#bb9af7",
|
|
91364
91378
|
tool: "#7aa2f7",
|
|
@@ -91382,6 +91396,134 @@ var THEMES = {
|
|
|
91382
91396
|
focus: "#ffd166",
|
|
91383
91397
|
error: "#e05a5a",
|
|
91384
91398
|
ok: "#6bcf6b"
|
|
91399
|
+
},
|
|
91400
|
+
midnight: {
|
|
91401
|
+
name: "midnight",
|
|
91402
|
+
bg: "#080d18",
|
|
91403
|
+
panel: "#101827",
|
|
91404
|
+
highlight: "#17233a",
|
|
91405
|
+
border: "#40577a",
|
|
91406
|
+
text: "#dbe7ff",
|
|
91407
|
+
muted: "#8292ad",
|
|
91408
|
+
user: "#a9c7ff",
|
|
91409
|
+
assistant: "#8bd5ca",
|
|
91410
|
+
tool: "#7aa2f7",
|
|
91411
|
+
side: "#c6a0f6",
|
|
91412
|
+
focus: "#f5c26b",
|
|
91413
|
+
error: "#ff7a90",
|
|
91414
|
+
ok: "#83d17f"
|
|
91415
|
+
},
|
|
91416
|
+
nord: {
|
|
91417
|
+
name: "nord",
|
|
91418
|
+
bg: "#242933",
|
|
91419
|
+
panel: "#2e3440",
|
|
91420
|
+
highlight: "#3b4252",
|
|
91421
|
+
border: "#5e6b80",
|
|
91422
|
+
text: "#eceff4",
|
|
91423
|
+
muted: "#929db0",
|
|
91424
|
+
user: "#d8dee9",
|
|
91425
|
+
assistant: "#88c0d0",
|
|
91426
|
+
tool: "#81a1c1",
|
|
91427
|
+
side: "#b48ead",
|
|
91428
|
+
focus: "#ebcb8b",
|
|
91429
|
+
error: "#f0808b",
|
|
91430
|
+
ok: "#a3be8c"
|
|
91431
|
+
},
|
|
91432
|
+
ember: {
|
|
91433
|
+
name: "ember",
|
|
91434
|
+
bg: "#17100d",
|
|
91435
|
+
panel: "#211713",
|
|
91436
|
+
highlight: "#30201a",
|
|
91437
|
+
border: "#6a4d3d",
|
|
91438
|
+
text: "#f2e3d5",
|
|
91439
|
+
muted: "#a48672",
|
|
91440
|
+
user: "#ffd2ad",
|
|
91441
|
+
assistant: "#ff9f68",
|
|
91442
|
+
tool: "#e1b274",
|
|
91443
|
+
side: "#d89b72",
|
|
91444
|
+
focus: "#ffd166",
|
|
91445
|
+
error: "#ff7676",
|
|
91446
|
+
ok: "#a6d27a"
|
|
91447
|
+
},
|
|
91448
|
+
violet: {
|
|
91449
|
+
name: "violet",
|
|
91450
|
+
bg: "#100b1b",
|
|
91451
|
+
panel: "#1a1227",
|
|
91452
|
+
highlight: "#281b3c",
|
|
91453
|
+
border: "#61497d",
|
|
91454
|
+
text: "#eee8ff",
|
|
91455
|
+
muted: "#9f8db8",
|
|
91456
|
+
user: "#d6c4ff",
|
|
91457
|
+
assistant: "#c099ff",
|
|
91458
|
+
tool: "#76b7ff",
|
|
91459
|
+
side: "#ff8cc6",
|
|
91460
|
+
focus: "#ffd166",
|
|
91461
|
+
error: "#ff7699",
|
|
91462
|
+
ok: "#7bdba5"
|
|
91463
|
+
},
|
|
91464
|
+
paper: {
|
|
91465
|
+
name: "paper",
|
|
91466
|
+
bg: "#faf7f0",
|
|
91467
|
+
panel: "#f1ece1",
|
|
91468
|
+
highlight: "#e5ddcf",
|
|
91469
|
+
border: "#9d9280",
|
|
91470
|
+
text: "#29251f",
|
|
91471
|
+
muted: "#746d62",
|
|
91472
|
+
user: "#4b4033",
|
|
91473
|
+
assistant: "#6b4bbc",
|
|
91474
|
+
tool: "#1f62a8",
|
|
91475
|
+
side: "#8a4f72",
|
|
91476
|
+
focus: "#815500",
|
|
91477
|
+
error: "#b4233c",
|
|
91478
|
+
ok: "#2e7d32"
|
|
91479
|
+
},
|
|
91480
|
+
frost: {
|
|
91481
|
+
name: "frost",
|
|
91482
|
+
bg: "#f4f8fb",
|
|
91483
|
+
panel: "#eaf1f6",
|
|
91484
|
+
highlight: "#dbe8f0",
|
|
91485
|
+
border: "#93a8b7",
|
|
91486
|
+
text: "#1f2d3a",
|
|
91487
|
+
muted: "#627483",
|
|
91488
|
+
user: "#314c65",
|
|
91489
|
+
assistant: "#5b4bb7",
|
|
91490
|
+
tool: "#1769aa",
|
|
91491
|
+
side: "#794ca8",
|
|
91492
|
+
focus: "#805400",
|
|
91493
|
+
error: "#b32642",
|
|
91494
|
+
ok: "#2d7544"
|
|
91495
|
+
},
|
|
91496
|
+
sand: {
|
|
91497
|
+
name: "sand",
|
|
91498
|
+
bg: "#fff7e8",
|
|
91499
|
+
panel: "#f6ead5",
|
|
91500
|
+
highlight: "#ead9bb",
|
|
91501
|
+
border: "#ad936d",
|
|
91502
|
+
text: "#33291d",
|
|
91503
|
+
muted: "#776751",
|
|
91504
|
+
user: "#5b4630",
|
|
91505
|
+
assistant: "#744494",
|
|
91506
|
+
tool: "#176b75",
|
|
91507
|
+
side: "#91483b",
|
|
91508
|
+
focus: "#805400",
|
|
91509
|
+
error: "#b3263b",
|
|
91510
|
+
ok: "#347536"
|
|
91511
|
+
},
|
|
91512
|
+
mint: {
|
|
91513
|
+
name: "mint",
|
|
91514
|
+
bg: "#f2faf7",
|
|
91515
|
+
panel: "#e4f3ed",
|
|
91516
|
+
highlight: "#d3e9e0",
|
|
91517
|
+
border: "#8fafa3",
|
|
91518
|
+
text: "#19332a",
|
|
91519
|
+
muted: "#5d776d",
|
|
91520
|
+
user: "#285548",
|
|
91521
|
+
assistant: "#6745a6",
|
|
91522
|
+
tool: "#176b72",
|
|
91523
|
+
side: "#86506b",
|
|
91524
|
+
focus: "#805400",
|
|
91525
|
+
error: "#b32643",
|
|
91526
|
+
ok: "#217343"
|
|
91385
91527
|
}
|
|
91386
91528
|
};
|
|
91387
91529
|
var kind = DEFAULT_THEME_ID;
|
|
@@ -91419,14 +91561,8 @@ function themeLabel(id) {
|
|
|
91419
91561
|
switch (id) {
|
|
91420
91562
|
case "auto":
|
|
91421
91563
|
return "auto (follow terminal)";
|
|
91422
|
-
|
|
91423
|
-
return
|
|
91424
|
-
case "grokday":
|
|
91425
|
-
return "grokday";
|
|
91426
|
-
case "tokyonight":
|
|
91427
|
-
return "tokyonight";
|
|
91428
|
-
case "keryx":
|
|
91429
|
-
return "keryx";
|
|
91564
|
+
default:
|
|
91565
|
+
return LIGHT_THEME_NAMES.has(id) ? `${id} \u2600` : id;
|
|
91430
91566
|
}
|
|
91431
91567
|
}
|
|
91432
91568
|
function applyThemeId(id, mode = null) {
|
|
@@ -92550,18 +92686,23 @@ function createBlockView(otui, renderer, parent, block, options = {}) {
|
|
|
92550
92686
|
}
|
|
92551
92687
|
function appendUserEcho(otui, renderer, parent, options) {
|
|
92552
92688
|
const text = `${options.marker ?? "\u276F"} ${options.line}`;
|
|
92689
|
+
const fullWidth = options.fullWidth === true;
|
|
92553
92690
|
const box = new otui.BoxRenderable(renderer, {
|
|
92554
92691
|
id: options.id,
|
|
92555
|
-
borderStyle: "rounded",
|
|
92556
|
-
border: true,
|
|
92557
|
-
borderColor: options.borderColor ?? frameColor(),
|
|
92692
|
+
borderStyle: fullWidth ? "single" : "rounded",
|
|
92693
|
+
border: fullWidth ? ["left"] : true,
|
|
92694
|
+
borderColor: options.borderColor ?? (fullWidth ? getTheme().user : frameColor()),
|
|
92695
|
+
...fullWidth ? { width: "100%", backgroundColor: getTheme().panel } : { maxWidth: hugWidth(text, FRAME_CHROME) },
|
|
92558
92696
|
paddingLeft: 1,
|
|
92559
92697
|
paddingRight: 1,
|
|
92560
92698
|
marginTop: options.marginTop ?? 1,
|
|
92561
|
-
flexShrink: 0
|
|
92562
|
-
maxWidth: hugWidth(text, FRAME_CHROME)
|
|
92699
|
+
flexShrink: 0
|
|
92563
92700
|
});
|
|
92564
|
-
box.add(new otui.TextRenderable(renderer, {
|
|
92701
|
+
box.add(new otui.TextRenderable(renderer, {
|
|
92702
|
+
id: `${options.id}-t`,
|
|
92703
|
+
content: fullWidth ? text : otui.t`${otui.dim(text)}`,
|
|
92704
|
+
...fullWidth ? { fg: getTheme().user, wrapMode: "word" } : {}
|
|
92705
|
+
}));
|
|
92565
92706
|
parent.add(box);
|
|
92566
92707
|
return box;
|
|
92567
92708
|
}
|
|
@@ -92897,6 +93038,7 @@ function innerWidthOf(state) {
|
|
|
92897
93038
|
}
|
|
92898
93039
|
function paintTabs(state) {
|
|
92899
93040
|
clearTranscriptChildren(state.tabStrip);
|
|
93041
|
+
const theme = getTheme();
|
|
92900
93042
|
for (const [index, tab] of state.tabs.entries()) {
|
|
92901
93043
|
const active = tab.id === state.active;
|
|
92902
93044
|
const label = active ? `[${tab.label}]` : ` ${tab.label} `;
|
|
@@ -92904,6 +93046,7 @@ function paintTabs(state) {
|
|
|
92904
93046
|
state.tabStrip.add(new state.otui.TextRenderable(state.chrome.renderer, {
|
|
92905
93047
|
id: `modal-tab-${tab.id}`,
|
|
92906
93048
|
content: active ? state.otui.t`${prefix}${state.otui.bold(label)}` : state.otui.t`${prefix}${state.otui.dim(label)}`,
|
|
93049
|
+
fg: active ? theme.focus : theme.muted,
|
|
92907
93050
|
onMouseDown: () => {
|
|
92908
93051
|
if (!state.open || state.input === undefined || tab.id === state.active) {
|
|
92909
93052
|
return;
|
|
@@ -93012,12 +93155,14 @@ function ensureHost(otui, chrome) {
|
|
|
93012
93155
|
const titleText = new otui.TextRenderable(r, {
|
|
93013
93156
|
id: "modal-title",
|
|
93014
93157
|
content: "",
|
|
93015
|
-
flexGrow: 1
|
|
93158
|
+
flexGrow: 1,
|
|
93159
|
+
fg: getTheme().text
|
|
93016
93160
|
});
|
|
93017
93161
|
const closeText = new otui.TextRenderable(r, {
|
|
93018
93162
|
id: "modal-close",
|
|
93019
93163
|
content: "",
|
|
93020
93164
|
flexShrink: 0,
|
|
93165
|
+
fg: getTheme().muted,
|
|
93021
93166
|
onMouseDown: () => {
|
|
93022
93167
|
const current = hosts.get(r);
|
|
93023
93168
|
if (current !== undefined && current.open) {
|
|
@@ -93054,7 +93199,8 @@ function ensureHost(otui, chrome) {
|
|
|
93054
93199
|
});
|
|
93055
93200
|
const footerText = new otui.TextRenderable(r, {
|
|
93056
93201
|
id: "modal-footer-text",
|
|
93057
|
-
content: ""
|
|
93202
|
+
content: "",
|
|
93203
|
+
fg: getTheme().text
|
|
93058
93204
|
});
|
|
93059
93205
|
footer.add(footerText);
|
|
93060
93206
|
panel.add(header);
|
|
@@ -93156,6 +93302,10 @@ function ensureHost(otui, chrome) {
|
|
|
93156
93302
|
state.backdrop.backgroundColor = theme.bg;
|
|
93157
93303
|
state.panel.backgroundColor = theme.panel;
|
|
93158
93304
|
state.panel.borderColor = theme.border;
|
|
93305
|
+
state.titleText.fg = theme.text;
|
|
93306
|
+
state.closeText.fg = theme.muted;
|
|
93307
|
+
state.footerText.fg = theme.text;
|
|
93308
|
+
paintTabs(state);
|
|
93159
93309
|
});
|
|
93160
93310
|
return state;
|
|
93161
93311
|
}
|
|
@@ -95122,6 +95272,27 @@ async function createShellChrome(otui, renderer, opts) {
|
|
|
95122
95272
|
target.content = text.length === 0 ? "" : otui.t`${otui.dim(text)}`;
|
|
95123
95273
|
};
|
|
95124
95274
|
paintDim(headerRight, opts.headerMeta ?? "");
|
|
95275
|
+
const promptPin = new otui.BoxRenderable(r, {
|
|
95276
|
+
id: "prompt-pin",
|
|
95277
|
+
flexShrink: 0,
|
|
95278
|
+
width: "100%",
|
|
95279
|
+
height: 1,
|
|
95280
|
+
visible: false,
|
|
95281
|
+
border: ["left"],
|
|
95282
|
+
borderColor: getTheme().user,
|
|
95283
|
+
backgroundColor: getTheme().highlight,
|
|
95284
|
+
paddingLeft: 1,
|
|
95285
|
+
paddingRight: 1
|
|
95286
|
+
});
|
|
95287
|
+
const promptPinText = new otui.TextRenderable(r, {
|
|
95288
|
+
id: "prompt-pin-text",
|
|
95289
|
+
content: "",
|
|
95290
|
+
fg: getTheme().user,
|
|
95291
|
+
wrapMode: "none",
|
|
95292
|
+
truncate: true
|
|
95293
|
+
});
|
|
95294
|
+
promptPin.add(promptPinText);
|
|
95295
|
+
main.add(promptPin);
|
|
95125
95296
|
const scroll = new otui.ScrollBoxRenderable(r, {
|
|
95126
95297
|
id: "transcript",
|
|
95127
95298
|
flexGrow: 1,
|
|
@@ -95138,6 +95309,36 @@ async function createShellChrome(otui, renderer, opts) {
|
|
|
95138
95309
|
});
|
|
95139
95310
|
main.add(scroll);
|
|
95140
95311
|
const transcript = scroll.content;
|
|
95312
|
+
const userPrompts = [];
|
|
95313
|
+
let pinnedPrompt;
|
|
95314
|
+
const syncPromptPin = () => {
|
|
95315
|
+
let active;
|
|
95316
|
+
for (let i = userPrompts.length - 1;i >= 0; i -= 1) {
|
|
95317
|
+
const candidate = userPrompts[i];
|
|
95318
|
+
if (candidate === undefined)
|
|
95319
|
+
continue;
|
|
95320
|
+
if (candidate.box.parent !== transcript) {
|
|
95321
|
+
userPrompts.splice(i, 1);
|
|
95322
|
+
continue;
|
|
95323
|
+
}
|
|
95324
|
+
const logicalTop = candidate.box.y - transcript.y;
|
|
95325
|
+
if (logicalTop < scroll.scrollTop) {
|
|
95326
|
+
active = candidate;
|
|
95327
|
+
break;
|
|
95328
|
+
}
|
|
95329
|
+
}
|
|
95330
|
+
if (active?.box === pinnedPrompt?.box)
|
|
95331
|
+
return;
|
|
95332
|
+
pinnedPrompt = active;
|
|
95333
|
+
promptPin.visible = active !== undefined;
|
|
95334
|
+
promptPinText.content = active === undefined ? "" : `\u21A5 \u276F ${active.line}`;
|
|
95335
|
+
};
|
|
95336
|
+
const registerUserPrompt = (box, line) => {
|
|
95337
|
+
if (line.length === 0 || userPrompts.some((item) => item.box === box))
|
|
95338
|
+
return;
|
|
95339
|
+
userPrompts.push({ box, line });
|
|
95340
|
+
};
|
|
95341
|
+
r.on(otui.CliRenderEvents.FRAME, syncPromptPin);
|
|
95141
95342
|
let liveStatus;
|
|
95142
95343
|
const originalTranscriptAdd = transcript.add.bind(transcript);
|
|
95143
95344
|
const originalTranscriptRemove = transcript.remove.bind(transcript);
|
|
@@ -95551,6 +95752,9 @@ async function createShellChrome(otui, renderer, opts) {
|
|
|
95551
95752
|
sidebar.borderColor = theme.border;
|
|
95552
95753
|
sidebar.backgroundColor = theme.panel;
|
|
95553
95754
|
header.backgroundColor = theme.bg;
|
|
95755
|
+
promptPin.borderColor = theme.user;
|
|
95756
|
+
promptPin.backgroundColor = theme.highlight;
|
|
95757
|
+
promptPinText.fg = theme.user;
|
|
95554
95758
|
footer.backgroundColor = theme.bg;
|
|
95555
95759
|
dock.backgroundColor = theme.panel;
|
|
95556
95760
|
dock.borderColor = theme.border;
|
|
@@ -95594,6 +95798,7 @@ async function createShellChrome(otui, renderer, opts) {
|
|
|
95594
95798
|
sidebarTop,
|
|
95595
95799
|
sidebarScroll: sidebarTopScroll,
|
|
95596
95800
|
header,
|
|
95801
|
+
promptPin,
|
|
95597
95802
|
scroll,
|
|
95598
95803
|
transcript,
|
|
95599
95804
|
dock,
|
|
@@ -95603,6 +95808,8 @@ async function createShellChrome(otui, renderer, opts) {
|
|
|
95603
95808
|
textarea,
|
|
95604
95809
|
footer,
|
|
95605
95810
|
input,
|
|
95811
|
+
registerUserPrompt,
|
|
95812
|
+
pinnedUserPrompt: () => pinnedPrompt?.line,
|
|
95606
95813
|
focusComposer: () => {
|
|
95607
95814
|
textarea.focus();
|
|
95608
95815
|
},
|
|
@@ -95663,6 +95870,9 @@ async function createShellChrome(otui, renderer, opts) {
|
|
|
95663
95870
|
try {
|
|
95664
95871
|
r.off(otui.CliRenderEvents.SELECTION, onSelection);
|
|
95665
95872
|
} catch {}
|
|
95873
|
+
try {
|
|
95874
|
+
r.off(otui.CliRenderEvents.FRAME, syncPromptPin);
|
|
95875
|
+
} catch {}
|
|
95666
95876
|
}
|
|
95667
95877
|
};
|
|
95668
95878
|
}
|
|
@@ -106652,7 +106862,12 @@ Usage: /reasoning <${REASONING_EFFORT_LEVELS.join("|")}>
|
|
|
106652
106862
|
}
|
|
106653
106863
|
return;
|
|
106654
106864
|
}
|
|
106655
|
-
appendUserEcho(otui, r, transcript, {
|
|
106865
|
+
const userEcho = appendUserEcho(otui, r, transcript, {
|
|
106866
|
+
id: `ub${uid++}`,
|
|
106867
|
+
line: displayLine,
|
|
106868
|
+
fullWidth: true
|
|
106869
|
+
});
|
|
106870
|
+
chrome.registerUserPrompt(userEcho, displayLine);
|
|
106656
106871
|
transcript.add(new otui.TextRenderable(r, {
|
|
106657
106872
|
id: `h${uid++}`,
|
|
106658
106873
|
content: otui.t`${otui.cyan("\u25CF")} ${otui.bold("keryx")} ${otui.dim(hhmm())}`,
|
|
@@ -107130,7 +107345,15 @@ async function mountChatShell(otui, renderer, opts) {
|
|
|
107130
107345
|
const bridge = createChatBridge({
|
|
107131
107346
|
onAccepted: (line) => {
|
|
107132
107347
|
const displayLine = line.startsWith("/") ? line : summarizeSubmittedLine(line);
|
|
107133
|
-
|
|
107348
|
+
const isCommand = line.startsWith("/");
|
|
107349
|
+
const userEcho = appendUserEcho(otui, r, transcript, {
|
|
107350
|
+
id: `ub${uid++}`,
|
|
107351
|
+
line: displayLine,
|
|
107352
|
+
fullWidth: !isCommand
|
|
107353
|
+
});
|
|
107354
|
+
if (!isCommand) {
|
|
107355
|
+
chrome.registerUserPrompt(userEcho, displayLine);
|
|
107356
|
+
}
|
|
107134
107357
|
if (!line.startsWith("/")) {
|
|
107135
107358
|
seen.push({ content: line });
|
|
107136
107359
|
paintContext();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mrciphersmith/keryx",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.140",
|
|
4
4
|
"description": "Version-controlled project context for AI coding agents: code graph, architecture wiki, project memory, relevant tests, quality signals, and task flows.",
|
|
5
5
|
"private": false,
|
|
6
6
|
"publishConfig": {
|