fix: reasoning iMessage sessions + final reply (#655) (thanks @antons)
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
- Onboarding/Gateway: persist non-interactive gateway token auth in config; add WS wizard + gateway tool-calling regression coverage.
|
||||
- CLI: `clawdbot sessions` now includes `elev:*` + `usage:*` flags in the table output.
|
||||
- Branding: normalize user-facing “ClawdBot”/“CLAWDBOT” → “Clawdbot” (CLI, status, docs).
|
||||
- iMessage: fix reasoning persistence across DMs; avoid partial/duplicate replies when reasoning is enabled. (#655) — thanks @antons.
|
||||
- Models/Auth: allow MiniMax API configs without `models.providers.minimax.apiKey` (auth profiles / `MINIMAX_API_KEY`). (#656) — thanks @mneves75.
|
||||
|
||||
## 2026.1.9
|
||||
|
||||
@@ -370,7 +370,15 @@ describe("subscribeEmbeddedPiSession", () => {
|
||||
message: { role: "assistant" },
|
||||
assistantMessageEvent: {
|
||||
type: "text_delta",
|
||||
delta: "Final answer",
|
||||
delta: "Final ",
|
||||
},
|
||||
});
|
||||
handler?.({
|
||||
type: "message_update",
|
||||
message: { role: "assistant" },
|
||||
assistantMessageEvent: {
|
||||
type: "text_delta",
|
||||
delta: "answer",
|
||||
},
|
||||
});
|
||||
handler?.({
|
||||
|
||||
@@ -111,6 +111,8 @@ describe("sessions", () => {
|
||||
updatedAt: 123,
|
||||
systemSent: true,
|
||||
thinkingLevel: "low",
|
||||
responseUsage: "on",
|
||||
queueDebounceMs: 1234,
|
||||
reasoningLevel: "on",
|
||||
elevatedLevel: "on",
|
||||
authProfileOverride: "auth-1",
|
||||
@@ -135,6 +137,8 @@ describe("sessions", () => {
|
||||
expect(store[mainSessionKey]?.updatedAt).toBeGreaterThanOrEqual(123);
|
||||
expect(store[mainSessionKey]?.lastProvider).toBe("telegram");
|
||||
expect(store[mainSessionKey]?.lastTo).toBe("12345");
|
||||
expect(store[mainSessionKey]?.responseUsage).toBe("on");
|
||||
expect(store[mainSessionKey]?.queueDebounceMs).toBe(1234);
|
||||
expect(store[mainSessionKey]?.reasoningLevel).toBe("on");
|
||||
expect(store[mainSessionKey]?.elevatedLevel).toBe("on");
|
||||
expect(store[mainSessionKey]?.authProfileOverride).toBe("auth-1");
|
||||
|
||||
@@ -487,38 +487,11 @@ export async function updateLastRoute(params: {
|
||||
const store = loadSessionStore(storePath);
|
||||
const existing = store[sessionKey];
|
||||
const now = Date.now();
|
||||
const sessionId = existing?.sessionId ?? crypto.randomUUID();
|
||||
const next: SessionEntry = {
|
||||
sessionId: existing?.sessionId ?? crypto.randomUUID(),
|
||||
...(existing ?? { sessionId, updatedAt: 0 }),
|
||||
sessionId,
|
||||
updatedAt: Math.max(existing?.updatedAt ?? 0, now),
|
||||
sessionFile: existing?.sessionFile,
|
||||
systemSent: existing?.systemSent,
|
||||
abortedLastRun: existing?.abortedLastRun,
|
||||
spawnedBy: existing?.spawnedBy,
|
||||
thinkingLevel: existing?.thinkingLevel,
|
||||
verboseLevel: existing?.verboseLevel,
|
||||
reasoningLevel: existing?.reasoningLevel,
|
||||
elevatedLevel: existing?.elevatedLevel,
|
||||
providerOverride: existing?.providerOverride,
|
||||
modelOverride: existing?.modelOverride,
|
||||
authProfileOverride: existing?.authProfileOverride,
|
||||
groupActivation: existing?.groupActivation,
|
||||
groupActivationNeedsSystemIntro: existing?.groupActivationNeedsSystemIntro,
|
||||
sendPolicy: existing?.sendPolicy,
|
||||
queueMode: existing?.queueMode,
|
||||
inputTokens: existing?.inputTokens,
|
||||
outputTokens: existing?.outputTokens,
|
||||
totalTokens: existing?.totalTokens,
|
||||
modelProvider: existing?.modelProvider,
|
||||
model: existing?.model,
|
||||
contextTokens: existing?.contextTokens,
|
||||
compactionCount: existing?.compactionCount,
|
||||
displayName: existing?.displayName,
|
||||
chatType: existing?.chatType,
|
||||
provider: existing?.provider,
|
||||
subject: existing?.subject,
|
||||
room: existing?.room,
|
||||
space: existing?.space,
|
||||
skillsSnapshot: existing?.skillsSnapshot,
|
||||
lastProvider: provider,
|
||||
lastTo: to?.trim() ? to.trim() : undefined,
|
||||
lastAccountId: accountId?.trim()
|
||||
|
||||
Reference in New Issue
Block a user