feat(embedding-providers): load separately, add bert & bge
This commit is contained in:
parent
68837e06ee
commit
321e60b993
|
@ -158,15 +158,26 @@ export const getAvailableEmbeddingModelProviders = async () => {
|
|||
return acc;
|
||||
}, {});
|
||||
|
||||
models['local'] = {
|
||||
'GTE Small': new HuggingFaceTransformersEmbeddings({
|
||||
modelName: 'Xenova/gte-small',
|
||||
}),
|
||||
};
|
||||
} catch (err) {
|
||||
logger.error(`Error loading Ollama embeddings: ${err}`);
|
||||
}
|
||||
}
|
||||
|
||||
try {
|
||||
models['local'] = {
|
||||
'BGE Small': new HuggingFaceTransformersEmbeddings({
|
||||
modelName: 'Xenova/bge-small-en-v1.5',
|
||||
}),
|
||||
'GTE Small': new HuggingFaceTransformersEmbeddings({
|
||||
modelName: 'Xenova/gte-small',
|
||||
}),
|
||||
'Bert Multilingual': new HuggingFaceTransformersEmbeddings({
|
||||
modelName: 'Xenova/bert-base-multilingual-uncased'
|
||||
}),
|
||||
};
|
||||
} catch(err) {
|
||||
logger.error(`Error loading local embeddings: ${err}`);
|
||||
}
|
||||
|
||||
return models;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue