管理引擎版本

本頁說明如何管理 AML AI 引擎版本。引擎版本可用來控管訓練和執行模型時的架構或設定。這是唯讀資源。

如要進一步瞭解引擎版本,請參閱「引擎版本」。

事前準備

列出引擎版本

如要列出引擎版本,請使用 projects.locations.instances.engineVersions.list 方法。

使用任何要求資料之前,請先替換以下項目:

  • PROJECT_ID:您在身分與存取權管理設定中列出的 Google Cloud 專案 ID
  • LOCATION:執行個體的位置;請使用其中一個支援的區域
    顯示地區
    • us-central1
    • us-east1
    • asia-south1
    • europe-west1
    • europe-west2
    • europe-west4
    • northamerica-northeast1
    • southamerica-east1
    • australia-southeast1
  • INSTANCE_ID:使用者定義的執行個體 ID

如要傳送要求,請選擇以下其中一個選項:

curl

執行下列指令:

curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://financialservices.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION/instances/INSTANCE_ID/engineVersions"

PowerShell

執行下列指令:

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

Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://financialservices.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION/instances/INSTANCE_ID/engineVersions" | Select-Object -Expand Content

您應該會收到如下的 JSON 回應:

{
  "engineVersions": [
    {
      "name": "projects/PROJECT_ID/locations/LOCATION/instances/INSTANCE_ID/engineVersions/finserv-aml.live-with-data-validation.v1.1.2022-05",
      "state": "ACTIVE",
      "expectedLimitationStartTime": EXPECTED_LIMITATION_START_TIME,
      "expectedDecommissionTime": "EXPECTED_DECOMMISSION_TIME,
      "lineOfBusiness": "RETAIL"
    },
    {
      "name": "projects/PROJECT_ID/locations/LOCATION/instances/INSTANCE_ID/engineVersions/finserv-aml.live.v1.1.2022-05",
      "state": "ACTIVE",
      "expectedLimitationStartTime": EXPECTED_LIMITATION_START_TIME,
      "expectedDecommissionTime": "EXPECTED_DECOMMISSION_TIME,
      "lineOfBusiness": "RETAIL"
    }
  ]
}

取得引擎版本

如要取得引擎版本,請使用 projects.locations.instances.engineVersions.get 方法。

使用任何要求資料之前,請先替換以下項目:

  • PROJECT_ID:您在身分與存取權管理設定中列出的 Google Cloud 專案 ID
  • LOCATION:執行個體的位置;請使用其中一個支援的區域
    顯示地區
    • us-central1
    • us-east1
    • asia-south1
    • europe-west1
    • europe-west2
    • europe-west4
    • northamerica-northeast1
    • southamerica-east1
    • australia-southeast1
  • INSTANCE_ID:使用者定義的執行個體 ID
  • ENGINE_VERSION_ID:引擎版本 ID

如要傳送要求,請選擇以下其中一個選項:

curl

執行下列指令:

curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://financialservices.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION/instances/INSTANCE_ID/engineVersions/ENGINE_VERSION_ID"

PowerShell

執行下列指令:

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

Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://financialservices.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION/instances/INSTANCE_ID/engineVersions/ENGINE_VERSION_ID" | Select-Object -Expand Content

您應該會收到如下的 JSON 回應:

{
  "name": "projects/PROJECT_ID/locations/LOCATION/instances/INSTANCE_ID/engineVersions/ENGINE_VERSION_ID",
  "state": "ACTIVE",
  "expectedLimitationStartTime": EXPECTED_LIMITATION_START_TIME,
  "expectedDecommissionTime": "EXPECTED_DECOMMISSION_TIME,
  "lineOfBusiness": "RETAIL"
}