replicas-cli 0.3.524 → 0.3.527
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.cjs +17 -10
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -22790,7 +22790,7 @@ function codexTurnFromEvent(event) {
|
|
|
22790
22790
|
const { turnId, status, error: error62 } = event.payload;
|
|
22791
22791
|
return typeof turnId === "string" && typeof status === "string" ? { turnId, status, ...typeof error62 === "string" ? { error: error62 } : {} } : null;
|
|
22792
22792
|
}
|
|
22793
|
-
var MERGED_MESSAGE_SEPARATOR, engineStatusSnapshotSchema, updateChatDisplayNameRequestSchema, createChatFields, createChatRequestSchema, createHarnessChatRequestSchema, spawnSubagentRequestSchema, messageSubagentRequestSchema, waitSubagentRequestSchema, subagentResponseSchema, integrationErrorNotificationTargetSchema, sendChatMessageRequestSchema, CODEX_ITEM_FIELD_CHECKS, sendChatMessageResponseSchema, interruptChatRequestSchema, respondToolInputRequestSchema;
|
|
22793
|
+
var MERGED_MESSAGE_SEPARATOR, engineStatusSnapshotSchema, updateChatDisplayNameRequestSchema, createChatFields, createChatRequestSchema, createHarnessChatRequestSchema, spawnSubagentRequestSchema, messageSubagentRequestSchema, waitSubagentRequestSchema, subagentResponseSchema, integrationErrorNotificationTargetSchema, sendChatMessageRequestSchema, CODEX_ITEM_FIELD_CHECKS, sendChatMessageResponseSchema, interruptChatRequestSchema, turnStoppedSchema, engineInterruptChatRequestSchema, respondToolInputRequestSchema;
|
|
22794
22794
|
var init_v1 = __esm({
|
|
22795
22795
|
"../shared/src/engine/v1.ts"() {
|
|
22796
22796
|
"use strict";
|
|
@@ -22948,6 +22948,8 @@ var init_v1 = __esm({
|
|
|
22948
22948
|
// The workspace's stop count once this Stop was noted: set by the monolith alone. A send that saw a lower count is older than this Stop.
|
|
22949
22949
|
stopNumber: external_exports.number().int().positive().optional()
|
|
22950
22950
|
});
|
|
22951
|
+
turnStoppedSchema = external_exports.object({ byUserId: external_exports.string().optional() });
|
|
22952
|
+
engineInterruptChatRequestSchema = interruptChatRequestSchema.extend({ stopped: turnStoppedSchema.optional() });
|
|
22951
22953
|
respondToolInputRequestSchema = external_exports.object({
|
|
22952
22954
|
requestId: external_exports.string().min(1),
|
|
22953
22955
|
selectionId: external_exports.string().min(1),
|
|
@@ -38448,6 +38450,7 @@ function extractToolResult(event) {
|
|
|
38448
38450
|
toolUseId: toolResult.tool_use_id,
|
|
38449
38451
|
output: output3,
|
|
38450
38452
|
outputOmitted: toolResult.replicasOmitted,
|
|
38453
|
+
images: contentImages(normalizeContentBlocks(toolResult.content)),
|
|
38451
38454
|
exitCode: exitCode === void 0 ? void 0 : parseInt(exitCode, 10),
|
|
38452
38455
|
status: toolResult.is_error ? "failed" : "completed"
|
|
38453
38456
|
};
|
|
@@ -38478,16 +38481,19 @@ function readClaudeUserPrompt(payload, content) {
|
|
|
38478
38481
|
if (payload.isSynthetic || content.some((c) => c.type === "tool_result" && c.tool_use_id)) return void 0;
|
|
38479
38482
|
const text4 = content.filter((c) => c.type === "text").map((c) => c.text || "").join("\n");
|
|
38480
38483
|
if (LOCAL_COMMAND_ECHO_REGEX.test(text4.trim())) return void 0;
|
|
38481
|
-
const images = content
|
|
38482
|
-
|
|
38483
|
-
|
|
38484
|
+
const images = contentImages(content);
|
|
38485
|
+
return text4 || images.length > 0 ? { text: text4, images } : void 0;
|
|
38486
|
+
}
|
|
38487
|
+
function contentImages(content) {
|
|
38488
|
+
return content.flatMap((c) => {
|
|
38489
|
+
if (c.type !== "image" || !c.source || !c.source.data && !c.replicasOmitted) return [];
|
|
38490
|
+
return [{
|
|
38484
38491
|
type: "image",
|
|
38485
|
-
mediaType: source.media_type || "image/png",
|
|
38486
|
-
data: source.data || "",
|
|
38492
|
+
mediaType: c.source.media_type || "image/png",
|
|
38493
|
+
data: c.source.data || "",
|
|
38487
38494
|
...c.replicasOmitted ? { replicasOmitted: c.replicasOmitted } : {}
|
|
38488
|
-
};
|
|
38489
|
-
})
|
|
38490
|
-
return text4 || images.length > 0 ? { text: text4, images } : void 0;
|
|
38495
|
+
}];
|
|
38496
|
+
});
|
|
38491
38497
|
}
|
|
38492
38498
|
function parseClaudeEvents(events, parentToolUseId) {
|
|
38493
38499
|
const messages = [];
|
|
@@ -38971,6 +38977,7 @@ function parseClaudeEvents(events, parentToolUseId) {
|
|
|
38971
38977
|
} else if (message2.type === "tool_call") {
|
|
38972
38978
|
message2.output = resultContent;
|
|
38973
38979
|
message2.outputOmitted = outputOmitted;
|
|
38980
|
+
if (result.images.length > 0) message2.images = result.images;
|
|
38974
38981
|
message2.status = status;
|
|
38975
38982
|
} else if (message2.type === "skill" && isError && message2.path) {
|
|
38976
38983
|
replaceMessage(toolInfo.messageIndex, { id: message2.id, type: "tool_call", server: "claude", tool: toolInfo.toolName, input: toolInfo.input, output: resultContent, outputOmitted, status, timestamp: message2.timestamp });
|
|
@@ -40290,7 +40297,7 @@ var CLI_VERSION;
|
|
|
40290
40297
|
var init_cli_version = __esm({
|
|
40291
40298
|
"../shared/src/cli-version.ts"() {
|
|
40292
40299
|
"use strict";
|
|
40293
|
-
CLI_VERSION = "0.3.
|
|
40300
|
+
CLI_VERSION = "0.3.527";
|
|
40294
40301
|
}
|
|
40295
40302
|
});
|
|
40296
40303
|
|