MCPcopy Create free account
hub / github.com/Roy3838/Observer / unloadLocalModel

Method unloadLocalModel

app/src/utils/ModelManager.ts:541–547  ·  view source on GitHub ↗

* Unload the currently loaded local model for a given server type.

(server: string)

Source from the content-addressed store, hash-verified

539 * Unload the currently loaded local model for a given server type.
540 */
541 public async unloadLocalModel(server: string): Promise<void> {
542 if (server === ModelManager.BROWSER_LOCAL) {
543 GemmaModelManager.getInstance().unloadModel();
544 } else if (server === ModelManager.LLAMA_CPP_LOCAL && isTauri()) {
545 await NativeLlmManager.getInstance().unloadModel();
546 }
547 }
548
549 /**
550 * Check if a local model is ready for inference.

Callers 1

handleCancelLoadFunction · 0.80

Calls 3

isTauriFunction · 0.90
unloadModelMethod · 0.65
getInstanceMethod · 0.45

Tested by

no test coverage detected