priiisk 0.1.8 → 0.1.9
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-BXVX5A4M.js → chunk-EHPEGFN2.js} +2 -2
- package/dist/{chunk-TZBPOE6G.js → chunk-F7LGUL2J.js} +2 -18
- package/dist/{chunk-FZQM7AKO.js → chunk-GEBZQLE7.js} +3 -3
- package/dist/{chunk-4V3HXXQ6.js → chunk-IORSBZKU.js} +2 -2
- package/dist/{chunk-W2ZL6LWM.js → chunk-LH753BUY.js} +31 -17
- package/dist/{chunk-S7LCWMQY.js → chunk-NIJ2J45R.js} +1 -1
- package/dist/{chunk-OWFOOE7W.js → chunk-QEUSNJ3D.js} +2 -2
- package/dist/{chunk-TGTG65RZ.js → chunk-QQBVNDLC.js} +4 -4
- package/dist/priiisk-host.js +105 -29
- package/dist/priiisk.js +56 -14
- package/package.json +11 -11
- /package/dist/{chunk-W2ZL6LWM.js.LEGAL.txt → chunk-LH753BUY.js.LEGAL.txt} +0 -0
- /package/dist/{chunk-OWFOOE7W.js.LEGAL.txt → chunk-QEUSNJ3D.js.LEGAL.txt} +0 -0
|
@@ -86,8 +86,8 @@ import {
|
|
|
86
86
|
selectCampRun,
|
|
87
87
|
styleCampUiTone,
|
|
88
88
|
uniqueCampUiNames
|
|
89
|
-
} from "./chunk-
|
|
90
|
-
import "./chunk-
|
|
89
|
+
} from "./chunk-NIJ2J45R.js";
|
|
90
|
+
import "./chunk-F7LGUL2J.js";
|
|
91
91
|
export {
|
|
92
92
|
CAMP_UI_BASH_PREVIEW_LINES,
|
|
93
93
|
CAMP_UI_DEFAULT_TOOL_PREVIEW_LINES,
|
|
@@ -43163,25 +43163,9 @@ var rollbackOrFail = (rollback, workerId) => Effect_exports.exit(rollback).pipe(
|
|
|
43163
43163
|
)
|
|
43164
43164
|
)
|
|
43165
43165
|
);
|
|
43166
|
-
var
|
|
43167
|
-
if (request2.role !== void 0 || request2.preset !== void 0) return request2;
|
|
43168
|
-
const overrides = {
|
|
43169
|
-
...request2.overrides,
|
|
43170
|
-
...request2.overrides?.model === void 0 && current2.model !== void 0 ? { model: current2.model } : {},
|
|
43171
|
-
...request2.overrides?.thinkingLevel === void 0 && current2.thinkingLevel !== void 0 ? { thinkingLevel: current2.thinkingLevel } : {}
|
|
43172
|
-
};
|
|
43173
|
-
return {
|
|
43174
|
-
...request2,
|
|
43175
|
-
...current2.role === void 0 ? {} : { role: current2.role },
|
|
43176
|
-
...current2.preset === void 0 ? {} : { preset: current2.preset },
|
|
43177
|
-
overrides
|
|
43178
|
-
};
|
|
43179
|
-
};
|
|
43180
|
-
var updateWorkerEquipment = (runtime6, command, identity6, request2) => Effect_exports.gen(function* () {
|
|
43166
|
+
var updateWorkerEquipment = (runtime6, command, identity6, change) => Effect_exports.gen(function* () {
|
|
43181
43167
|
const [initial, sessionRef] = yield* requireKernelSession(runtime6, identity6);
|
|
43182
|
-
const equipment = yield* runtime6.equipmentResolver.
|
|
43183
|
-
requestOnCurrentBase(request2, initial.equipment)
|
|
43184
|
-
);
|
|
43168
|
+
const equipment = yield* runtime6.equipmentResolver.reresolve(initial.equipment, change);
|
|
43185
43169
|
const resource = yield* getWorkerResource(runtime6, initial.id);
|
|
43186
43170
|
if (resource === void 0) {
|
|
43187
43171
|
return yield* Effect_exports.fail(
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
layerNet,
|
|
21
21
|
makeCampSurfaceName,
|
|
22
22
|
resolveProjectScopeSync
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-LH753BUY.js";
|
|
24
24
|
import {
|
|
25
25
|
Clock_exports,
|
|
26
26
|
Config_exports,
|
|
@@ -38,7 +38,7 @@ import {
|
|
|
38
38
|
Schedule_exports,
|
|
39
39
|
Schema_exports,
|
|
40
40
|
Stream_exports
|
|
41
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-F7LGUL2J.js";
|
|
42
42
|
|
|
43
43
|
// packages/cli/src/doctor/doctorModel.ts
|
|
44
44
|
var DOCTOR_REPORT_SCHEMA_VERSION = 1;
|
|
@@ -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.9";
|
|
116
116
|
|
|
117
117
|
// packages/cli/src/client/campRpcConnection.ts
|
|
118
118
|
var reportRetry = (options, diagnostic) => options.onRetry === void 0 ? Console_exports.error(
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
makePlatform,
|
|
29
29
|
makeRunMain,
|
|
30
30
|
stdin
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-LH753BUY.js";
|
|
32
32
|
import {
|
|
33
33
|
BaseProto,
|
|
34
34
|
__export,
|
|
@@ -112,7 +112,7 @@ import {
|
|
|
112
112
|
write,
|
|
113
113
|
zip,
|
|
114
114
|
zipRight
|
|
115
|
-
} from "./chunk-
|
|
115
|
+
} from "./chunk-F7LGUL2J.js";
|
|
116
116
|
|
|
117
117
|
// node_modules/.pnpm/@effect+platform-node@0.107.0_@effect+cluster@0.59.0_@effect+platform@0.96.2_effect@3.2_9535e05eb804fa0fb275ce283b448483/node_modules/@effect/platform-node/dist/esm/NodeContext.js
|
|
118
118
|
var NodeContext_exports = {};
|
|
@@ -366,7 +366,7 @@ import {
|
|
|
366
366
|
write,
|
|
367
367
|
zipRight,
|
|
368
368
|
zipRight2
|
|
369
|
-
} from "./chunk-
|
|
369
|
+
} from "./chunk-F7LGUL2J.js";
|
|
370
370
|
|
|
371
371
|
// node_modules/.pnpm/detect-libc@2.1.2/node_modules/detect-libc/lib/process.js
|
|
372
372
|
var require_process = __commonJS({
|
|
@@ -10447,15 +10447,7 @@ var resolveNamedServers = (config, names) => {
|
|
|
10447
10447
|
};
|
|
10448
10448
|
};
|
|
10449
10449
|
var resolveMcpServers = (config, role, mcpOverride) => resolveNamedServers(config, resolveServerNames(config, role, mcpOverride));
|
|
10450
|
-
var
|
|
10451
|
-
config,
|
|
10452
|
-
Object.values(AgentRole).flatMap((role) => resolveServerNames(config, role, void 0))
|
|
10453
|
-
);
|
|
10454
|
-
var resolveCampMcpOutsideUnion = (config, mcpOverride) => {
|
|
10455
|
-
if (mcpOverride === void 0) return [];
|
|
10456
|
-
const allowed = new Set(Object.keys(resolveCampMcpUnion(config).servers));
|
|
10457
|
-
return dedupe3(mcpOverride).filter((name) => !allowed.has(name));
|
|
10458
|
-
};
|
|
10450
|
+
var resolveCampMcpCatalog = (config) => resolveNamedServers(config, Object.keys(config?.mcpServers ?? {}));
|
|
10459
10451
|
var applyCampMcpRuntimeDefaults = (servers) => {
|
|
10460
10452
|
const codegraph = servers.codegraph;
|
|
10461
10453
|
if (codegraph === void 0 || codegraph.lifecycle !== void 0) return servers;
|
|
@@ -10487,6 +10479,7 @@ var resolveNamedThinkingForAlias = (config, alias, namedLevel) => {
|
|
|
10487
10479
|
var resolveDefaultPreset = (config) => ({
|
|
10488
10480
|
modelAlias: config.defaults.model,
|
|
10489
10481
|
modelId: resolveModelAlias(config, config.defaults.model),
|
|
10482
|
+
abstractThinking: config.defaults.thinking,
|
|
10490
10483
|
thinking: resolveThinkingForAlias(config, config.defaults.model, config.defaults.thinking)
|
|
10491
10484
|
});
|
|
10492
10485
|
var resolveModelAliasForRole = (config, role) => config.roles?.[role]?.model ?? config.defaults.model;
|
|
@@ -10499,6 +10492,7 @@ var resolveRolePreset = (config, role) => {
|
|
|
10499
10492
|
description: config.roles?.[role]?.description,
|
|
10500
10493
|
modelAlias,
|
|
10501
10494
|
modelId: resolveModelAlias(config, modelAlias),
|
|
10495
|
+
abstractThinking,
|
|
10502
10496
|
thinking: resolveThinkingForAlias(config, modelAlias, abstractThinking),
|
|
10503
10497
|
readOnly: config.roles?.[role]?.readOnly,
|
|
10504
10498
|
directTools: config.roles?.[role]?.directTools
|
|
@@ -10523,6 +10517,7 @@ var resolveHirePreset = (config, presetName) => {
|
|
|
10523
10517
|
role: entry.role,
|
|
10524
10518
|
modelAlias,
|
|
10525
10519
|
modelId,
|
|
10520
|
+
abstractThinking,
|
|
10526
10521
|
thinking,
|
|
10527
10522
|
readOnly: entry.readOnly ?? (entry.role !== void 0 ? config.roles?.[entry.role]?.readOnly : void 0),
|
|
10528
10523
|
directTools: entry.directTools ?? (entry.role !== void 0 ? config.roles?.[entry.role]?.directTools : void 0)
|
|
@@ -10677,8 +10672,8 @@ var parseDirectToolSandboxStatus = (status) => {
|
|
|
10677
10672
|
var describeDirectToolSandbox = (sandbox2) => sandbox2.kind === DirectToolSandboxKind.bubblewrap ? "External binaries run in a bubblewrap sandbox: read-only filesystem, writable worker directory, no network" : sandbox2.absence === DirectToolSandboxAbsence.disabled ? `External binaries run without an OS sandbox: disabled by ${DIRECT_TOOL_SANDBOX_ENV}` : sandbox2.absence === DirectToolSandboxAbsence.unsupportedPlatform ? `External binaries run without an OS sandbox: no supported mechanism on ${sandbox2.detail ?? "this platform"}` : sandbox2.absence === DirectToolSandboxAbsence.binaryMissing ? "External binaries run without an OS sandbox: bubblewrap (bwrap) is not installed" : "External binaries run without an OS sandbox: bubblewrap is present but cannot start";
|
|
10678
10673
|
|
|
10679
10674
|
// packages/protocol/src/domain/protocolVersion.ts
|
|
10680
|
-
var PRIIISK_PROTOCOL_VERSION = "
|
|
10681
|
-
var PRIIISK_PROTOCOL_PACKAGE_VERSION = "0.1.
|
|
10675
|
+
var PRIIISK_PROTOCOL_VERSION = "12";
|
|
10676
|
+
var PRIIISK_PROTOCOL_PACKAGE_VERSION = "0.1.9";
|
|
10682
10677
|
var ProtocolVersionSchema = Schema_exports.String.pipe(Schema_exports.minLength(1));
|
|
10683
10678
|
|
|
10684
10679
|
// packages/protocol/src/domain/protocolIdentifiers.ts
|
|
@@ -10939,6 +10934,21 @@ var EquipmentRequestSchema = Schema_exports.Struct({
|
|
|
10939
10934
|
})
|
|
10940
10935
|
)
|
|
10941
10936
|
});
|
|
10937
|
+
var EquipmentChangeSchema = Schema_exports.Struct({
|
|
10938
|
+
builtinTools: Schema_exports.optional(StringList),
|
|
10939
|
+
customToolNames: Schema_exports.optional(StringList),
|
|
10940
|
+
directTools: Schema_exports.optional(Schema_exports.Union(Schema_exports.Boolean, StringList)),
|
|
10941
|
+
skillNames: Schema_exports.optional(StringList),
|
|
10942
|
+
skillPaths: Schema_exports.optional(StringList),
|
|
10943
|
+
mcp: Schema_exports.optional(
|
|
10944
|
+
Schema_exports.Struct({
|
|
10945
|
+
serverNames: StringList,
|
|
10946
|
+
toolNamesByServer: Schema_exports.optional(
|
|
10947
|
+
Schema_exports.Record({ key: NonEmptyString5, value: Schema_exports.Array(NonEmptyString5) })
|
|
10948
|
+
)
|
|
10949
|
+
})
|
|
10950
|
+
)
|
|
10951
|
+
});
|
|
10942
10952
|
|
|
10943
10953
|
// packages/protocol/src/domain/eventDtos.ts
|
|
10944
10954
|
var CampEventKindSchema = Schema_exports.Literal(
|
|
@@ -13418,12 +13428,16 @@ var CampProtocol = class extends RpcGroup_exports.make(
|
|
|
13418
13428
|
success: WorkerSummarySchema,
|
|
13419
13429
|
error: CampOperationErrorSchema
|
|
13420
13430
|
}),
|
|
13421
|
-
/**
|
|
13431
|
+
/**
|
|
13432
|
+
* Changes the grant of a live worker; the answer carries the committed
|
|
13433
|
+
* equipment revision. The identity it was hired with is not part of the
|
|
13434
|
+
* payload: changing that means hiring another worker.
|
|
13435
|
+
*/
|
|
13422
13436
|
Rpc_exports.make("Equip", {
|
|
13423
13437
|
payload: {
|
|
13424
13438
|
...CommandContextSchema.fields,
|
|
13425
13439
|
worker: WorkerSelectorSchema,
|
|
13426
|
-
equipment:
|
|
13440
|
+
equipment: EquipmentChangeSchema
|
|
13427
13441
|
},
|
|
13428
13442
|
success: WorkerSummarySchema,
|
|
13429
13443
|
error: CampOperationErrorSchema
|
|
@@ -13553,7 +13567,7 @@ var CampProtocol = class extends RpcGroup_exports.make(
|
|
|
13553
13567
|
};
|
|
13554
13568
|
|
|
13555
13569
|
// packages/camp-state/src/bootstrap/campHostVersion.ts
|
|
13556
|
-
var PRIIISK_HOST_VERSION = "0.1.
|
|
13570
|
+
var PRIIISK_HOST_VERSION = "0.1.9";
|
|
13557
13571
|
|
|
13558
13572
|
// packages/surface/src/domain/surfaceModel.ts
|
|
13559
13573
|
var NonEmptyString7 = Schema_exports.String.pipe(Schema_exports.minLength(1));
|
|
@@ -14926,11 +14940,11 @@ export {
|
|
|
14926
14940
|
directToolBin,
|
|
14927
14941
|
resolveDirectTools,
|
|
14928
14942
|
resolveMcpServers,
|
|
14929
|
-
|
|
14930
|
-
resolveCampMcpOutsideUnion,
|
|
14943
|
+
resolveCampMcpCatalog,
|
|
14931
14944
|
applyCampMcpRuntimeDefaults,
|
|
14932
14945
|
resolveMcpSecretEnv,
|
|
14933
14946
|
resolveModelAlias,
|
|
14947
|
+
resolveThinkingForAlias,
|
|
14934
14948
|
resolveNamedThinkingForAlias,
|
|
14935
14949
|
resolveDefaultPreset,
|
|
14936
14950
|
resolveRolePreset,
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
Match_exports,
|
|
13
13
|
Stream_exports,
|
|
14
14
|
SubscriptionRef_exports
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-F7LGUL2J.js";
|
|
16
16
|
|
|
17
17
|
// packages/host-ui/src/backend/campUiBackend.ts
|
|
18
18
|
var CampUiBackendError = class extends Data_exports.TaggedError("CampUiBackendError") {
|
|
@@ -3,7 +3,7 @@ const require = __priiiskCreateRequire(import.meta.url);
|
|
|
3
3
|
import {
|
|
4
4
|
FileSystem_exports,
|
|
5
5
|
PRIIISK_PI_AGENT_DIR_ENV
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-LH753BUY.js";
|
|
7
7
|
import {
|
|
8
8
|
CampDeliveryPort,
|
|
9
9
|
CampFailureCode,
|
|
@@ -30,7 +30,7 @@ import {
|
|
|
30
30
|
__require,
|
|
31
31
|
__toESM,
|
|
32
32
|
campScopeClosedReason
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-F7LGUL2J.js";
|
|
34
34
|
|
|
35
35
|
// node_modules/.pnpm/undici@7.28.0/node_modules/undici/lib/core/symbols.js
|
|
36
36
|
var require_symbols = __commonJS({
|
|
@@ -8,13 +8,13 @@ import {
|
|
|
8
8
|
makeDoctorReport,
|
|
9
9
|
resolveCampSurface,
|
|
10
10
|
withCampRpc
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-GEBZQLE7.js";
|
|
12
12
|
import {
|
|
13
13
|
PI_RUNTIME_VERSION,
|
|
14
14
|
PiModelCatalogIssueCode,
|
|
15
15
|
inspectPiModelCatalog,
|
|
16
16
|
makePiOperatorResources
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-QEUSNJ3D.js";
|
|
18
18
|
import {
|
|
19
19
|
CampHealthComponentStatus,
|
|
20
20
|
CampHealthOverallStatus,
|
|
@@ -48,13 +48,13 @@ import {
|
|
|
48
48
|
resolveCredentialsPath,
|
|
49
49
|
resolveProjectScope,
|
|
50
50
|
resolveWorkerConfigPath
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-LH753BUY.js";
|
|
52
52
|
import {
|
|
53
53
|
Clock_exports,
|
|
54
54
|
Effect_exports,
|
|
55
55
|
Option_exports,
|
|
56
56
|
Ref_exports
|
|
57
|
-
} from "./chunk-
|
|
57
|
+
} from "./chunk-F7LGUL2J.js";
|
|
58
58
|
|
|
59
59
|
// packages/cli/src/doctor/environmentDoctor.ts
|
|
60
60
|
import { dirname } from "node:path";
|
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-IORSBZKU.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-NIJ2J45R.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-QEUSNJ3D.js";
|
|
23
23
|
import {
|
|
24
24
|
AgentRole,
|
|
25
25
|
AgentRoleSchema,
|
|
@@ -67,6 +67,7 @@ import {
|
|
|
67
67
|
campRecoveryDiagnosticFromCause,
|
|
68
68
|
campRunPaths,
|
|
69
69
|
currentDirectToolSandbox,
|
|
70
|
+
directToolBin,
|
|
70
71
|
directToolName,
|
|
71
72
|
directToolSandboxCommand,
|
|
72
73
|
findCampRecoveryHealthComponent,
|
|
@@ -81,8 +82,7 @@ import {
|
|
|
81
82
|
prepareCampRunStorage,
|
|
82
83
|
prepareCampStorage,
|
|
83
84
|
projectScopeFromCwd,
|
|
84
|
-
|
|
85
|
-
resolveCampMcpUnion,
|
|
85
|
+
resolveCampMcpCatalog,
|
|
86
86
|
resolveDefaultPreset,
|
|
87
87
|
resolveDirectTools,
|
|
88
88
|
resolveExecutablePath,
|
|
@@ -96,11 +96,12 @@ import {
|
|
|
96
96
|
resolveRolePreset,
|
|
97
97
|
resolveRoleProfilePath,
|
|
98
98
|
resolveSkillGroups,
|
|
99
|
+
resolveThinkingForAlias,
|
|
99
100
|
resolveWorkerSkillsRoot,
|
|
100
101
|
runningCampManifest,
|
|
101
102
|
saveCampHealth,
|
|
102
103
|
saveCampManifest
|
|
103
|
-
} from "./chunk-
|
|
104
|
+
} from "./chunk-LH753BUY.js";
|
|
104
105
|
import {
|
|
105
106
|
CampAskRouter,
|
|
106
107
|
CampCancellationCode,
|
|
@@ -193,7 +194,7 @@ import {
|
|
|
193
194
|
withFiberRuntime,
|
|
194
195
|
workerAliasIdentity,
|
|
195
196
|
workerIdIdentity
|
|
196
|
-
} from "./chunk-
|
|
197
|
+
} from "./chunk-F7LGUL2J.js";
|
|
197
198
|
|
|
198
199
|
// node_modules/.pnpm/ws@8.21.1/node_modules/ws/lib/constants.js
|
|
199
200
|
var require_constants = __commonJS({
|
|
@@ -11463,6 +11464,19 @@ var equipmentRequestFromDto = (request) => ({
|
|
|
11463
11464
|
}
|
|
11464
11465
|
}
|
|
11465
11466
|
});
|
|
11467
|
+
var equipmentChangeFromDto = (change) => ({
|
|
11468
|
+
...change.builtinTools === void 0 ? {} : { builtinTools: change.builtinTools },
|
|
11469
|
+
...change.customToolNames === void 0 ? {} : { customToolNames: change.customToolNames },
|
|
11470
|
+
...change.directTools === void 0 ? {} : { directTools: change.directTools },
|
|
11471
|
+
...change.skillNames === void 0 ? {} : { skillNames: change.skillNames },
|
|
11472
|
+
...change.skillPaths === void 0 ? {} : { skillPaths: change.skillPaths },
|
|
11473
|
+
...change.mcp === void 0 ? {} : {
|
|
11474
|
+
mcp: {
|
|
11475
|
+
serverNames: change.mcp.serverNames,
|
|
11476
|
+
...change.mcp.toolNamesByServer === void 0 ? {} : { toolNamesByServer: change.mcp.toolNamesByServer }
|
|
11477
|
+
}
|
|
11478
|
+
}
|
|
11479
|
+
});
|
|
11466
11480
|
var transcriptContentDto = (content) => {
|
|
11467
11481
|
if (content.kind === "text") return { kind: "text", text: content.text };
|
|
11468
11482
|
if (content.kind === "thinking") {
|
|
@@ -22437,7 +22451,7 @@ var Client = class extends Protocol {
|
|
|
22437
22451
|
};
|
|
22438
22452
|
|
|
22439
22453
|
// packages/mcp-backend/src/connections/clientIdentity.ts
|
|
22440
|
-
var backendVersion = "0.1.
|
|
22454
|
+
var backendVersion = "0.1.9";
|
|
22441
22455
|
|
|
22442
22456
|
// packages/mcp-backend/src/connections/mcpFailure.ts
|
|
22443
22457
|
var McpFailure = class extends Data_exports.TaggedError("McpFailure") {
|
|
@@ -25117,7 +25131,7 @@ var configLoadError = (path) => new CampMcpError({
|
|
|
25117
25131
|
});
|
|
25118
25132
|
var acquireMcpHubBackendForConfig = (config2) => Effect_exports.gen(function* () {
|
|
25119
25133
|
const fs = yield* FileSystem_exports.FileSystem;
|
|
25120
|
-
const resolution =
|
|
25134
|
+
const resolution = resolveCampMcpCatalog(config2);
|
|
25121
25135
|
const servers = applyCampMcpRuntimeDefaults(resolution.servers);
|
|
25122
25136
|
const credentials = yield* loadReferencedMcpCredentials(fs, resolution.referencedEnvNames).pipe(
|
|
25123
25137
|
Effect_exports.mapError((cause) => configLoadError(cause.path))
|
|
@@ -25218,7 +25232,12 @@ var selectModel = (config2, requested, sources) => {
|
|
|
25218
25232
|
};
|
|
25219
25233
|
var selectThinking = (config2, requested, alias, sources) => {
|
|
25220
25234
|
if (requested === void 0) {
|
|
25221
|
-
|
|
25235
|
+
const abstract = sources.find(
|
|
25236
|
+
(source) => source?.abstractThinking !== void 0
|
|
25237
|
+
)?.abstractThinking;
|
|
25238
|
+
return Effect_exports.succeed(
|
|
25239
|
+
abstract === void 0 || config2 === void 0 || alias === void 0 ? abstract : resolveThinkingForAlias(config2, alias, abstract) ?? abstract
|
|
25240
|
+
);
|
|
25222
25241
|
}
|
|
25223
25242
|
if (!Schema_exports.is(PiThinkingLevelSchema)(requested)) {
|
|
25224
25243
|
return Effect_exports.fail(equipmentError("unknown_thinking_level", { thinkingLevel: requested }));
|
|
@@ -25254,8 +25273,18 @@ var makeHostToolRegistry = (options) => ({
|
|
|
25254
25273
|
});
|
|
25255
25274
|
|
|
25256
25275
|
// packages/host/src/equipment/configEquipmentResolver.ts
|
|
25257
|
-
var
|
|
25258
|
-
|
|
25276
|
+
var carriedTools = (current) => {
|
|
25277
|
+
const bins = [];
|
|
25278
|
+
const customToolNames = [];
|
|
25279
|
+
for (const name of current.customToolNames) {
|
|
25280
|
+
const bin = directToolBin(name);
|
|
25281
|
+
if (bin === void 0) customToolNames.push(name);
|
|
25282
|
+
else bins.push(bin);
|
|
25283
|
+
}
|
|
25284
|
+
return { bins, customToolNames };
|
|
25285
|
+
};
|
|
25286
|
+
var makeConfigEquipmentResolver = (fs, path, config2, registry2 = makeHostToolRegistry()) => {
|
|
25287
|
+
const resolve = (request) => Effect_exports.gen(function* () {
|
|
25259
25288
|
const presetResolution = request.preset === void 0 ? void 0 : config2 === void 0 ? { found: false, reason: "not-found" } : resolveHirePreset(config2, request.preset);
|
|
25260
25289
|
if (presetResolution !== void 0 && !presetResolution.found) {
|
|
25261
25290
|
return yield* Effect_exports.fail(
|
|
@@ -25304,19 +25333,18 @@ var makeConfigEquipmentResolver = (fs, path, config2, registry2 = makeHostToolRe
|
|
|
25304
25333
|
equipmentError("unknown_skill_groups", { groups: skillResolution.unknownGroups })
|
|
25305
25334
|
);
|
|
25306
25335
|
}
|
|
25307
|
-
const
|
|
25336
|
+
const requestedSkillNames = request.overrides?.skillNames;
|
|
25337
|
+
const requestedSkillPaths = request.overrides?.skillPaths;
|
|
25338
|
+
const namedSkills = requestedSkillNames ?? (requestedSkillPaths === void 0 ? skillResolution.skillNames : []);
|
|
25308
25339
|
const skillPaths = [
|
|
25309
|
-
|
|
25340
|
+
.../* @__PURE__ */ new Set([
|
|
25341
|
+
...namedSkills.map((name) => path.join(resolveWorkerSkillsRoot(), name)),
|
|
25342
|
+
...requestedSkillPaths ?? []
|
|
25343
|
+
])
|
|
25310
25344
|
];
|
|
25311
25345
|
const skillNames = skillPaths.map((skillPath) => path.basename(skillPath, ".md"));
|
|
25312
25346
|
yield* requirePaths(fs, skillPaths);
|
|
25313
25347
|
const requestedMcp = request.overrides?.mcp;
|
|
25314
|
-
const outsideUnion = resolveCampMcpOutsideUnion(config2, requestedMcp?.serverNames);
|
|
25315
|
-
if (outsideUnion.length > 0) {
|
|
25316
|
-
return yield* Effect_exports.fail(
|
|
25317
|
-
equipmentError("mcp_outside_camp_catalog", { servers: outsideUnion })
|
|
25318
|
-
);
|
|
25319
|
-
}
|
|
25320
25348
|
const mcpResolution = resolveMcpServers(config2, role, requestedMcp?.serverNames);
|
|
25321
25349
|
if (mcpResolution.unknownServers.length > 0) {
|
|
25322
25350
|
return yield* Effect_exports.fail(
|
|
@@ -25355,8 +25383,40 @@ var makeConfigEquipmentResolver = (fs, path, config2, registry2 = makeHostToolRe
|
|
|
25355
25383
|
},
|
|
25356
25384
|
...request.overrides?.executionLimits === void 0 ? {} : { executionLimits: request.overrides.executionLimits }
|
|
25357
25385
|
};
|
|
25358
|
-
})
|
|
25359
|
-
|
|
25386
|
+
});
|
|
25387
|
+
return {
|
|
25388
|
+
resolve,
|
|
25389
|
+
/*
|
|
25390
|
+
* The identity of a live worker travels unchanged, and every category the
|
|
25391
|
+
* change stays silent about keeps what the worker already carries. Rebuilding
|
|
25392
|
+
* the untouched ones from the role turned a single `--skill` into a silent
|
|
25393
|
+
* revoke of the servers and binaries the worker had been given at hire.
|
|
25394
|
+
*/
|
|
25395
|
+
reresolve: (current, change) => {
|
|
25396
|
+
const carried = carriedTools(current);
|
|
25397
|
+
return resolve({
|
|
25398
|
+
...current.role === void 0 ? {} : { role: current.role },
|
|
25399
|
+
...current.preset === void 0 ? {} : { preset: current.preset },
|
|
25400
|
+
overrides: {
|
|
25401
|
+
...current.model === void 0 ? {} : { model: current.model },
|
|
25402
|
+
...current.thinkingLevel === void 0 ? {} : { thinkingLevel: current.thinkingLevel },
|
|
25403
|
+
readOnly: current.readOnly,
|
|
25404
|
+
builtinTools: change.builtinTools ?? current.builtinTools,
|
|
25405
|
+
customToolNames: change.customToolNames ?? carried.customToolNames,
|
|
25406
|
+
directTools: change.directTools ?? carried.bins,
|
|
25407
|
+
/*
|
|
25408
|
+
* Paths decide the set, so an unchanged worker keeps its exact paths
|
|
25409
|
+
* rather than names that would be re-resolved under the camp root.
|
|
25410
|
+
*/
|
|
25411
|
+
...change.skillNames === void 0 ? {} : { skillNames: change.skillNames },
|
|
25412
|
+
...change.skillNames === void 0 && change.skillPaths === void 0 ? { skillPaths: current.skillPaths } : change.skillPaths === void 0 ? {} : { skillPaths: change.skillPaths },
|
|
25413
|
+
mcp: change.mcp ?? current.mcp,
|
|
25414
|
+
...current.executionLimits === void 0 ? {} : { executionLimits: current.executionLimits }
|
|
25415
|
+
}
|
|
25416
|
+
});
|
|
25417
|
+
}
|
|
25418
|
+
};
|
|
25419
|
+
};
|
|
25360
25420
|
var ConfigEquipmentResolverLive = Layer_exports.effect(
|
|
25361
25421
|
EquipmentResolver,
|
|
25362
25422
|
Effect_exports.gen(function* () {
|
|
@@ -26151,7 +26211,7 @@ var makeWorkerEquipmentRpcHandlers = ({
|
|
|
26151
26211
|
},
|
|
26152
26212
|
operations.equip(commandContext(request), {
|
|
26153
26213
|
worker: workerIdentityFromDto(request.worker),
|
|
26154
|
-
equipment:
|
|
26214
|
+
equipment: equipmentChangeFromDto(request.equipment)
|
|
26155
26215
|
}).pipe(
|
|
26156
26216
|
Effect_exports.map(workerDetailFromRecord),
|
|
26157
26217
|
Effect_exports.mapError((error2) => failureFromHostOperation("equip", error2))
|
|
@@ -26489,6 +26549,8 @@ var directToolEnvironment = (source) => {
|
|
|
26489
26549
|
|
|
26490
26550
|
// packages/host/src/tools/directTools.ts
|
|
26491
26551
|
var DEFAULT_TIMEOUT_MS = 3e4;
|
|
26552
|
+
var TERMINATION_GRACE_MS = 2e3;
|
|
26553
|
+
var ABANDON_GRACE_MS = 2e3;
|
|
26492
26554
|
var DEFAULT_MAX_OUTPUT_BYTES = 64 * 1024;
|
|
26493
26555
|
var MAX_BUFFER_BYTES = 8 * 1024 * 1024;
|
|
26494
26556
|
var truncate = (value, limit) => {
|
|
@@ -26525,8 +26587,15 @@ var runBinary = (executablePath, args, options, environment, signal) => {
|
|
|
26525
26587
|
});
|
|
26526
26588
|
let timedOut = false;
|
|
26527
26589
|
let launchError;
|
|
26590
|
+
let settled = false;
|
|
26591
|
+
let killTimer;
|
|
26592
|
+
let abandonTimer;
|
|
26528
26593
|
const stop = () => {
|
|
26529
26594
|
child.kill("SIGTERM");
|
|
26595
|
+
killTimer ??= setTimeout(() => {
|
|
26596
|
+
child.kill("SIGKILL");
|
|
26597
|
+
abandonTimer = setTimeout(() => finish(void 0, "SIGKILL"), ABANDON_GRACE_MS);
|
|
26598
|
+
}, TERMINATION_GRACE_MS);
|
|
26530
26599
|
};
|
|
26531
26600
|
const stdout = collect(child.stdout, stop);
|
|
26532
26601
|
const stderr = collect(child.stderr, stop);
|
|
@@ -26538,18 +26607,18 @@ var runBinary = (executablePath, args, options, environment, signal) => {
|
|
|
26538
26607
|
timedOut = true;
|
|
26539
26608
|
stop();
|
|
26540
26609
|
}, options.timeoutMs ?? DEFAULT_TIMEOUT_MS);
|
|
26541
|
-
|
|
26542
|
-
if (
|
|
26543
|
-
|
|
26544
|
-
});
|
|
26545
|
-
child.on("close", (code, terminatedBy) => {
|
|
26610
|
+
const finish = (code, terminatedBy) => {
|
|
26611
|
+
if (settled) return;
|
|
26612
|
+
settled = true;
|
|
26546
26613
|
clearTimeout(timer);
|
|
26614
|
+
if (killTimer !== void 0) clearTimeout(killTimer);
|
|
26615
|
+
if (abandonTimer !== void 0) clearTimeout(abandonTimer);
|
|
26547
26616
|
const sandboxStatus = sandboxed ? parseDirectToolSandboxStatus(status.text()) : void 0;
|
|
26548
26617
|
resolve({
|
|
26549
26618
|
stdout: stdout.text(),
|
|
26550
26619
|
stderr: stderr.text(),
|
|
26551
26620
|
exitCode: sandboxStatus?.exitCode ?? code ?? void 0,
|
|
26552
|
-
signal: terminatedBy
|
|
26621
|
+
signal: terminatedBy,
|
|
26553
26622
|
timedOut,
|
|
26554
26623
|
/*
|
|
26555
26624
|
* A sandbox that never reached the command is only a refusal when the
|
|
@@ -26559,6 +26628,13 @@ var runBinary = (executablePath, args, options, environment, signal) => {
|
|
|
26559
26628
|
...sandboxStatus !== void 0 && !sandboxStatus.started && !timedOut && launchError === void 0 ? { sandboxFailed: true } : {},
|
|
26560
26629
|
...launchError === void 0 ? {} : { launchError }
|
|
26561
26630
|
});
|
|
26631
|
+
};
|
|
26632
|
+
child.on("error", (cause) => {
|
|
26633
|
+
if (signal?.aborted === true || cause.name === "AbortError") return;
|
|
26634
|
+
launchError = `${cause.code ?? cause.name}: ${cause.message}`;
|
|
26635
|
+
});
|
|
26636
|
+
child.on("close", (code, terminatedBy) => {
|
|
26637
|
+
finish(code, terminatedBy ?? void 0);
|
|
26562
26638
|
});
|
|
26563
26639
|
});
|
|
26564
26640
|
};
|
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-IORSBZKU.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-GEBZQLE7.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-LH753BUY.js";
|
|
62
62
|
import {
|
|
63
63
|
Cause_exports,
|
|
64
64
|
CommitPrototype,
|
|
@@ -239,7 +239,7 @@ import {
|
|
|
239
239
|
zipLeft,
|
|
240
240
|
zipRight,
|
|
241
241
|
zipWith
|
|
242
|
-
} from "./chunk-
|
|
242
|
+
} from "./chunk-F7LGUL2J.js";
|
|
243
243
|
|
|
244
244
|
// node_modules/.pnpm/ini@4.1.3/node_modules/ini/lib/ini.js
|
|
245
245
|
var require_ini = __commonJS({
|
|
@@ -19952,7 +19952,7 @@ var campResumeListCommand = Command_exports.make(
|
|
|
19952
19952
|
)
|
|
19953
19953
|
).pipe(Command_exports.withDescription("Lists saved runs of this project that resume can restore."));
|
|
19954
19954
|
var runIdArgument = Args_exports.text({ name: "runId" }).pipe(Args_exports.optional);
|
|
19955
|
-
var selectCampRunOnDemand = (items) => Effect_exports.promise(() => import("./chunk-
|
|
19955
|
+
var selectCampRunOnDemand = (items) => Effect_exports.promise(() => import("./chunk-EHPEGFN2.js")).pipe(
|
|
19956
19956
|
Effect_exports.flatMap((ui) => ui.selectCampRun({ items }))
|
|
19957
19957
|
);
|
|
19958
19958
|
var selectAndResume = (json) => {
|
|
@@ -20025,7 +20025,7 @@ var rootCommand = Command_exports.make(
|
|
|
20025
20025
|
).pipe(Command_exports.withDescription("Runs and observes a camp of collaborating workers."));
|
|
20026
20026
|
|
|
20027
20027
|
// packages/cli/src/commands/doctorCommand.ts
|
|
20028
|
-
var runDoctorOnDemand = Effect_exports.promise(() => import("./chunk-
|
|
20028
|
+
var runDoctorOnDemand = Effect_exports.promise(() => import("./chunk-QQBVNDLC.js")).pipe(
|
|
20029
20029
|
Effect_exports.flatMap((doctor) => doctor.runDoctor)
|
|
20030
20030
|
);
|
|
20031
20031
|
var statusLabel = {
|
|
@@ -20209,6 +20209,48 @@ var equipmentRequest = (role, preset, overrides) => ({
|
|
|
20209
20209
|
...Option_exports.isSome(preset) ? { preset: preset.value } : {},
|
|
20210
20210
|
...overrides === void 0 ? {} : { overrides }
|
|
20211
20211
|
});
|
|
20212
|
+
var equipmentChangeOptions = {
|
|
20213
|
+
tools: toolOption,
|
|
20214
|
+
customTools: customToolOption,
|
|
20215
|
+
skills: skillOption,
|
|
20216
|
+
skillPaths: skillPathOption,
|
|
20217
|
+
directTools: directToolOption,
|
|
20218
|
+
mcp: mcpOption,
|
|
20219
|
+
mcpTools: mcpToolOption,
|
|
20220
|
+
noTools: noToolsOption,
|
|
20221
|
+
noCustomTools: noCustomToolsOption,
|
|
20222
|
+
noSkills: noSkillsOption,
|
|
20223
|
+
noDirectTools: noDirectToolsOption,
|
|
20224
|
+
noMcp: noMcpOption
|
|
20225
|
+
};
|
|
20226
|
+
var resolveEquipmentChange = (operation, input) => {
|
|
20227
|
+
const full = {
|
|
20228
|
+
...input,
|
|
20229
|
+
model: Option_exports.none(),
|
|
20230
|
+
thinking: Option_exports.none(),
|
|
20231
|
+
access: Option_exports.none()
|
|
20232
|
+
};
|
|
20233
|
+
const categories = conflictingEquipmentCategories(full);
|
|
20234
|
+
if (categories.length > 0) {
|
|
20235
|
+
return Effect_exports.fail(
|
|
20236
|
+
new CliEquipmentConflict({
|
|
20237
|
+
operation,
|
|
20238
|
+
code: "equipment_flag_conflict",
|
|
20239
|
+
message: `granting and clearing the same equipment: ${categories.join(", ")}`,
|
|
20240
|
+
categories
|
|
20241
|
+
})
|
|
20242
|
+
);
|
|
20243
|
+
}
|
|
20244
|
+
const overrides = equipmentOverrides(full) ?? {};
|
|
20245
|
+
return Effect_exports.succeed({
|
|
20246
|
+
...overrides.builtinTools === void 0 ? {} : { builtinTools: overrides.builtinTools },
|
|
20247
|
+
...overrides.customToolNames === void 0 ? {} : { customToolNames: overrides.customToolNames },
|
|
20248
|
+
...overrides.directTools === void 0 ? {} : { directTools: overrides.directTools },
|
|
20249
|
+
...overrides.skillNames === void 0 ? {} : { skillNames: overrides.skillNames },
|
|
20250
|
+
...overrides.skillPaths === void 0 ? {} : { skillPaths: overrides.skillPaths },
|
|
20251
|
+
...overrides.mcp === void 0 ? {} : { mcp: overrides.mcp }
|
|
20252
|
+
});
|
|
20253
|
+
};
|
|
20212
20254
|
|
|
20213
20255
|
// packages/cli/src/commands/equipCommand.ts
|
|
20214
20256
|
var equipCommand = Command_exports.make(
|
|
@@ -20216,20 +20258,18 @@ var equipCommand = Command_exports.make(
|
|
|
20216
20258
|
{
|
|
20217
20259
|
worker: workerArgument,
|
|
20218
20260
|
byId: byIdOption,
|
|
20219
|
-
|
|
20220
|
-
preset: presetOption,
|
|
20221
|
-
...equipmentOptions,
|
|
20261
|
+
...equipmentChangeOptions,
|
|
20222
20262
|
json: jsonOption
|
|
20223
20263
|
},
|
|
20224
|
-
({ worker, byId,
|
|
20264
|
+
({ worker, byId, json, ...equipment }) => resolveEquipmentChange("equip", equipment).pipe(
|
|
20225
20265
|
Effect_exports.flatMap(
|
|
20226
|
-
(
|
|
20266
|
+
(change) => withCampRpc(
|
|
20227
20267
|
({ client, command: command2 }) => command2().pipe(
|
|
20228
20268
|
Effect_exports.flatMap(
|
|
20229
20269
|
(context) => client.Equip({
|
|
20230
20270
|
...context,
|
|
20231
20271
|
worker: workerSelector(worker, byId),
|
|
20232
|
-
equipment:
|
|
20272
|
+
equipment: change
|
|
20233
20273
|
})
|
|
20234
20274
|
)
|
|
20235
20275
|
),
|
|
@@ -20239,7 +20279,9 @@ var equipCommand = Command_exports.make(
|
|
|
20239
20279
|
printValue(json, formatWorker)
|
|
20240
20280
|
)
|
|
20241
20281
|
).pipe(
|
|
20242
|
-
Command_exports.withDescription(
|
|
20282
|
+
Command_exports.withDescription(
|
|
20283
|
+
"Hands a live worker skills, MCP servers, binaries and tools, or takes them back."
|
|
20284
|
+
)
|
|
20243
20285
|
);
|
|
20244
20286
|
|
|
20245
20287
|
// packages/cli/src/client/campStartupFlow.ts
|
|
@@ -20735,7 +20777,7 @@ var command = rootCommand.pipe(
|
|
|
20735
20777
|
);
|
|
20736
20778
|
var cli = Command_exports.run(command, {
|
|
20737
20779
|
name: "priiisk camp control",
|
|
20738
|
-
version: "0.1.
|
|
20780
|
+
version: "0.1.9"
|
|
20739
20781
|
});
|
|
20740
20782
|
var runCliCommand = (argumentsList) => cli(argumentsList).pipe(
|
|
20741
20783
|
Effect_exports.matchEffect({
|
package/package.json
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "priiisk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.9",
|
|
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-
|
|
17
|
-
"dist/chunk-
|
|
18
|
-
"dist/chunk-
|
|
19
|
-
"dist/chunk-
|
|
10
|
+
"dist/chunk-EHPEGFN2.js",
|
|
11
|
+
"dist/chunk-F7LGUL2J.js",
|
|
12
|
+
"dist/chunk-GEBZQLE7.js",
|
|
13
|
+
"dist/chunk-IORSBZKU.js",
|
|
14
|
+
"dist/chunk-LH753BUY.js",
|
|
15
|
+
"dist/chunk-LH753BUY.js.LEGAL.txt",
|
|
16
|
+
"dist/chunk-NIJ2J45R.js",
|
|
17
|
+
"dist/chunk-QEUSNJ3D.js",
|
|
18
|
+
"dist/chunk-QEUSNJ3D.js.LEGAL.txt",
|
|
19
|
+
"dist/chunk-QQBVNDLC.js",
|
|
20
20
|
"dist/priiisk-host.js",
|
|
21
21
|
"dist/priiisk.js",
|
|
22
22
|
"profiles",
|
|
File without changes
|
|
File without changes
|