[BUG] OpenAI Compatible: Context Window Size resets to 128000 for unknown models
維護者通常 3 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 72/100
- Issue 類型
- 缺陷
- 描述清晰度
- 描述清楚
- 活躍度
- 活躍
- 技術堆疊
- node.js, typescript, vscode
研究方向
Start by reproducing the steps in Settings and Model Configuration using the provided OpenAI-compatible gateway and an unknown model ID. Trace where the unknown-model fallback sets contextWindow to 128000 and where custom model profiles are saved. Done means the configured context window persists after saving and switching profiles; support for reading /v1/models would require using its context_length value.
由索引模型根據 Issue 內容生成。
描述
Describe the bug
The Context Window Size resets to 128000. This happens with models that Zoo Code does not know. I use the OpenAI Compatible provider with a gateway. Example: Base URL https://routellm.abacus.ai/v1, Model ID abacusai/Smaug-Flash. The model supports 1M context. The gateway's /v1/models endpoint reports context_length: 1000000. Zoo Code still shows 128000. Editing the field does not persist. The value springs back immediately.
To Reproduce
- Open Settings. Select the OpenAI Compatible provider.
- Set Base URL to a gateway. Set Model ID to a model outside Zoo Code's catalog.
- Open Model Configuration. Set Context Window Size to 1000000.
- The field springs back to 128000.
Expected behavior
Zoo Code saves my value. Even better: it reads context_length from the provider's /v1/models endpoint. Many OpenAI-compatible gateways expose this.
Actual result
The field resets to 128000. The profile keeps 128000 too. Zoo Code condenses context far too early as a result.
What version of zoo are you running
3.99.100823
Additional context
- macOS 27.3, Apple Silicon.
- The bug comes from Roo Code. See archived Roo issue #4475 (RooCodeInc/Roo-Code). The unknown-model fallback hardcodes
contextWindow: 128000. - Workaround: Quit VS Code. Edit
openAiCustomModelInfo.contextWindowin the extension state (~/Library/Application Support/Code/User/globalStorage/state.vscdb, keyZooCodeOrganization.zoo-code). Restart. Then change any setting in the UI. This triggers a profile save. The value persists now. A profile switch before the save reloads 128000. - I run three profiles on one gateway. I must repeat this procedure for every profile and every new model I select. Fetching
/v1/modelswould fix this whole class of gateways and custom models.
- 主要語言
- TypeScript
- 星號
- 2k
- 分支
- 301
- 平均合併
- 3 天 14 小時
- 30 天內合併 PR
- 103
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
Zoo-Code-Org/Zoo-Code 的其他 Issue
-
難度 2/5 1-3 小時 新手友好度 70/100
Zoo-Code-Org/Zoo-Code#2773 · 1 則留言 ·
維護者通常 3 天內回覆
-
難度 2/5 1-3 小時 新手友好度 68/100
Zoo-Code-Org/Zoo-Code#2717 · 1 則留言 ·
維護者通常 3 天內回覆
-
難度 2/5 1-3 小時 新手友好度 77/100
Zoo-Code-Org/Zoo-Code#2515 ·
維護者通常 3 天內回覆
-
fix(scripts): stryker-diff.mjs spawns the extensionless .bin shim and cannot run on Windows可能已有人在做 @easonLiangWorldedtech 於 16 天前認領。 未關閉
難度 2/5 1-3 小時 新手友好度 78/100
Zoo-Code-Org/Zoo-Code#2514 ·
維護者通常 3 天內回覆
-
[BUG] search_files hides matching text on long lines可能已有人在做 @DananjayaNadun 於 9 天前認領。 未關閉
難度 2/5 1-3 小時 新手友好度 74/100
Zoo-Code-Org/Zoo-Code#2496 · 1 則留言 · 已指派 1 人 ·
維護者通常 3 天內回覆
查看 Zoo-Code-Org/Zoo-Code 的全部 Issue
相似的 Issue
-
enhancement
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆
-
ci
難度 2/5 1-3 小時 新手友好度 78/100
ClickHouse/clickhouse-js#1248 ·
維護者通常 1 天內回覆
-
E2E: Darlehen-Test wartet auf die gebuchte Auszahlung, bevor er zur Liquiditätsvorschau wechselt未關閉technik
難度 2/5 1-3 小時 新手友好度 78/100
-
bug
難度 2/5 1-3 小時 新手友好度 67/100
SR5-FoundryVTT/SR5-FoundryVTT#2162 ·
維護者通常 1 天內回覆
-
enhancement good first issue
難度 2/5 1-3 小時 新手友好度 84/100
AhmedNAgy25/analysor#25 ·
維護者通常 1 天內回覆