@demicodes/agent 0.3.4 → 0.3.5
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/index.mjs +6 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1182,7 +1182,7 @@ var AgentSession = class AgentSession {
|
|
|
1182
1182
|
static fromCheckpoint(params, options = {}) {
|
|
1183
1183
|
if (params.checkpoint.harnessName !== params.runtime.harnessName) throw new Error(`AgentSession: checkpoint harness "${params.checkpoint.harnessName}" does not match "${params.runtime.harnessName}"`);
|
|
1184
1184
|
const checkpoint = params.checkpoint;
|
|
1185
|
-
|
|
1185
|
+
const session = new AgentSession({
|
|
1186
1186
|
provider: params.provider,
|
|
1187
1187
|
model: checkpoint.model,
|
|
1188
1188
|
cwd: checkpoint.cwd,
|
|
@@ -1190,6 +1190,11 @@ var AgentSession = class AgentSession {
|
|
|
1190
1190
|
transcript: checkpoint.transcript,
|
|
1191
1191
|
state: checkpoint.state
|
|
1192
1192
|
}, options);
|
|
1193
|
+
for (const toolCall of session.transcriptLog.pendingToolCalls()) session.transcriptLog.completeToolCall(toolCall.toolUseId, [{
|
|
1194
|
+
type: "text",
|
|
1195
|
+
text: `Tool call interrupted: ${toolCall.toolName} (the process died before a result was recorded)`
|
|
1196
|
+
}], true);
|
|
1197
|
+
return session;
|
|
1193
1198
|
}
|
|
1194
1199
|
constructor(params, options = {}) {
|
|
1195
1200
|
this.provider = params.provider;
|