Browse Source

fix: ollama embedding list

Timothy J. Baek 11 months ago
parent
commit
3be1cb98d3
1 changed files with 2 additions and 4 deletions
  1. 2 4
      src/lib/components/documents/Settings/General.svelte

+ 2 - 4
src/lib/components/documents/Settings/General.svelte

@@ -350,10 +350,8 @@
 							{#if !embeddingModel}
 							{#if !embeddingModel}
 								<option value="" disabled selected>{$i18n.t('Select a model')}</option>
 								<option value="" disabled selected>{$i18n.t('Select a model')}</option>
 							{/if}
 							{/if}
-							{#each $models.filter((m) => m.id && !m.external) as model}
-								<option value={model.name} class="bg-gray-100 dark:bg-gray-700"
-									>{model.name + ' (' + (model.size / 1024 ** 3).toFixed(1) + ' GB)'}</option
-								>
+							{#each $models.filter((m) => m.id && m.ollama && !(m?.preset ?? false)) as model}
+								<option value={model.id} class="bg-gray-100 dark:bg-gray-700">{model.name}</option>
 							{/each}
 							{/each}
 						</select>
 						</select>
 					</div>
 					</div>