feat: v2.2.64 — LM Studio 모델 발견/에러 표시 + macOS 셸 호환성

- LM Studio 모델 dropdown을 SDK system.listDownloadedModels('llm') 으로
  조회하도록 변경. REST /v1/models 는 JIT 옵션이 꺼져 있으면 로드된 모델만
  반환하여 macOS 환경에서 dropdown 이 비거나 fallback 한 줄만 남던 문제 해결.
  SDK 실패 시 REST 로 자동 fallback.
- LM Studio 로드/언로드 실패를 readyBar 의 영속 segment 로 표시. 모델을
  다시 선택하면 clearLmStudioError() 로 해제.
- src/security.ts: PowerShell '&&' rewrite 를 win32 에서만 수행. macOS/Linux
  에서는 'if (\$?) { ... }' 가 zsh/bash 문법 오류라 명령 자체가 깨졌음.
- src/utils.ts: system prompt 에 OS 별 [ENVIRONMENT] 블록 동적 주입
  (셸/경로 스타일/체이닝 연산자). 'cd E:\\... ; ...' 같은 Windows 전용
  예시를 macOS 에서 그대로 따라하던 회귀 차단.
- 테스트 mock 에 listDownloaded() 추가.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
g1nation
2026-05-23 09:37:29 +09:00
parent 49f941386f
commit 36db170844
15 changed files with 168 additions and 37 deletions
+4
View File
@@ -78,6 +78,10 @@ class FakeLMStudioClient implements ILMStudioClient {
return [];
}
async listDownloaded(): Promise<string[]> {
return [];
}
async getModelHandle(_modelKey: string): Promise<any> {
return {};
}
+1
View File
@@ -79,6 +79,7 @@ class FakeClient implements ILMStudioClient {
async unload(_: string): Promise<void> { /* noop */ }
async listLoaded(): Promise<string[]> { return []; }
async listLoadedCached(): Promise<string[]> { return []; }
async listDownloaded(): Promise<string[]> { return []; }
async isReachable(): Promise<boolean> { return true; }
async getModelHandle(modelKey: string): Promise<any> {