zidane 6.2.23 → 6.2.24
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/{acp-B7wH6LhE.js → acp-CTn1kFvP.js} +4 -4
- package/dist/{acp-B7wH6LhE.js.map → acp-CTn1kFvP.js.map} +1 -1
- package/dist/acp-cli.js +2 -2
- package/dist/acp.d.ts +1 -1
- package/dist/acp.js +1 -1
- package/dist/{agent-BSIMsEtD.js → agent-tLfGSSQw.js} +59 -25
- package/dist/agent-tLfGSSQw.js.map +1 -0
- package/dist/agent.d.ts +1 -1
- package/dist/agent.js +1 -1
- package/dist/chat/pure.d.ts +3 -3
- package/dist/chat/pure.js +1 -1
- package/dist/chat.d.ts +4 -4
- package/dist/chat.js +4 -4
- package/dist/contexts/daytona.d.ts +1 -1
- package/dist/contexts/e2b.d.ts +1 -1
- package/dist/eval.d.ts +1 -1
- package/dist/eval.js +1 -1
- package/dist/extensions.d.ts +1 -1
- package/dist/extensions.js +1 -1
- package/dist/headless.d.ts +1 -1
- package/dist/headless.js +2 -2
- package/dist/{index-Bv9qhj4n.d.ts → index-8zm_hwdY.d.ts} +44 -3
- package/dist/index-8zm_hwdY.d.ts.map +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +6 -6
- package/dist/{login-BkZ_d5sT.js → login-DfJGuHUj.js} +2 -2
- package/dist/{login-BkZ_d5sT.js.map → login-DfJGuHUj.js.map} +1 -1
- package/dist/mcp.d.ts +1 -1
- package/dist/output/stream-json.d.ts +1 -1
- package/dist/output/terminal.d.ts +1 -1
- package/dist/presets.d.ts +1 -1
- package/dist/presets.js +1 -1
- package/dist/providers/anthropic.d.ts +1 -1
- package/dist/providers/arcee.d.ts +1 -1
- package/dist/providers/baseten.d.ts +1 -1
- package/dist/providers/cerebras.d.ts +1 -1
- package/dist/providers/local.d.ts +1 -1
- package/dist/providers/openai-compat.d.ts +1 -1
- package/dist/providers/openai.d.ts +1 -1
- package/dist/providers/openrouter.d.ts +1 -1
- package/dist/providers/xai.d.ts +1 -1
- package/dist/providers.d.ts +1 -1
- package/dist/{resolve-x5mlFtLX.js → resolve-BPTA1RpX.js} +23 -3
- package/dist/resolve-BPTA1RpX.js.map +1 -0
- package/dist/restate.d.ts +1 -1
- package/dist/session/sqlite.d.ts +1 -1
- package/dist/{session-Dbvz1ZUE.js → session-jLsc_kMH.js} +22 -3
- package/dist/session-jLsc_kMH.js.map +1 -0
- package/dist/session.d.ts +2 -2
- package/dist/session.js +2 -2
- package/dist/{skills-C1vGKbqv.js → skills-C7eIjWYm.js} +2 -2
- package/dist/{skills-C1vGKbqv.js.map → skills-C7eIjWYm.js.map} +1 -1
- package/dist/skills.d.ts +1 -1
- package/dist/skills.js +2 -2
- package/dist/{tool-formatters-D9P6Znip.d.ts → tool-formatters-CZJYzP4x.d.ts} +2 -2
- package/dist/{tool-formatters-D9P6Znip.d.ts.map → tool-formatters-CZJYzP4x.d.ts.map} +1 -1
- package/dist/tools/fetch-url.d.ts +1 -1
- package/dist/tools/web-search.d.ts +1 -1
- package/dist/tools.d.ts +1 -1
- package/dist/tools.js +1 -1
- package/dist/{transcript-anchors-Ci5888xS.d.ts → transcript-anchors-CJ2dmpQk.d.ts} +2 -2
- package/dist/{transcript-anchors-Ci5888xS.d.ts.map → transcript-anchors-CJ2dmpQk.d.ts.map} +1 -1
- package/dist/{transcript-anchors-CqzIr74w.js → transcript-anchors-Ded7iJjG.js} +11 -7
- package/dist/transcript-anchors-Ded7iJjG.js.map +1 -0
- package/dist/tui.d.ts +15 -5
- package/dist/tui.d.ts.map +1 -1
- package/dist/tui.js +742 -315
- package/dist/tui.js.map +1 -1
- package/dist/{turn-operations-CokV32wf.js → turn-operations-ClGa1vnb.js} +6 -2
- package/dist/{turn-operations-CokV32wf.js.map → turn-operations-ClGa1vnb.js.map} +1 -1
- package/dist/{turn-operations-C3y6A82G.d.ts → turn-operations-DZYpXcU1.d.ts} +3 -3
- package/dist/{turn-operations-C3y6A82G.d.ts.map → turn-operations-DZYpXcU1.d.ts.map} +1 -1
- package/dist/types-BIarq1qE.js.map +1 -1
- package/dist/types.d.ts +1 -1
- package/package.json +1 -1
- package/dist/agent-BSIMsEtD.js.map +0 -1
- package/dist/index-Bv9qhj4n.d.ts.map +0 -1
- package/dist/resolve-x5mlFtLX.js.map +0 -1
- package/dist/session-Dbvz1ZUE.js.map +0 -1
- package/dist/transcript-anchors-CqzIr74w.js.map +0 -1
package/dist/acp-cli.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { Ft as resolveStorageDirs, lt as basic_default } from "./agent-
|
|
2
|
+
import { Ft as resolveStorageDirs, lt as basic_default } from "./agent-tLfGSSQw.js";
|
|
3
3
|
import { r as createProcessContext } from "./contexts-A4ep-iJs.js";
|
|
4
4
|
import { createSandboxContext } from "./contexts/sandbox.js";
|
|
5
5
|
import { m as openaiCompat } from "./openai-compat-pHI0kBWH.js";
|
|
@@ -10,7 +10,7 @@ import { cerebras } from "./providers/cerebras.js";
|
|
|
10
10
|
import { t as xai } from "./xai-BwhzoehX.js";
|
|
11
11
|
import { openai } from "./providers/openai.js";
|
|
12
12
|
import { openrouter } from "./providers/openrouter.js";
|
|
13
|
-
import { d as StartUsageError, f as buildStartLocalOptions, h as startProviderNames, i as withAcpDefaultTools, m as startLocalArgOptions, p as parseStartArgValues, t as runAcpStdioServer } from "./acp-
|
|
13
|
+
import { d as StartUsageError, f as buildStartLocalOptions, h as startProviderNames, i as withAcpDefaultTools, m as startLocalArgOptions, p as parseStartArgValues, t as runAcpStdioServer } from "./acp-CTn1kFvP.js";
|
|
14
14
|
import { f as credKeyOf, i as readCredentials, l as BUILTIN_PROVIDERS, r as credentialsPath, t as detectAuth, y as modelsForDescriptor } from "./auth-CpdQebUy.js";
|
|
15
15
|
import { createDaytonaProvider } from "./contexts/daytona.js";
|
|
16
16
|
import { createDockerContext } from "./contexts/docker.js";
|
package/dist/acp.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Li as AgentOptions, Md as AgentBehavior, Pf as TurnUsage, Pi as Agent, Tf as ToolResultContent, em as Provider, if as PromptPart, pf as SessionContentBlock, qd as McpServerConfig, rp as Session, sp as SessionStore, t as Preset, zf as ToolDef } from "./index-8zm_hwdY.js";
|
|
2
2
|
import { c as ExecutionContext } from "./types-BDccavwj.js";
|
|
3
3
|
import { Readable, Writable } from "node:stream";
|
|
4
4
|
|
package/dist/acp.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { _ as createJsonRpcConnection, a as wrapToolsForAcpClient, c as sessionBlocksToAcp, g as JsonRpcRemoteError, i as withAcpDefaultTools, l as stopReasonFromRun, n as AcpProtocolError, o as acpMcpServersToZidane, r as createAcpServer, s as acpPromptToPromptParts, t as runAcpStdioServer, u as toolResultToAcpContent } from "./acp-
|
|
1
|
+
import { _ as createJsonRpcConnection, a as wrapToolsForAcpClient, c as sessionBlocksToAcp, g as JsonRpcRemoteError, i as withAcpDefaultTools, l as stopReasonFromRun, n as AcpProtocolError, o as acpMcpServersToZidane, r as createAcpServer, s as acpPromptToPromptParts, t as runAcpStdioServer, u as toolResultToAcpContent } from "./acp-CTn1kFvP.js";
|
|
2
2
|
export { AcpProtocolError, JsonRpcRemoteError, acpMcpServersToZidane, acpPromptToPromptParts, createAcpServer, createJsonRpcConnection, runAcpStdioServer, sessionBlocksToAcp, stopReasonFromRun, toolResultToAcpContent, withAcpDefaultTools, wrapToolsForAcpClient };
|
|
@@ -9,16 +9,16 @@ import { c as parseGitLsFiles, r as isOutputExceededMessage, s as GIT_LS_FILES_C
|
|
|
9
9
|
import { n as alwaysQuote, r as shellQuote } from "./exec-file-size-PXkr-MGA.js";
|
|
10
10
|
import { r as createProcessContext, t as resolveDetachedTasksCapability } from "./contexts-A4ep-iJs.js";
|
|
11
11
|
import { i as AgentProviderError, l as errorMessage, m as toTypedError, n as AgentBudgetExceededError, o as AgentToolPairingError, t as AgentAbortedError, u as isAbortLikeError } from "./errors-DJUxZg9b.js";
|
|
12
|
-
import { C as stripShellInterpolations, O as validateResourcePathReal, S as interpolateShellCommands, _ as lastLine, b as resolveSubdirRoot, d as installAllowedToolsGate, f as createSkillActivationState, g as fetchInstallSource, h as defaultWhich, j as projectUserPaths, l as buildCatalog, m as defaultExec, p as InstallSourceError, t as resolveSkills, v as parseInstallSource, x as escapeXml, y as resolveNpmVersion } from "./resolve-
|
|
12
|
+
import { C as stripShellInterpolations, O as validateResourcePathReal, S as interpolateShellCommands, _ as lastLine, b as resolveSubdirRoot, d as installAllowedToolsGate, f as createSkillActivationState, g as fetchInstallSource, h as defaultWhich, j as projectUserPaths, l as buildCatalog, m as defaultExec, p as InstallSourceError, t as resolveSkills, v as parseInstallSource, x as escapeXml, y as resolveNpmVersion } from "./resolve-BPTA1RpX.js";
|
|
13
13
|
import { n as writeFileAtomicAsync, t as writeFileAtomic } from "./atomic-write-B7zr1ddF.js";
|
|
14
14
|
import { r as createLogger, t as consoleSink } from "./logger-DBX9uYOw.js";
|
|
15
15
|
import { n as reconcileImageMediaType } from "./media-sniff-Bn76JxAu.js";
|
|
16
16
|
import { c as wrapDiscoveredMcpTools, i as nonOwningMcpView, n as connectMcpServers, r as deriveMcpToolMeta } from "./mcp-H6bqyM94.js";
|
|
17
|
-
import { n as flattenTurns, r as formatTokenUsage, t as effectiveInputFromTurn } from "./stats-DAKBEKjc.js";
|
|
18
17
|
import { C as canonicalizePrompt, S as buildPromptMessage } from "./openai-compat-pHI0kBWH.js";
|
|
19
18
|
import { appendStaticSection, renderSystemForWire } from "./prompt.js";
|
|
20
19
|
import { a as detectTurnInterruption, c as filterUnresolvedToolUses, d as remintDuplicateToolCallIds, f as resolveContentRefsInMessages, n as SYNTHETIC_TOOL_RESULT_PLACEHOLDER, o as ensureEndsWithUserMessage, s as ensureToolResultPairing } from "./messages-CvHfYB7f.js";
|
|
21
|
-
import { a as getExtensionSessionState, c as withExtensionSession, n as currentExtensionSession, r as deleteExtensionSessionState, s as
|
|
20
|
+
import { a as getExtensionSessionState, c as setExtensionSessionState, l as withExtensionSession, n as currentExtensionSession, r as deleteExtensionSessionState, s as resumeChainRunIds } from "./session-jLsc_kMH.js";
|
|
21
|
+
import { n as flattenTurns, r as formatTokenUsage, t as effectiveInputFromTurn } from "./stats-DAKBEKjc.js";
|
|
22
22
|
import { a as withInactivityTimeout, i as settleWithinTimeout, n as linkAbortSignal, o as withTimeout$1, r as resolveTimeoutMs, t as OperationTimeoutError } from "./timeout-BDetbuN6.js";
|
|
23
23
|
import { createRequire } from "node:module";
|
|
24
24
|
import { basename, delimiter, dirname, isAbsolute, join, resolve, sep } from "node:path";
|
|
@@ -4838,6 +4838,7 @@ const BUBBLED_EVENTS = [
|
|
|
4838
4838
|
"stream:error",
|
|
4839
4839
|
"stream:server_tool_use",
|
|
4840
4840
|
"stream:server_tool_result",
|
|
4841
|
+
"stream:retry",
|
|
4841
4842
|
"tool:dispatched",
|
|
4842
4843
|
"tool:before",
|
|
4843
4844
|
"tool:after",
|
|
@@ -4861,6 +4862,7 @@ const CHILD_EVENT_NAME = {
|
|
|
4861
4862
|
"stream:error": "child:stream:error",
|
|
4862
4863
|
"stream:server_tool_use": "child:stream:server_tool_use",
|
|
4863
4864
|
"stream:server_tool_result": "child:stream:server_tool_result",
|
|
4865
|
+
"stream:retry": "child:stream:retry",
|
|
4864
4866
|
"tool:dispatched": "child:tool:dispatched",
|
|
4865
4867
|
"tool:before": "child:tool:before",
|
|
4866
4868
|
"tool:after": "child:tool:after",
|
|
@@ -4883,19 +4885,27 @@ function childRunsOf(session) {
|
|
|
4883
4885
|
return session.runs.filter((r) => (r.depth ?? 0) > 0);
|
|
4884
4886
|
}
|
|
4885
4887
|
/**
|
|
4886
|
-
* Human/model-facing list of this session's child runs
|
|
4887
|
-
*
|
|
4888
|
-
*
|
|
4889
|
-
*
|
|
4888
|
+
* Human/model-facing list of this session's child runs. Prefers the label
|
|
4889
|
+
* persisted at `startRun` (`SessionRun.label`) and falls back to positional
|
|
4890
|
+
* numbering for legacy sessions recorded before labels were stored.
|
|
4891
|
+
* Rendered into resume-rejection messages so the model can self-correct
|
|
4892
|
+
* with a valid label.
|
|
4890
4893
|
*/
|
|
4891
4894
|
function describeChildRuns(session) {
|
|
4892
4895
|
const childRuns = childRunsOf(session);
|
|
4893
4896
|
if (childRuns.length === 0) return "No child runs exist in this session.";
|
|
4894
|
-
return childRuns.map((r, i) => `- child-${i + 1} · ${r.status} · ${r.prompt.slice(0, 80)}`).join("\n");
|
|
4897
|
+
return childRuns.map((r, i) => `- ${r.label ?? `child-${i + 1}`} · ${r.status} · ${r.prompt.slice(0, 80)}`).join("\n");
|
|
4895
4898
|
}
|
|
4896
4899
|
function reserveChildLabel(session) {
|
|
4897
4900
|
let counter = sessionChildCounters.get(session);
|
|
4898
|
-
if (counter === void 0)
|
|
4901
|
+
if (counter === void 0) {
|
|
4902
|
+
const childRuns = childRunsOf(session);
|
|
4903
|
+
counter = childRuns.length;
|
|
4904
|
+
for (const r of childRuns) {
|
|
4905
|
+
const m = r.label ? /^child-(\d+)$/.exec(r.label) : null;
|
|
4906
|
+
if (m) counter = Math.max(counter, Number(m[1]));
|
|
4907
|
+
}
|
|
4908
|
+
}
|
|
4899
4909
|
counter += 1;
|
|
4900
4910
|
sessionChildCounters.set(session, counter);
|
|
4901
4911
|
return `child-${counter}`;
|
|
@@ -5318,7 +5328,12 @@ function buildSpawnTool(options, state) {
|
|
|
5318
5328
|
const announcedModel = childModel ?? childProvider.meta.defaultModel;
|
|
5319
5329
|
let resumeRun;
|
|
5320
5330
|
let resumeLabel;
|
|
5321
|
-
if (
|
|
5331
|
+
if (input.resume !== void 0 && input.resume !== null) {
|
|
5332
|
+
if (typeof input.resume !== "string" || input.resume.trim() === "") return {
|
|
5333
|
+
status: "rejected",
|
|
5334
|
+
text: "",
|
|
5335
|
+
message: `Cannot resume: invalid resume value ${JSON.stringify(input.resume)} — pass a child label like "child-2".`
|
|
5336
|
+
};
|
|
5322
5337
|
const wanted = input.resume.trim();
|
|
5323
5338
|
if (!options.persist || !ctx.session) return {
|
|
5324
5339
|
status: "rejected",
|
|
@@ -5326,26 +5341,31 @@ function buildSpawnTool(options, state) {
|
|
|
5326
5341
|
message: "Cannot resume: resuming a sub-agent requires the spawn tool to be configured with persist: true and the parent to have a session — no prior child turns are stored here."
|
|
5327
5342
|
};
|
|
5328
5343
|
const childRuns = childRunsOf(ctx.session);
|
|
5329
|
-
|
|
5330
|
-
|
|
5344
|
+
let index = childRuns.findIndex((r) => r.label === wanted);
|
|
5345
|
+
if (index < 0) {
|
|
5346
|
+
const labelMatch = /^child-(\d+)$/.exec(wanted);
|
|
5347
|
+
index = labelMatch ? Number(labelMatch[1]) - 1 : childRuns.findIndex((r) => r.id === wanted);
|
|
5348
|
+
}
|
|
5331
5349
|
const run = index >= 0 ? childRuns[index] : void 0;
|
|
5332
5350
|
if (!run) return {
|
|
5333
5351
|
status: "rejected",
|
|
5334
5352
|
text: "",
|
|
5335
5353
|
message: `Cannot resume: no child run matches "${wanted}". Child runs in this session:\n${describeChildRuns(ctx.session)}`
|
|
5336
5354
|
};
|
|
5355
|
+
const runLabel = run.label ?? `child-${index + 1}`;
|
|
5337
5356
|
if (run.status === "running") return {
|
|
5338
5357
|
status: "rejected",
|
|
5339
5358
|
text: "",
|
|
5340
|
-
message: `Cannot resume:
|
|
5359
|
+
message: `Cannot resume: ${runLabel} is still running. Only terminal children (aborted / error / completed) can be resumed.`
|
|
5341
5360
|
};
|
|
5342
|
-
|
|
5361
|
+
const chain = resumeChainRunIds(ctx.session.runs, run.id);
|
|
5362
|
+
if (!ctx.session.turns.some((t) => t.runId !== void 0 && chain.has(t.runId))) return {
|
|
5343
5363
|
status: "rejected",
|
|
5344
5364
|
text: "",
|
|
5345
|
-
message: `Cannot resume:
|
|
5365
|
+
message: `Cannot resume: ${runLabel} has no persisted turns (it likely failed before producing anything). Spawn a fresh child with a full task instead.`
|
|
5346
5366
|
};
|
|
5347
5367
|
resumeRun = run;
|
|
5348
|
-
resumeLabel =
|
|
5368
|
+
resumeLabel = runLabel;
|
|
5349
5369
|
}
|
|
5350
5370
|
const parentDepth = ctx.depth ?? 0;
|
|
5351
5371
|
const childDepth = parentDepth + 1;
|
|
@@ -5438,6 +5458,7 @@ function buildSpawnTool(options, state) {
|
|
|
5438
5458
|
signal: ctx.signal,
|
|
5439
5459
|
depth: childDepth,
|
|
5440
5460
|
...options.persist && ctx.runId ? { parentRunId: ctx.runId } : {},
|
|
5461
|
+
...options.persist && ctx.session ? { runLabel: id } : {},
|
|
5441
5462
|
...resumeRun ? { resumeRunId: resumeRun.id } : {},
|
|
5442
5463
|
...propagatedTracing ? { tracingContext: propagatedTracing } : {}
|
|
5443
5464
|
});
|
|
@@ -11256,6 +11277,7 @@ async function executeTurn(ctx, turn, priorUsage) {
|
|
|
11256
11277
|
turnId,
|
|
11257
11278
|
attempt,
|
|
11258
11279
|
nextAttempt: attempt + 1,
|
|
11280
|
+
maxAttempts: retryCfg.maxAttempts,
|
|
11259
11281
|
delayMs,
|
|
11260
11282
|
err: caught,
|
|
11261
11283
|
...meta
|
|
@@ -12995,6 +13017,7 @@ const HOOK_EVENT_SET = /* @__PURE__ */ new Set([
|
|
|
12995
13017
|
"child:stream:server_tool_use",
|
|
12996
13018
|
"child:stream:server_tool_result",
|
|
12997
13019
|
"child:stream:error",
|
|
13020
|
+
"child:stream:retry",
|
|
12998
13021
|
"child:tool:gate",
|
|
12999
13022
|
"child:mcp:tool:gate",
|
|
13000
13023
|
"child:tool:dispatched",
|
|
@@ -13474,10 +13497,10 @@ function installLazyDisclosureGate(hooks, lazyCanonicalNames, unlocked, discover
|
|
|
13474
13497
|
* (`via: 'resume'`) for skills it newly activates. Shared by the run-start
|
|
13475
13498
|
* resume rehydration and the mid-loop durable-replay gate below.
|
|
13476
13499
|
*/
|
|
13477
|
-
async function rehydrateActiveSkillsFromTurns(
|
|
13500
|
+
async function rehydrateActiveSkillsFromTurns(turns, resolvedSkills, state, hooks) {
|
|
13478
13501
|
const skillsByName = new Map(resolvedSkills.map((s) => [s.name, s]));
|
|
13479
13502
|
const lastModeBySkill = /* @__PURE__ */ new Map();
|
|
13480
|
-
for (const turn of
|
|
13503
|
+
for (const turn of turns) {
|
|
13481
13504
|
if (turn.role !== "assistant") continue;
|
|
13482
13505
|
for (const block of turn.content) {
|
|
13483
13506
|
if (block.type !== "tool_call" || block.name !== "skills_use") continue;
|
|
@@ -13523,7 +13546,7 @@ function installSkillsActivationHydrationGate(hooks, deps) {
|
|
|
13523
13546
|
const skillName = typeof ctx.input?.name === "string" ? ctx.input.name : void 0;
|
|
13524
13547
|
if (!skillName || deps.state.isActive(skillName)) return;
|
|
13525
13548
|
try {
|
|
13526
|
-
await rehydrateActiveSkillsFromTurns(session, resolvedSkills, deps.state, hooks);
|
|
13549
|
+
await rehydrateActiveSkillsFromTurns(session.turns, resolvedSkills, deps.state, hooks);
|
|
13527
13550
|
} catch {}
|
|
13528
13551
|
});
|
|
13529
13552
|
}
|
|
@@ -13941,7 +13964,8 @@ function createAgent(rawOptions) {
|
|
|
13941
13964
|
if (options.resumeRunId) {
|
|
13942
13965
|
if (!session) throw new Error("resumeRunId requires a session (the prior run's turns live there)");
|
|
13943
13966
|
if (!options.prompt) throw new Error("resumeRunId requires a prompt — pass the continuation instruction");
|
|
13944
|
-
|
|
13967
|
+
const chain = resumeChainRunIds(session.runs, options.resumeRunId);
|
|
13968
|
+
if (!session.turns.some((t) => t.runId !== void 0 && chain.has(t.runId))) throw new Error(`resumeRunId "${options.resumeRunId}" has no persisted turns in this session — nothing to resume`);
|
|
13945
13969
|
}
|
|
13946
13970
|
const clock = options.clock ?? agentClock ?? DEFAULT_AGENT_CLOCK;
|
|
13947
13971
|
let externalAbortListener;
|
|
@@ -13963,7 +13987,8 @@ function createAgent(rawOptions) {
|
|
|
13963
13987
|
session?.startRun(runId, promptLabel, {
|
|
13964
13988
|
...options.parentRunId ? { parentRunId: options.parentRunId } : {},
|
|
13965
13989
|
depth: typeof options.depth === "number" ? options.depth : 0,
|
|
13966
|
-
...options.resumeRunId ? { resumedFromRunId: options.resumeRunId } : {}
|
|
13990
|
+
...options.resumeRunId ? { resumedFromRunId: options.resumeRunId } : {},
|
|
13991
|
+
...options.runLabel ? { label: options.runLabel } : {}
|
|
13967
13992
|
});
|
|
13968
13993
|
const sessionRun = session?.runs.find((r) => r.id === runId);
|
|
13969
13994
|
if (sessionRun) sessionRun.startedAt = runStartedAt;
|
|
@@ -14022,7 +14047,14 @@ function createAgent(rawOptions) {
|
|
|
14022
14047
|
});
|
|
14023
14048
|
}
|
|
14024
14049
|
});
|
|
14025
|
-
if (resolvedSkills && session && session.turns.length > 0 && skillActivationState.active().length === 0)
|
|
14050
|
+
if (resolvedSkills && session && session.turns.length > 0 && skillActivationState.active().length === 0) {
|
|
14051
|
+
let rehydrationTurns = session.turns;
|
|
14052
|
+
if (options.resumeRunId) {
|
|
14053
|
+
const chain = resumeChainRunIds(session.runs, options.resumeRunId);
|
|
14054
|
+
rehydrationTurns = session.turns.filter((t) => t.runId !== void 0 && chain.has(t.runId));
|
|
14055
|
+
}
|
|
14056
|
+
await rehydrateActiveSkillsFromTurns(rehydrationTurns, resolvedSkills, skillActivationState, hooks);
|
|
14057
|
+
}
|
|
14026
14058
|
const thinking = options.thinking ?? "off";
|
|
14027
14059
|
const model = targets[0].model;
|
|
14028
14060
|
if (runProvider.meta?.clearsContextServerSide) resolvedBehavior.dedupReads = false;
|
|
@@ -14191,8 +14223,10 @@ function createAgent(rawOptions) {
|
|
|
14191
14223
|
const turns = [];
|
|
14192
14224
|
const isResume = session && session.turns.length > 0 && (session.runs.length > 0 || !options.prompt) && !options.parentRunId && !options.resumeRunId;
|
|
14193
14225
|
let seededTurns;
|
|
14194
|
-
if (options.resumeRunId && session)
|
|
14195
|
-
|
|
14226
|
+
if (options.resumeRunId && session) {
|
|
14227
|
+
const chain = resumeChainRunIds(session.runs, options.resumeRunId);
|
|
14228
|
+
seededTurns = filterUnresolvedToolUses(session.turns.filter((t) => t.runId !== void 0 && chain.has(t.runId)));
|
|
14229
|
+
} else if (isResume) {
|
|
14196
14230
|
const childRunIds = childRunIdSet(session);
|
|
14197
14231
|
const resumed = childRunIds.size === 0 ? session.turns : session.turns.filter((t) => !t.runId || !childRunIds.has(t.runId));
|
|
14198
14232
|
seededTurns = resumeFilteredTurns && resumed === session.turns ? resumeFilteredTurns : filterUnresolvedToolUses(resumed);
|
|
@@ -15068,4 +15102,4 @@ function createAgent(rawOptions) {
|
|
|
15068
15102
|
//#endregion
|
|
15069
15103
|
export { composeExtensionPreset as $, discoverExtensions as $t, ANCHOR_PREVIEW_MAX_CHARS as A, createInteractionTool as At, ExtensionInstallError as B, ensureKeybindingsFile as Bt, NO_TOOLS_PREAMBLE as C, readFile$1 as Ct, buildFullCompactPrompt as D, formatModelLine as Dt, buildFromCompactPrompt as E, createModelSearchTool as Et, truncateHeadForPtlRetry as F, resolveStorageDirs as Ft, readExtensionInstallProvenance as G, mergeKeybindings as Gt, installExtensionFromSpec as H, groupBindings as Ht, CompactInvalidInputError as I, DEFAULT_KEYBINDINGS as It, createExtensionHud as J, readKeybindingsRaw as Jt, removeInstalledExtension as K, parseBindingSpec as Kt, CompactPromptTooLongError as L, KEYBINDING_DEFS as Lt, sliceForCompaction as M, glob as Mt, stripImagesFromTurns as N, edit as Nt, buildTailCompactPrompt as O, matchModelEntries as Ot, summaryToTurn as P, validateToolArgs as Pt, buildExtensionRegistry as Q, defaultExtensionScanPaths as Qt, EMPTY_EXTENSION_REGISTRY as R, KEYBINDING_DEF_BY_ACTION as Rt, BASE_INSTRUCTIONS as S, tailTruncate as St, buildCompactPrompt as T, multiEdit as Tt, listExtensionCandidates as U, keybindingsPath as Ut, fetchExtensionSource as V, formatBindingForDisplay as Vt, parseExtensionInstallSource as W, matchesBinding as Wt, discoverAndBuildExtensionRegistry as X, stripJsonComments as Xt, registerExtensionHostModules as Y, resolveExtensionKeybindings as Yt, buildExtensionPreset as Z, ENTRY_CANDIDATES as Zt, buildPostCompactAttachments as _, defaultRepeatGuardNormalize as _n, createSkillsRunScriptTool as _t, SHELL_CASCADE_CANCEL_MESSAGE as a, clampExtensionConfigNumber as an, createWorkspaceSurface as at, selectRecentFiles as b, stableStringify as bn, createShellTool as bt, applyCompactSummaryCutoff as c, isValidExtensionConfigValue as cn, basicTools as ct, buildPersistedStub as d, sanitizeExtensionConfigActionPatch as dn, WAIT_TASK_TIMED_OUT_PREFIX as dt, inlineLoadedExtension as en, disposeExtensionRegistry as et, cleanupPersistedSession as f, toWireConfigSchema as fn, waitTask as ft, resolveTasksDir as g, shouldAutoCompact as gn, createSkillsUseTool as gt, resolvePersistDir as h, effectiveContextWindow as hn, isSpawnTool as ht, INTERRUPT_MESSAGE_FOR_TOOL_USE as i, defineExtension as in, createExtensionHostRuntimeBridge as it, anchorPreviewFor as j, grep as jt, buildUpToCompactPrompt as k, listFiles as kt, PERSISTED_STUB_PREFIX as l, resolveExtensionConfig as ln, basic_default as lt, resolveMcpWarningsDir as m, OUTPUT_RESERVE_TOKENS as mn, createSpawnTool as mt, normalizeProviders as n, parseExtensionScanPathEnv as nn, mergeContributions as nt, TOOL_USE_CANCELLED_MESSAGE as o, coerceExtensionConfigInput as on, composePresets as ot, maybePersistToolResult as p, AUTO_COMPACT_MIN_GROWTH_FRACTION as pn, createToolSearchTool as pt, updateInstalledExtension as q, readKeybindings as qt, resolveModelTargets as r, scanExtensionDirectories as rn, partitionExtensionCatalog as rt, TOOL_USE_SKIPPED_MESSAGE as s, isValidExtensionConfigItem as sn, definePreset as st, createAgent as t, isExtensionDefinition as tn, filterExtensionRegistry as tt, PERSISTENCE_PREVIEW_BYTES as u, resolveExtensionConfigValue as un, writeFile$1 as ut, selectFilesFromReadState as v, defaultRepeatGuardTracked as vn, createSkillsReadTool as vt, TRAILER as w, looksBinary as wt, compactConversation as x, shell as xt, selectFilesFromSession as y, normalizeShellCommand as yn, shellKill as yt, createExtensionPromptBridge as z, KEYBINDING_KEY_COL_WIDTH as zt };
|
|
15070
15104
|
|
|
15071
|
-
//# sourceMappingURL=agent-
|
|
15105
|
+
//# sourceMappingURL=agent-tLfGSSQw.js.map
|