Checkpoints

{#each projCheckpoints as checkpoint (checkpoint.id)} {@const state = checkpoint.projectState} {@const multiple = state.conversations.length > 1} {#snippet children(tooltip)}
{#if tooltip.open}
{#each state.conversations as conversation, i} {@const msgs = conversation.messages} {@const sliced = msgs.slice(0, 4)}

temp: {conversation.config.temperature} | max tokens: {conversation.config.max_tokens}

{#each sliced as msg, i} {@const isLast = i === sliced.length - 1}

{msg.role}

{#if msg.content?.trim()}

{msg.content.trim()}

{:else}

No content

{/if}
{#if !isLast}
{/if} {/each}
{/each}
{/if} {/snippet}
{:else}
No checkpoints available
{/each}