Skip to content

Commit 35aad68

Browse files
authored
Merge pull request #58 from trypear/pearai-smart
Working for pearai-smart
2 parents b3756c2 + 623646b commit 35aad68

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/api/providers/pearai/pearai.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,8 +119,8 @@ export class PearAiHandler extends BaseProvider implements SingleCompletionHandl
119119
getModel(): { id: string; info: ModelInfo } {
120120
if (this.options.apiModelId) {
121121
let modelInfo = null
122-
if (this.options.apiModelId === "pearai-model") {
123-
modelInfo = this.pearAiModelsResponse?.models["pearai-model"].underlyingModelUpdated
122+
if (this.options.apiModelId.startsWith("pearai")) {
123+
modelInfo = this.pearAiModelsResponse?.models[this.options.apiModelId].underlyingModelUpdated
124124
} else if (this.pearAiModelsResponse) {
125125
modelInfo = this.pearAiModelsResponse.models[this.options.apiModelId || "pearai-model"]
126126
}

0 commit comments

Comments
 (0)