Implemented streaming message functionality and declared 'out' variable in Playground component.
Browse files
src/lib/components/Playground/Playground.svelte
CHANGED
@@ -62,6 +62,8 @@
|
|
62 |
streamingMessage = { role: 'assistant', content: '' };
|
63 |
messages = [...messages, streamingMessage];
|
64 |
|
|
|
|
|
65 |
try {
|
66 |
const hf = new HfInference(hfToken);
|
67 |
|
|
|
62 |
streamingMessage = { role: 'assistant', content: '' };
|
63 |
messages = [...messages, streamingMessage];
|
64 |
|
65 |
+
let out = ''; // Declare the 'out' variable
|
66 |
+
|
67 |
try {
|
68 |
const hf = new HfInference(hfToken);
|
69 |
|