@tekmidian/pai 0.60.0 → 0.61.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chain-DFlzAfDE.mjs → chain-C5oeyUg4.mjs} +4 -4
- package/dist/{chain-DFlzAfDE.mjs.map → chain-C5oeyUg4.mjs.map} +1 -1
- package/dist/cli/index.mjs +12 -12
- package/dist/cli/program.mjs +12 -12
- package/dist/{config-msER8xj_.mjs → config-CQCmH_gV.mjs} +2 -1
- package/dist/config-CQCmH_gV.mjs.map +1 -0
- package/dist/{config-GceCMUxa.mjs → config-DjXq_W42.mjs} +1 -1
- package/dist/{context-handover-cache-DF0xWVB0.mjs → context-handover-cache-BdtJZpgv.mjs} +4 -4
- package/dist/{context-handover-cache-DF0xWVB0.mjs.map → context-handover-cache-BdtJZpgv.mjs.map} +1 -1
- package/dist/daemon/index.mjs +11 -11
- package/dist/{daemon-DArRKBlk.mjs → daemon-DSsIEqzW.mjs} +26 -19
- package/dist/{daemon-DArRKBlk.mjs.map → daemon-DSsIEqzW.mjs.map} +1 -1
- package/dist/daemon-MoFF4oeg.mjs +19 -0
- package/dist/daemon-mcp/index.mjs +9 -11
- package/dist/daemon-mcp/index.mjs.map +1 -1
- package/dist/{factory-D6I2jmjQ.mjs → factory-DW7BCJJT.mjs} +1 -1
- package/dist/{factory-ChfAvCzO.mjs → factory-EUUhSSoq.mjs} +5 -6
- package/dist/factory-EUUhSSoq.mjs.map +1 -0
- package/dist/{fallback-B7VEMMRn.mjs → fallback-DDbJVaR8.mjs} +12 -14
- package/dist/{fallback-B7VEMMRn.mjs.map → fallback-DDbJVaR8.mjs.map} +1 -1
- package/dist/hooks/block-sleep-poll.mjs.map +2 -2
- package/dist/hooks/context-compression-hook.mjs.map +1 -1
- package/dist/hooks/post-compact-inject.mjs.map +1 -1
- package/dist/hooks/route-agents-to-worker.mjs +5 -5
- package/dist/hooks/route-agents-to-worker.mjs.map +3 -3
- package/dist/hooks/security-validator.mjs +60 -60
- package/dist/hooks/security-validator.mjs.map +3 -3
- package/dist/hooks/stop-hook.mjs +15 -15
- package/dist/hooks/stop-hook.mjs.map +3 -3
- package/dist/hooks/update-tab-on-action.mjs +14 -12
- package/dist/hooks/update-tab-on-action.mjs.map +3 -3
- package/dist/hooks/update-tab-titles.mjs +13 -9
- package/dist/hooks/update-tab-titles.mjs.map +3 -3
- package/dist/hooks/whisper-rules.mjs +2 -2
- package/dist/hooks/whisper-rules.mjs.map +3 -3
- package/dist/hooks/worker-proxy.mjs +5 -5
- package/dist/hooks/worker-proxy.mjs.map +3 -3
- package/dist/hooks/worker-status-line.mjs +5 -5
- package/dist/hooks/worker-status-line.mjs.map +3 -3
- package/dist/hooks/worker-supervision.mjs +5 -5
- package/dist/hooks/worker-supervision.mjs.map +3 -3
- package/dist/main-resolver-CxOsxtOr.mjs +7 -0
- package/dist/{main-resolver-BqTjt-GL.mjs → main-resolver-DIQ6m_RA.mjs} +4 -4
- package/dist/{main-resolver-BqTjt-GL.mjs.map → main-resolver-DIQ6m_RA.mjs.map} +1 -1
- package/dist/{planner-DbpsMZqY.mjs → planner-D8jAr_sx.mjs} +7 -7
- package/dist/{planner-DbpsMZqY.mjs.map → planner-D8jAr_sx.mjs.map} +1 -1
- package/dist/{program-QSuci3RH.mjs → program-BTdspOOa.mjs} +131 -81
- package/dist/program-BTdspOOa.mjs.map +1 -0
- package/dist/{run-BFxuNnIJ.mjs → run-CxxZKEZw.mjs} +336 -174
- package/dist/run-CxxZKEZw.mjs.map +1 -0
- package/dist/{run-env-kbWVwUvU.mjs → run-env-BE5xyCwy.mjs} +26 -7
- package/dist/run-env-BE5xyCwy.mjs.map +1 -0
- package/dist/{server-B0vBmfJt.mjs → server-BY6AedmC.mjs} +2 -2
- package/dist/{server-B0vBmfJt.mjs.map → server-BY6AedmC.mjs.map} +1 -1
- package/dist/{session-keepalive-CUcFa8ld.mjs → session-keepalive-urk--pfa.mjs} +5 -5
- package/dist/{session-keepalive-CUcFa8ld.mjs.map → session-keepalive-urk--pfa.mjs.map} +1 -1
- package/dist/{tools-CaTZnIau.mjs → tools-qXyHFwNj.mjs} +2 -2
- package/dist/{tools-CaTZnIau.mjs.map → tools-qXyHFwNj.mjs.map} +1 -1
- package/dist/{tools-_7MF8Ebb.mjs → tools-r-7ZG8B5.mjs} +3 -3
- package/dist/{wakeup-CTX3rlz-.mjs → wakeup-C48hcN6O.mjs} +2 -2
- package/dist/{wakeup-CTX3rlz-.mjs.map → wakeup-C48hcN6O.mjs.map} +1 -1
- package/dist/work-queue-worker-1_VBfI_k.mjs +11 -0
- package/dist/{work-queue-worker-B4eZGy5n.mjs → work-queue-worker-DUvPiwGO.mjs} +2 -2
- package/dist/{work-queue-worker-B4eZGy5n.mjs.map → work-queue-worker-DUvPiwGO.mjs.map} +1 -1
- package/docs/commands/worker.md +1 -0
- package/package.json +1 -1
- package/src/hooks/ts/lib/tab-title.ts +18 -0
- package/src/hooks/ts/post-tool-use/update-tab-on-action.ts +3 -20
- package/src/hooks/ts/stop/stop-hook.ts +4 -15
- package/src/hooks/ts/user-prompt/update-tab-titles.ts +2 -10
- package/dist/config-msER8xj_.mjs.map +0 -1
- package/dist/daemon-BppwJtrH.mjs +0 -19
- package/dist/factory-ChfAvCzO.mjs.map +0 -1
- package/dist/main-resolver-CCojcYr2.mjs +0 -7
- package/dist/program-QSuci3RH.mjs.map +0 -1
- package/dist/run-BFxuNnIJ.mjs.map +0 -1
- package/dist/run-env-kbWVwUvU.mjs.map +0 -1
- package/dist/work-queue-worker-DuhZmfDB.mjs +0 -11
|
@@ -3997,10 +3997,10 @@ var require_resolve_block_map = __commonJS({
|
|
|
3997
3997
|
let offset = bm.offset;
|
|
3998
3998
|
let commentEnd = null;
|
|
3999
3999
|
for (const collItem of bm.items) {
|
|
4000
|
-
const { start, key, sep, value } = collItem;
|
|
4000
|
+
const { start, key, sep: sep2, value } = collItem;
|
|
4001
4001
|
const keyProps = resolveProps.resolveProps(start, {
|
|
4002
4002
|
indicator: "explicit-key-ind",
|
|
4003
|
-
next: key ??
|
|
4003
|
+
next: key ?? sep2?.[0],
|
|
4004
4004
|
offset,
|
|
4005
4005
|
onError,
|
|
4006
4006
|
parentIndent: bm.indent,
|
|
@@ -4014,7 +4014,7 @@ var require_resolve_block_map = __commonJS({
|
|
|
4014
4014
|
else if ("indent" in key && key.indent !== bm.indent)
|
|
4015
4015
|
onError(offset, "BAD_INDENT", startColMsg);
|
|
4016
4016
|
}
|
|
4017
|
-
if (!keyProps.anchor && !keyProps.tag && !
|
|
4017
|
+
if (!keyProps.anchor && !keyProps.tag && !sep2) {
|
|
4018
4018
|
commentEnd = keyProps.end;
|
|
4019
4019
|
if (keyProps.comment) {
|
|
4020
4020
|
if (map.comment)
|
|
@@ -4038,7 +4038,7 @@ var require_resolve_block_map = __commonJS({
|
|
|
4038
4038
|
ctx.atKey = false;
|
|
4039
4039
|
if (utilMapIncludes.mapIncludes(ctx, map.items, keyNode))
|
|
4040
4040
|
onError(keyStart, "DUPLICATE_KEY", "Map keys must be unique");
|
|
4041
|
-
const valueProps = resolveProps.resolveProps(
|
|
4041
|
+
const valueProps = resolveProps.resolveProps(sep2 ?? [], {
|
|
4042
4042
|
indicator: "map-value-ind",
|
|
4043
4043
|
next: value,
|
|
4044
4044
|
offset: keyNode.range[2],
|
|
@@ -4054,7 +4054,7 @@ var require_resolve_block_map = __commonJS({
|
|
|
4054
4054
|
if (ctx.options.strict && keyProps.start < valueProps.found.offset - 1024)
|
|
4055
4055
|
onError(keyNode.range, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit block mapping key");
|
|
4056
4056
|
}
|
|
4057
|
-
const valueNode = value ? composeNode(ctx, value, valueProps, onError) : composeEmptyNode(ctx, offset,
|
|
4057
|
+
const valueNode = value ? composeNode(ctx, value, valueProps, onError) : composeEmptyNode(ctx, offset, sep2, null, valueProps, onError);
|
|
4058
4058
|
if (ctx.schema.compat)
|
|
4059
4059
|
utilFlowIndentCheck.flowIndentCheck(bm.indent, value, onError);
|
|
4060
4060
|
offset = valueNode.range[2];
|
|
@@ -4145,7 +4145,7 @@ var require_resolve_end = __commonJS({
|
|
|
4145
4145
|
let comment = "";
|
|
4146
4146
|
if (end) {
|
|
4147
4147
|
let hasSpace = false;
|
|
4148
|
-
let
|
|
4148
|
+
let sep2 = "";
|
|
4149
4149
|
for (const token of end) {
|
|
4150
4150
|
const { source, type } = token;
|
|
4151
4151
|
switch (type) {
|
|
@@ -4159,13 +4159,13 @@ var require_resolve_end = __commonJS({
|
|
|
4159
4159
|
if (!comment)
|
|
4160
4160
|
comment = cb;
|
|
4161
4161
|
else
|
|
4162
|
-
comment +=
|
|
4163
|
-
|
|
4162
|
+
comment += sep2 + cb;
|
|
4163
|
+
sep2 = "";
|
|
4164
4164
|
break;
|
|
4165
4165
|
}
|
|
4166
4166
|
case "newline":
|
|
4167
4167
|
if (comment)
|
|
4168
|
-
|
|
4168
|
+
sep2 += source;
|
|
4169
4169
|
hasSpace = true;
|
|
4170
4170
|
break;
|
|
4171
4171
|
default:
|
|
@@ -4208,18 +4208,18 @@ var require_resolve_flow_collection = __commonJS({
|
|
|
4208
4208
|
let offset = fc.offset + fc.start.source.length;
|
|
4209
4209
|
for (let i = 0; i < fc.items.length; ++i) {
|
|
4210
4210
|
const collItem = fc.items[i];
|
|
4211
|
-
const { start, key, sep, value } = collItem;
|
|
4211
|
+
const { start, key, sep: sep2, value } = collItem;
|
|
4212
4212
|
const props = resolveProps.resolveProps(start, {
|
|
4213
4213
|
flow: fcName,
|
|
4214
4214
|
indicator: "explicit-key-ind",
|
|
4215
|
-
next: key ??
|
|
4215
|
+
next: key ?? sep2?.[0],
|
|
4216
4216
|
offset,
|
|
4217
4217
|
onError,
|
|
4218
4218
|
parentIndent: fc.indent,
|
|
4219
4219
|
startOnNewline: false
|
|
4220
4220
|
});
|
|
4221
4221
|
if (!props.found) {
|
|
4222
|
-
if (!props.anchor && !props.tag && !
|
|
4222
|
+
if (!props.anchor && !props.tag && !sep2 && !value) {
|
|
4223
4223
|
if (i === 0 && props.comma)
|
|
4224
4224
|
onError(props.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${fcName}`);
|
|
4225
4225
|
else if (i < fc.items.length - 1)
|
|
@@ -4273,8 +4273,8 @@ var require_resolve_flow_collection = __commonJS({
|
|
|
4273
4273
|
}
|
|
4274
4274
|
}
|
|
4275
4275
|
}
|
|
4276
|
-
if (!isMap && !
|
|
4277
|
-
const valueNode = value ? composeNode(ctx, value, props, onError) : composeEmptyNode(ctx, props.end,
|
|
4276
|
+
if (!isMap && !sep2 && !props.found) {
|
|
4277
|
+
const valueNode = value ? composeNode(ctx, value, props, onError) : composeEmptyNode(ctx, props.end, sep2, null, props, onError);
|
|
4278
4278
|
coll.items.push(valueNode);
|
|
4279
4279
|
offset = valueNode.range[2];
|
|
4280
4280
|
if (isBlock(value))
|
|
@@ -4286,7 +4286,7 @@ var require_resolve_flow_collection = __commonJS({
|
|
|
4286
4286
|
if (isBlock(key))
|
|
4287
4287
|
onError(keyNode.range, "BLOCK_IN_FLOW", blockMsg);
|
|
4288
4288
|
ctx.atKey = false;
|
|
4289
|
-
const valueProps = resolveProps.resolveProps(
|
|
4289
|
+
const valueProps = resolveProps.resolveProps(sep2 ?? [], {
|
|
4290
4290
|
flow: fcName,
|
|
4291
4291
|
indicator: "map-value-ind",
|
|
4292
4292
|
next: value,
|
|
@@ -4297,8 +4297,8 @@ var require_resolve_flow_collection = __commonJS({
|
|
|
4297
4297
|
});
|
|
4298
4298
|
if (valueProps.found) {
|
|
4299
4299
|
if (!isMap && !props.found && ctx.options.strict) {
|
|
4300
|
-
if (
|
|
4301
|
-
for (const st of
|
|
4300
|
+
if (sep2)
|
|
4301
|
+
for (const st of sep2) {
|
|
4302
4302
|
if (st === valueProps.found)
|
|
4303
4303
|
break;
|
|
4304
4304
|
if (st.type === "newline") {
|
|
@@ -4315,7 +4315,7 @@ var require_resolve_flow_collection = __commonJS({
|
|
|
4315
4315
|
else
|
|
4316
4316
|
onError(valueProps.start, "MISSING_CHAR", `Missing , or : between ${fcName} items`);
|
|
4317
4317
|
}
|
|
4318
|
-
const valueNode = value ? composeNode(ctx, value, valueProps, onError) : valueProps.found ? composeEmptyNode(ctx, valueProps.end,
|
|
4318
|
+
const valueNode = value ? composeNode(ctx, value, valueProps, onError) : valueProps.found ? composeEmptyNode(ctx, valueProps.end, sep2, null, valueProps, onError) : null;
|
|
4319
4319
|
if (valueNode) {
|
|
4320
4320
|
if (isBlock(value))
|
|
4321
4321
|
onError(valueNode.range, "BLOCK_IN_FLOW", blockMsg);
|
|
@@ -4495,7 +4495,7 @@ var require_resolve_block_scalar = __commonJS({
|
|
|
4495
4495
|
chompStart = i + 1;
|
|
4496
4496
|
}
|
|
4497
4497
|
let value = "";
|
|
4498
|
-
let
|
|
4498
|
+
let sep2 = "";
|
|
4499
4499
|
let prevMoreIndented = false;
|
|
4500
4500
|
for (let i = 0; i < contentStart; ++i)
|
|
4501
4501
|
value += lines[i][0].slice(trimIndent) + "\n";
|
|
@@ -4512,24 +4512,24 @@ var require_resolve_block_scalar = __commonJS({
|
|
|
4512
4512
|
indent = "";
|
|
4513
4513
|
}
|
|
4514
4514
|
if (type === Scalar2.Scalar.BLOCK_LITERAL) {
|
|
4515
|
-
value +=
|
|
4516
|
-
|
|
4515
|
+
value += sep2 + indent.slice(trimIndent) + content;
|
|
4516
|
+
sep2 = "\n";
|
|
4517
4517
|
} else if (indent.length > trimIndent || content[0] === " ") {
|
|
4518
|
-
if (
|
|
4519
|
-
|
|
4520
|
-
else if (!prevMoreIndented &&
|
|
4521
|
-
|
|
4522
|
-
value +=
|
|
4523
|
-
|
|
4518
|
+
if (sep2 === " ")
|
|
4519
|
+
sep2 = "\n";
|
|
4520
|
+
else if (!prevMoreIndented && sep2 === "\n")
|
|
4521
|
+
sep2 = "\n\n";
|
|
4522
|
+
value += sep2 + indent.slice(trimIndent) + content;
|
|
4523
|
+
sep2 = "\n";
|
|
4524
4524
|
prevMoreIndented = true;
|
|
4525
4525
|
} else if (content === "") {
|
|
4526
|
-
if (
|
|
4526
|
+
if (sep2 === "\n")
|
|
4527
4527
|
value += "\n";
|
|
4528
4528
|
else
|
|
4529
|
-
|
|
4529
|
+
sep2 = "\n";
|
|
4530
4530
|
} else {
|
|
4531
|
-
value +=
|
|
4532
|
-
|
|
4531
|
+
value += sep2 + content;
|
|
4532
|
+
sep2 = " ";
|
|
4533
4533
|
prevMoreIndented = false;
|
|
4534
4534
|
}
|
|
4535
4535
|
}
|
|
@@ -4712,25 +4712,25 @@ var require_resolve_flow_scalar = __commonJS({
|
|
|
4712
4712
|
trimBoth = /^[ \t]+|[ \t]+$/g;
|
|
4713
4713
|
}
|
|
4714
4714
|
let res = match[1].replace(trimEnd, "");
|
|
4715
|
-
let
|
|
4715
|
+
let sep2 = " ";
|
|
4716
4716
|
let pos = line.lastIndex;
|
|
4717
4717
|
while (match = line.exec(source)) {
|
|
4718
4718
|
const lm = match[1].replace(trimBoth, "");
|
|
4719
4719
|
if (lm === "") {
|
|
4720
|
-
if (
|
|
4721
|
-
res +=
|
|
4720
|
+
if (sep2 === "\n")
|
|
4721
|
+
res += sep2;
|
|
4722
4722
|
else
|
|
4723
|
-
|
|
4723
|
+
sep2 = "\n";
|
|
4724
4724
|
} else {
|
|
4725
|
-
res +=
|
|
4726
|
-
|
|
4725
|
+
res += sep2 + lm;
|
|
4726
|
+
sep2 = " ";
|
|
4727
4727
|
}
|
|
4728
4728
|
pos = line.lastIndex;
|
|
4729
4729
|
}
|
|
4730
4730
|
const last = /[ \t]*(.*)/sy;
|
|
4731
4731
|
last.lastIndex = pos;
|
|
4732
4732
|
match = last.exec(source);
|
|
4733
|
-
return res +
|
|
4733
|
+
return res + sep2 + (match?.[1] ?? "");
|
|
4734
4734
|
}
|
|
4735
4735
|
function doubleQuotedValue(source, onError) {
|
|
4736
4736
|
let res = "";
|
|
@@ -5540,14 +5540,14 @@ var require_cst_stringify = __commonJS({
|
|
|
5540
5540
|
}
|
|
5541
5541
|
}
|
|
5542
5542
|
}
|
|
5543
|
-
function stringifyItem({ start, key, sep, value }) {
|
|
5543
|
+
function stringifyItem({ start, key, sep: sep2, value }) {
|
|
5544
5544
|
let res = "";
|
|
5545
5545
|
for (const st of start)
|
|
5546
5546
|
res += st.source;
|
|
5547
5547
|
if (key)
|
|
5548
5548
|
res += stringifyToken(key);
|
|
5549
|
-
if (
|
|
5550
|
-
for (const st of
|
|
5549
|
+
if (sep2)
|
|
5550
|
+
for (const st of sep2)
|
|
5551
5551
|
res += st.source;
|
|
5552
5552
|
if (value)
|
|
5553
5553
|
res += stringifyToken(value);
|
|
@@ -6714,18 +6714,18 @@ var require_parser = __commonJS({
|
|
|
6714
6714
|
if (this.type === "map-value-ind") {
|
|
6715
6715
|
const prev = getPrevProps(this.peek(2));
|
|
6716
6716
|
const start = getFirstKeyStartProps(prev);
|
|
6717
|
-
let
|
|
6717
|
+
let sep2;
|
|
6718
6718
|
if (scalar.end) {
|
|
6719
|
-
|
|
6720
|
-
|
|
6719
|
+
sep2 = scalar.end;
|
|
6720
|
+
sep2.push(this.sourceToken);
|
|
6721
6721
|
delete scalar.end;
|
|
6722
6722
|
} else
|
|
6723
|
-
|
|
6723
|
+
sep2 = [this.sourceToken];
|
|
6724
6724
|
const map = {
|
|
6725
6725
|
type: "block-map",
|
|
6726
6726
|
offset: scalar.offset,
|
|
6727
6727
|
indent: scalar.indent,
|
|
6728
|
-
items: [{ start, key: scalar, sep }]
|
|
6728
|
+
items: [{ start, key: scalar, sep: sep2 }]
|
|
6729
6729
|
};
|
|
6730
6730
|
this.onKeyLine = true;
|
|
6731
6731
|
this.stack[this.stack.length - 1] = map;
|
|
@@ -6878,15 +6878,15 @@ var require_parser = __commonJS({
|
|
|
6878
6878
|
} else if (isFlowToken(it.key) && !includesToken(it.sep, "newline")) {
|
|
6879
6879
|
const start2 = getFirstKeyStartProps(it.start);
|
|
6880
6880
|
const key = it.key;
|
|
6881
|
-
const
|
|
6882
|
-
|
|
6881
|
+
const sep2 = it.sep;
|
|
6882
|
+
sep2.push(this.sourceToken);
|
|
6883
6883
|
delete it.key;
|
|
6884
6884
|
delete it.sep;
|
|
6885
6885
|
this.stack.push({
|
|
6886
6886
|
type: "block-map",
|
|
6887
6887
|
offset: this.offset,
|
|
6888
6888
|
indent: this.indent,
|
|
6889
|
-
items: [{ start: start2, key, sep }]
|
|
6889
|
+
items: [{ start: start2, key, sep: sep2 }]
|
|
6890
6890
|
});
|
|
6891
6891
|
} else if (start.length > 0) {
|
|
6892
6892
|
it.sep = it.sep.concat(start, this.sourceToken);
|
|
@@ -7080,13 +7080,13 @@ var require_parser = __commonJS({
|
|
|
7080
7080
|
const prev = getPrevProps(parent);
|
|
7081
7081
|
const start = getFirstKeyStartProps(prev);
|
|
7082
7082
|
fixFlowSeqItems(fc);
|
|
7083
|
-
const
|
|
7084
|
-
|
|
7083
|
+
const sep2 = fc.end.splice(1, fc.end.length);
|
|
7084
|
+
sep2.push(this.sourceToken);
|
|
7085
7085
|
const map = {
|
|
7086
7086
|
type: "block-map",
|
|
7087
7087
|
offset: fc.offset,
|
|
7088
7088
|
indent: fc.indent,
|
|
7089
|
-
items: [{ start, key: fc, sep }]
|
|
7089
|
+
items: [{ start, key: fc, sep: sep2 }]
|
|
7090
7090
|
};
|
|
7091
7091
|
this.onKeyLine = true;
|
|
7092
7092
|
this.stack[this.stack.length - 1] = map;
|
|
@@ -7366,7 +7366,7 @@ var require_dist = __commonJS({
|
|
|
7366
7366
|
|
|
7367
7367
|
// src/hooks/ts/pre-tool-use/security-validator.ts
|
|
7368
7368
|
import { appendFileSync, mkdirSync as mkdirSync3, existsSync as existsSync6 } from "fs";
|
|
7369
|
-
import { dirname as
|
|
7369
|
+
import { dirname as dirname6, resolve as resolve3 } from "path";
|
|
7370
7370
|
|
|
7371
7371
|
// src/hooks/ts/lib/pai-paths.ts
|
|
7372
7372
|
import { homedir as homedir2 } from "os";
|
|
@@ -7634,7 +7634,7 @@ function paiSocketPath() {
|
|
|
7634
7634
|
|
|
7635
7635
|
// src/config/main-config.ts
|
|
7636
7636
|
var import_yaml2 = __toESM(require_dist(), 1);
|
|
7637
|
-
import { existsSync as existsSync4, readFileSync as readFileSync4, renameSync as renameSync3 } from "node:fs";
|
|
7637
|
+
import { existsSync as existsSync4, readFileSync as readFileSync4, renameSync as renameSync3, chmodSync as chmodSync2 } from "node:fs";
|
|
7638
7638
|
import { dirname as dirname2, join as join3, basename } from "node:path";
|
|
7639
7639
|
|
|
7640
7640
|
// src/config/json-store.ts
|
|
@@ -7766,7 +7766,7 @@ function readMainConfigRaw(path = CONFIG_FILE) {
|
|
|
7766
7766
|
|
|
7767
7767
|
// src/workers/workers-config.ts
|
|
7768
7768
|
var import_yaml3 = __toESM(require_dist(), 1);
|
|
7769
|
-
import { existsSync as existsSync5, readFileSync as readFileSync5, writeFileSync as writeFileSync2, chmodSync as
|
|
7769
|
+
import { existsSync as existsSync5, readFileSync as readFileSync5, writeFileSync as writeFileSync2, chmodSync as chmodSync3 } from "node:fs";
|
|
7770
7770
|
import { homedir as homedir4 } from "node:os";
|
|
7771
7771
|
import { dirname as dirname4, join as join5 } from "node:path";
|
|
7772
7772
|
var WORKERS_YAML_FILENAME = "workers.yaml";
|
|
@@ -7828,7 +7828,7 @@ function parseBuiltinAnthropic(raw, pathPrefix) {
|
|
|
7828
7828
|
);
|
|
7829
7829
|
}
|
|
7830
7830
|
if (p.models === void 0) return { ...NATIVE_ANTHROPIC_MODELS };
|
|
7831
|
-
return parseModelsBlock(`${pathPrefix}.models`, p.models);
|
|
7831
|
+
return { ...NATIVE_ANTHROPIC_MODELS, ...parseModelsBlock(`${pathPrefix}.models`, p.models) };
|
|
7832
7832
|
}
|
|
7833
7833
|
function lineOf(doc, path) {
|
|
7834
7834
|
try {
|
|
@@ -7967,8 +7967,8 @@ function readWorkersYaml(yamlPath) {
|
|
|
7967
7967
|
// src/workers/config.ts
|
|
7968
7968
|
var ANTHROPIC_NATIVE = "anthropic";
|
|
7969
7969
|
var NATIVE_ANTHROPIC_MODELS = {
|
|
7970
|
-
default: "
|
|
7971
|
-
fast: "
|
|
7970
|
+
default: "sonnet",
|
|
7971
|
+
fast: "haiku"
|
|
7972
7972
|
};
|
|
7973
7973
|
var MODEL_TIERS = ["haiku", "sonnet", "opus"];
|
|
7974
7974
|
var PROVIDER_TAGS = [
|
|
@@ -8461,7 +8461,7 @@ function workersLogDir(config) {
|
|
|
8461
8461
|
}
|
|
8462
8462
|
|
|
8463
8463
|
// src/workers/worktree.ts
|
|
8464
|
-
import { isAbsolute, join as join7, resolve as resolve2 } from "node:path";
|
|
8464
|
+
import { dirname as dirname5, isAbsolute, join as join7, resolve as resolve2, sep } from "node:path";
|
|
8465
8465
|
function worktreesDir(logDir) {
|
|
8466
8466
|
return join7(logDir, "worktrees");
|
|
8467
8467
|
}
|
|
@@ -8546,7 +8546,7 @@ function logSecurityEvent(event) {
|
|
|
8546
8546
|
const logPath = securityEventsPath();
|
|
8547
8547
|
const entry = JSON.stringify({ timestamp: (/* @__PURE__ */ new Date()).toISOString(), ...event }) + "\n";
|
|
8548
8548
|
try {
|
|
8549
|
-
const dir =
|
|
8549
|
+
const dir = dirname6(logPath);
|
|
8550
8550
|
if (!existsSync6(dir)) {
|
|
8551
8551
|
mkdirSync3(dir, { recursive: true });
|
|
8552
8552
|
}
|