@tekmidian/pai 1.0.2 → 1.0.4
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/.claude-plugin/plugin.json +1 -1
- package/dist/{auto-route-B4azPk4l.mjs → auto-route-21GdHL70.mjs} +2 -2
- package/dist/auto-route-C3S2W3Bc.mjs +11 -0
- package/dist/{budget-Dod6rnA9.mjs → budget-BrloTOZW.mjs} +1 -1
- package/dist/{chain-D-yvET_y.mjs → chain-D7PFur8Y.mjs} +2 -2
- package/dist/cli/index.mjs +82 -198
- package/dist/{cockpit-actions-BWunx3rY.mjs → cockpit-actions-BfRMr2sm.mjs} +6 -6
- package/dist/{cockpit-actions-C8GlTzts.mjs → cockpit-actions-OodH_vx_.mjs} +20 -18
- package/dist/{cockpit-memory-vTlFWV7F.mjs → cockpit-memory-teG9M8bG.mjs} +6 -6
- package/dist/config/defaults/config.yaml +6 -0
- package/dist/{controls-BcKFHeG1.mjs → controls-JLm6g0yP.mjs} +7 -5
- package/dist/daemon/index.mjs +23 -23
- package/dist/daemon-DeYImF1F.mjs +45 -0
- package/dist/daemon-mcp/index.mjs +21 -21
- package/dist/{daemon-ColVHwGZ.mjs → daemon-nXanenDM.mjs} +23 -19
- package/dist/{detect-9CZNO0yf.mjs → detect-BLKsUOgG.mjs} +2 -2
- package/dist/{detect-D1ziFFfA.mjs → detect-Rrimh0xc.mjs} +3 -3
- package/dist/{embed-pass-DIWjA68P.mjs → embed-pass-e64AwDCa.mjs} +1 -1
- package/dist/{endreason-C577xIQz.mjs → endreason-BC-v05H_.mjs} +17 -3
- package/dist/{factory-DjAAsqr_.mjs → factory-B7nv75rC.mjs} +2 -2
- package/dist/{factory-Bsib-qDG.mjs → factory-Bs9imVMq.mjs} +2 -2
- package/dist/{fallback-DFlItw1Z.mjs → fallback-CBWpp2F2.mjs} +227 -5
- package/dist/{health-Dnym-qcT.mjs → health-C4FQmkJn.mjs} +2 -2
- package/dist/{helpers-BD6V-p9w.mjs → helpers-DSNK_1KP.mjs} +2 -2
- package/dist/{helpers-CMGjy_0N.mjs → helpers-Dz7mjTSw.mjs} +3 -3
- package/dist/hooks/capture-all-events.mjs +21 -2
- package/dist/hooks/capture-tool-output.mjs +21 -2
- package/dist/hooks/worker-pool-host.mjs +167 -124
- package/dist/hooks/worker-status-line.mjs +34 -6
- package/dist/index.mjs +4 -4
- package/dist/{indexer-backend-_a6UNhXJ.mjs → indexer-backend-BdjeL4P8.mjs} +32 -229
- package/dist/{ipc-client-CaiGJnSM.mjs → ipc-client-CnYEF31R.mjs} +1 -1
- package/dist/{ipc-client-ZRmDKd5Z.mjs → ipc-client-DN7EvoVo.mjs} +1 -1
- package/dist/{kill-tree-EWYaEk5v.mjs → kill-tree-DleMNZX3.mjs} +2 -2
- package/dist/{kill-tree-BG7dRVtp.mjs → kill-tree-SV6hrIa3.mjs} +2 -2
- package/dist/{launch-Jh5NVeNe.mjs → launch-Di7N-J5X.mjs} +2 -2
- package/dist/{launch-CXVlZjHt.mjs → launch-DlZTKE3u.mjs} +2 -2
- package/dist/{main-config-ops-BEMpuhDz.mjs → main-config-ops-kTXR8Pyv.mjs} +1 -1
- package/dist/{main-resolver-3Ns1HPmS.mjs → main-resolver-yp_puSSb.mjs} +5 -5
- package/dist/{model-inventory-BFVSNFT3.mjs → model-inventory-h6Z9fN_o.mjs} +1 -1
- package/dist/{models-add-BtB3Se6f.mjs → models-add-TVni3A7V.mjs} +22 -22
- package/dist/{pai-marker-DurzIbw8.mjs → pai-marker-BcZyJguM.mjs} +2 -2
- package/dist/{pane-audit-BQytYa60.mjs → pane-audit-Lqy9N_Ki.mjs} +23 -5
- package/dist/{planner-BM27GBfC.mjs → planner-j77ndkBf.mjs} +14 -14
- package/dist/{pool-BRvoOkv6.mjs → pool-Dh-q3iJi.mjs} +43 -4
- package/dist/{pool-cli-B_YR8_Gl.mjs → pool-cli-BggU8GRp.mjs} +2 -2
- package/dist/{pool-cli-DkZTAlSW.mjs → pool-cli-DQ6OzRy2.mjs} +2 -2
- package/dist/{postgres-BdBNkL_l.mjs → postgres-BK4FP9Zg.mjs} +1 -1
- package/dist/{postgres-C6ti4haA.mjs → postgres-DNIOQijl.mjs} +17 -7
- package/dist/{project-setup-CfpApz5o.mjs → project-setup-CBRtFFh0.mjs} +16 -236
- package/dist/{providers-CblTFrhz.mjs → providers-C9QC0TtO.mjs} +2 -2
- package/dist/{providers-BeDiVEb-.mjs → providers-FvCLzFge.mjs} +2 -2
- package/dist/{query-feedback-BRfPtqki.mjs → query-feedback-DN52N9C5.mjs} +1 -1
- package/dist/{registrable-C7b6givx.mjs → registrable-BzH4TObg.mjs} +3 -3
- package/dist/{registrable-Uzgmfyhz.mjs → registrable-DpyTtajg.mjs} +2 -2
- package/dist/{render-Cc2j5QG9.mjs → render-B35bQTE-.mjs} +4 -4
- package/dist/{render-CwIrgxLi.mjs → render-C84BqQRC.mjs} +3 -3
- package/dist/{root-BWy0c2Lq.mjs → root-C4oXlXS_.mjs} +7 -7
- package/dist/{root-wC_6Fx0B.mjs → root-DD1xx_Vu.mjs} +16 -16
- package/dist/route-table-FEfDuhIV.mjs +15 -0
- package/dist/{routing-BAAST9vT.mjs → routing-DmkheCRH.mjs} +126 -8
- package/dist/{routing-CENt4HH1.mjs → routing-f2zulGwD.mjs} +1 -1
- package/dist/{run-6Q9kCPem.mjs → run-BwZKBJZZ.mjs} +28 -14
- package/dist/{scan-ZQWm-_se.mjs → scan-BBGvU5EB.mjs} +4 -4
- package/dist/{session-Bok2PqRS.mjs → session-BAhtXdxj.mjs} +15 -15
- package/dist/{session-DVUExUnX.mjs → session-Dn5OJXlg.mjs} +23 -23
- package/dist/{session-scan-BJI_ZO8M.mjs → session-scan-B57dNuA4.mjs} +1 -1
- package/dist/{session-scan-W-gbwJHM.mjs → session-scan-DUn10MBd.mjs} +2 -2
- package/dist/session-usage-CPvXvSkw.mjs +222 -0
- package/dist/{sources-ESUkZaWv.mjs → sources-CiE3rZek.mjs} +1 -1
- package/dist/{viewer-MWBVJP3u.mjs → viewer-DEySE4c_.mjs} +8 -8
- package/dist/{viewer-DcpJwGKE.mjs → viewer-wfKnvnrI.mjs} +6 -6
- package/dist/{worker-config-gmAq_-rI.mjs → worker-config-CO5FXLAT.mjs} +21 -21
- package/dist/{worker-config-BDYNxbYz.mjs → worker-config-eY5Qy4vl.mjs} +322 -25
- package/dist/{worktree-CrnOqTBW.mjs → worktree-CRs2gyg0.mjs} +2 -2
- package/dist/{zettelkasten-BzMm8REH.mjs → zettelkasten-_h_tUm2T.mjs} +1 -1
- package/dist/{zettelkasten-B_rRRRvD.mjs → zettelkasten-tpCRBYvH.mjs} +2 -2
- package/docs/cockpit.md +1 -0
- package/docs/images/architecture.png +0 -0
- package/gemini-extension.json +1 -1
- package/package.json +1 -1
- package/pai-plugin.json +1 -1
- package/plugins/context-preservation/plugin.json +1 -1
- package/plugins/core/plugin.json +1 -1
- package/plugins/creative/plugin.json +1 -1
- package/plugins/observability/plugin.json +1 -1
- package/plugins/productivity/plugin.json +1 -1
- package/plugins/semantic-search/plugin.json +1 -1
- package/plugins/ui/plugin.json +1 -1
- package/plugins/zettelkasten/plugin.json +1 -1
- package/src/hooks/ts/capture-all-events.ts +15 -3
- package/src/hooks/ts/lib/raw-capture.ts +7 -0
- package/src/hooks/ts/post-tool-use/capture-tool-output.ts +13 -3
- package/dist/auto-route-BjoMHKyI.mjs +0 -11
- package/dist/daemon-N7WhYi6I.mjs +0 -45
- package/dist/route-table-B7zpoypi.mjs +0 -15
|
@@ -2,16 +2,16 @@ import { g as paiHomePath, h as paiHomeDir } from "./runtime-paths-WsO9sJFc.mjs"
|
|
|
2
2
|
import { Et as parseLedger, j as readWorkersSection, t as ANTHROPIC_NATIVE, tt as workersYamlPath, wt as appendLedger } from "./config-XpZWOYOG.mjs";
|
|
3
3
|
import { c as loadConfig, f as readMainConfigRaw, h as effectiveMainConfig, m as deepMergeConfig, p as writeMainConfigRaw, u as paiConfigFilePath, y as shippedMainDefaults } from "./config-Bu1_vbY8.mjs";
|
|
4
4
|
import { i as ledgerPath, u as workersLogDir } from "./paths-CHifubDh.mjs";
|
|
5
|
-
import { it as readInventory } from "./routing-
|
|
5
|
+
import { it as readInventory } from "./routing-DmkheCRH.mjs";
|
|
6
6
|
import { _ as readLocalConfig } from "./local-tiers-BE4jGaMa.mjs";
|
|
7
7
|
import { f as sharedScheduler } from "./scheduler-CtUyWJ3O.mjs";
|
|
8
8
|
import { r as instanceEngineKey } from "./local-instances-DOxSgT_L.mjs";
|
|
9
9
|
import { o as primaryLocal, s as readLocalStatus } from "./local-candidate-DLdwQt0s.mjs";
|
|
10
10
|
import { t as LOCAL_PROBE_TIMEOUT_MS } from "./timeouts-1MLooEBB.mjs";
|
|
11
|
-
import { f as setClass } from "./providers-
|
|
12
|
-
import { o as setConfigValueOp, s as unsetConfigValueOp } from "./main-config-ops-
|
|
13
|
-
import { n as PaiClient } from "./ipc-client-
|
|
14
|
-
import { l as readEmbedPasses } from "./embed-pass-
|
|
11
|
+
import { f as setClass } from "./providers-C9QC0TtO.mjs";
|
|
12
|
+
import { o as setConfigValueOp, s as unsetConfigValueOp } from "./main-config-ops-kTXR8Pyv.mjs";
|
|
13
|
+
import { n as PaiClient } from "./ipc-client-CnYEF31R.mjs";
|
|
14
|
+
import { l as readEmbedPasses } from "./embed-pass-e64AwDCa.mjs";
|
|
15
15
|
import { appendFileSync, closeSync, existsSync, mkdirSync, openSync, readFileSync, readSync, readdirSync, renameSync, rmSync, rmdirSync, statSync, writeFileSync } from "node:fs";
|
|
16
16
|
import { randomBytes } from "node:crypto";
|
|
17
17
|
import { dirname, join } from "node:path";
|
|
@@ -329,6 +329,7 @@ const SHIPPED = {
|
|
|
329
329
|
dailyDays: 14,
|
|
330
330
|
sessionsRows: 20,
|
|
331
331
|
sessionsTopRows: 10,
|
|
332
|
+
sessionDetailTurns: 200,
|
|
332
333
|
sessionNameMaxPct: 35,
|
|
333
334
|
workerRows: 15,
|
|
334
335
|
lowRequestMin: 5,
|
|
@@ -397,6 +398,7 @@ function cockpitLayout() {
|
|
|
397
398
|
dailyDays: num(s, "dailyDays", SHIPPED.dailyDays),
|
|
398
399
|
sessionsRows: num(s, "sessionsRows", SHIPPED.sessionsRows),
|
|
399
400
|
sessionsTopRows: num(s, "sessionsTopRows", SHIPPED.sessionsTopRows),
|
|
401
|
+
sessionDetailTurns: num(s, "sessionDetailTurns", SHIPPED.sessionDetailTurns),
|
|
400
402
|
sessionNameMaxPct: num(s, "sessionNameMaxPct", SHIPPED.sessionNameMaxPct),
|
|
401
403
|
workerRows: num(s, "workerRows", SHIPPED.workerRows),
|
|
402
404
|
lowRequestMin: numZ(s, "lowRequestMin", SHIPPED.lowRequestMin),
|
|
@@ -1273,23 +1275,23 @@ function defaultDeps() {
|
|
|
1273
1275
|
const logDir = workersLogDir(workers);
|
|
1274
1276
|
return {
|
|
1275
1277
|
startTier: async (tierName) => {
|
|
1276
|
-
const { startTier } = await import("./worker-config-
|
|
1278
|
+
const { startTier } = await import("./worker-config-CO5FXLAT.mjs");
|
|
1277
1279
|
const cfg = readLocalConfig(workersYamlPath());
|
|
1278
1280
|
const tier = cfg.tiers[tierName];
|
|
1279
1281
|
if (!tier) throw new Error(`no tier "${tierName}" (configured: ${Object.keys(cfg.tiers).join(", ") || "none"})`);
|
|
1280
1282
|
await startTier(cfg, tierName, tier);
|
|
1281
1283
|
},
|
|
1282
1284
|
stopAll: async () => {
|
|
1283
|
-
const { stopAll } = await import("./worker-config-
|
|
1285
|
+
const { stopAll } = await import("./worker-config-CO5FXLAT.mjs");
|
|
1284
1286
|
await stopAll(readLocalConfig(workersYamlPath()));
|
|
1285
1287
|
},
|
|
1286
1288
|
startModel: async (model) => {
|
|
1287
|
-
const { startInstance } = await import("./worker-config-
|
|
1289
|
+
const { startInstance } = await import("./worker-config-CO5FXLAT.mjs");
|
|
1288
1290
|
await startInstance(readLocalConfig(workersYamlPath()), model);
|
|
1289
1291
|
},
|
|
1290
1292
|
stopModel: async (target, opts) => {
|
|
1291
|
-
const { stopInstance } = await import("./worker-config-
|
|
1292
|
-
const { currentInstances } = await import("./worker-config-
|
|
1293
|
+
const { stopInstance } = await import("./worker-config-CO5FXLAT.mjs");
|
|
1294
|
+
const { currentInstances } = await import("./worker-config-CO5FXLAT.mjs");
|
|
1293
1295
|
const cfg = readLocalConfig(workersYamlPath());
|
|
1294
1296
|
const keys = new Map(currentInstances(cfg).map((r) => [r.id, instanceEngineKey(r)]));
|
|
1295
1297
|
await stopInstance(cfg, target, opts, {
|
|
@@ -1298,7 +1300,7 @@ function defaultDeps() {
|
|
|
1298
1300
|
});
|
|
1299
1301
|
},
|
|
1300
1302
|
runningCount: async (model) => {
|
|
1301
|
-
const { currentInstances } = await import("./worker-config-
|
|
1303
|
+
const { currentInstances } = await import("./worker-config-CO5FXLAT.mjs");
|
|
1302
1304
|
return currentInstances(readLocalConfig(workersYamlPath())).filter((r) => r.model === model && r.state !== "failed").length;
|
|
1303
1305
|
},
|
|
1304
1306
|
setClass: (cls, target) => void setClass(cls, target),
|
|
@@ -1582,7 +1584,7 @@ async function runCockpitAction(body, deps, hooks = {}) {
|
|
|
1582
1584
|
if (action === "route.set") {
|
|
1583
1585
|
if (!target) return fail("target (tier) required");
|
|
1584
1586
|
try {
|
|
1585
|
-
const { setRoute } = await import("./route-table-
|
|
1587
|
+
const { setRoute } = await import("./route-table-FEfDuhIV.mjs");
|
|
1586
1588
|
const models = Array.isArray(body.models) ? body.models : value !== void 0 ? value.split(",") : body.models;
|
|
1587
1589
|
const change = setRoute(target, models, deps.configPath);
|
|
1588
1590
|
writeLedgerLine(deps, action, change.id, `set:${change.entries.join(">")}`);
|
|
@@ -1599,7 +1601,7 @@ async function runCockpitAction(body, deps, hooks = {}) {
|
|
|
1599
1601
|
if (value !== "on" && value !== "off") return fail(`value must be on or off, got "${value ?? ""}"`);
|
|
1600
1602
|
if (!deps.workers.providers[target]?.characteristics) return fail(`"${target}" is not a registered endpoint (providers.${target}.characteristics)`);
|
|
1601
1603
|
try {
|
|
1602
|
-
const { setProviderEnabled } = await import("./providers-
|
|
1604
|
+
const { setProviderEnabled } = await import("./providers-FvCLzFge.mjs");
|
|
1603
1605
|
setProviderEnabled(target, value === "on", deps.configPath);
|
|
1604
1606
|
writeLedgerLine(deps, action, target, `routing ${value}`);
|
|
1605
1607
|
return {
|
|
@@ -1625,7 +1627,7 @@ async function runCockpitAction(body, deps, hooks = {}) {
|
|
|
1625
1627
|
message: `worker classes → ${provider}`
|
|
1626
1628
|
};
|
|
1627
1629
|
}
|
|
1628
|
-
const { useProvider } = await import("./providers-
|
|
1630
|
+
const { useProvider } = await import("./providers-FvCLzFge.mjs");
|
|
1629
1631
|
useProvider(provider);
|
|
1630
1632
|
try {
|
|
1631
1633
|
const raw = readMainConfigRaw();
|
|
@@ -1660,13 +1662,13 @@ async function memoryRunRefusal(deps, nowMs = Date.now()) {
|
|
|
1660
1662
|
}
|
|
1661
1663
|
/** The daemon's count of chunks without vectors; null when it does not answer. */
|
|
1662
1664
|
async function daemonEmbedBacklog() {
|
|
1663
|
-
const { fetchDaemonMemory } = await import("./cockpit-memory-
|
|
1665
|
+
const { fetchDaemonMemory } = await import("./cockpit-memory-teG9M8bG.mjs");
|
|
1664
1666
|
return (await fetchDaemonMemory())?.embedBacklog ?? null;
|
|
1665
1667
|
}
|
|
1666
1668
|
/** The daemon's in-process passes (no child, so no marker): its status says whether one runs. */
|
|
1667
1669
|
async function daemonMemoryBusy() {
|
|
1668
1670
|
try {
|
|
1669
|
-
const { PaiClient } = await import("./ipc-client-
|
|
1671
|
+
const { PaiClient } = await import("./ipc-client-DN7EvoVo.mjs");
|
|
1670
1672
|
const { loadConfig } = await import("./config-DtENJ6cL.mjs");
|
|
1671
1673
|
const s = await new PaiClient(loadConfig().socketPath).call("status", {}, 5e3);
|
|
1672
1674
|
if (s.embedInProgress) return "embed already running (started by daemon)";
|
|
@@ -1781,7 +1783,7 @@ async function finishRuntimeJob(deps, hooks, id, runtime, op) {
|
|
|
1781
1783
|
end(state, message);
|
|
1782
1784
|
}
|
|
1783
1785
|
async function defaultRefreshInventory() {
|
|
1784
|
-
const { computeInventory, readInventoryInput, writeInventory } = await import("./model-inventory-
|
|
1786
|
+
const { computeInventory, readInventoryInput, writeInventory } = await import("./model-inventory-h6Z9fN_o.mjs");
|
|
1785
1787
|
writeInventory(workersLogDir(readWorkersSection().workers), await computeInventory(readInventoryInput()));
|
|
1786
1788
|
}
|
|
1787
1789
|
/** Runs the injected local job, records its outcome in the job file and ledger. */
|
|
@@ -1851,4 +1853,4 @@ function cockpitActionLedger(ledgerFile, lastN = 10) {
|
|
|
1851
1853
|
|
|
1852
1854
|
//#endregion
|
|
1853
1855
|
export { cockpitMemoryPayload as A, cockpitLayout as B, runtimeOpRefusal as C, writeLedgerLine as D, tierNames as E, memoryRunLog as F, acquireRun as H, rateSeries as I, runProgress as L, latestMemoryJob as M, liveMemoryDeps as N, embeddingRuntimeName as O, memoryJobProgress as P, runningMemoryJob as R, runtimeJobProgress as S, spawnMemoryRun as T, readRun as U, cockpitProbeSettings as V, resolveTierName as _, classesOnProvider as a, runningRuntimeJob as b, defaultDeps as c, labelPath as d, logTailSince as f, readLabels as g, readCockpitJob as h, WORKER_ROLE_CLASSES as i, fetchDaemonMemory as j, readRuntimeCommands as k, engineInflight as l, orchestratorProvider as m, RUNTIME_START_EVENT as n, cockpitActionLedger as o, memoryRunRefusal as p, RUNTIME_STOP_EVENT as r, cockpitJobFile as s, COCKPIT_ACTION_EVENT as t, labelFor as u, runCockpitAction as v, runtimeStartStop as w, runningRuntimeJobs as x, runningLocalModel as y, sameModel as z };
|
|
1854
|
-
//# sourceMappingURL=cockpit-actions-
|
|
1856
|
+
//# sourceMappingURL=cockpit-actions-OodH_vx_.mjs.map
|
|
@@ -3,7 +3,7 @@ import "./config-Bu1_vbY8.mjs";
|
|
|
3
3
|
import "./paths-CHifubDh.mjs";
|
|
4
4
|
import "./status-ggJ7lgVg.mjs";
|
|
5
5
|
import "./scope-D-h6F6DN.mjs";
|
|
6
|
-
import "./routing-
|
|
6
|
+
import "./routing-DmkheCRH.mjs";
|
|
7
7
|
import "./tool-errors-7E13StWd.mjs";
|
|
8
8
|
import "./wait-ByV0OyMZ.mjs";
|
|
9
9
|
import "./local-tiers-BE4jGaMa.mjs";
|
|
@@ -11,10 +11,10 @@ import "./caller-identity-yLFb7CKq.mjs";
|
|
|
11
11
|
import "./capacity-DEveQdFV.mjs";
|
|
12
12
|
import "./local-instances-DOxSgT_L.mjs";
|
|
13
13
|
import "./local-candidate-DLdwQt0s.mjs";
|
|
14
|
-
import "./providers-
|
|
15
|
-
import "./main-config-ops-
|
|
16
|
-
import { A as cockpitMemoryPayload, F as memoryRunLog, I as rateSeries, L as runProgress, M as latestMemoryJob, N as liveMemoryDeps, P as memoryJobProgress, R as runningMemoryJob, j as fetchDaemonMemory, z as sameModel } from "./cockpit-actions-
|
|
17
|
-
import "./ipc-client-
|
|
18
|
-
import "./embed-pass-
|
|
14
|
+
import "./providers-C9QC0TtO.mjs";
|
|
15
|
+
import "./main-config-ops-kTXR8Pyv.mjs";
|
|
16
|
+
import { A as cockpitMemoryPayload, F as memoryRunLog, I as rateSeries, L as runProgress, M as latestMemoryJob, N as liveMemoryDeps, P as memoryJobProgress, R as runningMemoryJob, j as fetchDaemonMemory, z as sameModel } from "./cockpit-actions-OodH_vx_.mjs";
|
|
17
|
+
import "./ipc-client-CnYEF31R.mjs";
|
|
18
|
+
import "./embed-pass-e64AwDCa.mjs";
|
|
19
19
|
|
|
20
20
|
export { fetchDaemonMemory };
|
|
@@ -150,6 +150,10 @@ router:
|
|
|
150
150
|
# Bare aliases (besides ids starting with claude-) that also go to claudeUpstream.
|
|
151
151
|
claudeModelAliases: [sonnet, opus, haiku, default, opusplan]
|
|
152
152
|
bind: loopback
|
|
153
|
+
# Extra Host headers the router accepts beyond loopback and the bind address
|
|
154
|
+
# (tailnet/MagicDNS names the cockpit is opened by). Empty by default; a
|
|
155
|
+
# request whose Host matches none of these is refused with 403.
|
|
156
|
+
allowedHosts: []
|
|
153
157
|
# Milliseconds a stopping router waits for in-flight requests before force-closing.
|
|
154
158
|
drainMs: 120000
|
|
155
159
|
# Cockpit page layout policy (src/router/cockpit-layout.ts): tile min/max
|
|
@@ -217,6 +221,8 @@ router:
|
|
|
217
221
|
# sessions beyond the top N by tokens collapse into one expandable row;
|
|
218
222
|
# the session-name column is capped at this percent of the table width.
|
|
219
223
|
sessionsTopRows: 10
|
|
224
|
+
# turns kept in the per-session drill-down (the last N).
|
|
225
|
+
sessionDetailTurns: 200
|
|
220
226
|
sessionNameMaxPct: 35
|
|
221
227
|
workerRows: 15
|
|
222
228
|
# models under this many requests render as chips, not rings.
|
|
@@ -7,7 +7,7 @@ import { c as scopeKey, i as itermUuid$1, p as currentWorkerId } from "./scope-D
|
|
|
7
7
|
import { a as buildsDir, l as listBuildsSync, m as ticketKind } from "./caller-identity-yLFb7CKq.mjs";
|
|
8
8
|
import { o as providerCap, s as queueRows } from "./capacity-DEveQdFV.mjs";
|
|
9
9
|
import { n as tierProviderNames, s as readLocalStatus, t as isLocalCandidate } from "./local-candidate-DLdwQt0s.mjs";
|
|
10
|
-
import { d as paneRunStatusRow, f as paneStatusRow } from "./render-
|
|
10
|
+
import { d as paneRunStatusRow, f as paneStatusRow } from "./render-C84BqQRC.mjs";
|
|
11
11
|
import { r as sayToWorker } from "./operator-CyuB3aVw.mjs";
|
|
12
12
|
import { appendFileSync, existsSync, mkdirSync, mkdtempSync, openSync, readFileSync, readdirSync, renameSync, rmSync, unlinkSync, writeFileSync } from "node:fs";
|
|
13
13
|
import { createHash } from "node:crypto";
|
|
@@ -955,8 +955,8 @@ async function renderer(sp, id, out, err) {
|
|
|
955
955
|
err: (c) => err(c),
|
|
956
956
|
end: () => void 0
|
|
957
957
|
};
|
|
958
|
-
const { applyEvent, initialFollowState } = await import("./viewer-
|
|
959
|
-
const { makeColor } = await import("./render-
|
|
958
|
+
const { applyEvent, initialFollowState } = await import("./viewer-DEySE4c_.mjs");
|
|
959
|
+
const { makeColor } = await import("./render-B35bQTE-.mjs");
|
|
960
960
|
const c = makeColor(true);
|
|
961
961
|
let state = initialFollowState("");
|
|
962
962
|
let buf = "";
|
|
@@ -1086,13 +1086,15 @@ async function openOwnedPane(o) {
|
|
|
1086
1086
|
let pidWaiter = null;
|
|
1087
1087
|
let ended = false;
|
|
1088
1088
|
let startedAt = 0;
|
|
1089
|
+
const openedAt = Date.now();
|
|
1089
1090
|
const record = (extra = {}) => writeJson(recordPath(o.id), {
|
|
1090
1091
|
id: o.id,
|
|
1091
1092
|
kind: o.kind,
|
|
1092
1093
|
caller: process.pid,
|
|
1093
1094
|
wrapper: wrapper || void 0,
|
|
1094
1095
|
session,
|
|
1095
|
-
|
|
1096
|
+
openedMs: openedAt,
|
|
1097
|
+
startedMs: startedAt || openedAt,
|
|
1096
1098
|
...extra
|
|
1097
1099
|
});
|
|
1098
1100
|
const settle = (code, signal) => {
|
|
@@ -4706,4 +4708,4 @@ async function returnControlsIfHeld(logDir, id) {
|
|
|
4706
4708
|
|
|
4707
4709
|
//#endregion
|
|
4708
4710
|
export { checkPaneForWorker as $, tail as A, recordPath as At, loadPlanStatus as B, chatTickerRow as Bt, readRunLog as C, PANE_EXEC_PID_ENV as Ct, resumeState as D, pidAlive as Dt, requestPlanStop as E, openOwnedPane as Et, runLogPath as F, chatEnter as Ft, planRunId as G, handoffFromInside as Gt, planLogTail as H, parseChatLine as Ht, PlanTracker as I, chatInsertLine as It, queueLockPath as J, LOCAL_FAILURE_LIMIT as Jt, renderPlanLines as K, isHandoffMessage as Kt, fmtElapsed as L, chatLeave as Lt, dirtyConflicts as M, panePolicy as Mt, filesOverlap as N, CHAT_HELP as Nt, runExitCode as O, readExit as Ot, loadPlan as P, chatBlankRow as Pt, NoTerminalError as Q, followPlanLog as R, chatPromptRow as Rt, planStopPath as S, PANE_EXEC_ENV as St, renderStatus as T, listRecords as Tt, planRows as U, wrapText as Ut, loadPlanStatuses as V, holdAutoExit as Vt, planRunEnded as W, deliverHandoff as Wt, sinceText as X, localFailures as Xt, readRunLock as Y, classifyRoute as Yt, withRunLock as Z, routeLine as Zt, troublePolicy as _, paneTitle as _t, localIdleTick as a, headlessAllowed as at, idleText as b, psTableOrNull as bt, setMuted as c, openFollowPane as ct, aibrokerMessenger as d, osascript as dt, closeEndedPanes as et, detachRun as f, paneBackend as ft, sweepRuns as g, workerEnded as gt, originFromEnv as h, resolveHostSession as ht, localIdleLine as i, followCommand as it, PlanError as j, runPaneExec as jt, runPlan as k, readRecord as kt, PlanReporter as l, openPaneForWorker as lt, markRunDone as m, realPaneOps as mt, markControlsHeld as n, closePaneForWorker as nt, ownerOf as o, inVisiblePane as ot, eventLine as p, paneMayClose as pt, planLockPath as q, readInbox as qt, returnControlsIfHeld as r, closeSelfPane as rt, readLocalIdle as s, loadRegistry as st, clickrControlsArgv as t, closeOwnPane as tt, QueueReporter as u, openVerifiedPane as ut, appendRunLog as v, writePaneTitle as vt, renderSchedule as w, exitFilePath as wt, planStatus as x, truncateLines as xt, blockedMessage as y, psTable as yt, gatePhaseName as z, chatScrollRegion as zt };
|
|
4709
|
-
//# sourceMappingURL=controls-
|
|
4711
|
+
//# sourceMappingURL=controls-JLm6g0yP.mjs.map
|
package/dist/daemon/index.mjs
CHANGED
|
@@ -4,16 +4,16 @@ import "../migrate-DrA_OwlZ.mjs";
|
|
|
4
4
|
import "../config-XpZWOYOG.mjs";
|
|
5
5
|
import { a as ensureConfigDir, c as loadConfig } from "../config-Bu1_vbY8.mjs";
|
|
6
6
|
import "../paths-CHifubDh.mjs";
|
|
7
|
-
import "../worktree-
|
|
7
|
+
import "../worktree-CRs2gyg0.mjs";
|
|
8
8
|
import "../status-ggJ7lgVg.mjs";
|
|
9
|
-
import "../pool-
|
|
10
|
-
import "../registrable-
|
|
11
|
-
import "../pai-marker-
|
|
9
|
+
import "../pool-Dh-q3iJi.mjs";
|
|
10
|
+
import "../registrable-DpyTtajg.mjs";
|
|
11
|
+
import "../pai-marker-BcZyJguM.mjs";
|
|
12
12
|
import "../helpers-CRuBUas3.mjs";
|
|
13
13
|
import "../reranker-CqCbpGnX.mjs";
|
|
14
14
|
import { t as dropItermBundleId } from "../env-BE8mrsxr.mjs";
|
|
15
15
|
import "../scope-D-h6F6DN.mjs";
|
|
16
|
-
import "../routing-
|
|
16
|
+
import "../routing-DmkheCRH.mjs";
|
|
17
17
|
import "../tool-errors-7E13StWd.mjs";
|
|
18
18
|
import "../wait-ByV0OyMZ.mjs";
|
|
19
19
|
import "../local-tiers-BE4jGaMa.mjs";
|
|
@@ -21,28 +21,28 @@ import "../caller-identity-yLFb7CKq.mjs";
|
|
|
21
21
|
import "../capacity-DEveQdFV.mjs";
|
|
22
22
|
import "../local-instances-DOxSgT_L.mjs";
|
|
23
23
|
import "../local-candidate-DLdwQt0s.mjs";
|
|
24
|
-
import "../factory-
|
|
25
|
-
import "../postgres-
|
|
24
|
+
import "../factory-B7nv75rC.mjs";
|
|
25
|
+
import "../postgres-DNIOQijl.mjs";
|
|
26
26
|
import "../embedding-gate-6rZrWRXa.mjs";
|
|
27
27
|
import "../embeddings-BVq3esBF.mjs";
|
|
28
28
|
import "../router-CQSc3lk3.mjs";
|
|
29
|
-
import "../detect-
|
|
30
|
-
import "../scan-
|
|
31
|
-
import "../launch-
|
|
32
|
-
import "../run-
|
|
33
|
-
import "../controls-
|
|
34
|
-
import "../endreason-
|
|
35
|
-
import "../render-
|
|
29
|
+
import "../detect-BLKsUOgG.mjs";
|
|
30
|
+
import "../scan-BBGvU5EB.mjs";
|
|
31
|
+
import "../launch-Di7N-J5X.mjs";
|
|
32
|
+
import "../run-BwZKBJZZ.mjs";
|
|
33
|
+
import "../controls-JLm6g0yP.mjs";
|
|
34
|
+
import "../endreason-BC-v05H_.mjs";
|
|
35
|
+
import "../render-C84BqQRC.mjs";
|
|
36
36
|
import "../operator-CyuB3aVw.mjs";
|
|
37
|
-
import "../kill-tree-
|
|
38
|
-
import "../pool-cli-
|
|
39
|
-
import "../pane-audit-
|
|
40
|
-
import { n as PaiClient } from "../ipc-client-
|
|
41
|
-
import "../embed-pass-
|
|
42
|
-
import "../indexer-backend-
|
|
43
|
-
import { t as serve } from "../daemon-
|
|
44
|
-
import "../auto-route-
|
|
45
|
-
import "../zettelkasten-
|
|
37
|
+
import "../kill-tree-DleMNZX3.mjs";
|
|
38
|
+
import "../pool-cli-BggU8GRp.mjs";
|
|
39
|
+
import "../pane-audit-Lqy9N_Ki.mjs";
|
|
40
|
+
import { n as PaiClient } from "../ipc-client-CnYEF31R.mjs";
|
|
41
|
+
import "../embed-pass-e64AwDCa.mjs";
|
|
42
|
+
import "../indexer-backend-BdjeL4P8.mjs";
|
|
43
|
+
import { t as serve } from "../daemon-nXanenDM.mjs";
|
|
44
|
+
import "../auto-route-21GdHL70.mjs";
|
|
45
|
+
import "../zettelkasten-_h_tUm2T.mjs";
|
|
46
46
|
|
|
47
47
|
//#region src/daemon/index.ts
|
|
48
48
|
/**
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import "./utils-J2b9y8PC.mjs";
|
|
2
|
+
import "./migrate-DrA_OwlZ.mjs";
|
|
3
|
+
import "./config-XpZWOYOG.mjs";
|
|
4
|
+
import "./config-Bu1_vbY8.mjs";
|
|
5
|
+
import "./paths-CHifubDh.mjs";
|
|
6
|
+
import "./worktree-CRs2gyg0.mjs";
|
|
7
|
+
import "./status-ggJ7lgVg.mjs";
|
|
8
|
+
import "./pool-Dh-q3iJi.mjs";
|
|
9
|
+
import "./registrable-DpyTtajg.mjs";
|
|
10
|
+
import "./pai-marker-BcZyJguM.mjs";
|
|
11
|
+
import "./helpers-CRuBUas3.mjs";
|
|
12
|
+
import "./reranker-CqCbpGnX.mjs";
|
|
13
|
+
import "./scope-D-h6F6DN.mjs";
|
|
14
|
+
import "./routing-DmkheCRH.mjs";
|
|
15
|
+
import "./tool-errors-7E13StWd.mjs";
|
|
16
|
+
import "./wait-ByV0OyMZ.mjs";
|
|
17
|
+
import "./local-tiers-BE4jGaMa.mjs";
|
|
18
|
+
import "./caller-identity-yLFb7CKq.mjs";
|
|
19
|
+
import "./capacity-DEveQdFV.mjs";
|
|
20
|
+
import "./local-instances-DOxSgT_L.mjs";
|
|
21
|
+
import "./local-candidate-DLdwQt0s.mjs";
|
|
22
|
+
import "./factory-B7nv75rC.mjs";
|
|
23
|
+
import "./postgres-DNIOQijl.mjs";
|
|
24
|
+
import "./embedding-gate-6rZrWRXa.mjs";
|
|
25
|
+
import "./embeddings-BVq3esBF.mjs";
|
|
26
|
+
import "./router-CQSc3lk3.mjs";
|
|
27
|
+
import "./detect-BLKsUOgG.mjs";
|
|
28
|
+
import "./scan-BBGvU5EB.mjs";
|
|
29
|
+
import "./launch-Di7N-J5X.mjs";
|
|
30
|
+
import "./run-BwZKBJZZ.mjs";
|
|
31
|
+
import "./controls-JLm6g0yP.mjs";
|
|
32
|
+
import "./endreason-BC-v05H_.mjs";
|
|
33
|
+
import "./render-C84BqQRC.mjs";
|
|
34
|
+
import "./operator-CyuB3aVw.mjs";
|
|
35
|
+
import "./kill-tree-DleMNZX3.mjs";
|
|
36
|
+
import "./pool-cli-BggU8GRp.mjs";
|
|
37
|
+
import "./pane-audit-Lqy9N_Ki.mjs";
|
|
38
|
+
import "./ipc-client-CnYEF31R.mjs";
|
|
39
|
+
import "./embed-pass-e64AwDCa.mjs";
|
|
40
|
+
import "./indexer-backend-BdjeL4P8.mjs";
|
|
41
|
+
import { t as serve } from "./daemon-nXanenDM.mjs";
|
|
42
|
+
import "./auto-route-21GdHL70.mjs";
|
|
43
|
+
import "./zettelkasten-_h_tUm2T.mjs";
|
|
44
|
+
|
|
45
|
+
export { serve };
|
|
@@ -4,13 +4,13 @@ import { g as paiHomePath } from "../runtime-paths-WsO9sJFc.mjs";
|
|
|
4
4
|
import { Tt as ledgerSummary, a as MODEL_CAPABILITIES, f as escalationCloud, j as readWorkersSection, m as isLocalProvider, n as CAPABILITY_NAME_RE, p as getProviderOrNative } from "../config-XpZWOYOG.mjs";
|
|
5
5
|
import { S as MainConfigError, c as loadConfig, n as CONFIG_FILE } from "../config-Bu1_vbY8.mjs";
|
|
6
6
|
import { i as ledgerPath, u as workersLogDir } from "../paths-CHifubDh.mjs";
|
|
7
|
-
import "../worktree-
|
|
7
|
+
import "../worktree-CRs2gyg0.mjs";
|
|
8
8
|
import { A as setWorkerLabel, C as nowStamp, O as reconcileStatuses, g as isLive, o as ageOf, v as loadStatus, y as loadStatuses } from "../status-ggJ7lgVg.mjs";
|
|
9
|
-
import "../pool-
|
|
9
|
+
import "../pool-Dh-q3iJi.mjs";
|
|
10
10
|
import "../helpers-CRuBUas3.mjs";
|
|
11
11
|
import { t as dropItermBundleId } from "../env-BE8mrsxr.mjs";
|
|
12
12
|
import "../scope-D-h6F6DN.mjs";
|
|
13
|
-
import {
|
|
13
|
+
import { It as clearSessionRoute, J as inventoryRows, Sn as probeLoopback, W as currentInventory, fn as getProfile, hn as updateProfile, ln as detectSessionName, pn as profilesPath, qt as sessionRoutesPatch, vn as currentLocalStatus, z as INVENTORY_HEADERS } from "../routing-DmkheCRH.mjs";
|
|
14
14
|
import "../tool-errors-7E13StWd.mjs";
|
|
15
15
|
import "../wait-ByV0OyMZ.mjs";
|
|
16
16
|
import "../local-tiers-BE4jGaMa.mjs";
|
|
@@ -18,27 +18,27 @@ import { a as buildsDir, c as listBuilds, i as buildNext, p as renderBuildQueue,
|
|
|
18
18
|
import { i as effectiveCap, l as reorderQueue, s as queueRows } from "../capacity-DEveQdFV.mjs";
|
|
19
19
|
import "../local-instances-DOxSgT_L.mjs";
|
|
20
20
|
import { a as localStatusReport } from "../local-candidate-DLdwQt0s.mjs";
|
|
21
|
-
import "../factory-
|
|
22
|
-
import "../postgres-
|
|
21
|
+
import "../factory-B7nv75rC.mjs";
|
|
22
|
+
import "../postgres-DNIOQijl.mjs";
|
|
23
23
|
import "../embedding-gate-6rZrWRXa.mjs";
|
|
24
24
|
import "../embeddings-BVq3esBF.mjs";
|
|
25
25
|
import "../router-CQSc3lk3.mjs";
|
|
26
|
-
import "../launch-
|
|
27
|
-
import { H as testProvider, a as resolveWorkers, c as reportOriginWithHost, f as dirtyPaths, i as liveResolveCtx, t as runWorker, u as startDetached } from "../run-
|
|
28
|
-
import { A as tail, B as loadPlanStatus, C as readRunLog, D as resumeState, E as requestPlanStop, F as runLogPath, G as planRunId, Gt as handoffFromInside, J as queueLockPath, L as fmtElapsed, M as dirtyConflicts, P as loadPlan, S as planStopPath, X as sinceText, Y as readRunLock, b as idleText, j as PlanError, q as planLockPath, qt as readInbox, w as renderSchedule, x as planStatus } from "../controls-
|
|
29
|
-
import { a as endLabel } from "../endreason-
|
|
30
|
-
import { D as deadlineLabel } from "../render-
|
|
26
|
+
import "../launch-Di7N-J5X.mjs";
|
|
27
|
+
import { H as testProvider, a as resolveWorkers, c as reportOriginWithHost, f as dirtyPaths, i as liveResolveCtx, t as runWorker, u as startDetached } from "../run-BwZKBJZZ.mjs";
|
|
28
|
+
import { A as tail, B as loadPlanStatus, C as readRunLog, D as resumeState, E as requestPlanStop, F as runLogPath, G as planRunId, Gt as handoffFromInside, J as queueLockPath, L as fmtElapsed, M as dirtyConflicts, P as loadPlan, S as planStopPath, X as sinceText, Y as readRunLock, b as idleText, j as PlanError, q as planLockPath, qt as readInbox, w as renderSchedule, x as planStatus } from "../controls-JLm6g0yP.mjs";
|
|
29
|
+
import { a as endLabel } from "../endreason-BC-v05H_.mjs";
|
|
30
|
+
import { D as deadlineLabel } from "../render-C84BqQRC.mjs";
|
|
31
31
|
import { r as sayToWorker } from "../operator-CyuB3aVw.mjs";
|
|
32
|
-
import "../kill-tree-
|
|
33
|
-
import "../pool-cli-
|
|
34
|
-
import { t as runChain } from "../chain-
|
|
35
|
-
import { C as schedulerLines, E as resolveSpecPath, S as withTarget, T as readSpecPrompt, _ as issueClaims, a as branchDiff, d as loadSettings, f as move, g as issueClaim, i as projectChecks, l as QueueStore, n as initProject, o as realQueueDeps, p as queueStatePath, r as isGitProject, s as acceptItems, t as formatCheck, u as again, v as issueStale, w as schedulerView, x as resolveTarget, y as providerCaps } from "../project-setup-
|
|
36
|
-
import "../pane-audit-
|
|
37
|
-
import { d as psOutput, f as replayOutput } from "../viewer-
|
|
38
|
-
import {
|
|
39
|
-
import { a as
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
32
|
+
import "../kill-tree-DleMNZX3.mjs";
|
|
33
|
+
import "../pool-cli-BggU8GRp.mjs";
|
|
34
|
+
import { t as runChain } from "../chain-D7PFur8Y.mjs";
|
|
35
|
+
import { C as schedulerLines, E as resolveSpecPath, S as withTarget, T as readSpecPrompt, _ as issueClaims, a as branchDiff, d as loadSettings, f as move, g as issueClaim, i as projectChecks, l as QueueStore, n as initProject, o as realQueueDeps, p as queueStatePath, r as isGitProject, s as acceptItems, t as formatCheck, u as again, v as issueStale, w as schedulerView, x as resolveTarget, y as providerCaps } from "../project-setup-CBRtFFh0.mjs";
|
|
36
|
+
import "../pane-audit-Lqy9N_Ki.mjs";
|
|
37
|
+
import { d as psOutput, f as replayOutput } from "../viewer-wfKnvnrI.mjs";
|
|
38
|
+
import { i as fallbackStatusText, n as fallbackOn, r as fallbackStatus, t as fallbackOff } from "../fallback-CBWpp2F2.mjs";
|
|
39
|
+
import { _ as unsetCapabilityPreference, a as describeCapabilities, b as useProvider, c as modelPrefsText, d as setCapabilityPreference, f as setClass, g as setWorkersEnabled, h as setProviderModel, l as removeProvider, m as setProviderEnabled, o as describeModels, p as setProviderCap, r as classTargetText, s as describeProviders, t as addProvider, u as resolveProviderName, v as unsetClass, y as updateProvider } from "../providers-C9QC0TtO.mjs";
|
|
40
|
+
import { a as listConfigOp, i as getConfigValueOp, o as setConfigValueOp, s as unsetConfigValueOp, t as MainConfigOpsError } from "../main-config-ops-kTXR8Pyv.mjs";
|
|
41
|
+
import { n as PaiClient } from "../ipc-client-CnYEF31R.mjs";
|
|
42
42
|
import { existsSync, mkdirSync, readFileSync, writeFileSync } from "node:fs";
|
|
43
43
|
import { basename, dirname, join, resolve } from "node:path";
|
|
44
44
|
import { stringify } from "yaml";
|
|
@@ -6582,7 +6582,7 @@ function realDelegationDeps() {
|
|
|
6582
6582
|
return {
|
|
6583
6583
|
async resolveProject(project) {
|
|
6584
6584
|
if (existsSync(project)) return resolve(project);
|
|
6585
|
-
const { getProject } = await import("../helpers-
|
|
6585
|
+
const { getProject } = await import("../helpers-Dz7mjTSw.mjs");
|
|
6586
6586
|
const row = await getProject(project);
|
|
6587
6587
|
if (!row) throw new Error(`no project "${project}" is registered`);
|
|
6588
6588
|
return row.root_path;
|
|
@@ -3,36 +3,36 @@ import { t as writeFileAtomic } from "./atomic-file-BorMa4T3.mjs";
|
|
|
3
3
|
import { j as readWorkersSection, t as ANTHROPIC_NATIVE, wt as appendLedger } from "./config-XpZWOYOG.mjs";
|
|
4
4
|
import { f as readMainConfigRaw, i as defaults, p as writeMainConfigRaw, u as paiConfigFilePath, y as shippedMainDefaults } from "./config-Bu1_vbY8.mjs";
|
|
5
5
|
import { c as slotCurrentPath, i as ledgerPath, r as eventsPath, u as workersLogDir } from "./paths-CHifubDh.mjs";
|
|
6
|
-
import { f as gcWorktreesThrottled, w as worktreesDir } from "./worktree-
|
|
6
|
+
import { f as gcWorktreesThrottled, w as worktreesDir } from "./worktree-CRs2gyg0.mjs";
|
|
7
7
|
import { B as loadStatusConfig, C as nowStamp, G as writeSectionToForge, I as PROJECT_CONFIG_REL, L as formatStale, b as loadStatusesCached, h as isChatPane, k as saveStatus, s as alive, v as loadStatus, z as listStale } from "./status-ggJ7lgVg.mjs";
|
|
8
|
-
import { a as unregistrableReason } from "./registrable-
|
|
8
|
+
import { a as unregistrableReason } from "./registrable-DpyTtajg.mjs";
|
|
9
9
|
import { c as yieldToEventLoop, f as fileContentHash, l as buildOutline, n as chunkId, u as chunkMarkdown } from "./helpers-CRuBUas3.mjs";
|
|
10
10
|
import { n as TITLE_STOP_WORDS, t as STOP_WORDS } from "./stop-words-DSEYQdNe.mjs";
|
|
11
11
|
import { i as populateSlugs, t as applyRecencyBoost } from "./search-RSyeQqj1.mjs";
|
|
12
12
|
import { n as rerankResults } from "./reranker-CqCbpGnX.mjs";
|
|
13
13
|
import { i as itermUuid, r as itermForClaudeSession } from "./scope-D-h6F6DN.mjs";
|
|
14
|
-
import {
|
|
14
|
+
import { En as startLocalStatusRefresh, st as startInventoryRefresh } from "./routing-DmkheCRH.mjs";
|
|
15
15
|
import { n as minOf, t as maxOf } from "./min-max-DrSRUaWQ.mjs";
|
|
16
16
|
import { C as toolErrorSigTag, S as summarizeToolInput, T as toolErrorText, a as SAME_WORKER_WINDOW_MS, b as readToolErrors, c as classifyToolError, d as detectToolErrors, s as benignNote, u as detectRunningWorkerErrors, w as toolErrorSummary } from "./tool-errors-7E13StWd.mjs";
|
|
17
17
|
import { b as killProcessTree } from "./wait-ByV0OyMZ.mjs";
|
|
18
18
|
import { a as buildsDir, b as stallMinutes, c as listBuilds, l as listBuildsSync, u as patchTicket } from "./caller-identity-yLFb7CKq.mjs";
|
|
19
19
|
import { t as LOCAL_PROBE_TIMEOUT_MS } from "./timeouts-1MLooEBB.mjs";
|
|
20
|
-
import { d as getBackendOutage, n as createRegistryBackend, r as createStorageBackend } from "./factory-
|
|
21
|
-
import { c as resolveFromModule, n as embedChunksWithBackend } from "./postgres-
|
|
20
|
+
import { d as getBackendOutage, n as createRegistryBackend, r as createStorageBackend } from "./factory-B7nv75rC.mjs";
|
|
21
|
+
import { c as resolveFromModule, n as embedChunksWithBackend } from "./postgres-DNIOQijl.mjs";
|
|
22
22
|
import { a as requireQueryEmbedding, c as getConfiguredBackend, h as mismatchReason, m as bindingMatches, n as embedQuery } from "./embedding-gate-6rZrWRXa.mjs";
|
|
23
23
|
import { i as deserializeEmbedding, n as configureEmbeddingModel, r as cosineSimilarity$1 } from "./embeddings-BVq3esBF.mjs";
|
|
24
24
|
import { n as routeNotification } from "./router-CQSc3lk3.mjs";
|
|
25
|
-
import { r as formatDetectionJson, t as detectProject } from "./detect-
|
|
26
|
-
import { i as performScan } from "./scan-
|
|
25
|
+
import { r as formatDetectionJson, t as detectProject } from "./detect-BLKsUOgG.mjs";
|
|
26
|
+
import { i as performScan } from "./scan-BBGvU5EB.mjs";
|
|
27
27
|
import { r as sendToSession, t as callAiBroker } from "./aibroker-client-CQPGqLxL.mjs";
|
|
28
|
-
import { E as probeRouter, F as startHandover, M as routerSwapArgs, N as runRouterTick, O as routerIsStale, P as spawnRouter, j as routerRunningPid, l as runMessenger, t as runWorker } from "./run-
|
|
29
|
-
import { a as localIdleTick, et as closeEndedPanes, g as sweepRuns, gt as workerEnded, pt as paneMayClose, st as loadRegistry, xt as truncateLines } from "./controls-
|
|
30
|
-
import { l as isPaneRunId, n as auditTick, r as closeFinishedPanes } from "./pane-audit-
|
|
31
|
-
import { a as EMBED_PASS_BATCH_SIZE, c as liveYieldCheck, d as runEmbedCycle, i as DEFAULT_EMBED_RESUME_MINUTES, n as DEFAULT_EMBED_MAX_LOAD, r as DEFAULT_EMBED_MAX_MINUTES, t as DEFAULT_EMBED_CYCLE_MAX_MINUTES, u as recordEmbedPass } from "./embed-pass-
|
|
32
|
-
import { $ as setStartTime, A as indexSchedulerTimer, B as setDaemonConfig, Ct as runSessionKeepaliveTick, D as embedInProgress,
|
|
33
|
-
import { r as saveQueryResult } from "./query-feedback-
|
|
34
|
-
import { n as formatAutoRouteJson, r as detectTopicShift, t as autoRoute } from "./auto-route-
|
|
35
|
-
import { a as zettelThemes, c as zettelExplore, i as zettelHealth, n as zettelGodNotes, o as zettelConverse, r as zettelSuggest, s as zettelSurprise, t as zettelCommunities } from "./zettelkasten-
|
|
28
|
+
import { E as probeRouter, F as startHandover, M as routerSwapArgs, N as runRouterTick, O as routerIsStale, P as spawnRouter, j as routerRunningPid, l as runMessenger, t as runWorker } from "./run-BwZKBJZZ.mjs";
|
|
29
|
+
import { a as localIdleTick, et as closeEndedPanes, g as sweepRuns, gt as workerEnded, pt as paneMayClose, st as loadRegistry, xt as truncateLines } from "./controls-JLm6g0yP.mjs";
|
|
30
|
+
import { l as isPaneRunId, n as auditTick, r as closeFinishedPanes } from "./pane-audit-Lqy9N_Ki.mjs";
|
|
31
|
+
import { a as EMBED_PASS_BATCH_SIZE, c as liveYieldCheck, d as runEmbedCycle, i as DEFAULT_EMBED_RESUME_MINUTES, n as DEFAULT_EMBED_MAX_LOAD, r as DEFAULT_EMBED_MAX_MINUTES, t as DEFAULT_EMBED_CYCLE_MAX_MINUTES, u as recordEmbedPass } from "./embed-pass-e64AwDCa.mjs";
|
|
32
|
+
import { $ as setStartTime, A as indexSchedulerTimer, At as startQuietWatcher, B as setDaemonConfig, Ct as runSessionKeepaliveTick, D as embedInProgress, E as daemonConfig, F as lastVaultIndexTime, Ft as writeDaemonPidfile, G as setLastEmbedPass, H as setEmbedSchedulerTimer, I as notificationConfig, It as readContextHandoverCache, J as setLastIndexTime, K as setLastEmbedTime, L as passFailures, Lt as writeContextHandoverCache, M as lastEmbedTime, N as lastIndexPass, Nt as removeDaemonPidfile, O as embedSchedulerTimer, P as lastIndexTime, Q as setShutdownRequested, R as registryBackend, S as handleSessionSummary, T as cacheKeepaliveTimer, Tt as deferIfQuiet, U as setIndexInProgress, Ut as restartRouter, V as setEmbedInProgress, W as setIndexSchedulerTimer, X as setNotificationConfig, Y as setLastVaultIndexTime, Z as setRegistryBackend, _ as markFailed, _t as buildWakeupContext, a as runPassChild, at as vaultIndexInProgress, b as findLatestJsonl, c as NonRetryableError, ct as addWorkToSessionNote, d as enqueue, dt as getCurrentNotePath, et as setStorageBackend, f as enqueueCoalesced, ft as archiveSessionFilesToSessionsDir, g as markCompleted, gt as vaultIndexEnabled, h as loadQueue, ht as obsidianEnabled, it as storageBackend, j as lastEmbedPass, k as indexInProgress, kt as registerQuietRunner, l as cleanup, lt as appendCheckpoint, m as hasPendingOrProcessingOfType, n as buildPassCommand, nt as shutdownRequested, o as backfillKgFromNotes, ot as sessionIdFromTranscript, p as getStats, pt as findNotesDir, q as setLastIndexPass, r as cliEntry, rt as startTime, st as updateTodoContinue, t as PassSpawnError, tt as setVaultIndexInProgress, u as dequeue, ut as finalizeSessionNote, w as spawnSummarizer, x as getGitContext, xt as sweepOrphans, y as contentToText$2, z as setCacheKeepaliveTimer } from "./indexer-backend-BdjeL4P8.mjs";
|
|
33
|
+
import { r as saveQueryResult } from "./query-feedback-DN52N9C5.mjs";
|
|
34
|
+
import { n as formatAutoRouteJson, r as detectTopicShift, t as autoRoute } from "./auto-route-21GdHL70.mjs";
|
|
35
|
+
import { a as zettelThemes, c as zettelExplore, i as zettelHealth, n as zettelGodNotes, o as zettelConverse, r as zettelSuggest, s as zettelSurprise, t as zettelCommunities } from "./zettelkasten-_h_tUm2T.mjs";
|
|
36
36
|
import { appendFileSync, chmodSync, closeSync, existsSync, mkdirSync, openSync, readFileSync, readSync, readdirSync, realpathSync, statSync, unlinkSync, utimesSync, writeFileSync } from "node:fs";
|
|
37
37
|
import { basename, dirname, isAbsolute, join, normalize, relative, resolve, sep } from "node:path";
|
|
38
38
|
import { setPriority } from "node:os";
|
|
@@ -739,7 +739,7 @@ async function checkLoops(logDir, statuses, sent, deps = {}) {
|
|
|
739
739
|
}, kill = (pid) => {
|
|
740
740
|
process.kill(pid, "SIGTERM");
|
|
741
741
|
}, killChildren = async (logDir, id) => {
|
|
742
|
-
const { killTree } = await import("./kill-tree-
|
|
742
|
+
const { killTree } = await import("./kill-tree-SV6hrIa3.mjs");
|
|
743
743
|
return killTree(logDir, id, {
|
|
744
744
|
skipRoot: true,
|
|
745
745
|
by: "loop-guard",
|
|
@@ -3222,7 +3222,9 @@ function startCacheKeepalive(opts = {}) {
|
|
|
3222
3222
|
tool_input_summary: void 0,
|
|
3223
3223
|
files_read: [],
|
|
3224
3224
|
files_modified: [],
|
|
3225
|
-
concepts: []
|
|
3225
|
+
concepts: [],
|
|
3226
|
+
source: "daemon",
|
|
3227
|
+
fidelity: "inferred"
|
|
3226
3228
|
});
|
|
3227
3229
|
} catch (e) {
|
|
3228
3230
|
process.stderr.write(`[pai-daemon] Cache keepalive observation error: ${e instanceof Error ? e.message : String(e)}\n`);
|
|
@@ -6269,7 +6271,9 @@ async function handleRequest(request, socket) {
|
|
|
6269
6271
|
files_read: p.files_read ?? [],
|
|
6270
6272
|
files_modified: p.files_modified ?? [],
|
|
6271
6273
|
concepts: p.concepts ?? [],
|
|
6272
|
-
cwd: p.cwd
|
|
6274
|
+
cwd: p.cwd,
|
|
6275
|
+
source: "hook",
|
|
6276
|
+
fidelity: "observed"
|
|
6273
6277
|
})
|
|
6274
6278
|
}
|
|
6275
6279
|
});
|
|
@@ -6864,4 +6868,4 @@ async function serve(config) {
|
|
|
6864
6868
|
|
|
6865
6869
|
//#endregion
|
|
6866
6870
|
export { serve as t };
|
|
6867
|
-
//# sourceMappingURL=daemon-
|
|
6871
|
+
//# sourceMappingURL=daemon-nXanenDM.mjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as getRegistryBackend } from "./factory-
|
|
1
|
+
import { i as getRegistryBackend } from "./factory-B7nv75rC.mjs";
|
|
2
2
|
import { resolve } from "node:path";
|
|
3
3
|
|
|
4
4
|
//#region src/cli/impl/detect.ts
|
|
@@ -92,4 +92,4 @@ function formatDetectionJson(d) {
|
|
|
92
92
|
|
|
93
93
|
//#endregion
|
|
94
94
|
export { formatDetection as n, formatDetectionJson as r, detectProject as t };
|
|
95
|
-
//# sourceMappingURL=detect-
|
|
95
|
+
//# sourceMappingURL=detect-BLKsUOgG.mjs.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import "./config-Bu1_vbY8.mjs";
|
|
2
2
|
import "./helpers-CRuBUas3.mjs";
|
|
3
|
-
import "./factory-
|
|
4
|
-
import "./postgres-
|
|
3
|
+
import "./factory-B7nv75rC.mjs";
|
|
4
|
+
import "./postgres-DNIOQijl.mjs";
|
|
5
5
|
import "./embedding-gate-6rZrWRXa.mjs";
|
|
6
6
|
import "./embeddings-BVq3esBF.mjs";
|
|
7
7
|
import "./router-CQSc3lk3.mjs";
|
|
8
|
-
import { n as formatDetection, r as formatDetectionJson, t as detectProject } from "./detect-
|
|
8
|
+
import { n as formatDetection, r as formatDetectionJson, t as detectProject } from "./detect-BLKsUOgG.mjs";
|
|
9
9
|
|
|
10
10
|
export { detectProject };
|
|
@@ -161,4 +161,4 @@ async function runEmbedCycle(d) {
|
|
|
161
161
|
|
|
162
162
|
//#endregion
|
|
163
163
|
export { EMBED_PASS_BATCH_SIZE as a, liveYieldCheck as c, runEmbedCycle as d, DEFAULT_EMBED_RESUME_MINUTES as i, readEmbedPasses as l, DEFAULT_EMBED_MAX_LOAD as n, formatEmbedStatus as o, DEFAULT_EMBED_MAX_MINUTES as r, lastRecordedEmbedPass as s, DEFAULT_EMBED_CYCLE_MAX_MINUTES as t, recordEmbedPass as u };
|
|
164
|
-
//# sourceMappingURL=embed-pass-
|
|
164
|
+
//# sourceMappingURL=embed-pass-e64AwDCa.mjs.map
|
|
@@ -43,6 +43,13 @@ function requestKill(logDir, ledger, id, by = callerDescription(), forced = fals
|
|
|
43
43
|
...reason ? { reason } : {}
|
|
44
44
|
});
|
|
45
45
|
}
|
|
46
|
+
function peekMarker(logDir, id) {
|
|
47
|
+
try {
|
|
48
|
+
return JSON.parse(readFileSync(killMarkerPath(logDir, id), "utf8"));
|
|
49
|
+
} catch {
|
|
50
|
+
return null;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
46
53
|
function readMarker(logDir, id) {
|
|
47
54
|
const p = killMarkerPath(logDir, id);
|
|
48
55
|
if (!existsSync(p)) return null;
|
|
@@ -92,8 +99,15 @@ function parentInfo() {
|
|
|
92
99
|
function decideEndReason(a) {
|
|
93
100
|
if (a.timedOut) return { reason: "deadline" };
|
|
94
101
|
if (a.loopStopped) return { reason: "loop-stopped" };
|
|
95
|
-
|
|
96
|
-
|
|
102
|
+
const marker = a.signal || peekMarker(a.logDir, a.id)?.by === "pane audit" ? readMarker(a.logDir, a.id) : null;
|
|
103
|
+
if (!a.signal && !marker) return { reason: "exit" };
|
|
104
|
+
if (!a.signal && marker) return {
|
|
105
|
+
reason: "pai-worker-kill",
|
|
106
|
+
by: marker.by,
|
|
107
|
+
note: `killed by ${marker.by}${marker.reason ? `: ${marker.reason}` : ""}`,
|
|
108
|
+
...marker.reason ? { killReason: marker.reason } : {},
|
|
109
|
+
forced: true
|
|
110
|
+
};
|
|
97
111
|
if (marker) return {
|
|
98
112
|
reason: "pai-worker-kill",
|
|
99
113
|
by: marker.by,
|
|
@@ -137,4 +151,4 @@ function appendStopEvent(logDir, id, stop) {
|
|
|
137
151
|
|
|
138
152
|
//#endregion
|
|
139
153
|
export { endLabel as a, endFields as i, callerDescription as n, parentInfo as o, decideEndReason as r, requestKill as s, appendStopEvent as t };
|
|
140
|
-
//# sourceMappingURL=endreason-
|
|
154
|
+
//# sourceMappingURL=endreason-BC-v05H_.mjs.map
|
|
@@ -4,7 +4,7 @@ import { a as parseSessionTitleChunk, c as yieldToEventLoop, f as fileContentHas
|
|
|
4
4
|
import { t as STOP_WORDS } from "./stop-words-DSEYQdNe.mjs";
|
|
5
5
|
import { n as buildFtsQuery, r as isQuerySyntaxError } from "./search-RSyeQqj1.mjs";
|
|
6
6
|
import { n as minOf, t as maxOf } from "./min-max-DrSRUaWQ.mjs";
|
|
7
|
-
import { a as entityContentId, t as PostgresBackend } from "./postgres-
|
|
7
|
+
import { a as entityContentId, t as PostgresBackend } from "./postgres-DNIOQijl.mjs";
|
|
8
8
|
import { p as LEGACY_EMBEDDING_BINDING } from "./embedding-gate-6rZrWRXa.mjs";
|
|
9
9
|
import { i as deserializeEmbedding, r as cosineSimilarity } from "./embeddings-BVq3esBF.mjs";
|
|
10
10
|
import { n as routeNotification } from "./router-CQSc3lk3.mjs";
|
|
@@ -2915,4 +2915,4 @@ async function closeStorage() {
|
|
|
2915
2915
|
|
|
2916
2916
|
//#endregion
|
|
2917
2917
|
export { getStorageBackend as a, MergeError as c, getBackendOutage as d, humanDuration as f, getRegistryBackend as i, federationDbPath as l, createRegistryBackend as n, oldRegistryPath as o, createStorageBackend as r, registryDbPath as s, closeStorage as t, oldFederationPath as u };
|
|
2918
|
-
//# sourceMappingURL=factory-
|
|
2918
|
+
//# sourceMappingURL=factory-B7nv75rC.mjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./config-Bu1_vbY8.mjs";
|
|
2
2
|
import "./helpers-CRuBUas3.mjs";
|
|
3
|
-
import { a as getStorageBackend, i as getRegistryBackend, n as createRegistryBackend, r as createStorageBackend, t as closeStorage } from "./factory-
|
|
4
|
-
import "./postgres-
|
|
3
|
+
import { a as getStorageBackend, i as getRegistryBackend, n as createRegistryBackend, r as createStorageBackend, t as closeStorage } from "./factory-B7nv75rC.mjs";
|
|
4
|
+
import "./postgres-DNIOQijl.mjs";
|
|
5
5
|
import "./embedding-gate-6rZrWRXa.mjs";
|
|
6
6
|
import "./embeddings-BVq3esBF.mjs";
|
|
7
7
|
import "./router-CQSc3lk3.mjs";
|