From 4df6165fa93c7caeea86385312415e312de4d11f Mon Sep 17 00:00:00 2001 From: Moli <13026959681@163.com> Date: 星期二, 05 五月 2026 01:10:39 +0800 Subject: [PATCH] 暂存 --- docs/qa/llm-command-palette-acceptance-2026-05-04.md | 65 ++++++++++++++++++++++++++++++++ 1 files changed, 65 insertions(+), 0 deletions(-) diff --git a/docs/qa/llm-command-palette-acceptance-2026-05-04.md b/docs/qa/llm-command-palette-acceptance-2026-05-04.md new file mode 100644 index 0000000..1bf91a6 --- /dev/null +++ b/docs/qa/llm-command-palette-acceptance-2026-05-04.md @@ -0,0 +1,65 @@ +# LLM 妗岄潰杈撳叆鎻掍欢楠屾敹璁板綍 + +鏃ユ湡锛�2026-05-04 + +## 鑼冨洿 + +鏈楠屾敹瑕嗙洊 `sample.llm-command-palette` 鎻掍欢鍜屽涓讳晶 LLM 浠g悊鏈�灏忛棴鐜細 + +- LLM 妯″瀷閰嶇疆鏂囦欢 `llm-models.json`銆� +- 姣忔ā鍨嬬嫭绔� `provider`銆乣endpoint`銆乣authRef`銆乣apiModel` 鐨勮矾鐢辩粨鏋勩�� +- `ILlmGatewayService`銆乣ILlmModelRegistry`銆乣ICredentialStore`銆乣ILlmProviderAdapter`銆� +- WebView bridge 鐨� `window.moliDesktop.llm` API銆� +- OpenAI-compatible 娴佸紡鍝嶅簲瑙f瀽銆� +- 椤堕儴鍗婇�忔槑杈撳叆鎻掍欢闈欐�佹覆鏌撱�� + +## 楠屾敹缁撹 + +褰撳墠瀹炵幇婊¤冻鏈疆闇�姹傜殑寮�鍙戦獙鏀舵潯浠讹紝鍙繘鍏ュ悗缁湡瀹炰緵搴斿晢鑱旇皟銆� + +宸查�氳繃锛� + +- 鑷姩鍖栨瀯寤恒�� +- 鑷姩鍖栧崟鍏冩祴璇曘�� +- 鏍蜂緥鎻掍欢闈欐�佹覆鏌撻潪绌烘鏌ャ�� + +鏈鐩栵細 + +- 鐪熷疄 OpenAI / DeepSeek / 鏈湴妯″瀷鏈嶅姟鐨勮仈缃戣姹傘�� +- Windows Credential Manager 鐢熶骇瀵嗛挜瀛樺偍銆� +- 绠$悊绐楀彛閲岀殑妯″瀷閰嶇疆缂栬緫 UI銆� + +## 鎵ц缁撴灉 + +| 椤圭洰 | 鍛戒护鎴栨柟娉� | 缁撴灉 | +| --- | --- | --- | +| 鏋勫缓 | `dotnet build .\Moli.Desktop.slnx` | 閫氳繃锛�0 warning锛�0 error | +| 鑷姩鍖栨祴璇� | `dotnet test .\Moli.Desktop.slnx` | 閫氳繃锛�36/36 | +| 鏍蜂緥鎻掍欢娓叉煋 | Edge headless 鎵撳紑 `samples/plugins/sample.llm-command-palette/index.html` | 閫氳繃锛岀敓鎴愭埅鍥� | +| 鍍忕礌妫�鏌� | 閲囨牱鎴浘鍍忕礌 | 閫氳繃锛宍Sampled=1620 NonWhite=1620 NonTransparent=1620` | + +娓叉煋鎴浘锛� + +- `artifacts/llm-command-palette-edge-render-check.png` + +## 鍔熻兘楠屾敹 + +| 楠屾敹鐐� | 缁撴灉 | 璇存槑 | +| --- | --- | --- | +| 鎻掍欢榛樿 manifest 鍚堟硶 | 閫氳繃 | 鏂板 `sample.llm-command-palette/plugin.json`锛屽0鏄� `llm.stream` 鏉冮檺 | +| 鎻掍欢鏍峰紡涓洪《閮ㄥ崐閫忔槑杈撳叆鏉� | 閫氳繃 | HTML/CSS 瀹炵幇娣辫壊鍗婇�忔槑杈撳叆鏉°�佹ā鍨嬩笅鎷夊拰杈撳嚭鍖哄煙 | +| Enter 鎻愪氦銆丼hift+Enter 鎹㈣ | 閫氳繃 | 鍓嶇浜嬩欢宸插疄鐜� | +| 妯″瀷閫夋嫨浠庡涓昏鍙� | 閫氳繃 | `window.moliDesktop.llm.getModels()` 杩斿洖瀹夊叏妯″瀷鎽樿 | +| 鎻掍欢涓嶆帴瑙� endpoint/key | 閫氳繃 | bridge 鍙繑鍥� id銆乴abel銆乸rovider銆乻upportsStreaming銆乪nabled | +| 姣忔ā鍨嬬嫭绔嬭矾鐢� | 閫氳繃 | `LlmGatewayServiceTests` 楠岃瘉鎵�閫� `modelId` 璺敱鍒板搴� endpoint | +| 鏈0鏄庢潈闄愭嫆缁濇祦寮忚皟鐢� | 閫氳繃 | bridge 娴嬭瘯瑕嗙洊 `BridgePermissionDenied` | +| 娴佸紡浜嬩欢娲惧彂鍒版彃浠� | 閫氳繃 | bridge 娴嬭瘯瑕嗙洊 `llm.delta` 浜嬩欢鍙戝竷 | +| 閰嶇疆鎹熷潖鎭㈠ | 閫氳繃 | `llm-models.json` 鎹熷潖鍚庡浠藉苟鎭㈠榛樿鍊� | +| 闈炴硶妯″瀷杩囨护 | 閫氳繃 | 閲嶅 id 鍜岄潪娉� endpoint 浼氳杩囨护骞惰褰曡瘖鏂� | + +## 椋庨櫓涓庡悗缁� + +- 褰撳墠瀵嗛挜瀛樺偍瀹炵幇涓虹幆澧冨彉閲� fallback锛宍authRef` 鐨� Windows Credential Manager 瀹炵幇浠嶉渶琛ラ綈銆� +- 褰撳墠 provider adapter 浼樺厛瑕嗙洊 OpenAI-compatible SSE 鍗忚锛涘鏋� DeepSeek 瀹為檯鎺ュ彛瀛樺湪宸紓锛屽簲鏂板鐙珛 `DeepSeekAdapter`銆� +- 绠$悊绐楀彛灏氭湭鎻愪緵妯″瀷閰嶇疆 UI锛涚煭鏈熷彲鎵嬪伐缂栬緫 `%AppData%\DesktopEnhancer\config\llm-models.json`銆� +- 鐪熷疄渚涘簲鍟嗛獙鏀堕渶瑕佸噯澶囧彲鐢� endpoint 鍜� key锛屽啀鎵ц绔埌绔祦寮忚緭鍑烘祴璇曘�� -- Gitblit v1.9.1