Supported machine learning providers
watsonx.ai Runtime and many third-party machine learning providers are supported for machine learning model evaluations.
Use one of these supported machine learning providers to perform payload logging, feedback logging, and to measure performance accuracy, runtime bias detection, explainability, and auto-debias function as part of your model evaluation.
- watsonx.ai Runtime
- Azure ML Studio
- Azure ML Service
- AWS SageMaker
- Custom (The custom machine learning framework must have equivalent functionality to watsonx.ai Runtime.)
Support for multiple machine learning engines
You can provision multiple machine learning engines when you configure machine learning model evalations or use the Python SDK.
Adding providers for machine learning model evaluations
- From the Configure tab, click Add machine learning provider.
- Select the provider you want to add.
- Enter the required information, such as credentials, and click Save.
Changing or updating details for machine learning providers
Click the tile menu icon and then click View & edit details.
Adding machine learning providers by using the Python SDK
You can add more than one machine learning engine for model evaluations by using the Python API wos_client.service_providers.add
method.
IBM watsonx.ai Runtime
To add the IBM watsonx.ai Runtime machine learning engine, run the following command:
WML_CREDENTIALS = {
"url": "https://us-south.ml.cloud.ibm.com",
"apikey": IBM CLOUD_API_KEY
}
wos_client.service_providers.add(
name=SERVICE_PROVIDER_NAME,
description=SERVICE_PROVIDER_DESCRIPTION,
service_type=ServiceTypes.WATSON_MACHINE_LEARNING,
deployment_space_id = WML_SPACE_ID,
operational_space_id = "production",
credentials=WMLCredentialsCloud(
apikey=CLOUD_API_KEY, ## use `apikey=IAM_TOKEN` if using IAM_TOKEN to initiate client
url=WML_CREDENTIALS["url"],
instance_id=None
),
background_mode=False
).result
Microsoft Azure ML Studio
To add the Azure ML Studio machine learning engine, run the following command:
AZURE_ENGINE_CREDENTIALS = {
"client_id": "",
"client_secret": "",
"subscription_id": "",
"tenant": ""
}
wos_client.service_providers.add(
name=SERVICE_PROVIDER_NAME,
description=SERVICE_PROVIDER_DESCRIPTION,
service_type=ServiceTypes.AZURE_MACHINE_LEARNING,
#deployment_space_id = WML_SPACE_ID,
#operational_space_id = "production",
credentials=AzureCredentials(
subscription_id= AZURE_ENGINE_CREDENTIALS['subscription_id'],
client_id = AZURE_ENGINE_CREDENTIALS['client_id'],
client_secret= AZURE_ENGINE_CREDENTIALS['client_secret'],
tenant = AZURE_ENGINE_CREDENTIALS['tenant']
),
background_mode=False
).result
Amazon SageMaker
To add the AWS Sagemaker machine learning engine, run the following command:
SAGEMAKER_ENGINE_CREDENTIALS = {
'access_key_id':””,
'secret_access_key':””,
'region': '}
wos_client.service_providers.add(
name="AWS",
description="AWS Service Provider",
service_type=ServiceTypes.AMAZON_SAGEMAKER,
credentials=SageMakerCredentials(
access_key_id=SAGEMAKER_ENGINE_CREDENTIALS['access_key_id'],
secret_access_key=SAGEMAKER_ENGINE_CREDENTIALS['secret_access_key'],
region=SAGEMAKER_ENGINE_CREDENTIALS['region']
),
background_mode=False
).result
Microsoft Azure ML Service
To add the Azure ML Service machine learning engine, run the following command:
service_type = "azure_machine_learning_service"
added_service_provider_result = wos_client.service_providers.add(
name=SERVICE_PROVIDER_NAME,
description=SERVICE_PROVIDER_DESCRIPTION,
service_type = service_type,
credentials=AzureCredentials(
subscription_id= AZURE_ENGINE_CREDENTIALS['subscription_id'],
client_id = AZURE_ENGINE_CREDENTIALS['client_id'],
client_secret= AZURE_ENGINE_CREDENTIALS['client_secret'],
tenant = AZURE_ENGINE_CREDENTIALS['tenant']
),
background_mode=False
).result
Producing a list of machine learning providers
To view a list of all the bindings, run the list
method:
client.service_providers.list()
uid | name | service_type | created |
---|---|---|---|
e88ms###-####-####-############ | My Azure ML Service engine | azure_machine_learning | 2019-04-04T09:50:33.189Z |
e88sl###-####-####-############ | My Azure ML Studio engine | azure_machine_learning | 2019-04-04T09:50:33.186Z |
e00sjl###-####-####-############ | WML instance | watson_machine_learning | 2019-03-04T09:50:33.338Z |
e43kl###-####-####-############ | My AWS SageMaker engine | sagemaker_machine_learning | 2019-04-04T09:50:33.186Z |
For information about specific machine learning engines, see the following topics:
- Add your Custom machine learning engine.
- Add your Microsoft Azure machine learning studio engine
- Add your Microsoft Azure machine learning service engine
- Add your Amazon SageMaker machine learning engine
For a coding example, see the Watson OpenScale sample notebooks.
Parent topic: Evaluating AI models with Watson OpenScale