Membuat daftar grup fitur

Anda dapat mengambil daftar semua grup fitur yang dibuat untuk lokasi tertentu dalam project Google Cloud, beserta URI tabel atau tampilan sumber BigQuery yang terkait dengan setiap grup fitur.

Gunakan contoh berikut untuk mengambil daftar semua grup fitur untuk lokasi tertentu dalam project Anda.

Konsol

Gunakan petunjuk berikut untuk melihat daftar grup fitur untuk lokasi tertentu menggunakan konsol Google Cloud.

  1. Di bagian Vertex AI pada Konsol Google Cloud, buka halaman Feature Store.

    Buka halaman Feature Store

  2. Di bagian Grup fitur, Anda dapat melihat daftar semua grup fitur untuk lokasi yang dipilih.

REST

Untuk mengambil daftar semua resource FeatureGroup untuk lokasi tertentu di proyek Anda, kirim permintaan GET menggunakan metode featureGroups.list.

Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:

  • LOCATION_ID: Region tempat Anda ingin melihat daftar grup fitur, seperti us-central1.
  • PROJECT_ID: Project ID Anda.

Metode HTTP dan URL:

GET https://LOCATION_ID-aiplatform.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/featureGroups

Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:

curl

Jalankan perintah berikut:

curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://LOCATION_ID-aiplatform.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/featureGroups"

PowerShell

Jalankan perintah berikut:

$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }

Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://LOCATION_ID-aiplatform.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/featureGroups" | Select-Object -Expand Content

Anda akan menerima respons JSON yang mirip seperti berikut:

{
  "featureGroups": [
    {
      "name": "projects/PROJECT_NUMBER/locations/LOCATION_ID/featureGroups/FEATURE_GROUP_NAME_1",
      "createTime": "2023-09-07T00:57:00.142639Z",
      "updateTime": "2023-09-07T00:57:00.142639Z",
      "etag": "AMEw9yOY0byP8qKsDY0DoZyouAtX23zDru2l422C0affZZPYNFOGgIrONELNrM49uH4=",
      "bigQuery": {
        "bigQuerySource": {
          "inputUri": "BIGQUERY_URI_1"
        }
      }
    },
    {
      "name": "projects/PROJECT_NUMBER/locations/LOCATION_ID/featureGroups/FEATURE_GROUP_NAME_2",
      "createTime": "2023-09-06T23:14:30.795502Z",
      "updateTime": "2023-09-06T23:14:30.795502Z",
      "etag": "AMEw9yO5UfrPWobGR2Ry-PnbJUQoklW5lX0uW4JmKqj6OgQui6p-rMdUHfuENpQjbJ3t",
      "bigQuery": {
        "bigQuerySource": {
          "inputUri": "BIGQUERY_URI_2"
        }
      }
    }
  ]
}

Langkah selanjutnya