Spaces:
Runtime error
Runtime error
wip
Browse files31 unmodified lines32333435363738394 unmodified lines444546454748495015 unmodified lines6667686769707172114 unmodified lines18718818918819019119219354 unmodified lines24824925024925125225325480 unmodified lines33533633733633833934034134034234334434531 unmodified lines } ];
$: conversation = conversations[0];
let systemMessage: ChatCompletionInputMessage = { role: 'system', content: '' }; let hfToken: string | null = import.meta.env.VITE_HF_TOKEN; let viewCode = false;4 unmodified lines let abortControllers: AbortController[] = []; let waitForNonStreaming = true;
$: systemPromptSupported = isSystemPromptSupported(conversations[0].model); $: systemPromptSupported = isSystemPromptSupported(conversation.model);
onDestroy(() => { for (const abortController of abortControllers) {15 unmodified lines }
function updateMessage(value: string, conversationIdx: number, messageIdx: number) { const lastMsgIdx = conversations[0].messages.length - 1; const lastMsgIdx = conversation.messages.length - 1; const msg = conversations[conversationIdx].messages[messageIdx]; msg.content = value; const { role } = msg;114 unmodified lines if (!model) { return; } conversations[0].model = model; conversation.model = model; }</script>
54 unmodified lines > <Conversation {loading} conversation={conversations[0]} {conversation} index={0} {viewCode} on:addMessage={addMessage}80 unmodified lines > <PlaygroundModelSelector {models} conversation={conversations[0]} {conversation} on:click={() => (showModelPickerModal = open)} />
<PlaygroundOptions bind:conversation={conversations[0]} /> <PlaygroundOptions bind:conversation /> <div class="mt-auto"> <div class="mb-3 flex items-center justify-between gap-2"> <labelsrc/lib/components/InferencePlayground/InferencePlayground.svelte+8-6