@ai-sdk/google-vertex 5.0.0-canary.87 → 5.0.0-canary.89
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/dist/anthropic/edge/index.js +1 -1
- package/dist/edge/index.js +1 -1
- package/dist/index.js +1 -1
- package/dist/maas/edge/index.js +1 -1
- package/dist/xai/edge/index.js +1 -1
- package/docs/16-google-vertex.mdx +29 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @ai-sdk/google-vertex
|
|
2
2
|
|
|
3
|
+
## 5.0.0-canary.89
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [aeea161]
|
|
8
|
+
- @ai-sdk/google@4.0.0-canary.70
|
|
9
|
+
|
|
10
|
+
## 5.0.0-canary.88
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies [7f04802]
|
|
15
|
+
- @ai-sdk/google@4.0.0-canary.69
|
|
16
|
+
|
|
3
17
|
## 5.0.0-canary.87
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
} from "@ai-sdk/provider-utils";
|
|
11
11
|
|
|
12
12
|
// src/version.ts
|
|
13
|
-
var VERSION = true ? "5.0.0-canary.
|
|
13
|
+
var VERSION = true ? "5.0.0-canary.89" : "0.0.0-test";
|
|
14
14
|
|
|
15
15
|
// src/edge/google-vertex-auth-edge.ts
|
|
16
16
|
var loadCredentials = async () => {
|
package/dist/edge/index.js
CHANGED
package/dist/index.js
CHANGED
package/dist/maas/edge/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
} from "@ai-sdk/provider-utils";
|
|
11
11
|
|
|
12
12
|
// src/version.ts
|
|
13
|
-
var VERSION = true ? "5.0.0-canary.
|
|
13
|
+
var VERSION = true ? "5.0.0-canary.89" : "0.0.0-test";
|
|
14
14
|
|
|
15
15
|
// src/edge/google-vertex-auth-edge.ts
|
|
16
16
|
var loadCredentials = async () => {
|
package/dist/xai/edge/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
} from "@ai-sdk/provider-utils";
|
|
11
11
|
|
|
12
12
|
// src/version.ts
|
|
13
|
-
var VERSION = true ? "5.0.0-canary.
|
|
13
|
+
var VERSION = true ? "5.0.0-canary.89" : "0.0.0-test";
|
|
14
14
|
|
|
15
15
|
// src/edge/google-vertex-auth-edge.ts
|
|
16
16
|
var loadCredentials = async () => {
|
|
@@ -347,6 +347,35 @@ The following optional provider options are available for Google Vertex models:
|
|
|
347
347
|
|
|
348
348
|
Consult [Google's Documentation](https://docs.cloud.google.com/vertex-ai/generative-ai/docs/multimodal/function-calling#streaming-fc) for details.
|
|
349
349
|
|
|
350
|
+
- **sharedRequestType** _'priority' | 'flex' | 'standard'_
|
|
351
|
+
|
|
352
|
+
Optional. Selects a pay-as-you-go (PayGo) tier by setting the
|
|
353
|
+
`X-Vertex-AI-LLM-Shared-Request-Type` request header. Use `'priority'` for
|
|
354
|
+
consistent low-latency performance at a premium, or `'flex'` for a 50%
|
|
355
|
+
discount with longer expected latency. Both are supported only on the
|
|
356
|
+
`global` endpoint and on a subset of Gemini models.
|
|
357
|
+
|
|
358
|
+
By default — with Provisioned Throughput allocated and `requestType` unset
|
|
359
|
+
— the request consumes Provisioned Throughput quota first and only falls
|
|
360
|
+
back to the chosen shared tier if PT capacity is exhausted. To bypass
|
|
361
|
+
Provisioned Throughput entirely, also set `requestType: 'shared'`.
|
|
362
|
+
|
|
363
|
+
The served tier is reported back on
|
|
364
|
+
`result.providerMetadata.googleVertex.usageMetadata.trafficType` as
|
|
365
|
+
`ON_DEMAND_PRIORITY`, `ON_DEMAND_FLEX`, or (if downgraded under load) plain
|
|
366
|
+
`ON_DEMAND`.
|
|
367
|
+
|
|
368
|
+
See [Priority PayGo](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/priority-paygo)
|
|
369
|
+
and [Flex PayGo](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/flex-paygo)
|
|
370
|
+
for supported models, ramp limits, and downgrade behavior.
|
|
371
|
+
|
|
372
|
+
- **requestType** _'shared'_
|
|
373
|
+
|
|
374
|
+
Optional. Sets the `X-Vertex-AI-LLM-Request-Type` request header. Combine
|
|
375
|
+
with `sharedRequestType` to skip Provisioned Throughput entirely and route
|
|
376
|
+
the request through shared PayGo capacity. See
|
|
377
|
+
[Priority PayGo](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/priority-paygo).
|
|
378
|
+
|
|
350
379
|
You can use Google Vertex language models to generate text with the `generateText` function:
|
|
351
380
|
|
|
352
381
|
```ts highlight="1,4"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ai-sdk/google-vertex",
|
|
3
|
-
"version": "5.0.0-canary.
|
|
3
|
+
"version": "5.0.0-canary.89",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
"dependencies": {
|
|
74
74
|
"google-auth-library": "^10.6.2",
|
|
75
75
|
"@ai-sdk/anthropic": "4.0.0-canary.57",
|
|
76
|
-
"@ai-sdk/google": "4.0.0-canary.
|
|
76
|
+
"@ai-sdk/google": "4.0.0-canary.70",
|
|
77
77
|
"@ai-sdk/openai-compatible": "3.0.0-canary.50",
|
|
78
78
|
"@ai-sdk/provider": "4.0.0-canary.17",
|
|
79
79
|
"@ai-sdk/provider-utils": "5.0.0-canary.43"
|