mirror of
https://github.com/nomic-ai/gpt4all.git
synced 2025-09-30 01:08:47 +00:00
Always try and load default model first. Groovy is the default default.
This commit is contained in:
8
llm.cpp
8
llm.cpp
@@ -7,6 +7,7 @@
|
||||
#include <QFile>
|
||||
#include <QProcess>
|
||||
#include <QResource>
|
||||
#include <QSettings>
|
||||
#include <fstream>
|
||||
|
||||
class MyLLM: public LLM { };
|
||||
@@ -61,7 +62,12 @@ bool LLMObject::loadModel()
|
||||
return false;
|
||||
}
|
||||
|
||||
return loadModelPrivate(models.first());
|
||||
QSettings settings;
|
||||
settings.sync();
|
||||
QString defaultModel = settings.value("defaultModel", "gpt4all-j-v1.3-groovy").toString();
|
||||
if (defaultModel.isEmpty() || !models.contains(defaultModel))
|
||||
defaultModel = models.first();
|
||||
return loadModelPrivate(defaultModel);
|
||||
}
|
||||
|
||||
bool LLMObject::loadModelPrivate(const QString &modelName)
|
||||
|
Reference in New Issue
Block a user