mirror of
https://github.com/open-webui/open-webui
synced 2024-12-29 15:25:29 +00:00
refac
This commit is contained in:
parent
a18292da84
commit
44efd4d372
@ -429,7 +429,7 @@ def generate_openai_batch_embeddings(
|
|||||||
|
|
||||||
|
|
||||||
def generate_ollama_batch_embeddings(
|
def generate_ollama_batch_embeddings(
|
||||||
model: str, texts: list[str], url: str, key: str
|
model: str, texts: list[str], url: str, key: str = ""
|
||||||
) -> Optional[list[list[float]]]:
|
) -> Optional[list[list[float]]]:
|
||||||
try:
|
try:
|
||||||
r = requests.post(
|
r = requests.post(
|
||||||
|
@ -51,7 +51,7 @@
|
|||||||
onMount(async () => {
|
onMount(async () => {
|
||||||
config = await getModelsConfig(localStorage.token);
|
config = await getModelsConfig(localStorage.token);
|
||||||
|
|
||||||
defaultModelIds = config.DEFAULT_MODELS.split(',').filter((id) => id);
|
defaultModelIds = (config?.DEFAULT_MODELS ?? '').split(',').filter((id) => id);
|
||||||
|
|
||||||
const modelOrderList = config.MODEL_ORDER_LIST || [];
|
const modelOrderList = config.MODEL_ORDER_LIST || [];
|
||||||
const allModelIds = $models.map((model) => model.id);
|
const allModelIds = $models.map((model) => model.id);
|
||||||
|
Loading…
Reference in New Issue
Block a user