agentbox-sdk 0.1.309 → 0.1.310
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/agents/index.d.ts +2 -2
- package/dist/agents/index.js +2 -2
- package/dist/{chunk-VBMMNUB7.js → chunk-6MDOW3GK.js} +30 -6
- package/dist/{chunk-ZDSHOGJ4.js → chunk-PNONJAGY.js} +65 -3
- package/dist/events/index.d.ts +13 -1
- package/dist/events/index.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/dist/{types-DmkbgYmn.d.ts → types-du-Kkn53.d.ts} +17 -0
- package/package.json +1 -1
package/dist/agents/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { o as AgentProviderName, h as AgentOptions, t as AgentRunConfig, s as AgentRun, r as AgentResult, a2 as RawAgentEvent, b as AgentAttachRequest, y as AttachedRun, a9 as SetupLayout } from '../types-
|
|
2
|
-
export { a as AgentApprovalMode, c as AgentCommandConfig, d as AgentCostData, e as AgentExecutionRequest, f as AgentLocalMcpConfig, g as AgentMcpConfig, i as AgentOptionsBase, j as AgentOptionsMap, k as AgentPermissionDecision, l as AgentPermissionKind, m as AgentPermissionResponse, n as AgentProviderAdapter, p as AgentReasoningEffort, q as AgentRemoteMcpConfig, u as AgentRunSink, v as AgentSetupRequest, w as AgentSkillConfig, x as AgentSubAgentConfig, C as ClaudeCodeAgentOptions, z as ClaudeCodeHookConfig, B as ClaudeCodeHookEvent, D as ClaudeCodeHookHandler, E as ClaudeCodeHookMatcherGroup, F as ClaudeCodeHooksConfig, G as ClaudeCodeProviderOptions, H as CodexAgentOptions, I as CodexCommandHook, J as CodexHookEvent, K as CodexHookMatcherGroup, L as CodexHooksConfig, M as CodexProviderOptions, N as DataContent, O as EmbeddedSkillConfig, P as FilePart, Q as ImagePart, X as OpenCodeAgentOptions, Y as OpenCodePluginConfig, Z as OpenCodePluginEvent, _ as OpenCodePluginHookConfig, $ as OpenCodeProviderOptions, a4 as RepoSkillConfig, ab as TextPart, af as UserContent, ag as UserContentPart } from '../types-
|
|
1
|
+
import { o as AgentProviderName, h as AgentOptions, t as AgentRunConfig, s as AgentRun, r as AgentResult, a2 as RawAgentEvent, b as AgentAttachRequest, y as AttachedRun, a9 as SetupLayout } from '../types-du-Kkn53.js';
|
|
2
|
+
export { a as AgentApprovalMode, c as AgentCommandConfig, d as AgentCostData, e as AgentExecutionRequest, f as AgentLocalMcpConfig, g as AgentMcpConfig, i as AgentOptionsBase, j as AgentOptionsMap, k as AgentPermissionDecision, l as AgentPermissionKind, m as AgentPermissionResponse, n as AgentProviderAdapter, p as AgentReasoningEffort, q as AgentRemoteMcpConfig, u as AgentRunSink, v as AgentSetupRequest, w as AgentSkillConfig, x as AgentSubAgentConfig, C as ClaudeCodeAgentOptions, z as ClaudeCodeHookConfig, B as ClaudeCodeHookEvent, D as ClaudeCodeHookHandler, E as ClaudeCodeHookMatcherGroup, F as ClaudeCodeHooksConfig, G as ClaudeCodeProviderOptions, H as CodexAgentOptions, I as CodexCommandHook, J as CodexHookEvent, K as CodexHookMatcherGroup, L as CodexHooksConfig, M as CodexProviderOptions, N as DataContent, O as EmbeddedSkillConfig, P as FilePart, Q as ImagePart, X as OpenCodeAgentOptions, Y as OpenCodePluginConfig, Z as OpenCodePluginEvent, _ as OpenCodePluginHookConfig, $ as OpenCodeProviderOptions, a4 as RepoSkillConfig, ab as TextPart, af as UserContent, ag as UserContentPart } from '../types-du-Kkn53.js';
|
|
3
3
|
import { S as Sandbox } from '../Sandbox-DcKAU-E3.js';
|
|
4
4
|
export { AgentProvider } from '../enums.js';
|
|
5
5
|
import 'e2b';
|
package/dist/agents/index.js
CHANGED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
createNormalizedEvent,
|
|
3
3
|
normalizeRawAgentEvent,
|
|
4
4
|
toAISDKStream
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-PNONJAGY.js";
|
|
6
6
|
import {
|
|
7
7
|
AgentBoxError,
|
|
8
8
|
AsyncQueue,
|
|
@@ -1662,6 +1662,7 @@ function buildClaudeQueryOptions(params) {
|
|
|
1662
1662
|
if (run.systemPrompt) {
|
|
1663
1663
|
extraArgs["append-system-prompt"] = run.systemPrompt;
|
|
1664
1664
|
}
|
|
1665
|
+
const includeHookEvents = provider?.includeHookEvents ?? false;
|
|
1665
1666
|
return {
|
|
1666
1667
|
cwd: params.cwd ?? params.request.options.cwd,
|
|
1667
1668
|
env: params.env,
|
|
@@ -1669,7 +1670,9 @@ function buildClaudeQueryOptions(params) {
|
|
|
1669
1670
|
settings: params.settingsPath,
|
|
1670
1671
|
extraArgs,
|
|
1671
1672
|
includePartialMessages: true,
|
|
1673
|
+
includeHookEvents,
|
|
1672
1674
|
thinking: { type: "adaptive", display: "summarized" },
|
|
1675
|
+
...provider?.additionalDirectories?.length ? { additionalDirectories: provider.additionalDirectories } : {},
|
|
1673
1676
|
...run.model ? { model: run.model } : {},
|
|
1674
1677
|
...run.reasoning ? { effort: run.reasoning } : {},
|
|
1675
1678
|
...provider?.permissionMode ? { permissionMode: provider.permissionMode } : {},
|
|
@@ -2355,12 +2358,33 @@ var ClaudeCodeAgentAdapter = class {
|
|
|
2355
2358
|
rawPayloads.push(message);
|
|
2356
2359
|
sink.emitRaw(toRawEvent(request.runId, message, message.type));
|
|
2357
2360
|
if (message.type === "system") {
|
|
2358
|
-
const
|
|
2359
|
-
if (
|
|
2361
|
+
const sub = message.subtype;
|
|
2362
|
+
if (sub === "init") {
|
|
2363
|
+
const sys = message;
|
|
2364
|
+
if (sys.session_id) {
|
|
2365
|
+
debugClaude(
|
|
2366
|
+
"\u2605 session.init session_id=%s (%dms)",
|
|
2367
|
+
sys.session_id.slice(0, 8),
|
|
2368
|
+
Date.now() - executeStartedAt
|
|
2369
|
+
);
|
|
2370
|
+
}
|
|
2371
|
+
} else if (sub === "hook_started") {
|
|
2372
|
+
const h = message;
|
|
2360
2373
|
debugClaude(
|
|
2361
|
-
"
|
|
2362
|
-
|
|
2363
|
-
|
|
2374
|
+
"hook.started name=%s event=%s hook_id=%s",
|
|
2375
|
+
h.hook_name,
|
|
2376
|
+
h.hook_event,
|
|
2377
|
+
h.hook_id
|
|
2378
|
+
);
|
|
2379
|
+
} else if (sub === "hook_response") {
|
|
2380
|
+
const h = message;
|
|
2381
|
+
const stderr = h.stderr && h.stderr.length > 0 ? h.stderr.replace(/\s+$/, "") : void 0;
|
|
2382
|
+
debugClaude(
|
|
2383
|
+
"hook.response name=%s exit=%s outcome=%s%s",
|
|
2384
|
+
h.hook_name,
|
|
2385
|
+
h.exit_code,
|
|
2386
|
+
h.outcome,
|
|
2387
|
+
stderr ? ` stderr=${JSON.stringify(stderr).slice(0, 200)}` : ""
|
|
2364
2388
|
);
|
|
2365
2389
|
}
|
|
2366
2390
|
continue;
|
|
@@ -291,6 +291,9 @@ var CodexLogAssembler = class {
|
|
|
291
291
|
this.byItemId.set(itemId, next);
|
|
292
292
|
return clone(next);
|
|
293
293
|
}
|
|
294
|
+
getSnapshots() {
|
|
295
|
+
return Array.from(this.byItemId.values()).map(clone);
|
|
296
|
+
}
|
|
294
297
|
};
|
|
295
298
|
var OpenCodeLogAssembler = class {
|
|
296
299
|
userMessageIds = /* @__PURE__ */ new Set();
|
|
@@ -376,12 +379,22 @@ var OpenCodeLogAssembler = class {
|
|
|
376
379
|
this.byPartId.set(partId, next);
|
|
377
380
|
return clone(next);
|
|
378
381
|
}
|
|
382
|
+
getSnapshots() {
|
|
383
|
+
return Array.from(this.byPartId.values()).map(clone);
|
|
384
|
+
}
|
|
379
385
|
};
|
|
380
386
|
var ClaudeCodeLogAssembler = class {
|
|
381
387
|
currentMessageId = null;
|
|
382
388
|
textByMessageId = /* @__PURE__ */ new Map();
|
|
383
389
|
thinkingByMessageId = /* @__PURE__ */ new Map();
|
|
384
390
|
byMessageId = /* @__PURE__ */ new Map();
|
|
391
|
+
// Per-message tool_use / image / other non-text-non-thinking content blocks.
|
|
392
|
+
// Tracked persistently so any `upsertMessage` call (including those from a
|
|
393
|
+
// post-assistant `message_start` re-anchor) still renders them — otherwise
|
|
394
|
+
// a later stream_event for the same messageId would emit a snapshot without
|
|
395
|
+
// tool_use blocks, and the UI's dedup-by-messageId would wipe the running
|
|
396
|
+
// command from the trace.
|
|
397
|
+
extraBlocksByMessageId = /* @__PURE__ */ new Map();
|
|
385
398
|
process(event) {
|
|
386
399
|
if (!isRecord(event)) return [];
|
|
387
400
|
const type = typeof event.type === "string" ? event.type : "";
|
|
@@ -429,7 +442,8 @@ var ClaudeCodeLogAssembler = class {
|
|
|
429
442
|
if (final.thinking) {
|
|
430
443
|
this.thinkingByMessageId.set(id, final.thinking);
|
|
431
444
|
}
|
|
432
|
-
|
|
445
|
+
this.mergeExtraBlocks(id, final.extraBlocks);
|
|
446
|
+
const snapshot = this.upsertMessage(id);
|
|
433
447
|
this.currentMessageId = null;
|
|
434
448
|
return [snapshot];
|
|
435
449
|
}
|
|
@@ -440,6 +454,7 @@ var ClaudeCodeLogAssembler = class {
|
|
|
440
454
|
this.textByMessageId.clear();
|
|
441
455
|
this.thinkingByMessageId.clear();
|
|
442
456
|
this.byMessageId.clear();
|
|
457
|
+
this.extraBlocksByMessageId.clear();
|
|
443
458
|
for (const snapshot of snapshots) {
|
|
444
459
|
if (!isRecord(snapshot)) continue;
|
|
445
460
|
if (snapshot.type !== "message.updated") continue;
|
|
@@ -450,25 +465,46 @@ var ClaudeCodeLogAssembler = class {
|
|
|
450
465
|
const content = message && Array.isArray(message.content) ? message.content : [];
|
|
451
466
|
let text = "";
|
|
452
467
|
let thinking = "";
|
|
468
|
+
const extraBlocks = [];
|
|
453
469
|
for (const block of content) {
|
|
454
470
|
if (!isRecord(block)) continue;
|
|
455
471
|
if (block.type === "text" && typeof block.text === "string") {
|
|
456
472
|
text += block.text;
|
|
457
473
|
} else if (block.type === "thinking" && typeof block.thinking === "string") {
|
|
458
474
|
thinking += block.thinking;
|
|
475
|
+
} else {
|
|
476
|
+
extraBlocks.push(block);
|
|
459
477
|
}
|
|
460
478
|
}
|
|
461
479
|
this.textByMessageId.set(messageId, text);
|
|
462
480
|
this.thinkingByMessageId.set(messageId, thinking);
|
|
481
|
+
if (extraBlocks.length > 0) {
|
|
482
|
+
this.mergeExtraBlocks(messageId, extraBlocks);
|
|
483
|
+
}
|
|
484
|
+
}
|
|
485
|
+
}
|
|
486
|
+
mergeExtraBlocks(messageId, blocks) {
|
|
487
|
+
if (blocks.length === 0) return;
|
|
488
|
+
let map = this.extraBlocksByMessageId.get(messageId);
|
|
489
|
+
if (!map) {
|
|
490
|
+
map = /* @__PURE__ */ new Map();
|
|
491
|
+
this.extraBlocksByMessageId.set(messageId, map);
|
|
492
|
+
}
|
|
493
|
+
for (const block of blocks) {
|
|
494
|
+
const key = typeof block.id === "string" && block.id ? `id:${block.id}` : `idx:${map.size}`;
|
|
495
|
+
map.set(key, clone(block));
|
|
463
496
|
}
|
|
464
497
|
}
|
|
465
|
-
upsertMessage(messageId
|
|
498
|
+
upsertMessage(messageId) {
|
|
466
499
|
const text = this.textByMessageId.get(messageId) ?? "";
|
|
467
500
|
const thinking = this.thinkingByMessageId.get(messageId) ?? "";
|
|
468
501
|
const content = [];
|
|
469
502
|
if (thinking) content.push({ type: "thinking", thinking });
|
|
470
503
|
if (text) content.push({ type: "text", text });
|
|
471
|
-
|
|
504
|
+
const extras = this.extraBlocksByMessageId.get(messageId);
|
|
505
|
+
if (extras) {
|
|
506
|
+
for (const block of extras.values()) content.push(clone(block));
|
|
507
|
+
}
|
|
472
508
|
const next = {
|
|
473
509
|
type: "message.updated",
|
|
474
510
|
messageId,
|
|
@@ -481,6 +517,9 @@ var ClaudeCodeLogAssembler = class {
|
|
|
481
517
|
this.byMessageId.set(messageId, next);
|
|
482
518
|
return clone(next);
|
|
483
519
|
}
|
|
520
|
+
getSnapshots() {
|
|
521
|
+
return Array.from(this.byMessageId.values()).map(clone);
|
|
522
|
+
}
|
|
484
523
|
};
|
|
485
524
|
function extractClaudeAssistantContent(message) {
|
|
486
525
|
const content = Array.isArray(message.content) ? message.content : [];
|
|
@@ -523,6 +562,29 @@ var ProviderLogAssembler = class {
|
|
|
523
562
|
}
|
|
524
563
|
return [];
|
|
525
564
|
}
|
|
565
|
+
/**
|
|
566
|
+
* Return the current deduped snapshot set held by the active per-provider
|
|
567
|
+
* assembler. Equivalent to running `dedupeSnapshots` over the full sequence
|
|
568
|
+
* of snapshots emitted by `process()` since construction (or last seed), but
|
|
569
|
+
* read directly from in-memory state — no transport or persistence layer
|
|
570
|
+
* involved. Used end-of-run to persist the full trace without paying a
|
|
571
|
+
* Redis LRANGE + parse roundtrip.
|
|
572
|
+
*
|
|
573
|
+
* Snapshots are returned in first-seen order (Map insertion order). Entries
|
|
574
|
+
* are cloned, so the caller can serialize them freely.
|
|
575
|
+
*/
|
|
576
|
+
getSnapshots(provider) {
|
|
577
|
+
if (provider === AgentProvider.Codex || provider === "codex") {
|
|
578
|
+
return this.codex.getSnapshots();
|
|
579
|
+
}
|
|
580
|
+
if (provider === AgentProvider.OpenCode || provider === "opencode") {
|
|
581
|
+
return this.openCode.getSnapshots();
|
|
582
|
+
}
|
|
583
|
+
if (provider === AgentProvider.ClaudeCode || provider === "claude-code") {
|
|
584
|
+
return this.claudeCode.getSnapshots();
|
|
585
|
+
}
|
|
586
|
+
return [];
|
|
587
|
+
}
|
|
526
588
|
/**
|
|
527
589
|
* Re-seed the assembler from a sequence of previously-assembled snapshots
|
|
528
590
|
* so that subsequent `process()` calls produce snapshots consistent with
|
package/dist/events/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as AISDKEvent, R as MessageCompletedEvent, S as MessageInjectedEvent, T as MessageStartedEvent, U as NormalizedAgentEvent, V as NormalizedAgentEventBase, W as NormalizedAgentEventType, a0 as PermissionRequestedEvent, a1 as PermissionResolvedEvent, a2 as RawAgentEvent, a3 as ReasoningDeltaEvent, a5 as RunCancelledEvent, a6 as RunCompletedEvent, a7 as RunErrorEvent, a8 as RunStartedEvent, aa as TextDeltaEvent, ac as ToolCallCompletedEvent, ad as ToolCallDeltaEvent, ae as ToolCallStartedEvent, ah as createNormalizedEvent, ai as normalizeRawAgentEvent, aj as toAISDKEvent, ak as toAISDKStream } from '../types-
|
|
1
|
+
export { A as AISDKEvent, R as MessageCompletedEvent, S as MessageInjectedEvent, T as MessageStartedEvent, U as NormalizedAgentEvent, V as NormalizedAgentEventBase, W as NormalizedAgentEventType, a0 as PermissionRequestedEvent, a1 as PermissionResolvedEvent, a2 as RawAgentEvent, a3 as ReasoningDeltaEvent, a5 as RunCancelledEvent, a6 as RunCompletedEvent, a7 as RunErrorEvent, a8 as RunStartedEvent, aa as TextDeltaEvent, ac as ToolCallCompletedEvent, ad as ToolCallDeltaEvent, ae as ToolCallStartedEvent, ah as createNormalizedEvent, ai as normalizeRawAgentEvent, aj as toAISDKEvent, ak as toAISDKStream } from '../types-du-Kkn53.js';
|
|
2
2
|
import { AgentProvider } from '../enums.js';
|
|
3
3
|
import '../Sandbox-DcKAU-E3.js';
|
|
4
4
|
import 'e2b';
|
|
@@ -69,6 +69,18 @@ declare class ProviderLogAssembler {
|
|
|
69
69
|
* a delta with no payload) or already represented by a previous snapshot.
|
|
70
70
|
*/
|
|
71
71
|
process(provider: AgentProvider | string | null | undefined, event: unknown): JsonRecord[];
|
|
72
|
+
/**
|
|
73
|
+
* Return the current deduped snapshot set held by the active per-provider
|
|
74
|
+
* assembler. Equivalent to running `dedupeSnapshots` over the full sequence
|
|
75
|
+
* of snapshots emitted by `process()` since construction (or last seed), but
|
|
76
|
+
* read directly from in-memory state — no transport or persistence layer
|
|
77
|
+
* involved. Used end-of-run to persist the full trace without paying a
|
|
78
|
+
* Redis LRANGE + parse roundtrip.
|
|
79
|
+
*
|
|
80
|
+
* Snapshots are returned in first-seen order (Map insertion order). Entries
|
|
81
|
+
* are cloned, so the caller can serialize them freely.
|
|
82
|
+
*/
|
|
83
|
+
getSnapshots(provider: AgentProvider | string | null | undefined): JsonRecord[];
|
|
72
84
|
/**
|
|
73
85
|
* Re-seed the assembler from a sequence of previously-assembled snapshots
|
|
74
86
|
* so that subsequent `process()` calls produce snapshots consistent with
|
package/dist/events/index.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as AISDKEvent, a as AgentApprovalMode, b as AgentAttachRequest, c as AgentCommandConfig, d as AgentCostData, e as AgentExecutionRequest, f as AgentLocalMcpConfig, g as AgentMcpConfig, h as AgentOptions, i as AgentOptionsBase, j as AgentOptionsMap, k as AgentPermissionDecision, l as AgentPermissionKind, m as AgentPermissionResponse, n as AgentProviderAdapter, o as AgentProviderName, p as AgentReasoningEffort, q as AgentRemoteMcpConfig, r as AgentResult, s as AgentRun, t as AgentRunConfig, u as AgentRunSink, v as AgentSetupRequest, w as AgentSkillConfig, x as AgentSubAgentConfig, y as AttachedRun, C as ClaudeCodeAgentOptions, z as ClaudeCodeHookConfig, B as ClaudeCodeHookEvent, D as ClaudeCodeHookHandler, E as ClaudeCodeHookMatcherGroup, F as ClaudeCodeHooksConfig, G as ClaudeCodeProviderOptions, H as CodexAgentOptions, I as CodexCommandHook, J as CodexHookEvent, K as CodexHookMatcherGroup, L as CodexHooksConfig, M as CodexProviderOptions, N as DataContent, O as EmbeddedSkillConfig, P as FilePart, Q as ImagePart, R as MessageCompletedEvent, S as MessageInjectedEvent, T as MessageStartedEvent, U as NormalizedAgentEvent, V as NormalizedAgentEventBase, W as NormalizedAgentEventType, X as OpenCodeAgentOptions, Y as OpenCodePluginConfig, Z as OpenCodePluginEvent, _ as OpenCodePluginHookConfig, $ as OpenCodeProviderOptions, a0 as PermissionRequestedEvent, a1 as PermissionResolvedEvent, a2 as RawAgentEvent, a3 as ReasoningDeltaEvent, a4 as RepoSkillConfig, a5 as RunCancelledEvent, a6 as RunCompletedEvent, a7 as RunErrorEvent, a8 as RunStartedEvent, a9 as SetupLayout, aa as TextDeltaEvent, ab as TextPart, ac as ToolCallCompletedEvent, ad as ToolCallDeltaEvent, ae as ToolCallStartedEvent, af as UserContent, ag as UserContentPart, ah as createNormalizedEvent, ai as normalizeRawAgentEvent, aj as toAISDKEvent, ak as toAISDKStream } from './types-
|
|
1
|
+
export { A as AISDKEvent, a as AgentApprovalMode, b as AgentAttachRequest, c as AgentCommandConfig, d as AgentCostData, e as AgentExecutionRequest, f as AgentLocalMcpConfig, g as AgentMcpConfig, h as AgentOptions, i as AgentOptionsBase, j as AgentOptionsMap, k as AgentPermissionDecision, l as AgentPermissionKind, m as AgentPermissionResponse, n as AgentProviderAdapter, o as AgentProviderName, p as AgentReasoningEffort, q as AgentRemoteMcpConfig, r as AgentResult, s as AgentRun, t as AgentRunConfig, u as AgentRunSink, v as AgentSetupRequest, w as AgentSkillConfig, x as AgentSubAgentConfig, y as AttachedRun, C as ClaudeCodeAgentOptions, z as ClaudeCodeHookConfig, B as ClaudeCodeHookEvent, D as ClaudeCodeHookHandler, E as ClaudeCodeHookMatcherGroup, F as ClaudeCodeHooksConfig, G as ClaudeCodeProviderOptions, H as CodexAgentOptions, I as CodexCommandHook, J as CodexHookEvent, K as CodexHookMatcherGroup, L as CodexHooksConfig, M as CodexProviderOptions, N as DataContent, O as EmbeddedSkillConfig, P as FilePart, Q as ImagePart, R as MessageCompletedEvent, S as MessageInjectedEvent, T as MessageStartedEvent, U as NormalizedAgentEvent, V as NormalizedAgentEventBase, W as NormalizedAgentEventType, X as OpenCodeAgentOptions, Y as OpenCodePluginConfig, Z as OpenCodePluginEvent, _ as OpenCodePluginHookConfig, $ as OpenCodeProviderOptions, a0 as PermissionRequestedEvent, a1 as PermissionResolvedEvent, a2 as RawAgentEvent, a3 as ReasoningDeltaEvent, a4 as RepoSkillConfig, a5 as RunCancelledEvent, a6 as RunCompletedEvent, a7 as RunErrorEvent, a8 as RunStartedEvent, a9 as SetupLayout, aa as TextDeltaEvent, ab as TextPart, ac as ToolCallCompletedEvent, ad as ToolCallDeltaEvent, ae as ToolCallStartedEvent, af as UserContent, ag as UserContentPart, ah as createNormalizedEvent, ai as normalizeRawAgentEvent, aj as toAISDKEvent, ak as toAISDKStream } from './types-du-Kkn53.js';
|
|
2
2
|
export { AGENT_RESERVED_PORTS, Agent, agentboxRoot, collectAllAgentReservedPorts, getAgentLayout } from './agents/index.js';
|
|
3
3
|
export { A as AsyncCommandHandle, C as CommandEvent, a as CommandOptions, b as CommandResult, D as DaytonaProviderOptions, c as DaytonaSandboxOptions, E as E2bProviderOptions, d as E2bSandboxOptions, G as GitCloneOptions, L as LocalDockerProviderOptions, e as LocalDockerSandboxOptions, M as ModalProviderOptions, f as ModalSandboxOptions, S as Sandbox, g as SandboxDescriptor, h as SandboxListOptions, i as SandboxOptions, j as SandboxOptionsBase, k as SandboxOptionsMap, l as SandboxProviderName, m as SandboxRaw, n as SandboxRawMap, o as SandboxResourceSpec, T as TarballEntry, V as VercelGitSource, p as VercelProviderOptions, q as VercelSandboxOptions } from './Sandbox-DcKAU-E3.js';
|
|
4
4
|
export { SandboxAdapter, buildGitCloneCommand } from './sandboxes/index.js';
|
package/dist/index.js
CHANGED
|
@@ -2,14 +2,14 @@ import {
|
|
|
2
2
|
Agent,
|
|
3
3
|
agentboxRoot,
|
|
4
4
|
getAgentLayout
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-6MDOW3GK.js";
|
|
6
6
|
import {
|
|
7
7
|
ProviderLogAssembler,
|
|
8
8
|
createNormalizedEvent,
|
|
9
9
|
normalizeRawAgentEvent,
|
|
10
10
|
toAISDKEvent,
|
|
11
11
|
toAISDKStream
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-PNONJAGY.js";
|
|
13
13
|
import {
|
|
14
14
|
Sandbox,
|
|
15
15
|
SandboxAdapter,
|
|
@@ -401,6 +401,23 @@ interface ClaudeCodeProviderOptions {
|
|
|
401
401
|
allowedTools?: string[];
|
|
402
402
|
autoApproveTools?: boolean;
|
|
403
403
|
verbose?: boolean;
|
|
404
|
+
/**
|
|
405
|
+
* Extra directories Claude Code is allowed to read/write outside `cwd`.
|
|
406
|
+
* Passed through to `--add-dir` (one flag per entry). Use absolute paths.
|
|
407
|
+
*
|
|
408
|
+
* Common case: cwd points at a parent directory and tasks need access
|
|
409
|
+
* to sibling repos cloned under it. Listing each repo here surfaces it
|
|
410
|
+
* to the agent without changing the working directory.
|
|
411
|
+
*/
|
|
412
|
+
additionalDirectories?: string[];
|
|
413
|
+
/**
|
|
414
|
+
* When `true` (the default), the in-sandbox CLI emits `hook_started` and
|
|
415
|
+
* `hook_response` system messages so the host can observe every hook
|
|
416
|
+
* fire — useful to confirm a project-defined hook actually ran and to
|
|
417
|
+
* surface its stdout/stderr/exit_code on failures. Set `false` to
|
|
418
|
+
* silence them when hook noise drowns out the rest of the event stream.
|
|
419
|
+
*/
|
|
420
|
+
includeHookEvents?: boolean;
|
|
404
421
|
}
|
|
405
422
|
interface CodexAgentOptions extends AgentOptionsBase {
|
|
406
423
|
provider?: CodexProviderOptions;
|