{#if edit} {$i18n.t('Edit Connection')} {:else} {$i18n.t('Add Connection')} {/if}

{ e.preventDefault(); submitHandler(); }} >
{#if !direct}
{$i18n.t('Connection Type')}
{/if}
{#if auth_type === 'bearer'} {:else if auth_type === 'none'}
{$i18n.t('No authentication')}
{:else if auth_type === 'session'}
{$i18n.t('Forwards system user session credentials to authenticate')}
{:else if auth_type === 'oauth'}
{$i18n.t('Forwards system user OAuth access token to authenticate')}
{/if}
{#if !ollama && !direct}
{/if} {#if azure}
{/if}
{$i18n.t('Model IDs')}
{#if modelIds.length > 0}
    {#each modelIds as modelId, modelIdx}
  • {modelId}
  • {/each}
{:else}
{#if ollama} {$i18n.t('Leave empty to include all models from "{{url}}/api/tags" endpoint', { url: url })} {:else if azure} {$i18n.t('Deployment names are required for Azure OpenAI')} {:else} {$i18n.t('Leave empty to include all models from "{{url}}/models" endpoint', { url: url })} {/if}
{/if}


{$i18n.t('Tags')}
{ tags = [ ...tags, { name: e.detail } ]; }} on:delete={(e) => { tags = tags.filter((tag) => tag.name !== e.detail); }} />
{#if edit} {/if}