chore: v2.2.73 — ASTRA-DEBUG 로그 레벨 + webview CSP font-src 보강
- ASTRA-DEBUG 정상 흐름 로그를 console.error → logInfo/console.log 로 강등 (chatHandlers, extension, slashRouter): DevTools에 ERR로 찍히던 오탐 제거 - sidebar webview에 명시적 CSP meta 추가 + font-src에 data: 허용 (sidebar.html, sidebarProvider._getHtml): VS Code outer iframe이 codicon.ttf를 data:font/ttf 로 inject하면서 기본 CSP에 막혀 매 prompt 마다 violation 경고가 찍히던 문제 해소 - 누적된 LM Studio / agent / 컨텍스트 매니저 / 테스트 갱신 동반 Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import type { ILMStudioClient } from './client';
|
||||
import type { ILMStudioClient, LMStudioLoadConfig } from './client';
|
||||
import type { IActivityTracker } from './activityTracker';
|
||||
import type { EngineKind } from '../utils';
|
||||
import type { ISystemSpecsProvider, IModelMemoryEstimator } from '../system/specs';
|
||||
@@ -9,6 +9,10 @@ export type LifecycleState = 'idle' | 'loading' | 'loaded' | 'streaming' | 'unlo
|
||||
export interface LifecycleConfig {
|
||||
idleTimeoutMs: number;
|
||||
autoLoadOnSelect: boolean;
|
||||
/** Forwarded to `llm.load()` config field. Omit to use engine defaults. */
|
||||
loadConfig?: LMStudioLoadConfig;
|
||||
/** When set, the lifecycle manager pre-warms this draft model after every successful load. */
|
||||
draftModel?: string;
|
||||
}
|
||||
|
||||
export interface LifecycleManagerDeps {
|
||||
@@ -274,11 +278,16 @@ export class ModelLifecycleManager {
|
||||
const ac = new AbortController();
|
||||
this.loadAbort = ac;
|
||||
try {
|
||||
await this.deps.client.load(modelKey, ac.signal);
|
||||
const cfg = this.deps.getConfig();
|
||||
await this.deps.client.load(modelKey, ac.signal, cfg.loadConfig);
|
||||
if (this.loadAbort !== ac) return; // superseded by a newer switch
|
||||
this.loadAbort = undefined;
|
||||
this.state = 'loaded';
|
||||
this.resetIdleTimer();
|
||||
// Pre-warm the draft model so the first speculative prediction doesn't pay a cold-load cost.
|
||||
if (cfg.draftModel && this.deps.client.preloadDraftModel) {
|
||||
void this.deps.client.preloadDraftModel(cfg.draftModel);
|
||||
}
|
||||
} catch (e: any) {
|
||||
if (ac.signal.aborted) return; // superseded — newer switch owns state
|
||||
logError('LM Studio model load failed.', { model: modelKey, error: e?.message ?? String(e) });
|
||||
|
||||
Reference in New Issue
Block a user