chat client clean up and switch to llama.cpp with models folder network sharing
This commit is contained in:
@@ -79,4 +79,10 @@ export function streamMessage(sessionId, message, model, { onChunk, onDone, onEr
|
||||
})();
|
||||
|
||||
return () => controller.abort();
|
||||
}
|
||||
|
||||
export async function fetchModels() {
|
||||
const res = await fetch(`{BASE_URL}/models`);
|
||||
if(!res.ok) throw new Error(`Failted to fetch models: ${res.status}`);
|
||||
return res.json();
|
||||
}
|
||||
Reference in New Issue
Block a user