{#each messages as message, i} {#if i === 0 && $page.data?.assistant} {#if $page.data?.assistant.avatar} Avatar {:else}
{$page.data?.assistant.name[0]}
{/if} {$page.data.assistant.name}
{:else if i === 0 && preprompt && preprompt != currentModel.preprompt} {/if} {:else} {#if !assistant} {:else} {/if} {/each} {#if pending && messages[messages.length - 1]?.from === "user"} {/if}