fix: add getModel to SAP AI Core provider for correct SDK initialization (#5086)

Signed-off-by: Jérôme Benoit <jerome.benoit@piment-noir.org>
This commit is contained in:
Jérôme Benoit 2025-12-05 05:43:22 +01:00 committed by GitHub
parent 095a1ab041
commit bef4fdfc4b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -279,7 +279,7 @@ export namespace Provider {
project,
location,
},
async getModel(sdk, modelID) {
async getModel(sdk: any, modelID) {
const id = String(modelID).trim()
return sdk.languageModel(id)
},
@ -294,6 +294,9 @@ export namespace Provider {
return {
autoload: !!serviceKey,
options: serviceKey ? { serviceKey, deploymentId, resourceGroup } : {},
async getModel(sdk: any, modelID: string) {
return sdk(modelID)
},
}
},
zenmux: async () => {