跳至正文
Wener Notes

Vertex AI MaaS API

约 1 分钟阅读
  • Vertex AI 使用 Google Cloud project/location、IAM/ADC、quota、VPC-SC 和 regional/global endpoint。
  • API host
    • Regional:LOCATION-aiplatform.googleapis.com
    • Global:aiplatform.googleapis.com
    • Partner Models 还支持特定 multi-region host,例如 aiplatform.us.rep.googleapis.com。

PredictionService

Gemini on Vertex AI

  • Gemini Developer API 与 Vertex Gemini 可以共享相近的 content/tool/generation message,但 endpoint、认证、resource name 和可用能力不同。
  • Vertex publisher model resource:projects/{project}/locations/{location}/publishers/google/models/{model}。
  • 不应使用 generativelanguage.googleapis.com 的 API key 路径代替 Vertex IAM 调用。

Partner Models

  • Use partner models
  • Anthropic Claude、Mistral 等是 Vertex AI 上的 Partner Models,由 Google Cloud endpoint、IAM 和 quota 承载。
  • Vertex Anthropic 常见路径:
text
POST https://LOCATION-aiplatform.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION/publishers/anthropic/models/MODEL_ID:rawPredict
POST https://LOCATION-aiplatform.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION/publishers/anthropic/models/MODEL_ID:streamRawPredict
  • Body 使用 Anthropic on Vertex 的 partner-specific schema,例如 anthropic_version: "vertex-2023-10-16",不是 Gemini GenerateContentRequest。
  • 因此 Vertex Anthropic 是 PredictionService.RawPredict / StreamRawPredict transport 上承载 Anthropic payload 的特例,而不是 Generative Language API 的一部分。

参考

关联信息

反向链接、本文链接的其他页面和外部资料。

参考资料

GitHub1 条
其他外链4 条
最近更新commit 2c5cb2f编辑