Spaces:
Running
Running
Commit
•
436a794
1
Parent(s):
878e432
use finetuned smollm360m
Browse files- src/routes/+page.svelte +4 -4
src/routes/+page.svelte
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
import * as webllm from "@mlc-ai/web-llm";
|
5 |
import { onMount } from 'svelte';
|
6 |
|
7 |
-
let selectedModel = "
|
8 |
|
9 |
let engine: webllm.MLCEngineInterface;
|
10 |
let isLoading = false;
|
@@ -26,8 +26,8 @@
|
|
26 |
|
27 |
const appConfig: webllm.AppConfig = {
|
28 |
model_list: [{
|
29 |
-
model: `https://huggingface.co/
|
30 |
-
model_id: '
|
31 |
model_lib: `${webllm.modelLibURLPrefix}${webllm.modelVersion}/SmolLM-360M-Instruct-q4f16_1-ctx2k_cs1k-webgpu.wasm`,
|
32 |
overrides: { context_window_size: 2048 },
|
33 |
},
|
@@ -71,7 +71,7 @@
|
|
71 |
console.log("Generating completion:", content);
|
72 |
const response = await engine.chat.completions.create({
|
73 |
messages: [
|
74 |
-
{role:"system", content: "You are a helpful AI
|
75 |
{role: "user", content: content}
|
76 |
],
|
77 |
max_tokens: 10,
|
|
|
4 |
import * as webllm from "@mlc-ai/web-llm";
|
5 |
import { onMount } from 'svelte';
|
6 |
|
7 |
+
let selectedModel = "smollm-360M-instruct-add-basics-q4f16_1-MLC";
|
8 |
|
9 |
let engine: webllm.MLCEngineInterface;
|
10 |
let isLoading = false;
|
|
|
26 |
|
27 |
const appConfig: webllm.AppConfig = {
|
28 |
model_list: [{
|
29 |
+
model: `https://huggingface.co/reach-vb/smollm-360M-instruct-add-basics-q4f16_1-MLC`,
|
30 |
+
model_id: 'smollm-360M-instruct-add-basics-q4f16_1-MLC',
|
31 |
model_lib: `${webllm.modelLibURLPrefix}${webllm.modelVersion}/SmolLM-360M-Instruct-q4f16_1-ctx2k_cs1k-webgpu.wasm`,
|
32 |
overrides: { context_window_size: 2048 },
|
33 |
},
|
|
|
71 |
console.log("Generating completion:", content);
|
72 |
const response = await engine.chat.completions.create({
|
73 |
messages: [
|
74 |
+
{role:"system", content: "You are a helpful AI assistant. Try your best to answer the users request."},
|
75 |
{role: "user", content: content}
|
76 |
],
|
77 |
max_tokens: 10,
|