flavor-code 1.3.13 → 1.3.15
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/README.md +1 -1
- package/README.zh-CN.md +1 -1
- package/dist/{app-2SBDQ6NS.js → app-DDYOKGCX.js} +134 -30
- package/dist/{chunk-EYCTP5JB.js → chunk-TQXNF337.js} +1 -1
- package/dist/{chunk-W2D2MLY2.js → chunk-WB4IJXFT.js} +44 -22
- package/dist/cli-main.js +1036 -0
- package/dist/cli.js +48 -1007
- package/dist/desktop/main.js +44 -22
- package/dist/desktop-renderer/assets/{index-BiDVkW9t.js → index-BAHTmEUI.js} +5 -5
- package/dist/desktop-renderer/assets/index-ZZsUx916.css +1 -0
- package/dist/desktop-renderer/assets/{interactive-terminal-CKHHiGNG.js → interactive-terminal-Bn8G5Pig.js} +1 -1
- package/dist/desktop-renderer/index.html +2 -2
- package/dist/sdk/index.js +2 -2
- package/package.json +1 -1
- package/dist/desktop-renderer/assets/index-DHTr_Acb.css +0 -1
package/dist/desktop/main.js
CHANGED
|
@@ -24993,9 +24993,28 @@ async function createProductionRuntime(options) {
|
|
|
24993
24993
|
const recovered = options.resumeSession === void 0 ? void 0 : await sessionStore.load(options.resumeSession === true ? void 0 : options.resumeSession);
|
|
24994
24994
|
let timelineState = recovered === void 0 ? createTranscriptState() : restoreTranscriptState(recovered.timeline.state);
|
|
24995
24995
|
const restoredTranscript = restoreTranscriptState(timelineState);
|
|
24996
|
+
const pendingTimelineStreams = [];
|
|
24997
|
+
const flushTimelineStreams = () => {
|
|
24998
|
+
for (const pending2 of pendingTimelineStreams.splice(0)) {
|
|
24999
|
+
timelineState = transcriptReducer(timelineState, {
|
|
25000
|
+
type: "session",
|
|
25001
|
+
event: { type: pending2.type, text: pending2.chunks.join("") }
|
|
25002
|
+
});
|
|
25003
|
+
}
|
|
25004
|
+
};
|
|
25005
|
+
const recordTimelineEvent = (event) => {
|
|
25006
|
+
if (event.type === "text" || event.type === "thinking") {
|
|
25007
|
+
const last = pendingTimelineStreams.at(-1);
|
|
25008
|
+
if (last?.type === event.type) last.chunks.push(event.text);
|
|
25009
|
+
else pendingTimelineStreams.push({ type: event.type, chunks: [event.text] });
|
|
25010
|
+
return;
|
|
25011
|
+
}
|
|
25012
|
+
flushTimelineStreams();
|
|
25013
|
+
timelineState = transcriptReducer(timelineState, { type: "session", event });
|
|
25014
|
+
};
|
|
24996
25015
|
let ideSessionId;
|
|
24997
25016
|
const emitOutput = (event) => {
|
|
24998
|
-
|
|
25017
|
+
recordTimelineEvent(event);
|
|
24999
25018
|
options.output(event);
|
|
25000
25019
|
if (ideSessionId !== void 0) ide.publishEvent(ideSessionId, event);
|
|
25001
25020
|
};
|
|
@@ -25412,27 +25431,30 @@ async function createProductionRuntime(options) {
|
|
|
25412
25431
|
};
|
|
25413
25432
|
}
|
|
25414
25433
|
let persistTail = Promise.resolve();
|
|
25415
|
-
const sessionDocument = () =>
|
|
25416
|
-
|
|
25417
|
-
|
|
25418
|
-
|
|
25419
|
-
|
|
25420
|
-
|
|
25421
|
-
|
|
25422
|
-
|
|
25423
|
-
|
|
25424
|
-
|
|
25425
|
-
|
|
25426
|
-
|
|
25427
|
-
|
|
25428
|
-
|
|
25429
|
-
|
|
25430
|
-
|
|
25431
|
-
|
|
25432
|
-
|
|
25433
|
-
|
|
25434
|
-
|
|
25435
|
-
|
|
25434
|
+
const sessionDocument = () => {
|
|
25435
|
+
flushTimelineStreams();
|
|
25436
|
+
return {
|
|
25437
|
+
version: SESSION_VERSION,
|
|
25438
|
+
sessionId,
|
|
25439
|
+
createdAt,
|
|
25440
|
+
updatedAt: (/* @__PURE__ */ new Date()).toISOString(),
|
|
25441
|
+
workspace: { path: workspace },
|
|
25442
|
+
conversation: storedConversation(harness.main.context.snapshot()),
|
|
25443
|
+
tasks: {
|
|
25444
|
+
...taskPlan === void 0 ? {} : { plan: taskPlan },
|
|
25445
|
+
...taskGraph === void 0 ? {} : { graph: taskGraph },
|
|
25446
|
+
states: { ...taskStates },
|
|
25447
|
+
results: { ...taskResults }
|
|
25448
|
+
},
|
|
25449
|
+
// Persist the resolved decision, not the harness snapshot: after logout the
|
|
25450
|
+
// harness may still hold the old login model, and resuming from that stale
|
|
25451
|
+
// value is what made the welcome card show a previous service.
|
|
25452
|
+
models: { main: mainModel, subagent: childModel },
|
|
25453
|
+
permissionMode: harness.permissionMode,
|
|
25454
|
+
memory: memoryLifecycle,
|
|
25455
|
+
timeline: { version: 1, state: timelineState }
|
|
25456
|
+
};
|
|
25457
|
+
};
|
|
25436
25458
|
let persistFailed = false;
|
|
25437
25459
|
const persist = () => {
|
|
25438
25460
|
persistTail = persistTail.catch(() => void 0).then(
|