Merge pull request #328 from devchat-ai/update_default_model
update default llm model
This commit is contained in:
commit
0730c0a5a4
@ -88,6 +88,14 @@ export async function dependencyCheck(): Promise<[string, string]> {
|
|||||||
apiKeyStatus = 'has valid access key';
|
apiKeyStatus = 'has valid access key';
|
||||||
return apiKeyStatus;
|
return apiKeyStatus;
|
||||||
} else {
|
} else {
|
||||||
|
// test whether valid model exists
|
||||||
|
const modelList = await ApiKeyManager.getValidModels();
|
||||||
|
if (modelList && modelList.length > 0) {
|
||||||
|
// update default llm model
|
||||||
|
await UiUtilWrapper.updateConfiguration('devchat', 'defaultModel', modelList[0]);
|
||||||
|
apiKeyStatus = 'has valid access key';
|
||||||
|
return apiKeyStatus;
|
||||||
|
}
|
||||||
apiKeyStatus = 'Click "DevChat" status icon to set key';
|
apiKeyStatus = 'Click "DevChat" status icon to set key';
|
||||||
return apiKeyStatus;
|
return apiKeyStatus;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user