priiisk 0.1.12 → 0.1.13
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/{chunk-YYTSIIJP.js → chunk-7AGSTD6B.js} +2 -2
- package/dist/{chunk-A2W4SB7S.js → chunk-A4K4VHXE.js} +1 -1
- package/dist/{chunk-52IFMQA3.js → chunk-GPJJE2V7.js} +2 -2
- package/dist/{chunk-2HT6CW56.js → chunk-HK2LW6VV.js} +11 -1
- package/dist/{chunk-UMKSDJZP.js → chunk-M2NR2CXX.js} +3 -3
- package/dist/{chunk-JAEJXLWU.js → chunk-TI75FDW3.js} +1 -1
- package/dist/{chunk-6JECMSIQ.js → chunk-XVKL4E3L.js} +91 -26
- package/dist/priiisk-host.js +10 -7
- package/dist/priiisk.js +6 -6
- package/package.json +10 -10
- /package/dist/{chunk-52IFMQA3.js.LEGAL.txt → chunk-GPJJE2V7.js.LEGAL.txt} +0 -0
- /package/dist/{chunk-JAEJXLWU.js.LEGAL.txt → chunk-TI75FDW3.js.LEGAL.txt} +0 -0
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
layerNet,
|
|
21
21
|
makeCampSurfaceName,
|
|
22
22
|
resolveProjectScopeSync
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-GPJJE2V7.js";
|
|
24
24
|
import {
|
|
25
25
|
Clock_exports,
|
|
26
26
|
Config_exports,
|
|
@@ -112,7 +112,7 @@ var CliSurfaceSelectionError = class extends Data_exports.TaggedError("CliSurfac
|
|
|
112
112
|
import { randomUUID } from "node:crypto";
|
|
113
113
|
|
|
114
114
|
// packages/cli/src/domain/cliVersion.ts
|
|
115
|
-
var PRIIISK_CLI_VERSION = "0.1.
|
|
115
|
+
var PRIIISK_CLI_VERSION = "0.1.13";
|
|
116
116
|
|
|
117
117
|
// packages/cli/src/client/campRpcConnection.ts
|
|
118
118
|
var reportRetry = (options, diagnostic) => options.onRetry === void 0 ? Console_exports.error(
|
|
@@ -10670,7 +10670,7 @@ var describeDirectToolSandbox = (sandbox2) => sandbox2.kind === DirectToolSandbo
|
|
|
10670
10670
|
|
|
10671
10671
|
// packages/protocol/src/domain/protocolVersion.ts
|
|
10672
10672
|
var PRIIISK_PROTOCOL_VERSION = "12";
|
|
10673
|
-
var PRIIISK_PROTOCOL_PACKAGE_VERSION = "0.1.
|
|
10673
|
+
var PRIIISK_PROTOCOL_PACKAGE_VERSION = "0.1.13";
|
|
10674
10674
|
var ProtocolVersionSchema = Schema_exports.String.pipe(Schema_exports.minLength(1));
|
|
10675
10675
|
|
|
10676
10676
|
// packages/protocol/src/domain/protocolIdentifiers.ts
|
|
@@ -13564,7 +13564,7 @@ var CampProtocol = class extends RpcGroup_exports.make(
|
|
|
13564
13564
|
};
|
|
13565
13565
|
|
|
13566
13566
|
// packages/camp-state/src/bootstrap/campHostVersion.ts
|
|
13567
|
-
var PRIIISK_HOST_VERSION = "0.1.
|
|
13567
|
+
var PRIIISK_HOST_VERSION = "0.1.13";
|
|
13568
13568
|
|
|
13569
13569
|
// packages/surface/src/domain/surfaceModel.ts
|
|
13570
13570
|
var NonEmptyString7 = Schema_exports.String.pipe(Schema_exports.minLength(1));
|
|
@@ -30,12 +30,16 @@ import {
|
|
|
30
30
|
PiCampRunSelectorRoot,
|
|
31
31
|
PiCampUiRoot,
|
|
32
32
|
allocateCampUiSectionRows,
|
|
33
|
+
cachedCampUiBlock,
|
|
33
34
|
campUiAskBlockId,
|
|
35
|
+
campUiBlockCacheSize,
|
|
34
36
|
campUiEquipmentBlockRenderer,
|
|
35
37
|
campUiExploredReadPath,
|
|
36
38
|
campUiExploredReadRange,
|
|
39
|
+
campUiMessageSignature,
|
|
37
40
|
campUiPendingAskBlockRenderer,
|
|
38
41
|
campUiPendingAskTargets,
|
|
42
|
+
campUiResultSignature,
|
|
39
43
|
campUiSubscriptionRetryDelay,
|
|
40
44
|
campUiToolResultCacheSize,
|
|
41
45
|
campUiTranscriptBlockRenderer,
|
|
@@ -80,13 +84,14 @@ import {
|
|
|
80
84
|
renderCampUiToolResult,
|
|
81
85
|
renderCampUiWorkerState,
|
|
82
86
|
renderSelectedCampUiRow,
|
|
87
|
+
resetCampUiBlockCache,
|
|
83
88
|
resetCampUiToolResultCache,
|
|
84
89
|
runCampUiPresentationClock,
|
|
85
90
|
sameCampUiRuntimeHealth,
|
|
86
91
|
selectCampRun,
|
|
87
92
|
styleCampUiTone,
|
|
88
93
|
uniqueCampUiNames
|
|
89
|
-
} from "./chunk-
|
|
94
|
+
} from "./chunk-XVKL4E3L.js";
|
|
90
95
|
import "./chunk-RIYKIIGA.js";
|
|
91
96
|
export {
|
|
92
97
|
CAMP_UI_BASH_PREVIEW_LINES,
|
|
@@ -118,12 +123,16 @@ export {
|
|
|
118
123
|
PiCampRunSelectorRoot,
|
|
119
124
|
PiCampUiRoot,
|
|
120
125
|
allocateCampUiSectionRows,
|
|
126
|
+
cachedCampUiBlock,
|
|
121
127
|
campUiAskBlockId,
|
|
128
|
+
campUiBlockCacheSize,
|
|
122
129
|
campUiEquipmentBlockRenderer,
|
|
123
130
|
campUiExploredReadPath,
|
|
124
131
|
campUiExploredReadRange,
|
|
132
|
+
campUiMessageSignature,
|
|
125
133
|
campUiPendingAskBlockRenderer,
|
|
126
134
|
campUiPendingAskTargets,
|
|
135
|
+
campUiResultSignature,
|
|
127
136
|
campUiSubscriptionRetryDelay,
|
|
128
137
|
campUiToolResultCacheSize,
|
|
129
138
|
campUiTranscriptBlockRenderer,
|
|
@@ -168,6 +177,7 @@ export {
|
|
|
168
177
|
renderCampUiToolResult,
|
|
169
178
|
renderCampUiWorkerState,
|
|
170
179
|
renderSelectedCampUiRow,
|
|
180
|
+
resetCampUiBlockCache,
|
|
171
181
|
resetCampUiToolResultCache,
|
|
172
182
|
runCampUiPresentationClock,
|
|
173
183
|
sameCampUiRuntimeHealth,
|
|
@@ -8,13 +8,13 @@ import {
|
|
|
8
8
|
makeDoctorReport,
|
|
9
9
|
resolveCampSurface,
|
|
10
10
|
withCampRpc
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-7AGSTD6B.js";
|
|
12
12
|
import {
|
|
13
13
|
PI_RUNTIME_VERSION,
|
|
14
14
|
PiModelCatalogIssueCode,
|
|
15
15
|
inspectPiModelCatalog,
|
|
16
16
|
makePiOperatorResources
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-TI75FDW3.js";
|
|
18
18
|
import {
|
|
19
19
|
CampHealthComponentStatus,
|
|
20
20
|
CampHealthOverallStatus,
|
|
@@ -48,7 +48,7 @@ import {
|
|
|
48
48
|
resolveCredentialsPath,
|
|
49
49
|
resolveProjectScope,
|
|
50
50
|
resolveWorkerConfigPath
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-GPJJE2V7.js";
|
|
52
52
|
import {
|
|
53
53
|
Clock_exports,
|
|
54
54
|
Effect_exports,
|
|
@@ -8,6 +8,7 @@ import {
|
|
|
8
8
|
Data_exports,
|
|
9
9
|
Deferred_exports,
|
|
10
10
|
Effect_exports,
|
|
11
|
+
Exit_exports,
|
|
11
12
|
FiberSet_exports,
|
|
12
13
|
Match_exports,
|
|
13
14
|
Stream_exports,
|
|
@@ -795,7 +796,14 @@ var workerStatePresentation = /* @__PURE__ */ new Map([
|
|
|
795
796
|
/* A bounded wait, not a failure: the session and the transcript are still there. */
|
|
796
797
|
["retrying", { label: "retrying", tone: CampUiTone.attention, glyph: CampUiGlyph.attention }],
|
|
797
798
|
["idle", { label: "idle", tone: CampUiTone.neutral, glyph: CampUiGlyph.neutral }],
|
|
798
|
-
|
|
799
|
+
/*
|
|
800
|
+
* Attention, not a failure: an interrupted turn leaves the session alive and
|
|
801
|
+
* the next message continues the work.
|
|
802
|
+
*/
|
|
803
|
+
[
|
|
804
|
+
"interrupted",
|
|
805
|
+
{ label: "interrupted", tone: CampUiTone.attention, glyph: CampUiGlyph.attention }
|
|
806
|
+
],
|
|
799
807
|
["recovering", { label: "recovering", tone: CampUiTone.attention, glyph: CampUiGlyph.attention }],
|
|
800
808
|
["completed", { label: "done", tone: CampUiTone.success, glyph: CampUiGlyph.success }],
|
|
801
809
|
["failed", { label: "error", tone: CampUiTone.error, glyph: CampUiGlyph.error }],
|
|
@@ -806,14 +814,16 @@ var fallbackWorkerPresentation = {
|
|
|
806
814
|
tone: CampUiTone.neutral,
|
|
807
815
|
glyph: CampUiGlyph.neutral
|
|
808
816
|
};
|
|
817
|
+
var attentionStates = /* @__PURE__ */ new Set(["waiting_for_orchestrator", "recovering", "retrying"]);
|
|
809
818
|
var renderCampUiWorkerState = (state, options) => {
|
|
810
819
|
const base = workerStatePresentation.get(state) ?? fallbackWorkerPresentation;
|
|
811
820
|
const terminal = state === "completed" || state === "closed";
|
|
821
|
+
const streamingLifts = !terminal && options.streaming && !attentionStates.has(state);
|
|
812
822
|
const presentation = options.failed || state === "failed" || state === "interrupted" ? workerStatePresentation.get(state === "interrupted" ? "interrupted" : "failed") : !terminal && options.pendingAsks > 0 ? {
|
|
813
823
|
label: options.pendingAsks === 1 ? "ask" : `ask ${options.pendingAsks}`,
|
|
814
824
|
tone: CampUiTone.attention,
|
|
815
825
|
glyph: CampUiGlyph.attention
|
|
816
|
-
} :
|
|
826
|
+
} : streamingLifts ? workerStatePresentation.get("running") : base;
|
|
817
827
|
const resolved = presentation ?? fallbackWorkerPresentation;
|
|
818
828
|
return renderCampUiStatus(resolved.label, resolved.tone, resolved.glyph);
|
|
819
829
|
};
|
|
@@ -974,6 +984,38 @@ ${jsonText(content.value)}
|
|
|
974
984
|
}
|
|
975
985
|
};
|
|
976
986
|
|
|
987
|
+
// packages/host-ui/src/pi/blocks/campUiBlockCache.ts
|
|
988
|
+
var CAMP_UI_BLOCK_CACHE_LIMIT = 512;
|
|
989
|
+
var renderedBlocks = /* @__PURE__ */ new Map();
|
|
990
|
+
var resetCampUiBlockCache = () => {
|
|
991
|
+
renderedBlocks.clear();
|
|
992
|
+
};
|
|
993
|
+
var campUiBlockCacheSize = () => renderedBlocks.size;
|
|
994
|
+
var remember = (key, lines) => {
|
|
995
|
+
if (renderedBlocks.size >= CAMP_UI_BLOCK_CACHE_LIMIT) {
|
|
996
|
+
const oldest = renderedBlocks.keys().next();
|
|
997
|
+
if (!oldest.done) renderedBlocks.delete(oldest.value);
|
|
998
|
+
}
|
|
999
|
+
renderedBlocks.set(key, lines);
|
|
1000
|
+
return lines;
|
|
1001
|
+
};
|
|
1002
|
+
var cachedCampUiBlock = (key, render) => {
|
|
1003
|
+
const cached = renderedBlocks.get(key);
|
|
1004
|
+
if (cached !== void 0) return cached;
|
|
1005
|
+
return remember(key, render());
|
|
1006
|
+
};
|
|
1007
|
+
var campUiMessageSignature = (message) => {
|
|
1008
|
+
let text = 0;
|
|
1009
|
+
for (const content of message.content) {
|
|
1010
|
+
if (content.kind === "text" || content.kind === "thinking") text += content.text.length;
|
|
1011
|
+
if (content.kind === "tool-call") text += content.toolCallId.length;
|
|
1012
|
+
}
|
|
1013
|
+
return `${message.role}:${message.toolName ?? ""}:${String(message.content.length)}:${String(
|
|
1014
|
+
text
|
|
1015
|
+
)}:${String(message.errorMessage?.length ?? 0)}:${message.isError === true ? "1" : "0"}`;
|
|
1016
|
+
};
|
|
1017
|
+
var campUiResultSignature = (result) => result === void 0 ? "pending" : campUiMessageSignature(result);
|
|
1018
|
+
|
|
977
1019
|
// packages/host-ui/src/pi/blocks/campUiComposer.ts
|
|
978
1020
|
import { getMarkdownTheme as getMarkdownTheme3, getSelectListTheme as getSelectListTheme4 } from "@earendil-works/pi-coding-agent";
|
|
979
1021
|
import { Editor, Key, matchesKey } from "@earendil-works/pi-tui";
|
|
@@ -1081,7 +1123,7 @@ var renderMcpServers = (equipment) => renderNames(
|
|
|
1081
1123
|
})
|
|
1082
1124
|
);
|
|
1083
1125
|
var equipmentMarkdown = (equipment) => {
|
|
1084
|
-
const role = equipment.role ?? equipment.preset ?? "
|
|
1126
|
+
const role = equipment.role ?? equipment.preset ?? "unknown";
|
|
1085
1127
|
const tools = [.../* @__PURE__ */ new Set([...equipment.builtinTools, ...equipment.customToolNames])].sort();
|
|
1086
1128
|
const lines = [
|
|
1087
1129
|
`**Equipment \xB7 ${escapeMarkdown(role)}**`,
|
|
@@ -1302,7 +1344,7 @@ var cacheKey = (result, width, expanded, plainText) => result.toolCallId === voi
|
|
|
1302
1344
|
// The tool name is part of the key because it chooses the preview budget.
|
|
1303
1345
|
`${result.toolCallId}:${result.toolName ?? ""}:${String(width)}:${expanded ? "1" : "0"}:${String(plainText.length)}`
|
|
1304
1346
|
);
|
|
1305
|
-
var
|
|
1347
|
+
var remember2 = (key, lines) => {
|
|
1306
1348
|
if (renderedResults.size >= CAMP_UI_TOOL_RESULT_CACHE_LIMIT) {
|
|
1307
1349
|
const oldest = renderedResults.keys().next();
|
|
1308
1350
|
if (!oldest.done) renderedResults.delete(oldest.value);
|
|
@@ -1325,7 +1367,7 @@ var renderCampUiToolResult = (result, width, expanded) => {
|
|
|
1325
1367
|
previewLinesByTool.get(result.toolName ?? "") ?? CAMP_UI_DEFAULT_TOOL_PREVIEW_LINES,
|
|
1326
1368
|
boundedWidth
|
|
1327
1369
|
);
|
|
1328
|
-
const keep = (lines2) => key === void 0 ? lines2 :
|
|
1370
|
+
const keep = (lines2) => key === void 0 ? lines2 : remember2(key, lines2);
|
|
1329
1371
|
if (!expanded) {
|
|
1330
1372
|
return keep([
|
|
1331
1373
|
...preview.visualLines,
|
|
@@ -1472,9 +1514,12 @@ var renderTranscript = (transcript, width, expandedDetailBlockIds) => {
|
|
|
1472
1514
|
const first = group[0];
|
|
1473
1515
|
if (first === void 0) return;
|
|
1474
1516
|
const blockId = `explored:${first.toolCallId}`;
|
|
1517
|
+
const expanded = expandedDetailBlockIds.has(blockId);
|
|
1518
|
+
const reads = group;
|
|
1519
|
+
const key = `${blockId}:${String(width)}:${expanded ? "1" : "0"}:${reads.map((read) => `${read.toolCallId}${read.status}`).join(",")}`;
|
|
1475
1520
|
blocks.push({
|
|
1476
1521
|
id: blockId,
|
|
1477
|
-
lines: renderCampUiExploredGroup(
|
|
1522
|
+
lines: cachedCampUiBlock(key, () => renderCampUiExploredGroup(reads, width, expanded)),
|
|
1478
1523
|
toggleable: true
|
|
1479
1524
|
});
|
|
1480
1525
|
group = [];
|
|
@@ -1485,14 +1530,21 @@ var renderTranscript = (transcript, width, expandedDetailBlockIds) => {
|
|
|
1485
1530
|
if (message.toolCallId !== void 0 && callIds.has(message.toolCallId)) return;
|
|
1486
1531
|
closeGroup();
|
|
1487
1532
|
const blockId = `tool-result:${messageId}`;
|
|
1533
|
+
const expanded = expandedDetailBlockIds.has(blockId);
|
|
1488
1534
|
blocks.push({
|
|
1489
1535
|
id: blockId,
|
|
1490
|
-
lines:
|
|
1536
|
+
lines: cachedCampUiBlock(
|
|
1537
|
+
`${blockId}:${String(width)}:${expanded ? "1" : "0"}:${campUiMessageSignature(message)}`,
|
|
1538
|
+
() => renderUnmatchedToolResult(message, width, expanded)
|
|
1539
|
+
),
|
|
1491
1540
|
toggleable: true
|
|
1492
1541
|
});
|
|
1493
1542
|
return;
|
|
1494
1543
|
}
|
|
1495
|
-
const messageLines =
|
|
1544
|
+
const messageLines = cachedCampUiBlock(
|
|
1545
|
+
`message:${messageId}:${String(width)}:${campUiMessageSignature(message)}`,
|
|
1546
|
+
() => renderMessage(message, width)
|
|
1547
|
+
);
|
|
1496
1548
|
if (messageLines.length > 0) {
|
|
1497
1549
|
closeGroup();
|
|
1498
1550
|
blocks.push({ id: `message:${messageId}`, lines: messageLines });
|
|
@@ -1506,13 +1558,13 @@ var renderTranscript = (transcript, width, expandedDetailBlockIds) => {
|
|
|
1506
1558
|
}
|
|
1507
1559
|
closeGroup();
|
|
1508
1560
|
const blockId = `tool-call:${content.toolCallId}`;
|
|
1561
|
+
const expanded = expandedDetailBlockIds.has(blockId);
|
|
1562
|
+
const result = results.get(content.toolCallId);
|
|
1509
1563
|
blocks.push({
|
|
1510
1564
|
id: blockId,
|
|
1511
|
-
lines:
|
|
1512
|
-
content
|
|
1513
|
-
|
|
1514
|
-
width,
|
|
1515
|
-
expandedDetailBlockIds.has(blockId)
|
|
1565
|
+
lines: cachedCampUiBlock(
|
|
1566
|
+
`${blockId}:${content.toolName}:${String(width)}:${expanded ? "1" : "0"}:${campUiResultSignature(result)}`,
|
|
1567
|
+
() => renderToolCall(content, result, width, expanded)
|
|
1516
1568
|
),
|
|
1517
1569
|
toggleable: results.has(content.toolCallId)
|
|
1518
1570
|
});
|
|
@@ -1704,7 +1756,7 @@ var makeCampUiRoster = (context) => ({
|
|
|
1704
1756
|
const pendingAsks = entry.asks.filter((ask) => ask.state === "pending").length;
|
|
1705
1757
|
const tool = active.length === 0 ? "" : styleCampUiTone(CampUiTone.active, ` ${active.slice(0, 2).join(", ")}`);
|
|
1706
1758
|
const label = selected ? theme.selectedText(name) : name;
|
|
1707
|
-
const role = theme.description(`(${worker.equipment.role ?? "
|
|
1759
|
+
const role = theme.description(`(${worker.equipment.role ?? "unknown"})`);
|
|
1708
1760
|
const status = renderCampUiWorkerState(worker.state, {
|
|
1709
1761
|
failed: entry.error !== void 0,
|
|
1710
1762
|
pendingAsks,
|
|
@@ -1736,8 +1788,10 @@ var makeCampUiSessionHeader = (context) => ({
|
|
|
1736
1788
|
const worker = findCampUiWorker(model.snapshot, workerId);
|
|
1737
1789
|
if (worker === void 0) return [theme.noMatch("Worker unavailable")];
|
|
1738
1790
|
const workerName = worker.snapshot.worker.alias ?? workerId.slice(0, 8);
|
|
1739
|
-
const role = worker.snapshot.worker.equipment.role ?? "
|
|
1740
|
-
const
|
|
1791
|
+
const role = worker.snapshot.worker.equipment.role ?? "unknown";
|
|
1792
|
+
const focused = model.state.focusedSlotId === CampUiSlot.transcript;
|
|
1793
|
+
const title = `camp / ${workerName}`;
|
|
1794
|
+
const line = `${focused ? theme.selectedText(title) : theme.description(title)} ${theme.description(`\xB7 ${role} \xB7 session ${worker.snapshot.worker.sessionState}`)}`;
|
|
1741
1795
|
return [fitCampUiLine(line, viewport.width)];
|
|
1742
1796
|
},
|
|
1743
1797
|
handlePointer: (pointer) => pointer.action === "press" && pointer.button === "left" && pointer.y === 0 ? [
|
|
@@ -1761,18 +1815,20 @@ var aggregateCampUsage = (workers) => {
|
|
|
1761
1815
|
};
|
|
1762
1816
|
};
|
|
1763
1817
|
var aggregateUsageText = (usage) => {
|
|
1818
|
+
const partial = usage.reportedWorkers < usage.totalWorkers;
|
|
1819
|
+
const coverage = partial ? ` \xB7 ${usage.reportedWorkers}/${usage.totalWorkers} reported` : "";
|
|
1764
1820
|
if (usage.totalWorkers > 0 && usage.reportedWorkers === 0) {
|
|
1765
|
-
return
|
|
1821
|
+
return `tokens unknown \xB7 cost unknown${coverage}`;
|
|
1766
1822
|
}
|
|
1767
|
-
const partial = usage.reportedWorkers < usage.totalWorkers;
|
|
1768
1823
|
const lowerBound = partial ? "\u2265" : "";
|
|
1769
|
-
const coverage = partial ? ` \xB7 ${usage.reportedWorkers}/${usage.totalWorkers} reported` : "";
|
|
1770
1824
|
return `\u2193 ${lowerBound}${compactNumber(usage.tokens)} tokens \xB7 ${lowerBound}$${usage.cost.toFixed(3)}${coverage}`;
|
|
1771
1825
|
};
|
|
1772
1826
|
var footerDivider = (width) => fitCampUiLine(getMarkdownTheme8().codeBlockBorder("\u2500".repeat(width)), width);
|
|
1773
|
-
var retryText = (retryAt, now) => {
|
|
1774
|
-
if (retryAt === void 0) return ""
|
|
1775
|
-
|
|
1827
|
+
var retryText = (retryAt, attempt, now) => {
|
|
1828
|
+
if (retryAt === void 0) return attempt === void 0 ? "" : `attempt ${String(attempt)}`;
|
|
1829
|
+
const seconds = Math.max(0, Math.ceil((retryAt - now) / 1e3));
|
|
1830
|
+
const numbered = attempt === void 0 ? "" : `attempt ${String(attempt)} \xB7 `;
|
|
1831
|
+
return `${numbered}retry in ${String(seconds)}s`;
|
|
1776
1832
|
};
|
|
1777
1833
|
var diagnosticText = (value) => {
|
|
1778
1834
|
const normalized = value?.replaceAll(/\s+/gu, " ").trim();
|
|
@@ -1789,7 +1845,7 @@ var makeCampUiCampFooter = (context) => ({
|
|
|
1789
1845
|
const healthMessage = health.code === void 0 ? healthSummary : healthSummary === void 0 ? health.code : `${health.code} \xB7 ${healthSummary}`;
|
|
1790
1846
|
const healthTone = health.status === CampUiHealthStatus.failed ? CampUiTone.error : CampUiTone.attention;
|
|
1791
1847
|
const diagnostic = actionError !== void 0 ? `${renderCampUiStatus("action error", CampUiTone.error)} ${theme.description(`\xB7 ${actionError}`)}` : healthMessage !== void 0 ? styleCampUiTone(healthTone, healthMessage) : health.status === CampUiHealthStatus.ready ? "" : renderCampUiStatus(health.status, healthTone);
|
|
1792
|
-
const retry = retryText(health.retryAt, model.state.presentationNow);
|
|
1848
|
+
const retry = retryText(health.retryAt, health.attempt, model.state.presentationNow);
|
|
1793
1849
|
return [
|
|
1794
1850
|
footerDivider(viewport.width),
|
|
1795
1851
|
joinCampUiColumns(diagnostic, theme.description(usage), viewport.width),
|
|
@@ -2402,6 +2458,7 @@ var makeCampUiTerminalModes = (terminal) => {
|
|
|
2402
2458
|
};
|
|
2403
2459
|
|
|
2404
2460
|
// packages/host-ui/src/pi/mountPiCampUi.ts
|
|
2461
|
+
var closedOnPurpose = (exit) => Exit_exports.isSuccess(exit) || Cause_exports.isInterruptedOnly(exit.cause);
|
|
2405
2462
|
var mountPiCampUi = (options) => Effect_exports.gen(function* () {
|
|
2406
2463
|
const startedAt = yield* Clock_exports.currentTimeMillis;
|
|
2407
2464
|
const healthRef = yield* SubscriptionRef_exports.make({
|
|
@@ -2472,11 +2529,14 @@ var mountPiCampUi = (options) => Effect_exports.gen(function* () {
|
|
|
2472
2529
|
tui.start();
|
|
2473
2530
|
});
|
|
2474
2531
|
yield* Effect_exports.addFinalizer(
|
|
2475
|
-
() => Effect_exports.sync(() => {
|
|
2532
|
+
(exit) => Effect_exports.sync(() => {
|
|
2476
2533
|
tui.stop();
|
|
2477
2534
|
terminal.setProgress(false);
|
|
2478
2535
|
}).pipe(
|
|
2479
|
-
Effect_exports.zipRight(setHealth({ status: CampUiRuntimeStatus.stopped, operation: "ui.stop" }))
|
|
2536
|
+
Effect_exports.zipRight(setHealth({ status: CampUiRuntimeStatus.stopped, operation: "ui.stop" })),
|
|
2537
|
+
Effect_exports.zipRight(
|
|
2538
|
+
closedOnPurpose(exit) ? options.backend.shutdown.pipe(Effect_exports.ignore) : Effect_exports.void
|
|
2539
|
+
)
|
|
2480
2540
|
)
|
|
2481
2541
|
);
|
|
2482
2542
|
yield* Effect_exports.forkScoped(
|
|
@@ -2555,7 +2615,7 @@ var mountPiCampUi = (options) => Effect_exports.gen(function* () {
|
|
|
2555
2615
|
};
|
|
2556
2616
|
});
|
|
2557
2617
|
|
|
2558
|
-
// packages/host-ui/src/run-selector/campRunSelector.ts
|
|
2618
|
+
// packages/host-ui/src/pi/run-selector/campRunSelector.ts
|
|
2559
2619
|
import { getMarkdownTheme as getMarkdownTheme11, getSelectListTheme as getSelectListTheme13, initTheme as initTheme2 } from "@earendil-works/pi-coding-agent";
|
|
2560
2620
|
import {
|
|
2561
2621
|
Key as Key4,
|
|
@@ -2711,6 +2771,11 @@ export {
|
|
|
2711
2771
|
renderCampUiDirectedBlock,
|
|
2712
2772
|
campUiPendingAskBlockRenderer,
|
|
2713
2773
|
CampUiAssistantMessage,
|
|
2774
|
+
resetCampUiBlockCache,
|
|
2775
|
+
campUiBlockCacheSize,
|
|
2776
|
+
cachedCampUiBlock,
|
|
2777
|
+
campUiMessageSignature,
|
|
2778
|
+
campUiResultSignature,
|
|
2714
2779
|
makeCampUiComposerComponent,
|
|
2715
2780
|
campUiEquipmentBlockRenderer,
|
|
2716
2781
|
renderCampUiPanel,
|
package/dist/priiisk-host.js
CHANGED
|
@@ -4,14 +4,14 @@ const require = __priiiskCreateRequire(import.meta.url);
|
|
|
4
4
|
import {
|
|
5
5
|
NodeContext_exports,
|
|
6
6
|
NodeRuntime_exports
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-A4K4VHXE.js";
|
|
8
8
|
import {
|
|
9
9
|
CampUiBackendError,
|
|
10
10
|
CampUiHealthStatus,
|
|
11
11
|
CampUiPlacement,
|
|
12
12
|
CampUiRuntimeStatus,
|
|
13
13
|
mountPiCampUi
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-XVKL4E3L.js";
|
|
15
15
|
import {
|
|
16
16
|
PiTransport,
|
|
17
17
|
makePiOperatorResources,
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
makePiTransportLayer,
|
|
20
20
|
requirePiModelCatalog,
|
|
21
21
|
require_undici
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-TI75FDW3.js";
|
|
23
23
|
import {
|
|
24
24
|
AgentRole,
|
|
25
25
|
AgentRoleSchema,
|
|
@@ -101,7 +101,7 @@ import {
|
|
|
101
101
|
runningCampManifest,
|
|
102
102
|
saveCampHealth,
|
|
103
103
|
saveCampManifest
|
|
104
|
-
} from "./chunk-
|
|
104
|
+
} from "./chunk-GPJJE2V7.js";
|
|
105
105
|
import {
|
|
106
106
|
CampAskRouter,
|
|
107
107
|
CampCancellationCode,
|
|
@@ -22445,7 +22445,7 @@ var Client = class extends Protocol {
|
|
|
22445
22445
|
};
|
|
22446
22446
|
|
|
22447
22447
|
// packages/mcp-backend/src/connections/clientIdentity.ts
|
|
22448
|
-
var backendVersion = "0.1.
|
|
22448
|
+
var backendVersion = "0.1.13";
|
|
22449
22449
|
|
|
22450
22450
|
// packages/mcp-backend/src/connections/mcpFailure.ts
|
|
22451
22451
|
var McpFailure = class extends Data_exports.TaggedError("McpFailure") {
|
|
@@ -27029,7 +27029,9 @@ var makeHostCampUiSnapshot = (options, revision, activityRevisions) => Effect_ex
|
|
|
27029
27029
|
(component) => component.message ?? `${component.id}: ${component.status}`
|
|
27030
27030
|
)
|
|
27031
27031
|
].join("; ");
|
|
27032
|
-
const
|
|
27032
|
+
const retrying = unhealthyComponents.filter((component) => component.nextRetryAt !== void 0).sort((left, right) => (left.nextRetryAt ?? 0) - (right.nextRetryAt ?? 0))[0];
|
|
27033
|
+
const retryAt = retrying?.nextRetryAt;
|
|
27034
|
+
const attempt = retrying?.attempt;
|
|
27033
27035
|
return {
|
|
27034
27036
|
displayName: `priiisk-camp-${options.project.name.replaceAll(/[^a-zA-Z0-9_-]+/gu, "-")}-${options.project.hash.slice(0, 5)}`,
|
|
27035
27037
|
projectScope: options.project.cwd,
|
|
@@ -27040,7 +27042,8 @@ var makeHostCampUiSnapshot = (options, revision, activityRevisions) => Effect_ex
|
|
|
27040
27042
|
status: failures.length > 0 && hostHealth.overallStatus === CampUiHealthStatus.ready ? CampUiHealthStatus.degraded : hostHealth.overallStatus,
|
|
27041
27043
|
...recoveryHealth?.code === void 0 ? {} : { code: recoveryHealth.code },
|
|
27042
27044
|
...recoveryHealth?.message === void 0 ? healthMessage === "" ? {} : { message: healthMessage } : { message: recoveryHealth.message },
|
|
27043
|
-
...retryAt === void 0 ? {} : { retryAt }
|
|
27045
|
+
...retryAt === void 0 ? {} : { retryAt },
|
|
27046
|
+
...attempt === void 0 ? {} : { attempt }
|
|
27044
27047
|
},
|
|
27045
27048
|
controllerConnected: [...liveControllers.values()].some(
|
|
27046
27049
|
(clientKind) => clientKind === "orchestrator"
|
package/dist/priiisk.js
CHANGED
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
fromReadable,
|
|
6
6
|
layer,
|
|
7
7
|
runMain
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-A4K4VHXE.js";
|
|
9
9
|
import {
|
|
10
10
|
CliCampLifecycleError,
|
|
11
11
|
CliEquipmentConflict,
|
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
resolveCampSurface,
|
|
24
24
|
withCampRpc,
|
|
25
25
|
withCampRpcSession
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-7AGSTD6B.js";
|
|
27
27
|
import {
|
|
28
28
|
CampCommandFailure,
|
|
29
29
|
CampHostReadiness,
|
|
@@ -58,7 +58,7 @@ import {
|
|
|
58
58
|
resolveProjectScopeSync,
|
|
59
59
|
saveCampManifest,
|
|
60
60
|
startingCampManifest
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-GPJJE2V7.js";
|
|
62
62
|
import {
|
|
63
63
|
Cause_exports,
|
|
64
64
|
CommitPrototype,
|
|
@@ -19969,7 +19969,7 @@ var campResumeListCommand = Command_exports.make(
|
|
|
19969
19969
|
)
|
|
19970
19970
|
).pipe(Command_exports.withDescription("Lists saved runs of this project that resume can restore."));
|
|
19971
19971
|
var runIdArgument = Args_exports.text({ name: "runId" }).pipe(Args_exports.optional);
|
|
19972
|
-
var selectCampRunOnDemand = (items) => Effect_exports.promise(() => import("./chunk-
|
|
19972
|
+
var selectCampRunOnDemand = (items) => Effect_exports.promise(() => import("./chunk-HK2LW6VV.js")).pipe(
|
|
19973
19973
|
Effect_exports.flatMap((ui) => ui.selectCampRun({ items }))
|
|
19974
19974
|
);
|
|
19975
19975
|
var selectAndResume = (json) => {
|
|
@@ -20042,7 +20042,7 @@ var rootCommand = Command_exports.make(
|
|
|
20042
20042
|
).pipe(Command_exports.withDescription("Runs and observes a camp of collaborating workers."));
|
|
20043
20043
|
|
|
20044
20044
|
// packages/cli/src/commands/doctorCommand.ts
|
|
20045
|
-
var runDoctorOnDemand = Effect_exports.promise(() => import("./chunk-
|
|
20045
|
+
var runDoctorOnDemand = Effect_exports.promise(() => import("./chunk-M2NR2CXX.js")).pipe(
|
|
20046
20046
|
Effect_exports.flatMap((doctor) => doctor.runDoctor)
|
|
20047
20047
|
);
|
|
20048
20048
|
var statusLabel = {
|
|
@@ -20794,7 +20794,7 @@ var command = rootCommand.pipe(
|
|
|
20794
20794
|
);
|
|
20795
20795
|
var cli = Command_exports.run(command, {
|
|
20796
20796
|
name: "priiisk camp control",
|
|
20797
|
-
version: "0.1.
|
|
20797
|
+
version: "0.1.13"
|
|
20798
20798
|
});
|
|
20799
20799
|
var quietDiagnostics = (json, effect) => json ? Console_exports.consoleWith(
|
|
20800
20800
|
(console2) => Console_exports.withConsole({ ...console2, error: () => Effect_exports.void })(effect)
|
package/package.json
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "priiisk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.13",
|
|
4
4
|
"description": "CLI for running and observing a camp of collaborating agents",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
7
|
"priiisk": "./dist/priiisk.js"
|
|
8
8
|
},
|
|
9
9
|
"files": [
|
|
10
|
-
"dist/chunk-
|
|
11
|
-
"dist/chunk-
|
|
12
|
-
"dist/chunk-
|
|
13
|
-
"dist/chunk-
|
|
14
|
-
"dist/chunk-
|
|
15
|
-
"dist/chunk-
|
|
16
|
-
"dist/chunk-JAEJXLWU.js.LEGAL.txt",
|
|
10
|
+
"dist/chunk-7AGSTD6B.js",
|
|
11
|
+
"dist/chunk-A4K4VHXE.js",
|
|
12
|
+
"dist/chunk-GPJJE2V7.js",
|
|
13
|
+
"dist/chunk-GPJJE2V7.js.LEGAL.txt",
|
|
14
|
+
"dist/chunk-HK2LW6VV.js",
|
|
15
|
+
"dist/chunk-M2NR2CXX.js",
|
|
17
16
|
"dist/chunk-RIYKIIGA.js",
|
|
18
|
-
"dist/chunk-
|
|
19
|
-
"dist/chunk-
|
|
17
|
+
"dist/chunk-TI75FDW3.js",
|
|
18
|
+
"dist/chunk-TI75FDW3.js.LEGAL.txt",
|
|
19
|
+
"dist/chunk-XVKL4E3L.js",
|
|
20
20
|
"dist/priiisk-host.js",
|
|
21
21
|
"dist/priiisk.js",
|
|
22
22
|
"profiles",
|
|
File without changes
|
|
File without changes
|