MCPcopy Create free account
hub / github.com/Palm1r/QodeAssist / getInstalledModels

Method getInstalledModels

providers/OpenAIProvider.cpp:108–123  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

106}
107
108QFuture<QList<QString>> OpenAIProvider::getInstalledModels(const QString &baseUrl)
109{
110 m_client->setUrl(baseUrl);
111 m_client->setApiKey(apiKey());
112 return m_client->listModels().then([](const QList<QString> &allModels) {
113 QList<QString> filtered;
114 for (const QString &modelId : allModels) {
115 if (!modelId.contains("dall-e") && !modelId.contains("whisper")
116 && !modelId.contains("tts") && !modelId.contains("davinci")
117 && !modelId.contains("babbage") && !modelId.contains("omni")) {
118 filtered.append(modelId);
119 }
120 }
121 return filtered;
122 });
123}
124
125PluginLLMCore::ProviderID OpenAIProvider::providerID() const
126{

Callers

nothing calls this directly

Calls 3

setUrlMethod · 0.80
setApiKeyMethod · 0.80
appendMethod · 0.80

Tested by

no test coverage detected