Hello text data: Deploy model to an endpoint and send a prediction

After your AutoML text classification model is done training, use the Vertex AI console to create an endpoint and deploy your model to the endpoint. After your model is deployed to the endpoint, send a document to the model for label prediction.

This tutorial has several pages:

  1. Setting up your project and environment.

  2. Creating a text classification dataset .

  3. Training an AutoML text classification model.

  4. Deploy model to an endpoint and send a prediction.

  5. Cleaning up your project.

Each page assumes that you have already performed the instructions from the previous pages of the tutorial.

Deploy your model to an endpoint

Access your trained model to deploy it to a new endpoint from the Models page.

  1. In the Google Cloud Console, go to the Models page.

    Go to the Models page

  2. For Region, select us-central1 (Iowa).

  3. Click your trained AutoML model to view details about your model.

    For example, in the Evaluate tab, you can view your model's performance metrics.

  4. Select the Deploy & test tab to create an endpoint.

  5. Click Deploy to endpoint.

  6. In the Deploy to endpoint window, complete the following steps:

    1. Choose Create new endpoint and enter a name for the endpoint such as hello_automl_text.

    2. Accept the Traffic split of 100%, and click Deploy.

It takes several minutes to create the endpoint and deploy the AutoML model to the new endpoint.

Send a prediction to your model

After the endpoint is created, you can send text predictions from the Vertex AI console.

  1. In the Google Cloud Console, go to the Models page.

    Go to the Models page

  2. For Region, select us-central1 (Iowa).

  3. Click your trained AutoML model.

  4. Select the Deploy & test tab

  5. In the Test your model section, enter text for prediction.

  6. Click Predict to view the model's predicted label and confidence score.

    Sample prediction

What's next

Follow the last page of the tutorial to clean up resources that you have created.