# Google Vertex AI

{% hint style="info" %}
**Supported labeling types**: Row labeling.
{% endhint %}

**ML-assisted labeling** supports models from Vertex AI. If you already have data and training pipelines in Vertex AI, you can utilize your trained model to enhance the performance.

### Enable ML-assisted labeling

To use the models from Vertex AI, select **Google Vertex AI** as the service provider.

<figure><img src="/files/XUGA8N4y2AZ3jgtSqyFj" alt="Image of ML Assisted with Google Vertex AI"><figcaption><p><strong>ML-assisted labeling</strong> with Google Vertex AI</p></figcaption></figure>

Once selected, you will see the following fields:

* **Target text**: Select the input text used as reference.
* **Target question**: Select the output column to predict.
* **API URL**: The endpoint from Google Vertex AI. The format will follow the sample below:

  `https://<REGION>-aiplatform.googleapis.com/ui/projects/<PROJECT-ID>/locations/<REGION>/endpoints/<ENDPOINT-ID>:predict`
* **Faster prediction speed**: Enables faster predictions by processing requests on the backend.

### Setup your model

You can view the endpoint URL by clicking its name after successful deployment.

<figure><img src="/files/3LWvo5Ld3YH68GgaRSn0" alt="Image of Endpoint page from Google Vertex AI"><figcaption><p>Endpoint page from Google Vertex AI</p></figcaption></figure>

To allow **ML-assisted labeling** to run your model, you need to grant the Datasaur Service Account access as Vertex AI Administrator. Follow the steps below:

1. Navigate to the project where your model is located.
2. Go to **IAM & Admin**.
3. Click on the **IAM** in the left sidebar.

   <figure><img src="/files/QLnYi5AHAVhwcF5yi1nm" alt="Image of IAM page menu"><figcaption><p>IAM page menu</p></figcaption></figure>
4. Click **Grant access**.
5. In the **New principals** field, fill in the **Service account email**:

   <integrator@datasaur-gcp.iam.gserviceaccount.com>

   <figure><img src="/files/meq2kgMSuoxwdXOBNoKV" alt="Image of Grant Access Menu"><figcaption></figcaption></figure>
6. In the role field, select **Vertex AI Administrator**.
7. Click **Save** to complete the setup.

### Start prediction

After configuring the settings above, copy the endpoint URL and paste it into the **API URL** field. Click **Predict labels** to generate and retrieve predictions from your model.

<figure><img src="/files/oiK0FH6NbpQmuRoVabzl" alt="Image of Prediction result"><figcaption><p>Prediction result</p></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.datasaur.ai/assisted-labeling/ml-assisted-labeling/google-vertex-ai.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
