File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
tools/server/webui/src/lib/stores Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -295,14 +295,21 @@ class ModelsStore {
295295 * Fetch props for a specific model from /props endpoint
296296 * Uses caching to avoid redundant requests
297297 *
298+ * In ROUTER mode, this will only fetch props if the model is loaded,
299+ * since unloaded models return 400 from /props endpoint.
300+ *
298301 * @param modelId - Model identifier to fetch props for
299- * @returns Props data or null if fetch failed
302+ * @returns Props data or null if fetch failed or model not loaded
300303 */
301304 async fetchModelProps ( modelId : string ) : Promise < ApiLlamaCppServerProps | null > {
302305 // Return cached props if available
303306 const cached = this . modelPropsCache . get ( modelId ) ;
304307 if ( cached ) return cached ;
305308
309+ if ( serverStore . isRouterMode && ! this . isModelLoaded ( modelId ) ) {
310+ return null ;
311+ }
312+
306313 // Avoid duplicate fetches
307314 if ( this . modelPropsFetching . has ( modelId ) ) return null ;
308315
You can’t perform that action at this time.
0 commit comments