mirror of
https://github.com/nomic-ai/gpt4all.git
synced 2024-10-01 01:06:10 -04:00
Add trailing commas for things that need to be added in the future.
Signed-off-by: Adam Treat <treat.adam@gmail.com>
This commit is contained in:
parent
028a8db6ba
commit
fc169e739a
@ -217,7 +217,7 @@ void Download::removeModel(const QString &modelFile)
|
|||||||
{ ModelList::BytesTotalRole, 0 },
|
{ ModelList::BytesTotalRole, 0 },
|
||||||
{ ModelList::TimestampRole, 0 },
|
{ ModelList::TimestampRole, 0 },
|
||||||
{ ModelList::SpeedRole, QString() },
|
{ ModelList::SpeedRole, QString() },
|
||||||
{ ModelList::DownloadErrorRole, QString() }
|
{ ModelList::DownloadErrorRole, QString() },
|
||||||
};
|
};
|
||||||
ModelList::globalInstance()->updateDataByFilename(modelFile, data);
|
ModelList::globalInstance()->updateDataByFilename(modelFile, data);
|
||||||
}
|
}
|
||||||
@ -364,7 +364,7 @@ void Download::handleDownloadProgress(qint64 bytesReceived, qint64 bytesTotal)
|
|||||||
{ ModelList::BytesReceivedRole, currentBytesReceived },
|
{ ModelList::BytesReceivedRole, currentBytesReceived },
|
||||||
{ ModelList::BytesTotalRole, bytesTotal },
|
{ ModelList::BytesTotalRole, bytesTotal },
|
||||||
{ ModelList::SpeedRole, speedText },
|
{ ModelList::SpeedRole, speedText },
|
||||||
{ ModelList::TimestampRole, currentUpdate }
|
{ ModelList::TimestampRole, currentUpdate },
|
||||||
};
|
};
|
||||||
ModelList::globalInstance()->updateDataByFilename(modelFilename, data);
|
ModelList::globalInstance()->updateDataByFilename(modelFilename, data);
|
||||||
}
|
}
|
||||||
@ -470,7 +470,7 @@ void Download::handleModelDownloadFinished()
|
|||||||
if (!hasRetry(modelFilename)) {
|
if (!hasRetry(modelFilename)) {
|
||||||
QVector<QPair<int, QVariant>> data {
|
QVector<QPair<int, QVariant>> data {
|
||||||
{ ModelList::DownloadingRole, false },
|
{ ModelList::DownloadingRole, false },
|
||||||
{ ModelList::DownloadErrorRole, errorString }
|
{ ModelList::DownloadErrorRole, errorString },
|
||||||
};
|
};
|
||||||
ModelList::globalInstance()->updateDataByFilename(modelFilename, data);
|
ModelList::globalInstance()->updateDataByFilename(modelFilename, data);
|
||||||
}
|
}
|
||||||
@ -509,7 +509,7 @@ void Download::handleHashAndSaveFinished(bool success, const QString &error,
|
|||||||
|
|
||||||
QVector<QPair<int, QVariant>> data {
|
QVector<QPair<int, QVariant>> data {
|
||||||
{ ModelList::CalcHashRole, false },
|
{ ModelList::CalcHashRole, false },
|
||||||
{ ModelList::DownloadingRole, false }
|
{ ModelList::DownloadingRole, false },
|
||||||
};
|
};
|
||||||
|
|
||||||
modelReply->deleteLater();
|
modelReply->deleteLater();
|
||||||
|
@ -998,7 +998,7 @@ QString ModelList::clone(const ModelInfo &model)
|
|||||||
{ ModelList::RepeatPenaltyRole, model.repeatPenalty() },
|
{ ModelList::RepeatPenaltyRole, model.repeatPenalty() },
|
||||||
{ ModelList::RepeatPenaltyTokensRole, model.repeatPenaltyTokens() },
|
{ ModelList::RepeatPenaltyTokensRole, model.repeatPenaltyTokens() },
|
||||||
{ ModelList::PromptTemplateRole, model.promptTemplate() },
|
{ ModelList::PromptTemplateRole, model.promptTemplate() },
|
||||||
{ ModelList::SystemPromptRole, model.systemPrompt() }
|
{ ModelList::SystemPromptRole, model.systemPrompt() },
|
||||||
};
|
};
|
||||||
updateData(id, data);
|
updateData(id, data);
|
||||||
return id;
|
return id;
|
||||||
@ -1150,7 +1150,7 @@ void ModelList::updateModelsFromDirectory()
|
|||||||
// FIXME: WE should change this to use a consistent filename for online models
|
// FIXME: WE should change this to use a consistent filename for online models
|
||||||
{ OnlineRole, filename.startsWith("chatgpt-") || filename.startsWith("nomic-") },
|
{ OnlineRole, filename.startsWith("chatgpt-") || filename.startsWith("nomic-") },
|
||||||
{ DirpathRole, info.dir().absolutePath() + "/" },
|
{ DirpathRole, info.dir().absolutePath() + "/" },
|
||||||
{ FilesizeRole, toFileSize(info.size()) }
|
{ FilesizeRole, toFileSize(info.size()) },
|
||||||
};
|
};
|
||||||
updateData(id, data);
|
updateData(id, data);
|
||||||
}
|
}
|
||||||
@ -1420,7 +1420,7 @@ void ModelList::parseModelsJsonFile(const QByteArray &jsonData, bool save)
|
|||||||
{ ModelList::RamrequiredRole, 0 },
|
{ ModelList::RamrequiredRole, 0 },
|
||||||
{ ModelList::ParametersRole, "?" },
|
{ ModelList::ParametersRole, "?" },
|
||||||
{ ModelList::QuantRole, "NA" },
|
{ ModelList::QuantRole, "NA" },
|
||||||
{ ModelList::TypeRole, "GPT" }
|
{ ModelList::TypeRole, "GPT" },
|
||||||
};
|
};
|
||||||
updateData(id, data);
|
updateData(id, data);
|
||||||
}
|
}
|
||||||
@ -1447,7 +1447,7 @@ void ModelList::parseModelsJsonFile(const QByteArray &jsonData, bool save)
|
|||||||
{ ModelList::RamrequiredRole, 0 },
|
{ ModelList::RamrequiredRole, 0 },
|
||||||
{ ModelList::ParametersRole, "?" },
|
{ ModelList::ParametersRole, "?" },
|
||||||
{ ModelList::QuantRole, "NA" },
|
{ ModelList::QuantRole, "NA" },
|
||||||
{ ModelList::TypeRole, "GPT" }
|
{ ModelList::TypeRole, "GPT" },
|
||||||
};
|
};
|
||||||
updateData(id, data);
|
updateData(id, data);
|
||||||
}
|
}
|
||||||
@ -1478,7 +1478,7 @@ void ModelList::parseModelsJsonFile(const QByteArray &jsonData, bool save)
|
|||||||
{ ModelList::RamrequiredRole, 0 },
|
{ ModelList::RamrequiredRole, 0 },
|
||||||
{ ModelList::ParametersRole, "?" },
|
{ ModelList::ParametersRole, "?" },
|
||||||
{ ModelList::QuantRole, "NA" },
|
{ ModelList::QuantRole, "NA" },
|
||||||
{ ModelList::TypeRole, "Bert" }
|
{ ModelList::TypeRole, "Bert" },
|
||||||
};
|
};
|
||||||
updateData(id, data);
|
updateData(id, data);
|
||||||
}
|
}
|
||||||
@ -1497,7 +1497,7 @@ void ModelList::updateDiscoveredInstalled(const ModelInfo &info)
|
|||||||
{ ModelList::DownloadsRole, info.downloads() },
|
{ ModelList::DownloadsRole, info.downloads() },
|
||||||
{ ModelList::RecencyRole, info.recency() },
|
{ ModelList::RecencyRole, info.recency() },
|
||||||
{ ModelList::QuantRole, info.quant() },
|
{ ModelList::QuantRole, info.quant() },
|
||||||
{ ModelList::TypeRole, info.type() }
|
{ ModelList::TypeRole, info.type() },
|
||||||
};
|
};
|
||||||
updateData(info.id(), data);
|
updateData(info.id(), data);
|
||||||
}
|
}
|
||||||
@ -1910,7 +1910,7 @@ void ModelList::handleDiscoveryItemFinished()
|
|||||||
{ ModelList::QuantRole, toQuantString(modelFilename) },
|
{ ModelList::QuantRole, toQuantString(modelFilename) },
|
||||||
{ ModelList::TypeRole, type },
|
{ ModelList::TypeRole, type },
|
||||||
{ ModelList::HashRole, linkedEtagHeader },
|
{ ModelList::HashRole, linkedEtagHeader },
|
||||||
{ ModelList::HashAlgorithmRole, ModelInfo::Sha256 }
|
{ ModelList::HashAlgorithmRole, ModelInfo::Sha256 },
|
||||||
};
|
};
|
||||||
updateData(id, data);
|
updateData(id, data);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user