diff options
Diffstat (limited to 'packages/frontend/src')
| -rw-r--r-- | packages/frontend/src/lib/cache-warming.svelte.ts | 7 | ||||
| -rw-r--r-- | packages/frontend/src/lib/tabs.svelte.ts | 7 |
2 files changed, 13 insertions, 1 deletions
diff --git a/packages/frontend/src/lib/cache-warming.svelte.ts b/packages/frontend/src/lib/cache-warming.svelte.ts index cda3fd1..0253c08 100644 --- a/packages/frontend/src/lib/cache-warming.svelte.ts +++ b/packages/frontend/src/lib/cache-warming.svelte.ts @@ -41,6 +41,12 @@ export interface WarmRequestParams { keyId: string | null; modelId: string | null; agentModels: AgentModelEntry[] | null; + /** + * The SAME reasoning effort the next real turn would use. It drives the + * Anthropic thinking providerOptions, which is a message-cache key — warming + * must match it so it refreshes the bucket the real message reads. + */ + reasoningEffort: string | null; } /** Reactive, per-tab warming UI state (read by the Chat Settings debug strip). */ @@ -177,6 +183,7 @@ export function createCacheWarmingStore() { ...(params?.keyId ? { keyId: params.keyId } : {}), ...(params?.modelId ? { modelId: params.modelId } : {}), ...(params?.agentModels ? { agentModels: params.agentModels } : {}), + ...(params?.reasoningEffort ? { reasoningEffort: params.reasoningEffort } : {}), }), }); // A newer cancel/fire superseded this request — drop its result so it diff --git a/packages/frontend/src/lib/tabs.svelte.ts b/packages/frontend/src/lib/tabs.svelte.ts index a0125ef..ca04e62 100644 --- a/packages/frontend/src/lib/tabs.svelte.ts +++ b/packages/frontend/src/lib/tabs.svelte.ts @@ -251,7 +251,12 @@ export function createTabStore() { cacheWarming.setRequestResolver((tabId) => { const t = getTabById(tabId); if (!t) return null; - return { keyId: t.keyId, modelId: t.modelId, agentModels: t.agentModels }; + return { + keyId: t.keyId, + modelId: t.modelId, + agentModels: t.agentModels, + reasoningEffort: t.reasoningEffort, + }; }); $effect.root(() => { |
