mirror of
https://github.com/nomic-ai/gpt4all.git
synced 2025-06-26 07:23:38 +00:00
Don't try and load incomplete files.
This commit is contained in:
parent
27f25d5878
commit
3ca9e8692c
@ -451,7 +451,7 @@ void ModelList::updateModelsFromDirectory()
|
||||
// All files that end with .bin and have 'ggml' somewhere in the name
|
||||
QStringList fileNames;
|
||||
for(const QString& filename : allFiles) {
|
||||
if (filename.endsWith(".bin") && filename.contains("ggml")) {
|
||||
if (filename.endsWith(".bin") && filename.contains("ggml") && !filename.startsWith("incomplete")) {
|
||||
fileNames.append(filename);
|
||||
}
|
||||
}
|
||||
@ -473,7 +473,7 @@ void ModelList::updateModelsFromDirectory()
|
||||
QStringList allFiles = dir.entryList(QDir::Files);
|
||||
QStringList fileNames;
|
||||
for(const QString& filename : allFiles) {
|
||||
if ((filename.endsWith(".bin") && filename.contains("ggml"))
|
||||
if ((filename.endsWith(".bin") && filename.contains("ggml") && !filename.startsWith("incomplete"))
|
||||
|| (filename.endsWith(".txt") && filename.startsWith("chatgpt-"))) {
|
||||
fileNames.append(filename);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user