Update gpt4all-chat/embeddings.cpp

Co-authored-by: Jared Van Bortel <cebtenzzre@gmail.com>
Signed-off-by: AT <manyoso@users.noreply.github.com>
This commit is contained in:
AT 2023-11-14 11:53:26 -05:00
parent 17b346dfe7
commit 4b413a60e4

View File

@ -172,7 +172,7 @@ std::vector<qint64> Embeddings::search(const std::vector<float> &embedding, int
result = m_hnsw->searchKnn(embedding.data(), K);
} catch (const std::exception &e) {
qWarning() << "ERROR: could not search hnswlib index:" << e.what();
return std::vector<qint64>();
return {};
}
std::vector<qint64> neighbors;