mtmsdk 0.0.11 → 0.0.13
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/dist/components/MustAdmin.d.ts +14 -0
- package/dist/components/MustAdmin.d.ts.map +1 -0
- package/dist/components/MustAdmin.js +37 -0
- package/dist/components/MustAdmin.js.map +1 -0
- package/dist/gomtmapi/@tanstack/react-query.gen.d.ts +137 -2073
- package/dist/gomtmapi/@tanstack/react-query.gen.d.ts.map +1 -1
- package/dist/gomtmapi/@tanstack/react-query.gen.js +118 -2085
- package/dist/gomtmapi/@tanstack/react-query.gen.js.map +1 -1
- package/dist/gomtmapi/client/client.gen.d.ts +3 -0
- package/dist/gomtmapi/client/client.gen.d.ts.map +1 -0
- package/dist/{gomtmapi_v2/client/client.js → gomtmapi/client/client.gen.js} +82 -23
- package/dist/gomtmapi/client/client.gen.js.map +1 -0
- package/dist/gomtmapi/client/index.d.ts +7 -7
- package/dist/gomtmapi/client/index.d.ts.map +1 -1
- package/dist/gomtmapi/client/index.js +5 -4
- package/dist/gomtmapi/client/index.js.map +1 -1
- package/dist/gomtmapi/client/{types.d.ts → types.gen.d.ts} +19 -14
- package/dist/gomtmapi/client/types.gen.d.ts.map +1 -0
- package/dist/gomtmapi/client/types.gen.js +3 -0
- package/dist/gomtmapi/client/types.gen.js.map +1 -0
- package/dist/gomtmapi/client/{utils.d.ts → utils.gen.d.ts} +9 -21
- package/dist/gomtmapi/client/utils.gen.d.ts.map +1 -0
- package/dist/{gomtmapi_v2/client/utils.js → gomtmapi/client/utils.gen.js} +56 -110
- package/dist/gomtmapi/client/utils.gen.js.map +1 -0
- package/dist/gomtmapi/client.gen.d.ts +3 -3
- package/dist/gomtmapi/client.gen.d.ts.map +1 -1
- package/dist/gomtmapi/client.gen.js.map +1 -1
- package/dist/gomtmapi/core/{auth.d.ts → auth.gen.d.ts} +1 -1
- package/dist/gomtmapi/core/auth.gen.d.ts.map +1 -0
- package/dist/gomtmapi/core/{auth.js → auth.gen.js} +2 -1
- package/dist/gomtmapi/core/auth.gen.js.map +1 -0
- package/dist/{mtgate_api/core/bodySerializer.d.ts → gomtmapi/core/bodySerializer.gen.d.ts} +2 -2
- package/dist/gomtmapi/core/bodySerializer.gen.d.ts.map +1 -0
- package/dist/{mtgate_api/core/bodySerializer.js → gomtmapi/core/bodySerializer.gen.js} +5 -1
- package/dist/gomtmapi/core/bodySerializer.gen.js.map +1 -0
- package/dist/{mtgate_api/core/params.d.ts → gomtmapi/core/params.gen.d.ts} +11 -1
- package/dist/gomtmapi/core/params.gen.d.ts.map +1 -0
- package/dist/gomtmapi/core/{params.js → params.gen.js} +2 -1
- package/dist/gomtmapi/core/params.gen.js.map +1 -0
- package/dist/{mtgate_api/core/pathSerializer.d.ts → gomtmapi/core/pathSerializer.gen.d.ts} +1 -1
- package/dist/gomtmapi/core/pathSerializer.gen.d.ts.map +1 -0
- package/dist/gomtmapi/core/{pathSerializer.js → pathSerializer.gen.js} +2 -1
- package/dist/gomtmapi/core/pathSerializer.gen.js.map +1 -0
- package/dist/gomtmapi/core/serverSentEvents.gen.d.ts +72 -0
- package/dist/gomtmapi/core/serverSentEvents.gen.d.ts.map +1 -0
- package/dist/gomtmapi/core/serverSentEvents.gen.js +136 -0
- package/dist/gomtmapi/core/serverSentEvents.gen.js.map +1 -0
- package/dist/{mtgate_api/core/types.d.ts → gomtmapi/core/types.gen.d.ts} +20 -15
- package/dist/gomtmapi/core/types.gen.d.ts.map +1 -0
- package/dist/gomtmapi/core/types.gen.js +3 -0
- package/dist/gomtmapi/core/types.gen.js.map +1 -0
- package/dist/gomtmapi/core/utils.gen.d.ts +20 -0
- package/dist/gomtmapi/core/utils.gen.d.ts.map +1 -0
- package/dist/gomtmapi/core/utils.gen.js +88 -0
- package/dist/gomtmapi/core/utils.gen.js.map +1 -0
- package/dist/gomtmapi/index.d.ts.map +1 -1
- package/dist/gomtmapi/index.js.map +1 -1
- package/dist/gomtmapi/schemas.gen.d.ts +806 -3746
- package/dist/gomtmapi/schemas.gen.d.ts.map +1 -1
- package/dist/gomtmapi/schemas.gen.js +780 -3827
- package/dist/gomtmapi/schemas.gen.js.map +1 -1
- package/dist/gomtmapi/sdk.gen.d.ts +3 -306
- package/dist/gomtmapi/sdk.gen.d.ts.map +1 -1
- package/dist/gomtmapi/sdk.gen.js +53 -1338
- package/dist/gomtmapi/sdk.gen.js.map +1 -1
- package/dist/gomtmapi/types.gen.d.ts +1186 -5364
- package/dist/gomtmapi/types.gen.d.ts.map +1 -1
- package/dist/gomtmapi/types.gen.js +8 -45
- package/dist/gomtmapi/types.gen.js.map +1 -1
- package/dist/gomtmapi/zod.gen.d.ts +1371 -4628
- package/dist/gomtmapi/zod.gen.d.ts.map +1 -1
- package/dist/gomtmapi/zod.gen.js +565 -2224
- package/dist/gomtmapi/zod.gen.js.map +1 -1
- package/dist/gomtmapi_v2/@tanstack/react-query.gen.d.ts +286 -823
- package/dist/gomtmapi_v2/@tanstack/react-query.gen.d.ts.map +1 -1
- package/dist/gomtmapi_v2/@tanstack/react-query.gen.js +226 -787
- package/dist/gomtmapi_v2/@tanstack/react-query.gen.js.map +1 -1
- package/dist/gomtmapi_v2/client/client.gen.d.ts +3 -0
- package/dist/gomtmapi_v2/client/client.gen.d.ts.map +1 -0
- package/dist/{mtgate_api/client/client.js → gomtmapi_v2/client/client.gen.js} +82 -23
- package/dist/gomtmapi_v2/client/client.gen.js.map +1 -0
- package/dist/gomtmapi_v2/client/index.d.ts +7 -7
- package/dist/gomtmapi_v2/client/index.d.ts.map +1 -1
- package/dist/gomtmapi_v2/client/index.js +5 -4
- package/dist/gomtmapi_v2/client/index.js.map +1 -1
- package/dist/{mtgate_api/client/types.d.ts → gomtmapi_v2/client/types.gen.d.ts} +19 -14
- package/dist/gomtmapi_v2/client/types.gen.d.ts.map +1 -0
- package/dist/gomtmapi_v2/client/types.gen.js +3 -0
- package/dist/gomtmapi_v2/client/types.gen.js.map +1 -0
- package/dist/{mtgate_api/client/utils.d.ts → gomtmapi_v2/client/utils.gen.d.ts} +9 -21
- package/dist/gomtmapi_v2/client/utils.gen.d.ts.map +1 -0
- package/dist/{gomtmapi/client/utils.js → gomtmapi_v2/client/utils.gen.js} +56 -110
- package/dist/gomtmapi_v2/client/utils.gen.js.map +1 -0
- package/dist/gomtmapi_v2/client.gen.d.ts +3 -3
- package/dist/gomtmapi_v2/client.gen.d.ts.map +1 -1
- package/dist/gomtmapi_v2/client.gen.js.map +1 -1
- package/dist/{mtmai_api/core/auth.d.ts → gomtmapi_v2/core/auth.gen.d.ts} +1 -1
- package/dist/gomtmapi_v2/core/auth.gen.d.ts.map +1 -0
- package/dist/{mtmai_api/core/auth.js → gomtmapi_v2/core/auth.gen.js} +2 -1
- package/dist/gomtmapi_v2/core/auth.gen.js.map +1 -0
- package/dist/gomtmapi_v2/core/{bodySerializer.d.ts → bodySerializer.gen.d.ts} +2 -2
- package/dist/gomtmapi_v2/core/bodySerializer.gen.d.ts.map +1 -0
- package/dist/{gomtmapi/core/bodySerializer.js → gomtmapi_v2/core/bodySerializer.gen.js} +5 -1
- package/dist/gomtmapi_v2/core/bodySerializer.gen.js.map +1 -0
- package/dist/gomtmapi_v2/core/{params.d.ts → params.gen.d.ts} +11 -1
- package/dist/gomtmapi_v2/core/params.gen.d.ts.map +1 -0
- package/dist/{mtgate_api/core/params.js → gomtmapi_v2/core/params.gen.js} +2 -1
- package/dist/gomtmapi_v2/core/params.gen.js.map +1 -0
- package/dist/{mtmai_api/core/pathSerializer.d.ts → gomtmapi_v2/core/pathSerializer.gen.d.ts} +1 -1
- package/dist/gomtmapi_v2/core/pathSerializer.gen.d.ts.map +1 -0
- package/dist/{mtgate_api/core/pathSerializer.js → gomtmapi_v2/core/pathSerializer.gen.js} +2 -1
- package/dist/gomtmapi_v2/core/pathSerializer.gen.js.map +1 -0
- package/dist/gomtmapi_v2/core/serverSentEvents.gen.d.ts +72 -0
- package/dist/gomtmapi_v2/core/serverSentEvents.gen.d.ts.map +1 -0
- package/dist/gomtmapi_v2/core/serverSentEvents.gen.js +136 -0
- package/dist/gomtmapi_v2/core/serverSentEvents.gen.js.map +1 -0
- package/dist/{mtmai_api/core/types.d.ts → gomtmapi_v2/core/types.gen.d.ts} +20 -15
- package/dist/gomtmapi_v2/core/types.gen.d.ts.map +1 -0
- package/dist/gomtmapi_v2/core/types.gen.js +3 -0
- package/dist/gomtmapi_v2/core/types.gen.js.map +1 -0
- package/dist/gomtmapi_v2/core/utils.gen.d.ts +20 -0
- package/dist/gomtmapi_v2/core/utils.gen.d.ts.map +1 -0
- package/dist/gomtmapi_v2/core/utils.gen.js +88 -0
- package/dist/gomtmapi_v2/core/utils.gen.js.map +1 -0
- package/dist/gomtmapi_v2/index.d.ts +1 -1
- package/dist/gomtmapi_v2/index.d.ts.map +1 -1
- package/dist/gomtmapi_v2/index.js +0 -1
- package/dist/gomtmapi_v2/index.js.map +1 -1
- package/dist/gomtmapi_v2/schemas.gen.d.ts +317 -222
- package/dist/gomtmapi_v2/schemas.gen.d.ts.map +1 -1
- package/dist/gomtmapi_v2/schemas.gen.js +317 -222
- package/dist/gomtmapi_v2/schemas.gen.js.map +1 -1
- package/dist/gomtmapi_v2/sdk.gen.d.ts +142 -156
- package/dist/gomtmapi_v2/sdk.gen.d.ts.map +1 -1
- package/dist/gomtmapi_v2/sdk.gen.js +210 -233
- package/dist/gomtmapi_v2/sdk.gen.js.map +1 -1
- package/dist/gomtmapi_v2/types.gen.d.ts +188 -195
- package/dist/gomtmapi_v2/types.gen.d.ts.map +1 -1
- package/dist/gomtmapi_v2/zod.gen.d.ts +474 -428
- package/dist/gomtmapi_v2/zod.gen.d.ts.map +1 -1
- package/dist/gomtmapi_v2/zod.gen.js +892 -1054
- package/dist/gomtmapi_v2/zod.gen.js.map +1 -1
- package/dist/lib/adk-utils.d.ts +0 -5
- package/dist/lib/adk-utils.d.ts.map +1 -1
- package/dist/lib/adk-utils.js +31 -32
- package/dist/lib/adk-utils.js.map +1 -1
- package/dist/lib/auth-client.d.ts +5965 -0
- package/dist/lib/auth-client.d.ts.map +1 -0
- package/dist/lib/auth-client.js +29 -0
- package/dist/lib/auth-client.js.map +1 -0
- package/dist/lib/get-query-client.d.ts.map +1 -1
- package/dist/lib/get-query-client.js +1 -21
- package/dist/lib/get-query-client.js.map +1 -1
- package/dist/lib/mtgate_client_ss.d.ts +10 -0
- package/dist/lib/mtgate_client_ss.d.ts.map +1 -0
- package/dist/lib/mtgate_client_ss.js +24 -0
- package/dist/lib/mtgate_client_ss.js.map +1 -0
- package/dist/mtgate_api/@tanstack/react-query.gen.d.ts +367 -2123
- package/dist/mtgate_api/@tanstack/react-query.gen.d.ts.map +1 -1
- package/dist/mtgate_api/@tanstack/react-query.gen.js +142 -1018
- package/dist/mtgate_api/@tanstack/react-query.gen.js.map +1 -1
- package/dist/mtgate_api/client/client.gen.d.ts +3 -0
- package/dist/mtgate_api/client/client.gen.d.ts.map +1 -0
- package/dist/{gomtmapi/client/client.js → mtgate_api/client/client.gen.js} +82 -23
- package/dist/mtgate_api/client/client.gen.js.map +1 -0
- package/dist/mtgate_api/client/index.d.ts +7 -7
- package/dist/mtgate_api/client/index.d.ts.map +1 -1
- package/dist/mtgate_api/client/index.js +5 -4
- package/dist/mtgate_api/client/index.js.map +1 -1
- package/dist/{gomtmapi_v2/client/types.d.ts → mtgate_api/client/types.gen.d.ts} +19 -14
- package/dist/mtgate_api/client/types.gen.d.ts.map +1 -0
- package/dist/mtgate_api/client/types.gen.js +3 -0
- package/dist/mtgate_api/client/types.gen.js.map +1 -0
- package/dist/{mtmai_api/client/utils.d.ts → mtgate_api/client/utils.gen.d.ts} +9 -21
- package/dist/mtgate_api/client/utils.gen.d.ts.map +1 -0
- package/dist/mtgate_api/client/{utils.js → utils.gen.js} +56 -110
- package/dist/mtgate_api/client/utils.gen.js.map +1 -0
- package/dist/mtgate_api/client.gen.d.ts +3 -3
- package/dist/mtgate_api/client.gen.d.ts.map +1 -1
- package/dist/mtgate_api/client.gen.js.map +1 -1
- package/dist/{gomtmapi_v2/core/auth.d.ts → mtgate_api/core/auth.gen.d.ts} +1 -1
- package/dist/mtgate_api/core/auth.gen.d.ts.map +1 -0
- package/dist/mtgate_api/core/{auth.js → auth.gen.js} +2 -1
- package/dist/mtgate_api/core/auth.gen.js.map +1 -0
- package/dist/{gomtmapi/core/bodySerializer.d.ts → mtgate_api/core/bodySerializer.gen.d.ts} +2 -2
- package/dist/mtgate_api/core/bodySerializer.gen.d.ts.map +1 -0
- package/dist/{mtmai_api/core/bodySerializer.js → mtgate_api/core/bodySerializer.gen.js} +5 -1
- package/dist/mtgate_api/core/bodySerializer.gen.js.map +1 -0
- package/dist/{mtmai_api/core/params.d.ts → mtgate_api/core/params.gen.d.ts} +11 -1
- package/dist/mtgate_api/core/params.gen.d.ts.map +1 -0
- package/dist/{gomtmapi_v2/core/params.js → mtgate_api/core/params.gen.js} +2 -1
- package/dist/mtgate_api/core/params.gen.js.map +1 -0
- package/dist/{gomtmapi_v2/core/pathSerializer.d.ts → mtgate_api/core/pathSerializer.gen.d.ts} +1 -1
- package/dist/mtgate_api/core/pathSerializer.gen.d.ts.map +1 -0
- package/dist/{gomtmapi_v2/core/pathSerializer.js → mtgate_api/core/pathSerializer.gen.js} +2 -1
- package/dist/mtgate_api/core/pathSerializer.gen.js.map +1 -0
- package/dist/mtgate_api/core/serverSentEvents.gen.d.ts +72 -0
- package/dist/mtgate_api/core/serverSentEvents.gen.d.ts.map +1 -0
- package/dist/mtgate_api/core/serverSentEvents.gen.js +136 -0
- package/dist/mtgate_api/core/serverSentEvents.gen.js.map +1 -0
- package/dist/{gomtmapi/core/types.d.ts → mtgate_api/core/types.gen.d.ts} +20 -15
- package/dist/mtgate_api/core/types.gen.d.ts.map +1 -0
- package/dist/mtgate_api/core/types.gen.js +3 -0
- package/dist/mtgate_api/core/types.gen.js.map +1 -0
- package/dist/mtgate_api/core/utils.gen.d.ts +20 -0
- package/dist/mtgate_api/core/utils.gen.d.ts.map +1 -0
- package/dist/mtgate_api/core/utils.gen.js +88 -0
- package/dist/mtgate_api/core/utils.gen.js.map +1 -0
- package/dist/mtgate_api/index.d.ts.map +1 -1
- package/dist/mtgate_api/index.js.map +1 -1
- package/dist/mtgate_api/schemas.gen.d.ts +206 -289
- package/dist/mtgate_api/schemas.gen.d.ts.map +1 -1
- package/dist/mtgate_api/schemas.gen.js +230 -307
- package/dist/mtgate_api/schemas.gen.js.map +1 -1
- package/dist/mtgate_api/sdk.gen.d.ts +20 -43
- package/dist/mtgate_api/sdk.gen.d.ts.map +1 -1
- package/dist/mtgate_api/sdk.gen.js +88 -234
- package/dist/mtgate_api/sdk.gen.js.map +1 -1
- package/dist/mtgate_api/types.gen.d.ts +383 -862
- package/dist/mtgate_api/types.gen.d.ts.map +1 -1
- package/dist/mtgate_api/types.gen.js.map +1 -1
- package/dist/mtgate_api/zod.gen.d.ts +607 -978
- package/dist/mtgate_api/zod.gen.d.ts.map +1 -1
- package/dist/mtgate_api/zod.gen.js +718 -1215
- package/dist/mtgate_api/zod.gen.js.map +1 -1
- package/dist/mtmai_api/@tanstack/react-query.gen.d.ts +115 -475
- package/dist/mtmai_api/@tanstack/react-query.gen.d.ts.map +1 -1
- package/dist/mtmai_api/@tanstack/react-query.gen.js +55 -423
- package/dist/mtmai_api/@tanstack/react-query.gen.js.map +1 -1
- package/dist/mtmai_api/client/client.gen.d.ts +3 -0
- package/dist/mtmai_api/client/client.gen.d.ts.map +1 -0
- package/dist/mtmai_api/client/{client.js → client.gen.js} +82 -23
- package/dist/mtmai_api/client/client.gen.js.map +1 -0
- package/dist/mtmai_api/client/index.d.ts +7 -7
- package/dist/mtmai_api/client/index.d.ts.map +1 -1
- package/dist/mtmai_api/client/index.js +5 -4
- package/dist/mtmai_api/client/index.js.map +1 -1
- package/dist/mtmai_api/client/{types.d.ts → types.gen.d.ts} +19 -14
- package/dist/mtmai_api/client/types.gen.d.ts.map +1 -0
- package/dist/mtmai_api/client/types.gen.js +3 -0
- package/dist/mtmai_api/client/types.gen.js.map +1 -0
- package/dist/{gomtmapi_v2/client/utils.d.ts → mtmai_api/client/utils.gen.d.ts} +9 -21
- package/dist/mtmai_api/client/utils.gen.d.ts.map +1 -0
- package/dist/mtmai_api/client/{utils.js → utils.gen.js} +56 -110
- package/dist/mtmai_api/client/utils.gen.js.map +1 -0
- package/dist/mtmai_api/client.gen.d.ts +3 -3
- package/dist/mtmai_api/client.gen.d.ts.map +1 -1
- package/dist/mtmai_api/client.gen.js.map +1 -1
- package/dist/{mtgate_api/core/auth.d.ts → mtmai_api/core/auth.gen.d.ts} +1 -1
- package/dist/mtmai_api/core/auth.gen.d.ts.map +1 -0
- package/dist/{gomtmapi_v2/core/auth.js → mtmai_api/core/auth.gen.js} +2 -1
- package/dist/mtmai_api/core/auth.gen.js.map +1 -0
- package/dist/mtmai_api/core/{bodySerializer.d.ts → bodySerializer.gen.d.ts} +2 -2
- package/dist/mtmai_api/core/bodySerializer.gen.d.ts.map +1 -0
- package/dist/{gomtmapi_v2/core/bodySerializer.js → mtmai_api/core/bodySerializer.gen.js} +5 -1
- package/dist/mtmai_api/core/bodySerializer.gen.js.map +1 -0
- package/dist/{gomtmapi/core/params.d.ts → mtmai_api/core/params.gen.d.ts} +11 -1
- package/dist/mtmai_api/core/params.gen.d.ts.map +1 -0
- package/dist/mtmai_api/core/{params.js → params.gen.js} +2 -1
- package/dist/mtmai_api/core/params.gen.js.map +1 -0
- package/dist/{gomtmapi/core/pathSerializer.d.ts → mtmai_api/core/pathSerializer.gen.d.ts} +1 -1
- package/dist/mtmai_api/core/pathSerializer.gen.d.ts.map +1 -0
- package/dist/mtmai_api/core/{pathSerializer.js → pathSerializer.gen.js} +2 -1
- package/dist/mtmai_api/core/pathSerializer.gen.js.map +1 -0
- package/dist/mtmai_api/core/serverSentEvents.gen.d.ts +72 -0
- package/dist/mtmai_api/core/serverSentEvents.gen.d.ts.map +1 -0
- package/dist/mtmai_api/core/serverSentEvents.gen.js +136 -0
- package/dist/mtmai_api/core/serverSentEvents.gen.js.map +1 -0
- package/dist/{gomtmapi_v2/core/types.d.ts → mtmai_api/core/types.gen.d.ts} +20 -15
- package/dist/mtmai_api/core/types.gen.d.ts.map +1 -0
- package/dist/mtmai_api/core/types.gen.js +3 -0
- package/dist/mtmai_api/core/types.gen.js.map +1 -0
- package/dist/mtmai_api/core/utils.gen.d.ts +20 -0
- package/dist/mtmai_api/core/utils.gen.d.ts.map +1 -0
- package/dist/mtmai_api/core/utils.gen.js +88 -0
- package/dist/mtmai_api/core/utils.gen.js.map +1 -0
- package/dist/mtmai_api/index.d.ts.map +1 -1
- package/dist/mtmai_api/index.js.map +1 -1
- package/dist/mtmai_api/schemas.gen.d.ts +447 -90
- package/dist/mtmai_api/schemas.gen.d.ts.map +1 -1
- package/dist/mtmai_api/schemas.gen.js +561 -108
- package/dist/mtmai_api/schemas.gen.js.map +1 -1
- package/dist/mtmai_api/sdk.gen.d.ts +3 -8
- package/dist/mtmai_api/sdk.gen.d.ts.map +1 -1
- package/dist/mtmai_api/sdk.gen.js +53 -67
- package/dist/mtmai_api/sdk.gen.js.map +1 -1
- package/dist/mtmai_api/types.gen.d.ts +420 -208
- package/dist/mtmai_api/types.gen.d.ts.map +1 -1
- package/dist/mtmai_api/types.gen.js.map +1 -1
- package/dist/mtmai_api/zod.gen.d.ts +26092 -5524
- package/dist/mtmai_api/zod.gen.d.ts.map +1 -1
- package/dist/mtmai_api/zod.gen.js +1391 -1362
- package/dist/mtmai_api/zod.gen.js.map +1 -1
- package/dist/store/AuthProviders.d.ts +8 -0
- package/dist/store/AuthProviders.d.ts.map +1 -0
- package/dist/store/AuthProviders.js +34 -0
- package/dist/store/AuthProviders.js.map +1 -0
- package/dist/store/{ReactQueryApiV2Provider.d.ts → GomtmProvider.d.ts} +1 -1
- package/dist/store/GomtmProvider.d.ts.map +1 -0
- package/dist/store/{ReactQueryApiV2Provider.js → GomtmProvider.js} +2 -2
- package/dist/store/GomtmProvider.js.map +1 -0
- package/dist/store/{ReactQueryProvider.d.ts → GomtmV1Provider.d.ts} +1 -1
- package/dist/store/GomtmV1Provider.d.ts.map +1 -0
- package/dist/store/{ReactQueryProvider.js → GomtmV1Provider.js} +2 -2
- package/dist/store/GomtmV1Provider.js.map +1 -0
- package/dist/store/MtgateProvider.d.ts +6015 -0
- package/dist/store/MtgateProvider.d.ts.map +1 -0
- package/dist/store/MtgateProvider.js +76 -0
- package/dist/store/MtgateProvider.js.map +1 -0
- package/dist/store/MtmsdkProvider.d.ts +1 -0
- package/dist/store/MtmsdkProvider.d.ts.map +1 -1
- package/dist/store/MtmsdkProvider.js +10 -13
- package/dist/store/MtmsdkProvider.js.map +1 -1
- package/package.json +68 -72
- package/dist/gomtmapi/client/client.d.ts +0 -3
- package/dist/gomtmapi/client/client.d.ts.map +0 -1
- package/dist/gomtmapi/client/client.js.map +0 -1
- package/dist/gomtmapi/client/types.d.ts.map +0 -1
- package/dist/gomtmapi/client/types.js +0 -2
- package/dist/gomtmapi/client/types.js.map +0 -1
- package/dist/gomtmapi/client/utils.d.ts.map +0 -1
- package/dist/gomtmapi/client/utils.js.map +0 -1
- package/dist/gomtmapi/core/auth.d.ts.map +0 -1
- package/dist/gomtmapi/core/auth.js.map +0 -1
- package/dist/gomtmapi/core/bodySerializer.d.ts.map +0 -1
- package/dist/gomtmapi/core/bodySerializer.js.map +0 -1
- package/dist/gomtmapi/core/params.d.ts.map +0 -1
- package/dist/gomtmapi/core/params.js.map +0 -1
- package/dist/gomtmapi/core/pathSerializer.d.ts.map +0 -1
- package/dist/gomtmapi/core/pathSerializer.js.map +0 -1
- package/dist/gomtmapi/core/types.d.ts.map +0 -1
- package/dist/gomtmapi/core/types.js +0 -2
- package/dist/gomtmapi/core/types.js.map +0 -1
- package/dist/gomtmapi_v2/client/client.d.ts +0 -3
- package/dist/gomtmapi_v2/client/client.d.ts.map +0 -1
- package/dist/gomtmapi_v2/client/client.js.map +0 -1
- package/dist/gomtmapi_v2/client/types.d.ts.map +0 -1
- package/dist/gomtmapi_v2/client/types.js +0 -2
- package/dist/gomtmapi_v2/client/types.js.map +0 -1
- package/dist/gomtmapi_v2/client/utils.d.ts.map +0 -1
- package/dist/gomtmapi_v2/client/utils.js.map +0 -1
- package/dist/gomtmapi_v2/core/auth.d.ts.map +0 -1
- package/dist/gomtmapi_v2/core/auth.js.map +0 -1
- package/dist/gomtmapi_v2/core/bodySerializer.d.ts.map +0 -1
- package/dist/gomtmapi_v2/core/bodySerializer.js.map +0 -1
- package/dist/gomtmapi_v2/core/params.d.ts.map +0 -1
- package/dist/gomtmapi_v2/core/params.js.map +0 -1
- package/dist/gomtmapi_v2/core/pathSerializer.d.ts.map +0 -1
- package/dist/gomtmapi_v2/core/pathSerializer.js.map +0 -1
- package/dist/gomtmapi_v2/core/types.d.ts.map +0 -1
- package/dist/gomtmapi_v2/core/types.js +0 -2
- package/dist/gomtmapi_v2/core/types.js.map +0 -1
- package/dist/lib/constants.d.ts +0 -40
- package/dist/lib/constants.d.ts.map +0 -1
- package/dist/lib/constants.js +0 -40
- package/dist/lib/constants.js.map +0 -1
- package/dist/lib/d1-utils.d.ts +0 -5
- package/dist/lib/d1-utils.d.ts.map +0 -1
- package/dist/lib/d1-utils.js +0 -36
- package/dist/lib/d1-utils.js.map +0 -1
- package/dist/lib/mtmutils.d.ts +0 -2
- package/dist/lib/mtmutils.d.ts.map +0 -1
- package/dist/lib/mtmutils.js +0 -9
- package/dist/lib/mtmutils.js.map +0 -1
- package/dist/mtgate_api/client/client.d.ts +0 -3
- package/dist/mtgate_api/client/client.d.ts.map +0 -1
- package/dist/mtgate_api/client/client.js.map +0 -1
- package/dist/mtgate_api/client/types.d.ts.map +0 -1
- package/dist/mtgate_api/client/types.js +0 -2
- package/dist/mtgate_api/client/types.js.map +0 -1
- package/dist/mtgate_api/client/utils.d.ts.map +0 -1
- package/dist/mtgate_api/client/utils.js.map +0 -1
- package/dist/mtgate_api/core/auth.d.ts.map +0 -1
- package/dist/mtgate_api/core/auth.js.map +0 -1
- package/dist/mtgate_api/core/bodySerializer.d.ts.map +0 -1
- package/dist/mtgate_api/core/bodySerializer.js.map +0 -1
- package/dist/mtgate_api/core/params.d.ts.map +0 -1
- package/dist/mtgate_api/core/params.js.map +0 -1
- package/dist/mtgate_api/core/pathSerializer.d.ts.map +0 -1
- package/dist/mtgate_api/core/pathSerializer.js.map +0 -1
- package/dist/mtgate_api/core/types.d.ts.map +0 -1
- package/dist/mtgate_api/core/types.js +0 -2
- package/dist/mtgate_api/core/types.js.map +0 -1
- package/dist/mtmai_api/client/client.d.ts +0 -3
- package/dist/mtmai_api/client/client.d.ts.map +0 -1
- package/dist/mtmai_api/client/client.js.map +0 -1
- package/dist/mtmai_api/client/types.d.ts.map +0 -1
- package/dist/mtmai_api/client/types.js +0 -2
- package/dist/mtmai_api/client/types.js.map +0 -1
- package/dist/mtmai_api/client/utils.d.ts.map +0 -1
- package/dist/mtmai_api/client/utils.js.map +0 -1
- package/dist/mtmai_api/core/auth.d.ts.map +0 -1
- package/dist/mtmai_api/core/auth.js.map +0 -1
- package/dist/mtmai_api/core/bodySerializer.d.ts.map +0 -1
- package/dist/mtmai_api/core/bodySerializer.js.map +0 -1
- package/dist/mtmai_api/core/params.d.ts.map +0 -1
- package/dist/mtmai_api/core/params.js.map +0 -1
- package/dist/mtmai_api/core/pathSerializer.d.ts.map +0 -1
- package/dist/mtmai_api/core/pathSerializer.js.map +0 -1
- package/dist/mtmai_api/core/types.d.ts.map +0 -1
- package/dist/mtmai_api/core/types.js +0 -2
- package/dist/mtmai_api/core/types.js.map +0 -1
- package/dist/store/ReactQueryApiV2Provider.d.ts.map +0 -1
- package/dist/store/ReactQueryApiV2Provider.js.map +0 -1
- package/dist/store/ReactQueryCfApiProvider.d.ts +0 -9
- package/dist/store/ReactQueryCfApiProvider.d.ts.map +0 -1
- package/dist/store/ReactQueryCfApiProvider.js +0 -26
- package/dist/store/ReactQueryCfApiProvider.js.map +0 -1
- package/dist/store/ReactQueryProvider.d.ts.map +0 -1
- package/dist/store/ReactQueryProvider.js.map +0 -1
|
@@ -17,8 +17,8 @@ export const zApiKeyIn = z.enum(["query", "header", "cookie"]);
|
|
|
17
17
|
* APIKey
|
|
18
18
|
*/
|
|
19
19
|
export const zApiKey = z.object({
|
|
20
|
-
type:
|
|
21
|
-
description: z.union([z.string(), z.null()])
|
|
20
|
+
type: z.optional(zSecuritySchemeType),
|
|
21
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
22
22
|
in: zApiKeyIn,
|
|
23
23
|
name: z.string(),
|
|
24
24
|
});
|
|
@@ -30,42 +30,561 @@ export const zAddSessionToEvalSetRequest = z.object({
|
|
|
30
30
|
sessionId: z.string(),
|
|
31
31
|
userId: z.string(),
|
|
32
32
|
});
|
|
33
|
+
/**
|
|
34
|
+
* Behavior
|
|
35
|
+
* Defines the function behavior. Defaults to `BLOCKING`.
|
|
36
|
+
*/
|
|
37
|
+
export const zBehavior = z.enum(["UNSPECIFIED", "BLOCKING", "NON_BLOCKING"]);
|
|
38
|
+
/**
|
|
39
|
+
* Type
|
|
40
|
+
* Optional. The type of the data.
|
|
41
|
+
*/
|
|
42
|
+
export const zType = z.enum([
|
|
43
|
+
"TYPE_UNSPECIFIED",
|
|
44
|
+
"STRING",
|
|
45
|
+
"NUMBER",
|
|
46
|
+
"INTEGER",
|
|
47
|
+
"BOOLEAN",
|
|
48
|
+
"ARRAY",
|
|
49
|
+
"OBJECT",
|
|
50
|
+
"NULL",
|
|
51
|
+
]);
|
|
52
|
+
/**
|
|
53
|
+
* Schema
|
|
54
|
+
* Schema is used to define the format of input/output data.
|
|
55
|
+
*
|
|
56
|
+
* Represents a select subset of an [OpenAPI 3.0 schema
|
|
57
|
+
* object](https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may
|
|
58
|
+
* be added in the future as needed.
|
|
59
|
+
*/
|
|
60
|
+
export const zSchemaInput = z.object({
|
|
61
|
+
additionalProperties: z.optional(z.union([z.unknown(), z.null()])),
|
|
62
|
+
defs: z.optional(z.union([
|
|
63
|
+
z.record(z.string(), z.lazy(() => {
|
|
64
|
+
return zSchemaInput;
|
|
65
|
+
})),
|
|
66
|
+
z.null(),
|
|
67
|
+
])),
|
|
68
|
+
ref: z.optional(z.union([z.string(), z.null()])),
|
|
69
|
+
anyOf: z.optional(z.union([
|
|
70
|
+
z.array(z.lazy(() => {
|
|
71
|
+
return zSchemaInput;
|
|
72
|
+
})),
|
|
73
|
+
z.null(),
|
|
74
|
+
])),
|
|
75
|
+
default: z.optional(z.union([z.unknown(), z.null()])),
|
|
76
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
77
|
+
enum: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
78
|
+
example: z.optional(z.union([z.unknown(), z.null()])),
|
|
79
|
+
format: z.optional(z.union([z.string(), z.null()])),
|
|
80
|
+
items: z.optional(z.union([
|
|
81
|
+
z.lazy(() => {
|
|
82
|
+
return zSchemaInput;
|
|
83
|
+
}),
|
|
84
|
+
z.null(),
|
|
85
|
+
])),
|
|
86
|
+
maxItems: z.optional(z.union([z.int(), z.null()])),
|
|
87
|
+
maxLength: z.optional(z.union([z.int(), z.null()])),
|
|
88
|
+
maxProperties: z.optional(z.union([z.int(), z.null()])),
|
|
89
|
+
maximum: z.optional(z.union([z.number(), z.null()])),
|
|
90
|
+
minItems: z.optional(z.union([z.int(), z.null()])),
|
|
91
|
+
minLength: z.optional(z.union([z.int(), z.null()])),
|
|
92
|
+
minProperties: z.optional(z.union([z.int(), z.null()])),
|
|
93
|
+
minimum: z.optional(z.union([z.number(), z.null()])),
|
|
94
|
+
nullable: z.optional(z.union([z.boolean(), z.null()])),
|
|
95
|
+
pattern: z.optional(z.union([z.string(), z.null()])),
|
|
96
|
+
properties: z.optional(z.union([
|
|
97
|
+
z.record(z.string(), z.lazy(() => {
|
|
98
|
+
return zSchemaInput;
|
|
99
|
+
})),
|
|
100
|
+
z.null(),
|
|
101
|
+
])),
|
|
102
|
+
propertyOrdering: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
103
|
+
required: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
104
|
+
title: z.optional(z.union([z.string(), z.null()])),
|
|
105
|
+
type: z.optional(z.union([zType, z.null()])),
|
|
106
|
+
});
|
|
107
|
+
/**
|
|
108
|
+
* FunctionDeclaration
|
|
109
|
+
* Defines a function that the model can generate JSON inputs for.
|
|
110
|
+
*
|
|
111
|
+
* The inputs are based on `OpenAPI 3.0 specifications
|
|
112
|
+
* <https://spec.openapis.org/oas/v3.0.3>`_.
|
|
113
|
+
*/
|
|
114
|
+
export const zFunctionDeclarationInput = z.object({
|
|
115
|
+
behavior: z.optional(z.union([zBehavior, z.null()])),
|
|
116
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
117
|
+
name: z.optional(z.union([z.string(), z.null()])),
|
|
118
|
+
parameters: z.optional(z.union([zSchemaInput, z.null()])),
|
|
119
|
+
parametersJsonSchema: z.optional(z.union([z.unknown(), z.null()])),
|
|
120
|
+
response: z.optional(z.union([zSchemaInput, z.null()])),
|
|
121
|
+
responseJsonSchema: z.optional(z.union([z.unknown(), z.null()])),
|
|
122
|
+
});
|
|
123
|
+
/**
|
|
124
|
+
* VertexAISearchDataStoreSpec
|
|
125
|
+
* Define data stores within engine to filter on in a search call and configurations for those data stores.
|
|
126
|
+
*
|
|
127
|
+
* For more information, see
|
|
128
|
+
* https://cloud.google.com/generative-ai-app-builder/docs/reference/rpc/google.cloud.discoveryengine.v1#datastorespec
|
|
129
|
+
*/
|
|
130
|
+
export const zVertexAiSearchDataStoreSpec = z.object({
|
|
131
|
+
dataStore: z.optional(z.union([z.string(), z.null()])),
|
|
132
|
+
filter: z.optional(z.union([z.string(), z.null()])),
|
|
133
|
+
});
|
|
134
|
+
/**
|
|
135
|
+
* VertexAISearch
|
|
136
|
+
* Retrieve from Vertex AI Search datastore or engine for grounding.
|
|
137
|
+
*
|
|
138
|
+
* datastore and engine are mutually exclusive. See
|
|
139
|
+
* https://cloud.google.com/products/agent-builder
|
|
140
|
+
*/
|
|
141
|
+
export const zVertexAiSearch = z.object({
|
|
142
|
+
dataStoreSpecs: z.optional(z.union([z.array(zVertexAiSearchDataStoreSpec), z.null()])),
|
|
143
|
+
datastore: z.optional(z.union([z.string(), z.null()])),
|
|
144
|
+
engine: z.optional(z.union([z.string(), z.null()])),
|
|
145
|
+
filter: z.optional(z.union([z.string(), z.null()])),
|
|
146
|
+
maxResults: z.optional(z.union([z.int(), z.null()])),
|
|
147
|
+
});
|
|
148
|
+
/**
|
|
149
|
+
* VertexRagStoreRagResource
|
|
150
|
+
* The definition of the Rag resource.
|
|
151
|
+
*/
|
|
152
|
+
export const zVertexRagStoreRagResource = z.object({
|
|
153
|
+
ragCorpus: z.optional(z.union([z.string(), z.null()])),
|
|
154
|
+
ragFileIds: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
155
|
+
});
|
|
156
|
+
/**
|
|
157
|
+
* RagRetrievalConfigFilter
|
|
158
|
+
* Config for filters.
|
|
159
|
+
*/
|
|
160
|
+
export const zRagRetrievalConfigFilter = z.object({
|
|
161
|
+
metadataFilter: z.optional(z.union([z.string(), z.null()])),
|
|
162
|
+
vectorDistanceThreshold: z.optional(z.union([z.number(), z.null()])),
|
|
163
|
+
vectorSimilarityThreshold: z.optional(z.union([z.number(), z.null()])),
|
|
164
|
+
});
|
|
165
|
+
/**
|
|
166
|
+
* RagRetrievalConfigHybridSearch
|
|
167
|
+
* Config for Hybrid Search.
|
|
168
|
+
*/
|
|
169
|
+
export const zRagRetrievalConfigHybridSearch = z.object({
|
|
170
|
+
alpha: z.optional(z.union([z.number(), z.null()])),
|
|
171
|
+
});
|
|
172
|
+
/**
|
|
173
|
+
* RagRetrievalConfigRankingLlmRanker
|
|
174
|
+
* Config for LlmRanker.
|
|
175
|
+
*/
|
|
176
|
+
export const zRagRetrievalConfigRankingLlmRanker = z.object({
|
|
177
|
+
modelName: z.optional(z.union([z.string(), z.null()])),
|
|
178
|
+
});
|
|
179
|
+
/**
|
|
180
|
+
* RagRetrievalConfigRankingRankService
|
|
181
|
+
* Config for Rank Service.
|
|
182
|
+
*/
|
|
183
|
+
export const zRagRetrievalConfigRankingRankService = z.object({
|
|
184
|
+
modelName: z.optional(z.union([z.string(), z.null()])),
|
|
185
|
+
});
|
|
186
|
+
/**
|
|
187
|
+
* RagRetrievalConfigRanking
|
|
188
|
+
* Config for ranking and reranking.
|
|
189
|
+
*/
|
|
190
|
+
export const zRagRetrievalConfigRanking = z.object({
|
|
191
|
+
llmRanker: z.optional(z.union([zRagRetrievalConfigRankingLlmRanker, z.null()])),
|
|
192
|
+
rankService: z.optional(z.union([zRagRetrievalConfigRankingRankService, z.null()])),
|
|
193
|
+
});
|
|
194
|
+
/**
|
|
195
|
+
* RagRetrievalConfig
|
|
196
|
+
* Specifies the context retrieval config.
|
|
197
|
+
*/
|
|
198
|
+
export const zRagRetrievalConfigInput = z.object({
|
|
199
|
+
filter: z.optional(z.union([zRagRetrievalConfigFilter, z.null()])),
|
|
200
|
+
hybridSearch: z.optional(z.union([zRagRetrievalConfigHybridSearch, z.null()])),
|
|
201
|
+
ranking: z.optional(z.union([zRagRetrievalConfigRanking, z.null()])),
|
|
202
|
+
topK: z.optional(z.union([z.int(), z.null()])),
|
|
203
|
+
});
|
|
204
|
+
/**
|
|
205
|
+
* VertexRagStore
|
|
206
|
+
* Retrieve from Vertex RAG Store for grounding.
|
|
207
|
+
*/
|
|
208
|
+
export const zVertexRagStoreInput = z.object({
|
|
209
|
+
ragCorpora: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
210
|
+
ragResources: z.optional(z.union([z.array(zVertexRagStoreRagResource), z.null()])),
|
|
211
|
+
ragRetrievalConfig: z.optional(z.union([zRagRetrievalConfigInput, z.null()])),
|
|
212
|
+
similarityTopK: z.optional(z.union([z.int(), z.null()])),
|
|
213
|
+
storeContext: z.optional(z.union([z.boolean(), z.null()])),
|
|
214
|
+
vectorDistanceThreshold: z.optional(z.union([z.number(), z.null()])),
|
|
215
|
+
});
|
|
216
|
+
/**
|
|
217
|
+
* Retrieval
|
|
218
|
+
* Defines a retrieval tool that model can call to access external knowledge.
|
|
219
|
+
*/
|
|
220
|
+
export const zRetrievalInput = z.object({
|
|
221
|
+
disableAttribution: z.optional(z.union([z.boolean(), z.null()])),
|
|
222
|
+
vertexAiSearch: z.optional(z.union([zVertexAiSearch, z.null()])),
|
|
223
|
+
vertexRagStore: z.optional(z.union([zVertexRagStoreInput, z.null()])),
|
|
224
|
+
});
|
|
225
|
+
/**
|
|
226
|
+
* Interval
|
|
227
|
+
* Represents a time interval, encoded as a start time (inclusive) and an end time (exclusive).
|
|
228
|
+
*
|
|
229
|
+
* The start time must be less than or equal to the end time.
|
|
230
|
+
* When the start equals the end time, the interval is an empty interval.
|
|
231
|
+
* (matches no time)
|
|
232
|
+
* When both start and end are unspecified, the interval matches any time.
|
|
233
|
+
*/
|
|
234
|
+
export const zIntervalInput = z.object({
|
|
235
|
+
startTime: z.optional(z.union([z.iso.datetime(), z.null()])),
|
|
236
|
+
endTime: z.optional(z.union([z.iso.datetime(), z.null()])),
|
|
237
|
+
});
|
|
238
|
+
/**
|
|
239
|
+
* GoogleSearch
|
|
240
|
+
* Tool to support Google Search in Model. Powered by Google.
|
|
241
|
+
*/
|
|
242
|
+
export const zGoogleSearchInput = z.object({
|
|
243
|
+
timeRangeFilter: z.optional(z.union([zIntervalInput, z.null()])),
|
|
244
|
+
});
|
|
245
|
+
/**
|
|
246
|
+
* DynamicRetrievalConfigMode
|
|
247
|
+
* Config for the dynamic retrieval config mode.
|
|
248
|
+
*/
|
|
249
|
+
export const zDynamicRetrievalConfigMode = z.enum([
|
|
250
|
+
"MODE_UNSPECIFIED",
|
|
251
|
+
"MODE_DYNAMIC",
|
|
252
|
+
]);
|
|
253
|
+
/**
|
|
254
|
+
* DynamicRetrievalConfig
|
|
255
|
+
* Describes the options to customize dynamic retrieval.
|
|
256
|
+
*/
|
|
257
|
+
export const zDynamicRetrievalConfig = z.object({
|
|
258
|
+
mode: z.optional(z.union([zDynamicRetrievalConfigMode, z.null()])),
|
|
259
|
+
dynamicThreshold: z.optional(z.union([z.number(), z.null()])),
|
|
260
|
+
});
|
|
261
|
+
/**
|
|
262
|
+
* GoogleSearchRetrieval
|
|
263
|
+
* Tool to retrieve public web data for grounding, powered by Google.
|
|
264
|
+
*/
|
|
265
|
+
export const zGoogleSearchRetrievalInput = z.object({
|
|
266
|
+
dynamicRetrievalConfig: z.optional(z.union([zDynamicRetrievalConfig, z.null()])),
|
|
267
|
+
});
|
|
268
|
+
/**
|
|
269
|
+
* EnterpriseWebSearch
|
|
270
|
+
* Tool to search public web data, powered by Vertex AI Search and Sec4 compliance.
|
|
271
|
+
*/
|
|
272
|
+
export const zEnterpriseWebSearch = z.record(z.string(), z.never());
|
|
33
273
|
/**
|
|
34
274
|
* ApiKeyConfig
|
|
35
275
|
* Config for authentication with API key.
|
|
36
276
|
*/
|
|
37
277
|
export const zApiKeyConfig = z.object({
|
|
38
|
-
apiKeyString: z.union([z.string(), z.null()])
|
|
278
|
+
apiKeyString: z.optional(z.union([z.string(), z.null()])),
|
|
39
279
|
});
|
|
280
|
+
/**
|
|
281
|
+
* AuthType
|
|
282
|
+
* Type of auth scheme.
|
|
283
|
+
*/
|
|
284
|
+
export const zAuthType = z.enum([
|
|
285
|
+
"AUTH_TYPE_UNSPECIFIED",
|
|
286
|
+
"NO_AUTH",
|
|
287
|
+
"API_KEY_AUTH",
|
|
288
|
+
"HTTP_BASIC_AUTH",
|
|
289
|
+
"GOOGLE_SERVICE_ACCOUNT_AUTH",
|
|
290
|
+
"OAUTH",
|
|
291
|
+
"OIDC_AUTH",
|
|
292
|
+
]);
|
|
40
293
|
/**
|
|
41
294
|
* AuthConfigGoogleServiceAccountConfig
|
|
42
295
|
* Config for Google Service Account Authentication.
|
|
43
296
|
*/
|
|
44
297
|
export const zAuthConfigGoogleServiceAccountConfig = z.object({
|
|
45
|
-
serviceAccount: z.union([z.string(), z.null()])
|
|
298
|
+
serviceAccount: z.optional(z.union([z.string(), z.null()])),
|
|
46
299
|
});
|
|
47
300
|
/**
|
|
48
301
|
* AuthConfigHttpBasicAuthConfig
|
|
49
302
|
* Config for HTTP Basic Authentication.
|
|
50
303
|
*/
|
|
51
304
|
export const zAuthConfigHttpBasicAuthConfig = z.object({
|
|
52
|
-
credentialSecret: z.union([z.string(), z.null()])
|
|
305
|
+
credentialSecret: z.optional(z.union([z.string(), z.null()])),
|
|
53
306
|
});
|
|
54
307
|
/**
|
|
55
308
|
* AuthConfigOauthConfig
|
|
56
309
|
* Config for user oauth.
|
|
57
310
|
*/
|
|
58
311
|
export const zAuthConfigOauthConfig = z.object({
|
|
59
|
-
accessToken: z.union([z.string(), z.null()])
|
|
60
|
-
serviceAccount: z.union([z.string(), z.null()])
|
|
312
|
+
accessToken: z.optional(z.union([z.string(), z.null()])),
|
|
313
|
+
serviceAccount: z.optional(z.union([z.string(), z.null()])),
|
|
61
314
|
});
|
|
62
315
|
/**
|
|
63
316
|
* AuthConfigOidcConfig
|
|
64
317
|
* Config for user OIDC auth.
|
|
65
318
|
*/
|
|
66
319
|
export const zAuthConfigOidcConfig = z.object({
|
|
67
|
-
idToken: z.union([z.string(), z.null()])
|
|
68
|
-
serviceAccount: z.union([z.string(), z.null()])
|
|
320
|
+
idToken: z.optional(z.union([z.string(), z.null()])),
|
|
321
|
+
serviceAccount: z.optional(z.union([z.string(), z.null()])),
|
|
322
|
+
});
|
|
323
|
+
/**
|
|
324
|
+
* AuthConfig
|
|
325
|
+
* Auth configuration to run the extension.
|
|
326
|
+
*/
|
|
327
|
+
export const zGoogleGenaiTypesAuthConfig = z.object({
|
|
328
|
+
apiKeyConfig: z.optional(z.union([zApiKeyConfig, z.null()])),
|
|
329
|
+
authType: z.optional(z.union([zAuthType, z.null()])),
|
|
330
|
+
googleServiceAccountConfig: z.optional(z.union([zAuthConfigGoogleServiceAccountConfig, z.null()])),
|
|
331
|
+
httpBasicAuthConfig: z.optional(z.union([zAuthConfigHttpBasicAuthConfig, z.null()])),
|
|
332
|
+
oauthConfig: z.optional(z.union([zAuthConfigOauthConfig, z.null()])),
|
|
333
|
+
oidcConfig: z.optional(z.union([zAuthConfigOidcConfig, z.null()])),
|
|
334
|
+
});
|
|
335
|
+
/**
|
|
336
|
+
* GoogleMaps
|
|
337
|
+
* Tool to support Google Maps in Model.
|
|
338
|
+
*/
|
|
339
|
+
export const zGoogleMapsInput = z.object({
|
|
340
|
+
authConfig: z.optional(z.union([zGoogleGenaiTypesAuthConfig, z.null()])),
|
|
341
|
+
});
|
|
342
|
+
/**
|
|
343
|
+
* UrlContext
|
|
344
|
+
* Tool to support URL context retrieval.
|
|
345
|
+
*/
|
|
346
|
+
export const zUrlContext = z.record(z.string(), z.never());
|
|
347
|
+
/**
|
|
348
|
+
* ToolCodeExecution
|
|
349
|
+
* Tool that executes code generated by the model, and automatically returns the result to the model.
|
|
350
|
+
*
|
|
351
|
+
* See also [ExecutableCode]and [CodeExecutionResult] which are input and output
|
|
352
|
+
* to this tool.
|
|
353
|
+
*/
|
|
354
|
+
export const zToolCodeExecution = z.record(z.string(), z.never());
|
|
355
|
+
/**
|
|
356
|
+
* Tool
|
|
357
|
+
* Tool details of a tool that the model may use to generate a response.
|
|
358
|
+
*/
|
|
359
|
+
export const zGoogleGenaiTypesToolInput = z.object({
|
|
360
|
+
functionDeclarations: z.optional(z.union([z.array(zFunctionDeclarationInput), z.null()])),
|
|
361
|
+
retrieval: z.optional(z.union([zRetrievalInput, z.null()])),
|
|
362
|
+
googleSearch: z.optional(z.union([zGoogleSearchInput, z.null()])),
|
|
363
|
+
googleSearchRetrieval: z.optional(z.union([zGoogleSearchRetrievalInput, z.null()])),
|
|
364
|
+
enterpriseWebSearch: z.optional(z.union([zEnterpriseWebSearch, z.null()])),
|
|
365
|
+
googleMaps: z.optional(z.union([zGoogleMapsInput, z.null()])),
|
|
366
|
+
urlContext: z.optional(z.union([zUrlContext, z.null()])),
|
|
367
|
+
codeExecution: z.optional(z.union([zToolCodeExecution, z.null()])),
|
|
368
|
+
});
|
|
369
|
+
/**
|
|
370
|
+
* ToolAnnotations
|
|
371
|
+
* Additional properties describing a Tool to clients.
|
|
372
|
+
*
|
|
373
|
+
* NOTE: all properties in ToolAnnotations are **hints**.
|
|
374
|
+
* They are not guaranteed to provide a faithful description of
|
|
375
|
+
* tool behavior (including descriptive properties like `title`).
|
|
376
|
+
*
|
|
377
|
+
* Clients should never make tool use decisions based on ToolAnnotations
|
|
378
|
+
* received from untrusted servers.
|
|
379
|
+
*/
|
|
380
|
+
export const zToolAnnotations = z.object({
|
|
381
|
+
title: z.optional(z.union([z.string(), z.null()])),
|
|
382
|
+
readOnlyHint: z.optional(z.union([z.boolean(), z.null()])),
|
|
383
|
+
destructiveHint: z.optional(z.union([z.boolean(), z.null()])),
|
|
384
|
+
idempotentHint: z.optional(z.union([z.boolean(), z.null()])),
|
|
385
|
+
openWorldHint: z.optional(z.union([z.boolean(), z.null()])),
|
|
386
|
+
});
|
|
387
|
+
/**
|
|
388
|
+
* Tool
|
|
389
|
+
* Definition for a tool the client can call.
|
|
390
|
+
*/
|
|
391
|
+
export const zMcpTypesTool = z.object({
|
|
392
|
+
name: z.string(),
|
|
393
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
394
|
+
inputSchema: z.record(z.string(), z.unknown()),
|
|
395
|
+
annotations: z.optional(z.union([zToolAnnotations, z.null()])),
|
|
396
|
+
});
|
|
397
|
+
/**
|
|
398
|
+
* AgentDetails
|
|
399
|
+
* Details about the individual agent in the App.
|
|
400
|
+
*
|
|
401
|
+
* This could be a root agent or the sub-agents in the Agent Tree.
|
|
402
|
+
*/
|
|
403
|
+
export const zAgentDetailsInput = z.object({
|
|
404
|
+
name: z.string(),
|
|
405
|
+
instructions: z.optional(z.string()).default(""),
|
|
406
|
+
toolDeclarations: z.optional(z.array(z.union([zGoogleGenaiTypesToolInput, zMcpTypesTool]))),
|
|
407
|
+
});
|
|
408
|
+
/**
|
|
409
|
+
* Schema
|
|
410
|
+
* Schema is used to define the format of input/output data.
|
|
411
|
+
*
|
|
412
|
+
* Represents a select subset of an [OpenAPI 3.0 schema
|
|
413
|
+
* object](https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may
|
|
414
|
+
* be added in the future as needed.
|
|
415
|
+
*/
|
|
416
|
+
export const zSchemaOutput = z.object({
|
|
417
|
+
additionalProperties: z.optional(z.union([z.unknown(), z.null()])),
|
|
418
|
+
defs: z.optional(z.union([
|
|
419
|
+
z.record(z.string(), z.lazy(() => {
|
|
420
|
+
return zSchemaOutput;
|
|
421
|
+
})),
|
|
422
|
+
z.null(),
|
|
423
|
+
])),
|
|
424
|
+
ref: z.optional(z.union([z.string(), z.null()])),
|
|
425
|
+
anyOf: z.optional(z.union([
|
|
426
|
+
z.array(z.lazy(() => {
|
|
427
|
+
return zSchemaOutput;
|
|
428
|
+
})),
|
|
429
|
+
z.null(),
|
|
430
|
+
])),
|
|
431
|
+
default: z.optional(z.union([z.unknown(), z.null()])),
|
|
432
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
433
|
+
enum: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
434
|
+
example: z.optional(z.union([z.unknown(), z.null()])),
|
|
435
|
+
format: z.optional(z.union([z.string(), z.null()])),
|
|
436
|
+
items: z.optional(z.union([
|
|
437
|
+
z.lazy(() => {
|
|
438
|
+
return zSchemaOutput;
|
|
439
|
+
}),
|
|
440
|
+
z.null(),
|
|
441
|
+
])),
|
|
442
|
+
maxItems: z.optional(z.union([z.int(), z.null()])),
|
|
443
|
+
maxLength: z.optional(z.union([z.int(), z.null()])),
|
|
444
|
+
maxProperties: z.optional(z.union([z.int(), z.null()])),
|
|
445
|
+
maximum: z.optional(z.union([z.number(), z.null()])),
|
|
446
|
+
minItems: z.optional(z.union([z.int(), z.null()])),
|
|
447
|
+
minLength: z.optional(z.union([z.int(), z.null()])),
|
|
448
|
+
minProperties: z.optional(z.union([z.int(), z.null()])),
|
|
449
|
+
minimum: z.optional(z.union([z.number(), z.null()])),
|
|
450
|
+
nullable: z.optional(z.union([z.boolean(), z.null()])),
|
|
451
|
+
pattern: z.optional(z.union([z.string(), z.null()])),
|
|
452
|
+
properties: z.optional(z.union([
|
|
453
|
+
z.record(z.string(), z.lazy(() => {
|
|
454
|
+
return zSchemaOutput;
|
|
455
|
+
})),
|
|
456
|
+
z.null(),
|
|
457
|
+
])),
|
|
458
|
+
propertyOrdering: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
459
|
+
required: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
460
|
+
title: z.optional(z.union([z.string(), z.null()])),
|
|
461
|
+
type: z.optional(z.union([zType, z.null()])),
|
|
462
|
+
});
|
|
463
|
+
/**
|
|
464
|
+
* FunctionDeclaration
|
|
465
|
+
* Defines a function that the model can generate JSON inputs for.
|
|
466
|
+
*
|
|
467
|
+
* The inputs are based on `OpenAPI 3.0 specifications
|
|
468
|
+
* <https://spec.openapis.org/oas/v3.0.3>`_.
|
|
469
|
+
*/
|
|
470
|
+
export const zFunctionDeclarationOutput = z.object({
|
|
471
|
+
behavior: z.optional(z.union([zBehavior, z.null()])),
|
|
472
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
473
|
+
name: z.optional(z.union([z.string(), z.null()])),
|
|
474
|
+
parameters: z.optional(z.union([zSchemaOutput, z.null()])),
|
|
475
|
+
parametersJsonSchema: z.optional(z.union([z.unknown(), z.null()])),
|
|
476
|
+
response: z.optional(z.union([zSchemaOutput, z.null()])),
|
|
477
|
+
responseJsonSchema: z.optional(z.union([z.unknown(), z.null()])),
|
|
478
|
+
});
|
|
479
|
+
/**
|
|
480
|
+
* RagRetrievalConfig
|
|
481
|
+
* Specifies the context retrieval config.
|
|
482
|
+
*/
|
|
483
|
+
export const zRagRetrievalConfigOutput = z.object({
|
|
484
|
+
filter: z.optional(z.union([zRagRetrievalConfigFilter, z.null()])),
|
|
485
|
+
hybridSearch: z.optional(z.union([zRagRetrievalConfigHybridSearch, z.null()])),
|
|
486
|
+
ranking: z.optional(z.union([zRagRetrievalConfigRanking, z.null()])),
|
|
487
|
+
topK: z.optional(z.union([z.int(), z.null()])),
|
|
488
|
+
});
|
|
489
|
+
/**
|
|
490
|
+
* VertexRagStore
|
|
491
|
+
* Retrieve from Vertex RAG Store for grounding.
|
|
492
|
+
*/
|
|
493
|
+
export const zVertexRagStoreOutput = z.object({
|
|
494
|
+
ragCorpora: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
495
|
+
ragResources: z.optional(z.union([z.array(zVertexRagStoreRagResource), z.null()])),
|
|
496
|
+
ragRetrievalConfig: z.optional(z.union([zRagRetrievalConfigOutput, z.null()])),
|
|
497
|
+
similarityTopK: z.optional(z.union([z.int(), z.null()])),
|
|
498
|
+
storeContext: z.optional(z.union([z.boolean(), z.null()])),
|
|
499
|
+
vectorDistanceThreshold: z.optional(z.union([z.number(), z.null()])),
|
|
500
|
+
});
|
|
501
|
+
/**
|
|
502
|
+
* Retrieval
|
|
503
|
+
* Defines a retrieval tool that model can call to access external knowledge.
|
|
504
|
+
*/
|
|
505
|
+
export const zRetrievalOutput = z.object({
|
|
506
|
+
disableAttribution: z.optional(z.union([z.boolean(), z.null()])),
|
|
507
|
+
vertexAiSearch: z.optional(z.union([zVertexAiSearch, z.null()])),
|
|
508
|
+
vertexRagStore: z.optional(z.union([zVertexRagStoreOutput, z.null()])),
|
|
509
|
+
});
|
|
510
|
+
/**
|
|
511
|
+
* Interval
|
|
512
|
+
* Represents a time interval, encoded as a start time (inclusive) and an end time (exclusive).
|
|
513
|
+
*
|
|
514
|
+
* The start time must be less than or equal to the end time.
|
|
515
|
+
* When the start equals the end time, the interval is an empty interval.
|
|
516
|
+
* (matches no time)
|
|
517
|
+
* When both start and end are unspecified, the interval matches any time.
|
|
518
|
+
*/
|
|
519
|
+
export const zGoogleGenaiTypesInterval = z.object({
|
|
520
|
+
startTime: z.optional(z.union([z.iso.datetime(), z.null()])),
|
|
521
|
+
endTime: z.optional(z.union([z.iso.datetime(), z.null()])),
|
|
522
|
+
});
|
|
523
|
+
/**
|
|
524
|
+
* GoogleSearch
|
|
525
|
+
* Tool to support Google Search in Model. Powered by Google.
|
|
526
|
+
*/
|
|
527
|
+
export const zGoogleSearchOutput = z.object({
|
|
528
|
+
timeRangeFilter: z.optional(z.union([zGoogleGenaiTypesInterval, z.null()])),
|
|
529
|
+
});
|
|
530
|
+
/**
|
|
531
|
+
* GoogleSearchRetrieval
|
|
532
|
+
* Tool to retrieve public web data for grounding, powered by Google.
|
|
533
|
+
*/
|
|
534
|
+
export const zGoogleSearchRetrievalOutput = z.object({
|
|
535
|
+
dynamicRetrievalConfig: z.optional(z.union([zDynamicRetrievalConfig, z.null()])),
|
|
536
|
+
});
|
|
537
|
+
/**
|
|
538
|
+
* GoogleMaps
|
|
539
|
+
* Tool to support Google Maps in Model.
|
|
540
|
+
*/
|
|
541
|
+
export const zGoogleMapsOutput = z.object({
|
|
542
|
+
authConfig: z.optional(z.union([zGoogleGenaiTypesAuthConfig, z.null()])),
|
|
543
|
+
});
|
|
544
|
+
/**
|
|
545
|
+
* Tool
|
|
546
|
+
* Tool details of a tool that the model may use to generate a response.
|
|
547
|
+
*/
|
|
548
|
+
export const zGoogleGenaiTypesToolOutput = z.object({
|
|
549
|
+
functionDeclarations: z.optional(z.union([z.array(zFunctionDeclarationOutput), z.null()])),
|
|
550
|
+
retrieval: z.optional(z.union([zRetrievalOutput, z.null()])),
|
|
551
|
+
googleSearch: z.optional(z.union([zGoogleSearchOutput, z.null()])),
|
|
552
|
+
googleSearchRetrieval: z.optional(z.union([zGoogleSearchRetrievalOutput, z.null()])),
|
|
553
|
+
enterpriseWebSearch: z.optional(z.union([zEnterpriseWebSearch, z.null()])),
|
|
554
|
+
googleMaps: z.optional(z.union([zGoogleMapsOutput, z.null()])),
|
|
555
|
+
urlContext: z.optional(z.union([zUrlContext, z.null()])),
|
|
556
|
+
codeExecution: z.optional(z.union([zToolCodeExecution, z.null()])),
|
|
557
|
+
});
|
|
558
|
+
/**
|
|
559
|
+
* AgentDetails
|
|
560
|
+
* Details about the individual agent in the App.
|
|
561
|
+
*
|
|
562
|
+
* This could be a root agent or the sub-agents in the Agent Tree.
|
|
563
|
+
*/
|
|
564
|
+
export const zAgentDetailsOutput = z.object({
|
|
565
|
+
name: z.string(),
|
|
566
|
+
instructions: z.optional(z.string()).default(""),
|
|
567
|
+
toolDeclarations: z.optional(z.array(z.union([zGoogleGenaiTypesToolOutput, zMcpTypesTool]))),
|
|
568
|
+
});
|
|
569
|
+
/**
|
|
570
|
+
* AppDetails
|
|
571
|
+
* Contains details about the App (the agentic system).
|
|
572
|
+
*
|
|
573
|
+
* This structure is only a projection of the acutal app. Only details
|
|
574
|
+
* that are relevant to the Eval System are captured here.
|
|
575
|
+
*/
|
|
576
|
+
export const zAppDetailsInput = z.object({
|
|
577
|
+
agentDetails: z.optional(z.record(z.string(), zAgentDetailsInput)),
|
|
578
|
+
});
|
|
579
|
+
/**
|
|
580
|
+
* AppDetails
|
|
581
|
+
* Contains details about the App (the agentic system).
|
|
582
|
+
*
|
|
583
|
+
* This structure is only a projection of the acutal app. Only details
|
|
584
|
+
* that are relevant to the Eval System are captured here.
|
|
585
|
+
*/
|
|
586
|
+
export const zAppDetailsOutput = z.object({
|
|
587
|
+
agentDetails: z.optional(z.record(z.string(), zAgentDetailsOutput)),
|
|
69
588
|
});
|
|
70
589
|
/**
|
|
71
590
|
* AuthCredentialTypes
|
|
@@ -83,9 +602,9 @@ export const zAuthCredentialTypes = z.enum([
|
|
|
83
602
|
* Represents the secret token value for HTTP authentication, like user name, password, oauth token, etc.
|
|
84
603
|
*/
|
|
85
604
|
export const zHttpCredentials = z.object({
|
|
86
|
-
username: z.union([z.string(), z.null()])
|
|
87
|
-
password: z.union([z.string(), z.null()])
|
|
88
|
-
token: z.union([z.string(), z.null()])
|
|
605
|
+
username: z.optional(z.union([z.string(), z.null()])),
|
|
606
|
+
password: z.optional(z.union([z.string(), z.null()])),
|
|
607
|
+
token: z.optional(z.union([z.string(), z.null()])),
|
|
89
608
|
});
|
|
90
609
|
/**
|
|
91
610
|
* HttpAuth
|
|
@@ -134,7 +653,7 @@ export const zHttpAuth = z.object({
|
|
|
134
653
|
* })
|
|
135
654
|
*/
|
|
136
655
|
export const zServiceAccountCredential = z.object({
|
|
137
|
-
type: z.
|
|
656
|
+
type: z.optional(z.string()).default(""),
|
|
138
657
|
projectId: z.string(),
|
|
139
658
|
privateKeyId: z.string(),
|
|
140
659
|
privateKey: z.string(),
|
|
@@ -151,29 +670,27 @@ export const zServiceAccountCredential = z.object({
|
|
|
151
670
|
* Represents Google Service Account configuration.
|
|
152
671
|
*/
|
|
153
672
|
export const zServiceAccount = z.object({
|
|
154
|
-
serviceAccountCredential: z
|
|
155
|
-
.union([zServiceAccountCredential, z.null()])
|
|
156
|
-
.optional(),
|
|
673
|
+
serviceAccountCredential: z.optional(z.union([zServiceAccountCredential, z.null()])),
|
|
157
674
|
scopes: z.array(z.string()),
|
|
158
|
-
useDefaultCredential: z.union([z.boolean(), z.null()])
|
|
675
|
+
useDefaultCredential: z.optional(z.union([z.boolean(), z.null()])),
|
|
159
676
|
});
|
|
160
677
|
/**
|
|
161
678
|
* OAuth2Auth
|
|
162
679
|
* Represents credential value and its metadata for a OAuth2 credential.
|
|
163
680
|
*/
|
|
164
681
|
export const zOAuth2Auth = z.object({
|
|
165
|
-
clientId: z.union([z.string(), z.null()])
|
|
166
|
-
clientSecret: z.union([z.string(), z.null()])
|
|
167
|
-
authUri: z.union([z.string(), z.null()])
|
|
168
|
-
state: z.union([z.string(), z.null()])
|
|
169
|
-
redirectUri: z.union([z.string(), z.null()])
|
|
170
|
-
authResponseUri: z.union([z.string(), z.null()])
|
|
171
|
-
authCode: z.union([z.string(), z.null()])
|
|
172
|
-
accessToken: z.union([z.string(), z.null()])
|
|
173
|
-
refreshToken: z.union([z.string(), z.null()])
|
|
174
|
-
expiresAt: z.union([z.
|
|
175
|
-
expiresIn: z.union([z.
|
|
176
|
-
audience: z.union([z.string(), z.null()])
|
|
682
|
+
clientId: z.optional(z.union([z.string(), z.null()])),
|
|
683
|
+
clientSecret: z.optional(z.union([z.string(), z.null()])),
|
|
684
|
+
authUri: z.optional(z.union([z.string(), z.null()])),
|
|
685
|
+
state: z.optional(z.union([z.string(), z.null()])),
|
|
686
|
+
redirectUri: z.optional(z.union([z.string(), z.null()])),
|
|
687
|
+
authResponseUri: z.optional(z.union([z.string(), z.null()])),
|
|
688
|
+
authCode: z.optional(z.union([z.string(), z.null()])),
|
|
689
|
+
accessToken: z.optional(z.union([z.string(), z.null()])),
|
|
690
|
+
refreshToken: z.optional(z.union([z.string(), z.null()])),
|
|
691
|
+
expiresAt: z.optional(z.union([z.int(), z.null()])),
|
|
692
|
+
expiresIn: z.optional(z.union([z.int(), z.null()])),
|
|
693
|
+
audience: z.optional(z.union([z.string(), z.null()])),
|
|
177
694
|
});
|
|
178
695
|
/**
|
|
179
696
|
* AuthCredential
|
|
@@ -234,11 +751,11 @@ export const zOAuth2Auth = z.object({
|
|
|
234
751
|
*/
|
|
235
752
|
export const zAuthCredentialInput = z.object({
|
|
236
753
|
authType: zAuthCredentialTypes,
|
|
237
|
-
resourceRef: z.union([z.string(), z.null()])
|
|
238
|
-
apiKey: z.union([z.string(), z.null()])
|
|
239
|
-
http: z.union([zHttpAuth, z.null()])
|
|
240
|
-
serviceAccount: z.union([zServiceAccount, z.null()])
|
|
241
|
-
oauth2: z.union([zOAuth2Auth, z.null()])
|
|
754
|
+
resourceRef: z.optional(z.union([z.string(), z.null()])),
|
|
755
|
+
apiKey: z.optional(z.union([z.string(), z.null()])),
|
|
756
|
+
http: z.optional(z.union([zHttpAuth, z.null()])),
|
|
757
|
+
serviceAccount: z.optional(z.union([zServiceAccount, z.null()])),
|
|
758
|
+
oauth2: z.optional(z.union([zOAuth2Auth, z.null()])),
|
|
242
759
|
});
|
|
243
760
|
/**
|
|
244
761
|
* AuthCredential
|
|
@@ -299,33 +816,20 @@ export const zAuthCredentialInput = z.object({
|
|
|
299
816
|
*/
|
|
300
817
|
export const zAuthCredentialOutput = z.object({
|
|
301
818
|
authType: zAuthCredentialTypes,
|
|
302
|
-
resourceRef: z.union([z.string(), z.null()])
|
|
303
|
-
apiKey: z.union([z.string(), z.null()])
|
|
304
|
-
http: z.union([zHttpAuth, z.null()])
|
|
305
|
-
serviceAccount: z.union([zServiceAccount, z.null()])
|
|
306
|
-
oauth2: z.union([zOAuth2Auth, z.null()])
|
|
819
|
+
resourceRef: z.optional(z.union([z.string(), z.null()])),
|
|
820
|
+
apiKey: z.optional(z.union([z.string(), z.null()])),
|
|
821
|
+
http: z.optional(z.union([zHttpAuth, z.null()])),
|
|
822
|
+
serviceAccount: z.optional(z.union([zServiceAccount, z.null()])),
|
|
823
|
+
oauth2: z.optional(z.union([zOAuth2Auth, z.null()])),
|
|
307
824
|
});
|
|
308
|
-
/**
|
|
309
|
-
* AuthType
|
|
310
|
-
* Type of auth scheme.
|
|
311
|
-
*/
|
|
312
|
-
export const zAuthType = z.enum([
|
|
313
|
-
"AUTH_TYPE_UNSPECIFIED",
|
|
314
|
-
"NO_AUTH",
|
|
315
|
-
"API_KEY_AUTH",
|
|
316
|
-
"HTTP_BASIC_AUTH",
|
|
317
|
-
"GOOGLE_SERVICE_ACCOUNT_AUTH",
|
|
318
|
-
"OAUTH",
|
|
319
|
-
"OIDC_AUTH",
|
|
320
|
-
]);
|
|
321
825
|
/**
|
|
322
826
|
* AutomaticFunctionCallingConfig
|
|
323
827
|
* The configuration for automatic function calling.
|
|
324
828
|
*/
|
|
325
829
|
export const zAutomaticFunctionCallingConfig = z.object({
|
|
326
|
-
disable: z.union([z.boolean(), z.null()])
|
|
327
|
-
maximumRemoteCalls: z.union([z.
|
|
328
|
-
ignoreCallHistory: z.union([z.boolean(), z.null()])
|
|
830
|
+
disable: z.optional(z.union([z.boolean(), z.null()])),
|
|
831
|
+
maximumRemoteCalls: z.optional(z.union([z.int(), z.null()])),
|
|
832
|
+
ignoreCallHistory: z.optional(z.union([z.boolean(), z.null()])),
|
|
329
833
|
});
|
|
330
834
|
/**
|
|
331
835
|
* BaseCriterion
|
|
@@ -334,19 +838,14 @@ export const zAutomaticFunctionCallingConfig = z.object({
|
|
|
334
838
|
export const zBaseCriterion = z.object({
|
|
335
839
|
threshold: z.number(),
|
|
336
840
|
});
|
|
337
|
-
/**
|
|
338
|
-
* Behavior
|
|
339
|
-
* Defines the function behavior. Defaults to `BLOCKING`.
|
|
340
|
-
*/
|
|
341
|
-
export const zBehavior = z.enum(["UNSPECIFIED", "BLOCKING", "NON_BLOCKING"]);
|
|
342
841
|
/**
|
|
343
842
|
* Blob
|
|
344
843
|
* Content blob.
|
|
345
844
|
*/
|
|
346
845
|
export const zBlob = z.object({
|
|
347
|
-
displayName: z.union([z.string(), z.null()])
|
|
348
|
-
data: z.union([z.string(), z.null()])
|
|
349
|
-
mimeType: z.union([z.string(), z.null()])
|
|
846
|
+
displayName: z.optional(z.union([z.string(), z.null()])),
|
|
847
|
+
data: z.optional(z.union([z.string(), z.null()])),
|
|
848
|
+
mimeType: z.optional(z.union([z.string(), z.null()])),
|
|
350
849
|
});
|
|
351
850
|
/**
|
|
352
851
|
* Body_builder_build
|
|
@@ -354,19 +853,45 @@ export const zBlob = z.object({
|
|
|
354
853
|
export const zBodyBuilderBuild = z.object({
|
|
355
854
|
files: z.array(z.string()),
|
|
356
855
|
});
|
|
856
|
+
/**
|
|
857
|
+
* CacheMetadata
|
|
858
|
+
* Metadata for context cache associated with LLM responses.
|
|
859
|
+
*
|
|
860
|
+
* This class stores cache identification, usage tracking, and lifecycle
|
|
861
|
+
* information for a particular cache instance.
|
|
862
|
+
*
|
|
863
|
+
* Token counts (cached and total) are available in the LlmResponse.usage_metadata
|
|
864
|
+
* and should be accessed from there to avoid duplication.
|
|
865
|
+
*
|
|
866
|
+
* Attributes:
|
|
867
|
+
* cache_name: The full resource name of the cached content (e.g.,
|
|
868
|
+
* 'projects/123/locations/us-central1/cachedContents/456')
|
|
869
|
+
* expire_time: Unix timestamp when the cache expires
|
|
870
|
+
* fingerprint: Hash of agent configuration (instruction + tools + model)
|
|
871
|
+
* invocations_used: Number of invocations this cache has been used for
|
|
872
|
+
* cached_contents_count: Number of contents stored in this cache
|
|
873
|
+
* created_at: Unix timestamp when the cache was created
|
|
874
|
+
*/
|
|
875
|
+
export const zCacheMetadata = z.object({
|
|
876
|
+
cache_name: z.string(),
|
|
877
|
+
expire_time: z.number(),
|
|
878
|
+
fingerprint: z.string(),
|
|
879
|
+
invocations_used: z.int().gte(0),
|
|
880
|
+
cached_contents_count: z.int().gte(0),
|
|
881
|
+
created_at: z.optional(z.union([z.number(), z.null()])),
|
|
882
|
+
});
|
|
357
883
|
/**
|
|
358
884
|
* ChatConfig
|
|
359
885
|
* 聊天配置
|
|
360
886
|
*/
|
|
361
887
|
export const zChatConfig = z.object({
|
|
362
|
-
provider: z.
|
|
363
|
-
model_name: z.
|
|
364
|
-
api_key: z.union([z.string(), z.null()])
|
|
365
|
-
base_url: z.union([z.string(), z.null()])
|
|
366
|
-
max_turns: z.
|
|
888
|
+
provider: z.optional(z.string()).default("openai"),
|
|
889
|
+
model_name: z.optional(z.string()).default("gpt-4o-mini"),
|
|
890
|
+
api_key: z.optional(z.union([z.string(), z.null()])),
|
|
891
|
+
base_url: z.optional(z.union([z.string(), z.null()])),
|
|
892
|
+
max_turns: z.optional(z.int()).default(10),
|
|
367
893
|
system_message: z
|
|
368
|
-
.string()
|
|
369
|
-
.optional()
|
|
894
|
+
.optional(z.string())
|
|
370
895
|
.default("你是一个有用的AI助手,可以回答各种问题并提供帮助。"),
|
|
371
896
|
});
|
|
372
897
|
/**
|
|
@@ -375,7 +900,7 @@ export const zChatConfig = z.object({
|
|
|
375
900
|
*/
|
|
376
901
|
export const zChatRequest = z.object({
|
|
377
902
|
message: z.string(),
|
|
378
|
-
config: z.union([zChatConfig, z.null()])
|
|
903
|
+
config: z.optional(z.union([zChatConfig, z.null()])),
|
|
379
904
|
});
|
|
380
905
|
/**
|
|
381
906
|
* ChatResponse
|
|
@@ -383,8 +908,8 @@ export const zChatRequest = z.object({
|
|
|
383
908
|
*/
|
|
384
909
|
export const zChatResponse = z.object({
|
|
385
910
|
message: z.string(),
|
|
386
|
-
success: z.
|
|
387
|
-
error: z.union([z.string(), z.null()])
|
|
911
|
+
success: z.optional(z.boolean()).default(true),
|
|
912
|
+
error: z.optional(z.union([z.string(), z.null()])),
|
|
388
913
|
});
|
|
389
914
|
/**
|
|
390
915
|
* CheckSandboxStatusRequest
|
|
@@ -399,14 +924,14 @@ export const zCheckSandboxStatusRequest = z.object({
|
|
|
399
924
|
export const zSandboxStatusInfo = z.object({
|
|
400
925
|
sandboxId: z.string(),
|
|
401
926
|
status: z.string(),
|
|
402
|
-
error: z.union([z.string(), z.null()])
|
|
927
|
+
error: z.optional(z.union([z.string(), z.null()])),
|
|
403
928
|
});
|
|
404
929
|
/**
|
|
405
930
|
* CheckSandboxStatusResponse
|
|
406
931
|
*/
|
|
407
932
|
export const zCheckSandboxStatusResponse = z.object({
|
|
408
|
-
results: z.array(zSandboxStatusInfo)
|
|
409
|
-
total_checked: z.
|
|
933
|
+
results: z.optional(z.array(zSandboxStatusInfo)),
|
|
934
|
+
total_checked: z.int(),
|
|
410
935
|
});
|
|
411
936
|
/**
|
|
412
937
|
* Outcome
|
|
@@ -425,26 +950,26 @@ export const zOutcome = z.enum([
|
|
|
425
950
|
* Always follows a `part` containing the [ExecutableCode].
|
|
426
951
|
*/
|
|
427
952
|
export const zCodeExecutionResult = z.object({
|
|
428
|
-
outcome: z.union([zOutcome, z.null()])
|
|
429
|
-
output: z.union([z.string(), z.null()])
|
|
953
|
+
outcome: z.optional(z.union([zOutcome, z.null()])),
|
|
954
|
+
output: z.optional(z.union([z.string(), z.null()])),
|
|
430
955
|
});
|
|
431
956
|
/**
|
|
432
957
|
* VideoMetadata
|
|
433
958
|
* Describes how the video in the Part should be used by the model.
|
|
434
959
|
*/
|
|
435
960
|
export const zVideoMetadata = z.object({
|
|
436
|
-
fps: z.union([z.number(), z.null()])
|
|
437
|
-
endOffset: z.union([z.string(), z.null()])
|
|
438
|
-
startOffset: z.union([z.string(), z.null()])
|
|
961
|
+
fps: z.optional(z.union([z.number(), z.null()])),
|
|
962
|
+
endOffset: z.optional(z.union([z.string(), z.null()])),
|
|
963
|
+
startOffset: z.optional(z.union([z.string(), z.null()])),
|
|
439
964
|
});
|
|
440
965
|
/**
|
|
441
966
|
* FileData
|
|
442
967
|
* URI based data.
|
|
443
968
|
*/
|
|
444
969
|
export const zFileData = z.object({
|
|
445
|
-
displayName: z.union([z.string(), z.null()])
|
|
446
|
-
fileUri: z.union([z.string(), z.null()])
|
|
447
|
-
mimeType: z.union([z.string(), z.null()])
|
|
970
|
+
displayName: z.optional(z.union([z.string(), z.null()])),
|
|
971
|
+
fileUri: z.optional(z.union([z.string(), z.null()])),
|
|
972
|
+
mimeType: z.optional(z.union([z.string(), z.null()])),
|
|
448
973
|
});
|
|
449
974
|
/**
|
|
450
975
|
* Language
|
|
@@ -459,17 +984,17 @@ export const zLanguage = z.enum(["LANGUAGE_UNSPECIFIED", "PYTHON"]);
|
|
|
459
984
|
* [FunctionCallingConfig] mode is set to [Mode.CODE].
|
|
460
985
|
*/
|
|
461
986
|
export const zExecutableCode = z.object({
|
|
462
|
-
code: z.union([z.string(), z.null()])
|
|
463
|
-
language: z.union([zLanguage, z.null()])
|
|
987
|
+
code: z.optional(z.union([z.string(), z.null()])),
|
|
988
|
+
language: z.optional(z.union([zLanguage, z.null()])),
|
|
464
989
|
});
|
|
465
990
|
/**
|
|
466
991
|
* FunctionCall
|
|
467
992
|
* A function call.
|
|
468
993
|
*/
|
|
469
994
|
export const zFunctionCall = z.object({
|
|
470
|
-
id: z.union([z.string(), z.null()])
|
|
471
|
-
args: z.union([z.
|
|
472
|
-
name: z.union([z.string(), z.null()])
|
|
995
|
+
id: z.optional(z.union([z.string(), z.null()])),
|
|
996
|
+
args: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
997
|
+
name: z.optional(z.union([z.string(), z.null()])),
|
|
473
998
|
});
|
|
474
999
|
/**
|
|
475
1000
|
* FunctionResponseScheduling
|
|
@@ -486,11 +1011,11 @@ export const zFunctionResponseScheduling = z.enum([
|
|
|
486
1011
|
* A function response.
|
|
487
1012
|
*/
|
|
488
1013
|
export const zFunctionResponse = z.object({
|
|
489
|
-
willContinue: z.union([z.boolean(), z.null()])
|
|
490
|
-
scheduling: z.union([zFunctionResponseScheduling, z.null()])
|
|
491
|
-
id: z.union([z.string(), z.null()])
|
|
492
|
-
name: z.union([z.string(), z.null()])
|
|
493
|
-
response: z.union([z.
|
|
1014
|
+
willContinue: z.optional(z.union([z.boolean(), z.null()])),
|
|
1015
|
+
scheduling: z.optional(z.union([zFunctionResponseScheduling, z.null()])),
|
|
1016
|
+
id: z.optional(z.union([z.string(), z.null()])),
|
|
1017
|
+
name: z.optional(z.union([z.string(), z.null()])),
|
|
1018
|
+
response: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
494
1019
|
});
|
|
495
1020
|
/**
|
|
496
1021
|
* Part
|
|
@@ -501,24 +1026,24 @@ export const zFunctionResponse = z.object({
|
|
|
501
1026
|
* instance is considered invalid.
|
|
502
1027
|
*/
|
|
503
1028
|
export const zPartInput = z.object({
|
|
504
|
-
videoMetadata: z.union([zVideoMetadata, z.null()])
|
|
505
|
-
thought: z.union([z.boolean(), z.null()])
|
|
506
|
-
inlineData: z.union([zBlob, z.null()])
|
|
507
|
-
fileData: z.union([zFileData, z.null()])
|
|
508
|
-
thoughtSignature: z.union([z.string(), z.null()])
|
|
509
|
-
codeExecutionResult: z.union([zCodeExecutionResult, z.null()])
|
|
510
|
-
executableCode: z.union([zExecutableCode, z.null()])
|
|
511
|
-
functionCall: z.union([zFunctionCall, z.null()])
|
|
512
|
-
functionResponse: z.union([zFunctionResponse, z.null()])
|
|
513
|
-
text: z.union([z.string(), z.null()])
|
|
1029
|
+
videoMetadata: z.optional(z.union([zVideoMetadata, z.null()])),
|
|
1030
|
+
thought: z.optional(z.union([z.boolean(), z.null()])),
|
|
1031
|
+
inlineData: z.optional(z.union([zBlob, z.null()])),
|
|
1032
|
+
fileData: z.optional(z.union([zFileData, z.null()])),
|
|
1033
|
+
thoughtSignature: z.optional(z.union([z.string(), z.null()])),
|
|
1034
|
+
codeExecutionResult: z.optional(z.union([zCodeExecutionResult, z.null()])),
|
|
1035
|
+
executableCode: z.optional(z.union([zExecutableCode, z.null()])),
|
|
1036
|
+
functionCall: z.optional(z.union([zFunctionCall, z.null()])),
|
|
1037
|
+
functionResponse: z.optional(z.union([zFunctionResponse, z.null()])),
|
|
1038
|
+
text: z.optional(z.union([z.string(), z.null()])),
|
|
514
1039
|
});
|
|
515
1040
|
/**
|
|
516
1041
|
* Content
|
|
517
1042
|
* Contains the multi-part content of a message.
|
|
518
1043
|
*/
|
|
519
1044
|
export const zContentInput = z.object({
|
|
520
|
-
parts: z.union([z.array(zPartInput), z.null()])
|
|
521
|
-
role: z.union([z.string(), z.null()])
|
|
1045
|
+
parts: z.optional(z.union([z.array(zPartInput), z.null()])),
|
|
1046
|
+
role: z.optional(z.union([z.string(), z.null()])),
|
|
522
1047
|
});
|
|
523
1048
|
/**
|
|
524
1049
|
* Part
|
|
@@ -529,37 +1054,57 @@ export const zContentInput = z.object({
|
|
|
529
1054
|
* instance is considered invalid.
|
|
530
1055
|
*/
|
|
531
1056
|
export const zPartOutput = z.object({
|
|
532
|
-
videoMetadata: z.union([zVideoMetadata, z.null()])
|
|
533
|
-
thought: z.union([z.boolean(), z.null()])
|
|
534
|
-
inlineData: z.union([zBlob, z.null()])
|
|
535
|
-
fileData: z.union([zFileData, z.null()])
|
|
536
|
-
thoughtSignature: z.union([z.string(), z.null()])
|
|
537
|
-
codeExecutionResult: z.union([zCodeExecutionResult, z.null()])
|
|
538
|
-
executableCode: z.union([zExecutableCode, z.null()])
|
|
539
|
-
functionCall: z.union([zFunctionCall, z.null()])
|
|
540
|
-
functionResponse: z.union([zFunctionResponse, z.null()])
|
|
541
|
-
text: z.union([z.string(), z.null()])
|
|
1057
|
+
videoMetadata: z.optional(z.union([zVideoMetadata, z.null()])),
|
|
1058
|
+
thought: z.optional(z.union([z.boolean(), z.null()])),
|
|
1059
|
+
inlineData: z.optional(z.union([zBlob, z.null()])),
|
|
1060
|
+
fileData: z.optional(z.union([zFileData, z.null()])),
|
|
1061
|
+
thoughtSignature: z.optional(z.union([z.string(), z.null()])),
|
|
1062
|
+
codeExecutionResult: z.optional(z.union([zCodeExecutionResult, z.null()])),
|
|
1063
|
+
executableCode: z.optional(z.union([zExecutableCode, z.null()])),
|
|
1064
|
+
functionCall: z.optional(z.union([zFunctionCall, z.null()])),
|
|
1065
|
+
functionResponse: z.optional(z.union([zFunctionResponse, z.null()])),
|
|
1066
|
+
text: z.optional(z.union([z.string(), z.null()])),
|
|
542
1067
|
});
|
|
543
1068
|
/**
|
|
544
1069
|
* Content
|
|
545
1070
|
* Contains the multi-part content of a message.
|
|
546
1071
|
*/
|
|
547
1072
|
export const zContentOutput = z.object({
|
|
548
|
-
parts: z.union([z.array(zPartOutput), z.null()])
|
|
549
|
-
role: z.union([z.string(), z.null()])
|
|
1073
|
+
parts: z.optional(z.union([z.array(zPartOutput), z.null()])),
|
|
1074
|
+
role: z.optional(z.union([z.string(), z.null()])),
|
|
550
1075
|
});
|
|
551
1076
|
/**
|
|
552
1077
|
* IntermediateData
|
|
553
1078
|
* Container for intermediate data that an agent would generate as it responds with a final answer.
|
|
554
1079
|
*/
|
|
555
1080
|
export const zIntermediateDataInput = z.object({
|
|
556
|
-
toolUses: z.array(zFunctionCall)
|
|
557
|
-
toolResponses: z.array(zFunctionResponse)
|
|
1081
|
+
toolUses: z.optional(z.array(zFunctionCall)).default([]),
|
|
1082
|
+
toolResponses: z.optional(z.array(zFunctionResponse)).default([]),
|
|
558
1083
|
intermediateResponses: z
|
|
559
|
-
.array(z.tuple([z.string(), z.array(zPartInput)]))
|
|
560
|
-
.optional()
|
|
1084
|
+
.optional(z.array(z.tuple([z.string(), z.array(zPartInput)])))
|
|
561
1085
|
.default([]),
|
|
562
1086
|
});
|
|
1087
|
+
/**
|
|
1088
|
+
* InvocationEvent
|
|
1089
|
+
* An immutable record representing a specific point in the agent's invocation.
|
|
1090
|
+
*
|
|
1091
|
+
* It captures agent's replies, requests to use tools (function calls), and tool
|
|
1092
|
+
* results.
|
|
1093
|
+
*
|
|
1094
|
+
* This structure is a simple projection of the actual `Event` datamodel that
|
|
1095
|
+
* is intended for the Eval System.
|
|
1096
|
+
*/
|
|
1097
|
+
export const zInvocationEventInput = z.object({
|
|
1098
|
+
author: z.string(),
|
|
1099
|
+
content: z.union([zContentInput, z.null()]),
|
|
1100
|
+
});
|
|
1101
|
+
/**
|
|
1102
|
+
* InvocationEvents
|
|
1103
|
+
* A container for events that occur during the course of an invocation.
|
|
1104
|
+
*/
|
|
1105
|
+
export const zInvocationEventsInput = z.object({
|
|
1106
|
+
invocationEvents: z.optional(z.array(zInvocationEventInput)),
|
|
1107
|
+
});
|
|
563
1108
|
/**
|
|
564
1109
|
* RubricContent
|
|
565
1110
|
* The content of a rubric.
|
|
@@ -574,20 +1119,21 @@ export const zRubricContent = z.object({
|
|
|
574
1119
|
export const zRubric = z.object({
|
|
575
1120
|
rubricId: z.string(),
|
|
576
1121
|
rubricContent: zRubricContent,
|
|
577
|
-
description: z.union([z.string(), z.null()])
|
|
578
|
-
type: z.union([z.string(), z.null()])
|
|
1122
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
1123
|
+
type: z.optional(z.union([z.string(), z.null()])),
|
|
579
1124
|
});
|
|
580
1125
|
/**
|
|
581
1126
|
* Invocation
|
|
582
1127
|
* Represents a single invocation.
|
|
583
1128
|
*/
|
|
584
1129
|
export const zInvocationInput = z.object({
|
|
585
|
-
invocationId: z.
|
|
1130
|
+
invocationId: z.optional(z.string()).default(""),
|
|
586
1131
|
userContent: zContentInput,
|
|
587
|
-
finalResponse: z.union([zContentInput, z.null()])
|
|
588
|
-
intermediateData: z.union([zIntermediateDataInput, z.null()])
|
|
589
|
-
creationTimestamp: z.
|
|
590
|
-
rubrics: z.union([z.array(zRubric), z.null()])
|
|
1132
|
+
finalResponse: z.optional(z.union([zContentInput, z.null()])),
|
|
1133
|
+
intermediateData: z.optional(z.union([zIntermediateDataInput, zInvocationEventsInput, z.null()])),
|
|
1134
|
+
creationTimestamp: z.optional(z.number()).default(0),
|
|
1135
|
+
rubrics: z.optional(z.union([z.array(zRubric), z.null()])),
|
|
1136
|
+
appDetails: z.optional(z.union([zAppDetailsInput, z.null()])),
|
|
591
1137
|
});
|
|
592
1138
|
/**
|
|
593
1139
|
* SessionInput
|
|
@@ -596,7 +1142,7 @@ export const zInvocationInput = z.object({
|
|
|
596
1142
|
export const zSessionInput = z.object({
|
|
597
1143
|
appName: z.string(),
|
|
598
1144
|
userId: z.string(),
|
|
599
|
-
state: z.
|
|
1145
|
+
state: z.optional(z.record(z.string(), z.unknown())),
|
|
600
1146
|
});
|
|
601
1147
|
/**
|
|
602
1148
|
* EvalCase
|
|
@@ -605,9 +1151,9 @@ export const zSessionInput = z.object({
|
|
|
605
1151
|
export const zEvalCaseInput = z.object({
|
|
606
1152
|
evalId: z.string(),
|
|
607
1153
|
conversation: z.array(zInvocationInput),
|
|
608
|
-
sessionInput: z.union([zSessionInput, z.null()])
|
|
609
|
-
creationTimestamp: z.
|
|
610
|
-
rubrics: z.union([z.array(zRubric), z.null()])
|
|
1154
|
+
sessionInput: z.optional(z.union([zSessionInput, z.null()])),
|
|
1155
|
+
creationTimestamp: z.optional(z.number()).default(0),
|
|
1156
|
+
rubrics: z.optional(z.union([z.array(zRubric), z.null()])),
|
|
611
1157
|
});
|
|
612
1158
|
/**
|
|
613
1159
|
* EvalSet
|
|
@@ -615,10 +1161,10 @@ export const zEvalCaseInput = z.object({
|
|
|
615
1161
|
*/
|
|
616
1162
|
export const zEvalSetInput = z.object({
|
|
617
1163
|
eval_set_id: z.string(),
|
|
618
|
-
name: z.union([z.string(), z.null()])
|
|
619
|
-
description: z.union([z.string(), z.null()])
|
|
1164
|
+
name: z.optional(z.union([z.string(), z.null()])),
|
|
1165
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
620
1166
|
eval_cases: z.array(zEvalCaseInput),
|
|
621
|
-
creation_timestamp: z.
|
|
1167
|
+
creation_timestamp: z.optional(z.number()).default(0),
|
|
622
1168
|
});
|
|
623
1169
|
/**
|
|
624
1170
|
* CreateEvalSetRequest
|
|
@@ -631,95 +1177,89 @@ export const zCreateEvalSetRequest = z.object({
|
|
|
631
1177
|
* Represents where the chunk starts and ends in the document.
|
|
632
1178
|
*/
|
|
633
1179
|
export const zRagChunkPageSpan = z.object({
|
|
634
|
-
firstPage: z.union([z.
|
|
635
|
-
lastPage: z.union([z.
|
|
1180
|
+
firstPage: z.optional(z.union([z.int(), z.null()])),
|
|
1181
|
+
lastPage: z.optional(z.union([z.int(), z.null()])),
|
|
636
1182
|
});
|
|
637
1183
|
/**
|
|
638
1184
|
* RagChunk
|
|
639
1185
|
* A RagChunk includes the content of a chunk of a RagFile, and associated metadata.
|
|
640
1186
|
*/
|
|
641
1187
|
export const zRagChunk = z.object({
|
|
642
|
-
pageSpan: z.union([zRagChunkPageSpan, z.null()])
|
|
643
|
-
text: z.union([z.string(), z.null()])
|
|
1188
|
+
pageSpan: z.optional(z.union([zRagChunkPageSpan, z.null()])),
|
|
1189
|
+
text: z.optional(z.union([z.string(), z.null()])),
|
|
644
1190
|
});
|
|
645
1191
|
/**
|
|
646
1192
|
* GroundingChunkRetrievedContext
|
|
647
1193
|
* Chunk from context retrieved by the retrieval tools.
|
|
648
1194
|
*/
|
|
649
1195
|
export const zGroundingChunkRetrievedContextInput = z.object({
|
|
650
|
-
ragChunk: z.union([zRagChunk, z.null()])
|
|
651
|
-
text: z.union([z.string(), z.null()])
|
|
652
|
-
title: z.union([z.string(), z.null()])
|
|
653
|
-
uri: z.union([z.string(), z.null()])
|
|
1196
|
+
ragChunk: z.optional(z.union([zRagChunk, z.null()])),
|
|
1197
|
+
text: z.optional(z.union([z.string(), z.null()])),
|
|
1198
|
+
title: z.optional(z.union([z.string(), z.null()])),
|
|
1199
|
+
uri: z.optional(z.union([z.string(), z.null()])),
|
|
654
1200
|
});
|
|
655
1201
|
/**
|
|
656
1202
|
* GroundingChunkWeb
|
|
657
1203
|
* Chunk from the web.
|
|
658
1204
|
*/
|
|
659
1205
|
export const zGroundingChunkWeb = z.object({
|
|
660
|
-
domain: z.union([z.string(), z.null()])
|
|
661
|
-
title: z.union([z.string(), z.null()])
|
|
662
|
-
uri: z.union([z.string(), z.null()])
|
|
1206
|
+
domain: z.optional(z.union([z.string(), z.null()])),
|
|
1207
|
+
title: z.optional(z.union([z.string(), z.null()])),
|
|
1208
|
+
uri: z.optional(z.union([z.string(), z.null()])),
|
|
663
1209
|
});
|
|
664
1210
|
/**
|
|
665
1211
|
* GroundingChunk
|
|
666
1212
|
* Grounding chunk.
|
|
667
1213
|
*/
|
|
668
1214
|
export const zGroundingChunkInput = z.object({
|
|
669
|
-
retrievedContext: z
|
|
670
|
-
|
|
671
|
-
.optional(),
|
|
672
|
-
web: z.union([zGroundingChunkWeb, z.null()]).optional(),
|
|
1215
|
+
retrievedContext: z.optional(z.union([zGroundingChunkRetrievedContextInput, z.null()])),
|
|
1216
|
+
web: z.optional(z.union([zGroundingChunkWeb, z.null()])),
|
|
673
1217
|
});
|
|
674
1218
|
/**
|
|
675
1219
|
* Segment
|
|
676
1220
|
* Segment of the content.
|
|
677
1221
|
*/
|
|
678
1222
|
export const zSegment = z.object({
|
|
679
|
-
endIndex: z.union([z.
|
|
680
|
-
partIndex: z.union([z.
|
|
681
|
-
startIndex: z.union([z.
|
|
682
|
-
text: z.union([z.string(), z.null()])
|
|
1223
|
+
endIndex: z.optional(z.union([z.int(), z.null()])),
|
|
1224
|
+
partIndex: z.optional(z.union([z.int(), z.null()])),
|
|
1225
|
+
startIndex: z.optional(z.union([z.int(), z.null()])),
|
|
1226
|
+
text: z.optional(z.union([z.string(), z.null()])),
|
|
683
1227
|
});
|
|
684
1228
|
/**
|
|
685
1229
|
* GroundingSupport
|
|
686
1230
|
* Grounding support.
|
|
687
1231
|
*/
|
|
688
1232
|
export const zGroundingSupport = z.object({
|
|
689
|
-
confidenceScores: z.union([z.array(z.number()), z.null()])
|
|
690
|
-
groundingChunkIndices: z
|
|
691
|
-
|
|
692
|
-
.optional(),
|
|
693
|
-
segment: z.union([zSegment, z.null()]).optional(),
|
|
1233
|
+
confidenceScores: z.optional(z.union([z.array(z.number()), z.null()])),
|
|
1234
|
+
groundingChunkIndices: z.optional(z.union([z.array(z.int()), z.null()])),
|
|
1235
|
+
segment: z.optional(z.union([zSegment, z.null()])),
|
|
694
1236
|
});
|
|
695
1237
|
/**
|
|
696
1238
|
* RetrievalMetadata
|
|
697
1239
|
* Metadata related to retrieval in the grounding flow.
|
|
698
1240
|
*/
|
|
699
1241
|
export const zRetrievalMetadata = z.object({
|
|
700
|
-
googleSearchDynamicRetrievalScore: z.union([z.number(), z.null()])
|
|
1242
|
+
googleSearchDynamicRetrievalScore: z.optional(z.union([z.number(), z.null()])),
|
|
701
1243
|
});
|
|
702
1244
|
/**
|
|
703
1245
|
* SearchEntryPoint
|
|
704
1246
|
* Google search entry point.
|
|
705
1247
|
*/
|
|
706
1248
|
export const zSearchEntryPoint = z.object({
|
|
707
|
-
renderedContent: z.union([z.string(), z.null()])
|
|
708
|
-
sdkBlob: z.union([z.string(), z.null()])
|
|
1249
|
+
renderedContent: z.optional(z.union([z.string(), z.null()])),
|
|
1250
|
+
sdkBlob: z.optional(z.union([z.string(), z.null()])),
|
|
709
1251
|
});
|
|
710
1252
|
/**
|
|
711
1253
|
* GroundingMetadata
|
|
712
1254
|
* Metadata returned to client when grounding is enabled.
|
|
713
1255
|
*/
|
|
714
1256
|
export const zGroundingMetadataInput = z.object({
|
|
715
|
-
groundingChunks: z
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
searchEntryPoint: z.union([zSearchEntryPoint, z.null()]).optional(),
|
|
722
|
-
webSearchQueries: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1257
|
+
groundingChunks: z.optional(z.union([z.array(zGroundingChunkInput), z.null()])),
|
|
1258
|
+
groundingSupports: z.optional(z.union([z.array(zGroundingSupport), z.null()])),
|
|
1259
|
+
retrievalMetadata: z.optional(z.union([zRetrievalMetadata, z.null()])),
|
|
1260
|
+
retrievalQueries: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
1261
|
+
searchEntryPoint: z.optional(z.union([zSearchEntryPoint, z.null()])),
|
|
1262
|
+
webSearchQueries: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
723
1263
|
});
|
|
724
1264
|
/**
|
|
725
1265
|
* FinishReason
|
|
@@ -759,79 +1299,220 @@ export const zMediaModality = z.enum([
|
|
|
759
1299
|
* Represents token counting info for a single modality.
|
|
760
1300
|
*/
|
|
761
1301
|
export const zModalityTokenCount = z.object({
|
|
762
|
-
modality: z.union([zMediaModality, z.null()])
|
|
763
|
-
tokenCount: z.union([z.
|
|
1302
|
+
modality: z.optional(z.union([zMediaModality, z.null()])),
|
|
1303
|
+
tokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
1304
|
+
});
|
|
1305
|
+
/**
|
|
1306
|
+
* TrafficType
|
|
1307
|
+
* Output only.
|
|
1308
|
+
*
|
|
1309
|
+
* Traffic type. This shows whether a request consumes Pay-As-You-Go or
|
|
1310
|
+
* Provisioned Throughput quota.
|
|
1311
|
+
*/
|
|
1312
|
+
export const zTrafficType = z.enum([
|
|
1313
|
+
"TRAFFIC_TYPE_UNSPECIFIED",
|
|
1314
|
+
"ON_DEMAND",
|
|
1315
|
+
"PROVISIONED_THROUGHPUT",
|
|
1316
|
+
]);
|
|
1317
|
+
/**
|
|
1318
|
+
* GenerateContentResponseUsageMetadata
|
|
1319
|
+
* Usage metadata about response(s).
|
|
1320
|
+
*/
|
|
1321
|
+
export const zGenerateContentResponseUsageMetadataInput = z.object({
|
|
1322
|
+
cacheTokensDetails: z.optional(z.union([z.array(zModalityTokenCount), z.null()])),
|
|
1323
|
+
cachedContentTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
1324
|
+
candidatesTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
1325
|
+
candidatesTokensDetails: z.optional(z.union([z.array(zModalityTokenCount), z.null()])),
|
|
1326
|
+
promptTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
1327
|
+
promptTokensDetails: z.optional(z.union([z.array(zModalityTokenCount), z.null()])),
|
|
1328
|
+
thoughtsTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
1329
|
+
toolUsePromptTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
1330
|
+
toolUsePromptTokensDetails: z.optional(z.union([z.array(zModalityTokenCount), z.null()])),
|
|
1331
|
+
totalTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
1332
|
+
trafficType: z.optional(z.union([zTrafficType, z.null()])),
|
|
1333
|
+
});
|
|
1334
|
+
/**
|
|
1335
|
+
* LiveServerSessionResumptionUpdate
|
|
1336
|
+
* Update of the session resumption state.
|
|
1337
|
+
*
|
|
1338
|
+
* Only sent if `session_resumption` was set in the connection config.
|
|
1339
|
+
*/
|
|
1340
|
+
export const zLiveServerSessionResumptionUpdate = z.object({
|
|
1341
|
+
newHandle: z.optional(z.union([z.string(), z.null()])),
|
|
1342
|
+
resumable: z.optional(z.union([z.boolean(), z.null()])),
|
|
1343
|
+
lastConsumedClientMessageIndex: z.optional(z.union([z.int(), z.null()])),
|
|
1344
|
+
});
|
|
1345
|
+
/**
|
|
1346
|
+
* Transcription
|
|
1347
|
+
* Audio transcription in Server Conent.
|
|
1348
|
+
*/
|
|
1349
|
+
export const zTranscription = z.object({
|
|
1350
|
+
text: z.optional(z.union([z.string(), z.null()])),
|
|
1351
|
+
finished: z.optional(z.union([z.boolean(), z.null()])),
|
|
1352
|
+
});
|
|
1353
|
+
/**
|
|
1354
|
+
* LogprobsResultCandidate
|
|
1355
|
+
* Candidate for the logprobs token and score.
|
|
1356
|
+
*/
|
|
1357
|
+
export const zLogprobsResultCandidate = z.object({
|
|
1358
|
+
logProbability: z.optional(z.union([z.number(), z.null()])),
|
|
1359
|
+
token: z.optional(z.union([z.string(), z.null()])),
|
|
1360
|
+
tokenId: z.optional(z.union([z.int(), z.null()])),
|
|
1361
|
+
});
|
|
1362
|
+
/**
|
|
1363
|
+
* LogprobsResultTopCandidates
|
|
1364
|
+
* Candidates with top log probabilities at each decoding step.
|
|
1365
|
+
*/
|
|
1366
|
+
export const zLogprobsResultTopCandidates = z.object({
|
|
1367
|
+
candidates: z.optional(z.union([z.array(zLogprobsResultCandidate), z.null()])),
|
|
1368
|
+
});
|
|
1369
|
+
/**
|
|
1370
|
+
* LogprobsResult
|
|
1371
|
+
* Logprobs Result
|
|
1372
|
+
*/
|
|
1373
|
+
export const zLogprobsResultInput = z.object({
|
|
1374
|
+
chosenCandidates: z.optional(z.union([z.array(zLogprobsResultCandidate), z.null()])),
|
|
1375
|
+
topCandidates: z.optional(z.union([z.array(zLogprobsResultTopCandidates), z.null()])),
|
|
1376
|
+
});
|
|
1377
|
+
/**
|
|
1378
|
+
* HTTPBase
|
|
1379
|
+
*/
|
|
1380
|
+
export const zHttpBase = z.object({
|
|
1381
|
+
type: z.optional(zSecuritySchemeType),
|
|
1382
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
1383
|
+
scheme: z.string(),
|
|
1384
|
+
});
|
|
1385
|
+
/**
|
|
1386
|
+
* OAuthFlowImplicit
|
|
1387
|
+
*/
|
|
1388
|
+
export const zOAuthFlowImplicit = z.object({
|
|
1389
|
+
refreshUrl: z.optional(z.union([z.string(), z.null()])),
|
|
1390
|
+
scopes: z.optional(z.record(z.string(), z.string())).default({}),
|
|
1391
|
+
authorizationUrl: z.string(),
|
|
1392
|
+
});
|
|
1393
|
+
/**
|
|
1394
|
+
* OAuthFlowPassword
|
|
1395
|
+
*/
|
|
1396
|
+
export const zOAuthFlowPassword = z.object({
|
|
1397
|
+
refreshUrl: z.optional(z.union([z.string(), z.null()])),
|
|
1398
|
+
scopes: z.optional(z.record(z.string(), z.string())).default({}),
|
|
1399
|
+
tokenUrl: z.string(),
|
|
1400
|
+
});
|
|
1401
|
+
/**
|
|
1402
|
+
* OAuthFlowClientCredentials
|
|
1403
|
+
*/
|
|
1404
|
+
export const zOAuthFlowClientCredentials = z.object({
|
|
1405
|
+
refreshUrl: z.optional(z.union([z.string(), z.null()])),
|
|
1406
|
+
scopes: z.optional(z.record(z.string(), z.string())).default({}),
|
|
1407
|
+
tokenUrl: z.string(),
|
|
1408
|
+
});
|
|
1409
|
+
/**
|
|
1410
|
+
* OAuthFlowAuthorizationCode
|
|
1411
|
+
*/
|
|
1412
|
+
export const zOAuthFlowAuthorizationCode = z.object({
|
|
1413
|
+
refreshUrl: z.optional(z.union([z.string(), z.null()])),
|
|
1414
|
+
scopes: z.optional(z.record(z.string(), z.string())).default({}),
|
|
1415
|
+
authorizationUrl: z.string(),
|
|
1416
|
+
tokenUrl: z.string(),
|
|
1417
|
+
});
|
|
1418
|
+
/**
|
|
1419
|
+
* OAuthFlows
|
|
1420
|
+
*/
|
|
1421
|
+
export const zOAuthFlows = z.object({
|
|
1422
|
+
implicit: z.optional(z.union([zOAuthFlowImplicit, z.null()])),
|
|
1423
|
+
password: z.optional(z.union([zOAuthFlowPassword, z.null()])),
|
|
1424
|
+
clientCredentials: z.optional(z.union([zOAuthFlowClientCredentials, z.null()])),
|
|
1425
|
+
authorizationCode: z.optional(z.union([zOAuthFlowAuthorizationCode, z.null()])),
|
|
1426
|
+
});
|
|
1427
|
+
/**
|
|
1428
|
+
* OAuth2
|
|
1429
|
+
*/
|
|
1430
|
+
export const zOAuth2Input = z.object({
|
|
1431
|
+
type: z.optional(zSecuritySchemeType),
|
|
1432
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
1433
|
+
flows: zOAuthFlows,
|
|
1434
|
+
});
|
|
1435
|
+
/**
|
|
1436
|
+
* OpenIdConnect
|
|
1437
|
+
*/
|
|
1438
|
+
export const zOpenIdConnect = z.object({
|
|
1439
|
+
type: z.optional(zSecuritySchemeType),
|
|
1440
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
1441
|
+
openIdConnectUrl: z.string(),
|
|
1442
|
+
});
|
|
1443
|
+
/**
|
|
1444
|
+
* HTTPBearer
|
|
1445
|
+
*/
|
|
1446
|
+
export const zHttpBearer = z.object({
|
|
1447
|
+
type: z.optional(zSecuritySchemeType),
|
|
1448
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
1449
|
+
scheme: z.optional(z.literal("bearer")).default("bearer"),
|
|
1450
|
+
bearerFormat: z.optional(z.union([z.string(), z.null()])),
|
|
1451
|
+
});
|
|
1452
|
+
/**
|
|
1453
|
+
* OpenIdConnectWithConfig
|
|
1454
|
+
*/
|
|
1455
|
+
export const zOpenIdConnectWithConfig = z.object({
|
|
1456
|
+
type: z.optional(zSecuritySchemeType),
|
|
1457
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
1458
|
+
authorization_endpoint: z.string(),
|
|
1459
|
+
token_endpoint: z.string(),
|
|
1460
|
+
userinfo_endpoint: z.optional(z.union([z.string(), z.null()])),
|
|
1461
|
+
revocation_endpoint: z.optional(z.union([z.string(), z.null()])),
|
|
1462
|
+
token_endpoint_auth_methods_supported: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
1463
|
+
grant_types_supported: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
1464
|
+
scopes: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
764
1465
|
});
|
|
765
1466
|
/**
|
|
766
|
-
*
|
|
767
|
-
*
|
|
1467
|
+
* AuthConfig
|
|
1468
|
+
* The auth config sent by tool asking client to collect auth credentials and
|
|
768
1469
|
*
|
|
769
|
-
*
|
|
770
|
-
* Provisioned Throughput quota.
|
|
771
|
-
*/
|
|
772
|
-
export const zTrafficType = z.enum([
|
|
773
|
-
"TRAFFIC_TYPE_UNSPECIFIED",
|
|
774
|
-
"ON_DEMAND",
|
|
775
|
-
"PROVISIONED_THROUGHPUT",
|
|
776
|
-
]);
|
|
777
|
-
/**
|
|
778
|
-
* GenerateContentResponseUsageMetadata
|
|
779
|
-
* Usage metadata about response(s).
|
|
1470
|
+
* adk and client will help to fill in the response
|
|
780
1471
|
*/
|
|
781
|
-
export const
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
.optional(),
|
|
794
|
-
thoughtsTokenCount: z.union([z.number().int(), z.null()]).optional(),
|
|
795
|
-
toolUsePromptTokenCount: z.union([z.number().int(), z.null()]).optional(),
|
|
796
|
-
toolUsePromptTokensDetails: z
|
|
797
|
-
.union([z.array(zModalityTokenCount), z.null()])
|
|
798
|
-
.optional(),
|
|
799
|
-
totalTokenCount: z.union([z.number().int(), z.null()]).optional(),
|
|
800
|
-
trafficType: z.union([zTrafficType, z.null()]).optional(),
|
|
1472
|
+
export const zGoogleAdkAuthAuthToolAuthConfigInput = z.object({
|
|
1473
|
+
authScheme: z.union([
|
|
1474
|
+
zApiKey,
|
|
1475
|
+
zHttpBase,
|
|
1476
|
+
zOAuth2Input,
|
|
1477
|
+
zOpenIdConnect,
|
|
1478
|
+
zHttpBearer,
|
|
1479
|
+
zOpenIdConnectWithConfig,
|
|
1480
|
+
]),
|
|
1481
|
+
rawAuthCredential: z.optional(z.union([zAuthCredentialInput, z.null()])),
|
|
1482
|
+
exchangedAuthCredential: z.optional(z.union([zAuthCredentialInput, z.null()])),
|
|
1483
|
+
credentialKey: z.optional(z.union([z.string(), z.null()])),
|
|
801
1484
|
});
|
|
802
1485
|
/**
|
|
803
|
-
*
|
|
804
|
-
*
|
|
805
|
-
*
|
|
806
|
-
* Only sent if `session_resumption` was set in the connection config.
|
|
1486
|
+
* ToolConfirmation
|
|
1487
|
+
* Represents a tool confirmation configuration.
|
|
807
1488
|
*/
|
|
808
|
-
export const
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
.union([z.number().int(), z.null()])
|
|
813
|
-
.optional(),
|
|
1489
|
+
export const zToolConfirmation = z.object({
|
|
1490
|
+
hint: z.optional(z.string()).default(""),
|
|
1491
|
+
confirmed: z.optional(z.boolean()).default(false),
|
|
1492
|
+
payload: z.optional(z.union([z.unknown(), z.null()])),
|
|
814
1493
|
});
|
|
815
1494
|
/**
|
|
816
|
-
*
|
|
817
|
-
*
|
|
1495
|
+
* EventCompaction
|
|
1496
|
+
* The compaction of the events.
|
|
818
1497
|
*/
|
|
819
|
-
export const
|
|
820
|
-
|
|
821
|
-
|
|
1498
|
+
export const zEventCompactionInput = z.object({
|
|
1499
|
+
startTimestamp: z.number(),
|
|
1500
|
+
endTimestamp: z.number(),
|
|
1501
|
+
compactedContent: zContentInput,
|
|
822
1502
|
});
|
|
823
1503
|
/**
|
|
824
1504
|
* EventActions
|
|
825
1505
|
* Represents the actions attached to an event.
|
|
826
1506
|
*/
|
|
827
1507
|
export const zEventActionsInput = z.object({
|
|
828
|
-
skipSummarization: z.union([z.boolean(), z.null()])
|
|
829
|
-
stateDelta: z.
|
|
830
|
-
artifactDelta: z.
|
|
831
|
-
transferToAgent: z.union([z.string(), z.null()])
|
|
832
|
-
escalate: z.union([z.boolean(), z.null()])
|
|
833
|
-
requestedAuthConfigs: z.
|
|
834
|
-
requestedToolConfirmations: z.
|
|
1508
|
+
skipSummarization: z.optional(z.union([z.boolean(), z.null()])),
|
|
1509
|
+
stateDelta: z.optional(z.record(z.string(), z.unknown())),
|
|
1510
|
+
artifactDelta: z.optional(z.record(z.string(), z.int())),
|
|
1511
|
+
transferToAgent: z.optional(z.union([z.string(), z.null()])),
|
|
1512
|
+
escalate: z.optional(z.union([z.boolean(), z.null()])),
|
|
1513
|
+
requestedAuthConfigs: z.optional(z.record(z.string(), zGoogleAdkAuthAuthToolAuthConfigInput)),
|
|
1514
|
+
requestedToolConfirmations: z.optional(z.record(z.string(), zToolConfirmation)),
|
|
1515
|
+
compaction: z.optional(z.union([zEventCompactionInput, z.null()])),
|
|
835
1516
|
});
|
|
836
1517
|
/**
|
|
837
1518
|
* Event
|
|
@@ -841,89 +1522,82 @@ export const zEventActionsInput = z.object({
|
|
|
841
1522
|
* taken by the agents like function calls, etc.
|
|
842
1523
|
*/
|
|
843
1524
|
export const zEventInput = z.object({
|
|
844
|
-
content: z.union([zContentInput, z.null()])
|
|
845
|
-
groundingMetadata: z.union([zGroundingMetadataInput, z.null()])
|
|
846
|
-
partial: z.union([z.boolean(), z.null()])
|
|
847
|
-
turnComplete: z.union([z.boolean(), z.null()])
|
|
848
|
-
finishReason: z.union([zFinishReason, z.null()])
|
|
849
|
-
errorCode: z.union([z.string(), z.null()])
|
|
850
|
-
errorMessage: z.union([z.string(), z.null()])
|
|
851
|
-
interrupted: z.union([z.boolean(), z.null()])
|
|
852
|
-
customMetadata: z.union([z.
|
|
853
|
-
usageMetadata: z
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
invocationId: z.string().optional().default(""),
|
|
1525
|
+
content: z.optional(z.union([zContentInput, z.null()])),
|
|
1526
|
+
groundingMetadata: z.optional(z.union([zGroundingMetadataInput, z.null()])),
|
|
1527
|
+
partial: z.optional(z.union([z.boolean(), z.null()])),
|
|
1528
|
+
turnComplete: z.optional(z.union([z.boolean(), z.null()])),
|
|
1529
|
+
finishReason: z.optional(z.union([zFinishReason, z.null()])),
|
|
1530
|
+
errorCode: z.optional(z.union([z.string(), z.null()])),
|
|
1531
|
+
errorMessage: z.optional(z.union([z.string(), z.null()])),
|
|
1532
|
+
interrupted: z.optional(z.union([z.boolean(), z.null()])),
|
|
1533
|
+
customMetadata: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
1534
|
+
usageMetadata: z.optional(z.union([zGenerateContentResponseUsageMetadataInput, z.null()])),
|
|
1535
|
+
liveSessionResumptionUpdate: z.optional(z.union([zLiveServerSessionResumptionUpdate, z.null()])),
|
|
1536
|
+
inputTranscription: z.optional(z.union([zTranscription, z.null()])),
|
|
1537
|
+
outputTranscription: z.optional(z.union([zTranscription, z.null()])),
|
|
1538
|
+
avgLogprobs: z.optional(z.union([z.number(), z.null()])),
|
|
1539
|
+
logprobsResult: z.optional(z.union([zLogprobsResultInput, z.null()])),
|
|
1540
|
+
cacheMetadata: z.optional(z.union([zCacheMetadata, z.null()])),
|
|
1541
|
+
invocationId: z.optional(z.string()).default(""),
|
|
862
1542
|
author: z.string(),
|
|
863
|
-
actions:
|
|
864
|
-
longRunningToolIds: z.union([z.array(z.string()), z.null()])
|
|
865
|
-
branch: z.union([z.string(), z.null()])
|
|
866
|
-
id: z.
|
|
867
|
-
timestamp: z.
|
|
1543
|
+
actions: z.optional(zEventActionsInput),
|
|
1544
|
+
longRunningToolIds: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
1545
|
+
branch: z.optional(z.union([z.string(), z.null()])),
|
|
1546
|
+
id: z.optional(z.string()).default(""),
|
|
1547
|
+
timestamp: z.optional(z.number()),
|
|
868
1548
|
});
|
|
869
1549
|
/**
|
|
870
1550
|
* CreateSessionRequest
|
|
871
1551
|
*/
|
|
872
1552
|
export const zCreateSessionRequest = z.object({
|
|
873
|
-
sessionId: z.union([z.string(), z.null()])
|
|
874
|
-
state: z.union([z.
|
|
875
|
-
events: z.union([z.array(zEventInput), z.null()])
|
|
1553
|
+
sessionId: z.optional(z.union([z.string(), z.null()])),
|
|
1554
|
+
state: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
1555
|
+
events: z.optional(z.union([z.array(zEventInput), z.null()])),
|
|
876
1556
|
});
|
|
877
1557
|
/**
|
|
878
|
-
*
|
|
1558
|
+
* IntermediateData
|
|
1559
|
+
* Container for intermediate data that an agent would generate as it responds with a final answer.
|
|
879
1560
|
*/
|
|
880
|
-
export const
|
|
881
|
-
|
|
1561
|
+
export const zIntermediateDataOutput = z.object({
|
|
1562
|
+
toolUses: z.optional(z.array(zFunctionCall)).default([]),
|
|
1563
|
+
toolResponses: z.optional(z.array(zFunctionResponse)).default([]),
|
|
1564
|
+
intermediateResponses: z
|
|
1565
|
+
.optional(z.array(z.tuple([z.string(), z.array(zPartOutput)])))
|
|
1566
|
+
.default([]),
|
|
882
1567
|
});
|
|
883
1568
|
/**
|
|
884
|
-
*
|
|
885
|
-
*
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
* DynamicRetrievalConfig
|
|
893
|
-
* Describes the options to customize dynamic retrieval.
|
|
1569
|
+
* InvocationEvent
|
|
1570
|
+
* An immutable record representing a specific point in the agent's invocation.
|
|
1571
|
+
*
|
|
1572
|
+
* It captures agent's replies, requests to use tools (function calls), and tool
|
|
1573
|
+
* results.
|
|
1574
|
+
*
|
|
1575
|
+
* This structure is a simple projection of the actual `Event` datamodel that
|
|
1576
|
+
* is intended for the Eval System.
|
|
894
1577
|
*/
|
|
895
|
-
export const
|
|
896
|
-
|
|
897
|
-
|
|
1578
|
+
export const zInvocationEventOutput = z.object({
|
|
1579
|
+
author: z.string(),
|
|
1580
|
+
content: z.union([zContentOutput, z.null()]),
|
|
898
1581
|
});
|
|
899
1582
|
/**
|
|
900
|
-
*
|
|
901
|
-
*
|
|
902
|
-
*/
|
|
903
|
-
export const zEnterpriseWebSearch = z.object({});
|
|
904
|
-
/**
|
|
905
|
-
* IntermediateData
|
|
906
|
-
* Container for intermediate data that an agent would generate as it responds with a final answer.
|
|
1583
|
+
* InvocationEvents
|
|
1584
|
+
* A container for events that occur during the course of an invocation.
|
|
907
1585
|
*/
|
|
908
|
-
export const
|
|
909
|
-
|
|
910
|
-
toolResponses: z.array(zFunctionResponse).optional().default([]),
|
|
911
|
-
intermediateResponses: z
|
|
912
|
-
.array(z.tuple([z.string(), z.array(zPartOutput)]))
|
|
913
|
-
.optional()
|
|
914
|
-
.default([]),
|
|
1586
|
+
export const zInvocationEventsOutput = z.object({
|
|
1587
|
+
invocationEvents: z.optional(z.array(zInvocationEventOutput)),
|
|
915
1588
|
});
|
|
916
1589
|
/**
|
|
917
1590
|
* Invocation
|
|
918
1591
|
* Represents a single invocation.
|
|
919
1592
|
*/
|
|
920
1593
|
export const zInvocationOutput = z.object({
|
|
921
|
-
invocationId: z.
|
|
1594
|
+
invocationId: z.optional(z.string()).default(""),
|
|
922
1595
|
userContent: zContentOutput,
|
|
923
|
-
finalResponse: z.union([zContentOutput, z.null()])
|
|
924
|
-
intermediateData: z.union([zIntermediateDataOutput, z.null()])
|
|
925
|
-
creationTimestamp: z.
|
|
926
|
-
rubrics: z.union([z.array(zRubric), z.null()])
|
|
1596
|
+
finalResponse: z.optional(z.union([zContentOutput, z.null()])),
|
|
1597
|
+
intermediateData: z.optional(z.union([zIntermediateDataOutput, zInvocationEventsOutput, z.null()])),
|
|
1598
|
+
creationTimestamp: z.optional(z.number()).default(0),
|
|
1599
|
+
rubrics: z.optional(z.union([z.array(zRubric), z.null()])),
|
|
1600
|
+
appDetails: z.optional(z.union([zAppDetailsOutput, z.null()])),
|
|
927
1601
|
});
|
|
928
1602
|
/**
|
|
929
1603
|
* EvalCase
|
|
@@ -932,9 +1606,9 @@ export const zInvocationOutput = z.object({
|
|
|
932
1606
|
export const zEvalCaseOutput = z.object({
|
|
933
1607
|
evalId: z.string(),
|
|
934
1608
|
conversation: z.array(zInvocationOutput),
|
|
935
|
-
sessionInput: z.union([zSessionInput, z.null()])
|
|
936
|
-
creationTimestamp: z.
|
|
937
|
-
rubrics: z.union([z.array(zRubric), z.null()])
|
|
1609
|
+
sessionInput: z.optional(z.union([zSessionInput, z.null()])),
|
|
1610
|
+
creationTimestamp: z.optional(z.number()).default(0),
|
|
1611
|
+
rubrics: z.optional(z.union([z.array(zRubric), z.null()])),
|
|
938
1612
|
});
|
|
939
1613
|
/**
|
|
940
1614
|
* EvalStatus
|
|
@@ -945,26 +1619,26 @@ export const zEvalStatus = z.unknown();
|
|
|
945
1619
|
* HTTP retry options to be used in each of the requests.
|
|
946
1620
|
*/
|
|
947
1621
|
export const zHttpRetryOptions = z.object({
|
|
948
|
-
attempts: z.union([z.
|
|
949
|
-
initialDelay: z.union([z.number(), z.null()])
|
|
950
|
-
maxDelay: z.union([z.number(), z.null()])
|
|
951
|
-
expBase: z.union([z.number(), z.null()])
|
|
952
|
-
jitter: z.union([z.number(), z.null()])
|
|
953
|
-
httpStatusCodes: z.union([z.array(z.
|
|
1622
|
+
attempts: z.optional(z.union([z.int(), z.null()])),
|
|
1623
|
+
initialDelay: z.optional(z.union([z.number(), z.null()])),
|
|
1624
|
+
maxDelay: z.optional(z.union([z.number(), z.null()])),
|
|
1625
|
+
expBase: z.optional(z.union([z.number(), z.null()])),
|
|
1626
|
+
jitter: z.optional(z.union([z.number(), z.null()])),
|
|
1627
|
+
httpStatusCodes: z.optional(z.union([z.array(z.int()), z.null()])),
|
|
954
1628
|
});
|
|
955
1629
|
/**
|
|
956
1630
|
* HttpOptions
|
|
957
1631
|
* HTTP options to be used in each of the requests.
|
|
958
1632
|
*/
|
|
959
1633
|
export const zHttpOptions = z.object({
|
|
960
|
-
baseUrl: z.union([z.string(), z.null()])
|
|
961
|
-
apiVersion: z.union([z.string(), z.null()])
|
|
962
|
-
headers: z.union([z.
|
|
963
|
-
timeout: z.union([z.
|
|
964
|
-
clientArgs: z.union([z.
|
|
965
|
-
asyncClientArgs: z.union([z.
|
|
966
|
-
extraBody: z.union([z.
|
|
967
|
-
retryOptions: z.union([zHttpRetryOptions, z.null()])
|
|
1634
|
+
baseUrl: z.optional(z.union([z.string(), z.null()])),
|
|
1635
|
+
apiVersion: z.optional(z.union([z.string(), z.null()])),
|
|
1636
|
+
headers: z.optional(z.union([z.record(z.string(), z.string()), z.null()])),
|
|
1637
|
+
timeout: z.optional(z.union([z.int(), z.null()])),
|
|
1638
|
+
clientArgs: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
1639
|
+
asyncClientArgs: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
1640
|
+
extraBody: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
1641
|
+
retryOptions: z.optional(z.union([zHttpRetryOptions, z.null()])),
|
|
968
1642
|
});
|
|
969
1643
|
/**
|
|
970
1644
|
* FileState
|
|
@@ -990,128 +1664,54 @@ export const zFileSource = z.enum([
|
|
|
990
1664
|
* Status of a File that uses a common error model.
|
|
991
1665
|
*/
|
|
992
1666
|
export const zFileStatus = z.object({
|
|
993
|
-
details: z.union([z.array(z.
|
|
994
|
-
message: z.union([z.string(), z.null()])
|
|
995
|
-
code: z.union([z.
|
|
1667
|
+
details: z.optional(z.union([z.array(z.record(z.string(), z.unknown())), z.null()])),
|
|
1668
|
+
message: z.optional(z.union([z.string(), z.null()])),
|
|
1669
|
+
code: z.optional(z.union([z.int(), z.null()])),
|
|
996
1670
|
});
|
|
997
1671
|
/**
|
|
998
1672
|
* File
|
|
999
1673
|
* A file uploaded to the API.
|
|
1000
1674
|
*/
|
|
1001
1675
|
export const zFile = z.object({
|
|
1002
|
-
name: z.union([z.string(), z.null()])
|
|
1003
|
-
displayName: z.union([z.string(), z.null()])
|
|
1004
|
-
mimeType: z.union([z.string(), z.null()])
|
|
1005
|
-
sizeBytes: z.union([z.
|
|
1006
|
-
createTime: z.union([z.
|
|
1007
|
-
expirationTime: z.union([z.
|
|
1008
|
-
updateTime: z.union([z.
|
|
1009
|
-
sha256Hash: z.union([z.string(), z.null()])
|
|
1010
|
-
uri: z.union([z.string(), z.null()])
|
|
1011
|
-
downloadUri: z.union([z.string(), z.null()])
|
|
1012
|
-
state: z.union([zFileState, z.null()])
|
|
1013
|
-
source: z.union([zFileSource, z.null()])
|
|
1014
|
-
videoMetadata: z.union([z.
|
|
1015
|
-
error: z.union([zFileStatus, z.null()])
|
|
1016
|
-
});
|
|
1017
|
-
/**
|
|
1018
|
-
* Type
|
|
1019
|
-
* Optional. The type of the data.
|
|
1020
|
-
*/
|
|
1021
|
-
export const zType = z.enum([
|
|
1022
|
-
"TYPE_UNSPECIFIED",
|
|
1023
|
-
"STRING",
|
|
1024
|
-
"NUMBER",
|
|
1025
|
-
"INTEGER",
|
|
1026
|
-
"BOOLEAN",
|
|
1027
|
-
"ARRAY",
|
|
1028
|
-
"OBJECT",
|
|
1029
|
-
"NULL",
|
|
1030
|
-
]);
|
|
1031
|
-
/**
|
|
1032
|
-
* Schema
|
|
1033
|
-
* Schema is used to define the format of input/output data.
|
|
1034
|
-
*
|
|
1035
|
-
* Represents a select subset of an [OpenAPI 3.0 schema
|
|
1036
|
-
* object](https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may
|
|
1037
|
-
* be added in the future as needed.
|
|
1038
|
-
*/
|
|
1039
|
-
export const zSchemaOutput = z.object({
|
|
1040
|
-
additionalProperties: z.union([z.unknown(), z.null()]).optional(),
|
|
1041
|
-
defs: z.union([z.object({}), z.null()]).optional(),
|
|
1042
|
-
ref: z.union([z.string(), z.null()]).optional(),
|
|
1043
|
-
anyOf: z
|
|
1044
|
-
.union([
|
|
1045
|
-
z.array(z.lazy(() => {
|
|
1046
|
-
return zSchemaOutput;
|
|
1047
|
-
})),
|
|
1048
|
-
z.null(),
|
|
1049
|
-
])
|
|
1050
|
-
.optional(),
|
|
1051
|
-
default: z.union([z.unknown(), z.null()]).optional(),
|
|
1052
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
1053
|
-
enum: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1054
|
-
example: z.union([z.unknown(), z.null()]).optional(),
|
|
1055
|
-
format: z.union([z.string(), z.null()]).optional(),
|
|
1056
|
-
items: z
|
|
1057
|
-
.union([
|
|
1058
|
-
z.lazy(() => {
|
|
1059
|
-
return zSchemaOutput;
|
|
1060
|
-
}),
|
|
1061
|
-
z.null(),
|
|
1062
|
-
])
|
|
1063
|
-
.optional(),
|
|
1064
|
-
maxItems: z.union([z.number().int(), z.null()]).optional(),
|
|
1065
|
-
maxLength: z.union([z.number().int(), z.null()]).optional(),
|
|
1066
|
-
maxProperties: z.union([z.number().int(), z.null()]).optional(),
|
|
1067
|
-
maximum: z.union([z.number(), z.null()]).optional(),
|
|
1068
|
-
minItems: z.union([z.number().int(), z.null()]).optional(),
|
|
1069
|
-
minLength: z.union([z.number().int(), z.null()]).optional(),
|
|
1070
|
-
minProperties: z.union([z.number().int(), z.null()]).optional(),
|
|
1071
|
-
minimum: z.union([z.number(), z.null()]).optional(),
|
|
1072
|
-
nullable: z.union([z.boolean(), z.null()]).optional(),
|
|
1073
|
-
pattern: z.union([z.string(), z.null()]).optional(),
|
|
1074
|
-
properties: z.union([z.object({}), z.null()]).optional(),
|
|
1075
|
-
propertyOrdering: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1076
|
-
required: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1077
|
-
title: z.union([z.string(), z.null()]).optional(),
|
|
1078
|
-
type: z.union([zType, z.null()]).optional(),
|
|
1676
|
+
name: z.optional(z.union([z.string(), z.null()])),
|
|
1677
|
+
displayName: z.optional(z.union([z.string(), z.null()])),
|
|
1678
|
+
mimeType: z.optional(z.union([z.string(), z.null()])),
|
|
1679
|
+
sizeBytes: z.optional(z.union([z.int(), z.null()])),
|
|
1680
|
+
createTime: z.optional(z.union([z.iso.datetime(), z.null()])),
|
|
1681
|
+
expirationTime: z.optional(z.union([z.iso.datetime(), z.null()])),
|
|
1682
|
+
updateTime: z.optional(z.union([z.iso.datetime(), z.null()])),
|
|
1683
|
+
sha256Hash: z.optional(z.union([z.string(), z.null()])),
|
|
1684
|
+
uri: z.optional(z.union([z.string(), z.null()])),
|
|
1685
|
+
downloadUri: z.optional(z.union([z.string(), z.null()])),
|
|
1686
|
+
state: z.optional(z.union([zFileState, z.null()])),
|
|
1687
|
+
source: z.optional(z.union([zFileSource, z.null()])),
|
|
1688
|
+
videoMetadata: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
1689
|
+
error: z.optional(z.union([zFileStatus, z.null()])),
|
|
1079
1690
|
});
|
|
1080
1691
|
/**
|
|
1081
1692
|
* GenerationConfigRoutingConfigAutoRoutingMode
|
|
1082
1693
|
* When automated routing is specified, the routing will be determined by the pretrained routing model and customer provided model routing preference.
|
|
1083
1694
|
*/
|
|
1084
1695
|
export const zGenerationConfigRoutingConfigAutoRoutingMode = z.object({
|
|
1085
|
-
modelRoutingPreference: z
|
|
1086
|
-
.
|
|
1087
|
-
z.enum([
|
|
1088
|
-
"UNKNOWN",
|
|
1089
|
-
"PRIORITIZE_QUALITY",
|
|
1090
|
-
"BALANCED",
|
|
1091
|
-
"PRIORITIZE_COST",
|
|
1092
|
-
]),
|
|
1696
|
+
modelRoutingPreference: z.optional(z.union([
|
|
1697
|
+
z.enum(["UNKNOWN", "PRIORITIZE_QUALITY", "BALANCED", "PRIORITIZE_COST"]),
|
|
1093
1698
|
z.null(),
|
|
1094
|
-
])
|
|
1095
|
-
.optional(),
|
|
1699
|
+
])),
|
|
1096
1700
|
});
|
|
1097
1701
|
/**
|
|
1098
1702
|
* GenerationConfigRoutingConfigManualRoutingMode
|
|
1099
1703
|
* When manual routing is set, the specified model will be used directly.
|
|
1100
1704
|
*/
|
|
1101
1705
|
export const zGenerationConfigRoutingConfigManualRoutingMode = z.object({
|
|
1102
|
-
modelName: z.union([z.string(), z.null()])
|
|
1706
|
+
modelName: z.optional(z.union([z.string(), z.null()])),
|
|
1103
1707
|
});
|
|
1104
1708
|
/**
|
|
1105
1709
|
* GenerationConfigRoutingConfig
|
|
1106
1710
|
* The configuration for routing the request to a specific model.
|
|
1107
1711
|
*/
|
|
1108
1712
|
export const zGenerationConfigRoutingConfig = z.object({
|
|
1109
|
-
autoMode: z
|
|
1110
|
-
|
|
1111
|
-
.optional(),
|
|
1112
|
-
manualMode: z
|
|
1113
|
-
.union([zGenerationConfigRoutingConfigManualRoutingMode, z.null()])
|
|
1114
|
-
.optional(),
|
|
1713
|
+
autoMode: z.optional(z.union([zGenerationConfigRoutingConfigAutoRoutingMode, z.null()])),
|
|
1714
|
+
manualMode: z.optional(z.union([zGenerationConfigRoutingConfigManualRoutingMode, z.null()])),
|
|
1115
1715
|
});
|
|
1116
1716
|
/**
|
|
1117
1717
|
* FeatureSelectionPreference
|
|
@@ -1128,9 +1728,7 @@ export const zFeatureSelectionPreference = z.enum([
|
|
|
1128
1728
|
* Config for model selection.
|
|
1129
1729
|
*/
|
|
1130
1730
|
export const zModelSelectionConfig = z.object({
|
|
1131
|
-
featureSelectionPreference: z
|
|
1132
|
-
.union([zFeatureSelectionPreference, z.null()])
|
|
1133
|
-
.optional(),
|
|
1731
|
+
featureSelectionPreference: z.optional(z.union([zFeatureSelectionPreference, z.null()])),
|
|
1134
1732
|
});
|
|
1135
1733
|
/**
|
|
1136
1734
|
* HarmBlockMethod
|
|
@@ -1149,270 +1747,33 @@ export const zHarmBlockMethod = z.enum([
|
|
|
1149
1747
|
* Required. Harm category.
|
|
1150
1748
|
*/
|
|
1151
1749
|
export const zHarmCategory = z.enum([
|
|
1152
|
-
"HARM_CATEGORY_UNSPECIFIED",
|
|
1153
|
-
"HARM_CATEGORY_HATE_SPEECH",
|
|
1154
|
-
"HARM_CATEGORY_DANGEROUS_CONTENT",
|
|
1155
|
-
"HARM_CATEGORY_HARASSMENT",
|
|
1156
|
-
"HARM_CATEGORY_SEXUALLY_EXPLICIT",
|
|
1157
|
-
"HARM_CATEGORY_CIVIC_INTEGRITY",
|
|
1158
|
-
]);
|
|
1159
|
-
/**
|
|
1160
|
-
* HarmBlockThreshold
|
|
1161
|
-
* Required. The harm block threshold.
|
|
1162
|
-
*/
|
|
1163
|
-
export const zHarmBlockThreshold = z.enum([
|
|
1164
|
-
"HARM_BLOCK_THRESHOLD_UNSPECIFIED",
|
|
1165
|
-
"BLOCK_LOW_AND_ABOVE",
|
|
1166
|
-
"BLOCK_MEDIUM_AND_ABOVE",
|
|
1167
|
-
"BLOCK_ONLY_HIGH",
|
|
1168
|
-
"BLOCK_NONE",
|
|
1169
|
-
"OFF",
|
|
1170
|
-
]);
|
|
1171
|
-
/**
|
|
1172
|
-
* SafetySetting
|
|
1173
|
-
* Safety settings.
|
|
1174
|
-
*/
|
|
1175
|
-
export const zSafetySetting = z.object({
|
|
1176
|
-
method: z.union([zHarmBlockMethod, z.null()]).optional(),
|
|
1177
|
-
category: z.union([zHarmCategory, z.null()]).optional(),
|
|
1178
|
-
threshold: z.union([zHarmBlockThreshold, z.null()]).optional(),
|
|
1179
|
-
});
|
|
1180
|
-
/**
|
|
1181
|
-
* FunctionDeclaration
|
|
1182
|
-
* Defines a function that the model can generate JSON inputs for.
|
|
1183
|
-
*
|
|
1184
|
-
* The inputs are based on `OpenAPI 3.0 specifications
|
|
1185
|
-
* <https://spec.openapis.org/oas/v3.0.3>`_.
|
|
1186
|
-
*/
|
|
1187
|
-
export const zFunctionDeclarationOutput = z.object({
|
|
1188
|
-
behavior: z.union([zBehavior, z.null()]).optional(),
|
|
1189
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
1190
|
-
name: z.union([z.string(), z.null()]).optional(),
|
|
1191
|
-
parameters: z.union([zSchemaOutput, z.null()]).optional(),
|
|
1192
|
-
parametersJsonSchema: z.union([z.unknown(), z.null()]).optional(),
|
|
1193
|
-
response: z.union([zSchemaOutput, z.null()]).optional(),
|
|
1194
|
-
responseJsonSchema: z.union([z.unknown(), z.null()]).optional(),
|
|
1195
|
-
});
|
|
1196
|
-
/**
|
|
1197
|
-
* VertexAISearchDataStoreSpec
|
|
1198
|
-
* Define data stores within engine to filter on in a search call and configurations for those data stores.
|
|
1199
|
-
*
|
|
1200
|
-
* For more information, see
|
|
1201
|
-
* https://cloud.google.com/generative-ai-app-builder/docs/reference/rpc/google.cloud.discoveryengine.v1#datastorespec
|
|
1202
|
-
*/
|
|
1203
|
-
export const zVertexAiSearchDataStoreSpec = z.object({
|
|
1204
|
-
dataStore: z.union([z.string(), z.null()]).optional(),
|
|
1205
|
-
filter: z.union([z.string(), z.null()]).optional(),
|
|
1206
|
-
});
|
|
1207
|
-
/**
|
|
1208
|
-
* VertexAISearch
|
|
1209
|
-
* Retrieve from Vertex AI Search datastore or engine for grounding.
|
|
1210
|
-
*
|
|
1211
|
-
* datastore and engine are mutually exclusive. See
|
|
1212
|
-
* https://cloud.google.com/products/agent-builder
|
|
1213
|
-
*/
|
|
1214
|
-
export const zVertexAiSearch = z.object({
|
|
1215
|
-
dataStoreSpecs: z
|
|
1216
|
-
.union([z.array(zVertexAiSearchDataStoreSpec), z.null()])
|
|
1217
|
-
.optional(),
|
|
1218
|
-
datastore: z.union([z.string(), z.null()]).optional(),
|
|
1219
|
-
engine: z.union([z.string(), z.null()]).optional(),
|
|
1220
|
-
filter: z.union([z.string(), z.null()]).optional(),
|
|
1221
|
-
maxResults: z.union([z.number().int(), z.null()]).optional(),
|
|
1222
|
-
});
|
|
1223
|
-
/**
|
|
1224
|
-
* VertexRagStoreRagResource
|
|
1225
|
-
* The definition of the Rag resource.
|
|
1226
|
-
*/
|
|
1227
|
-
export const zVertexRagStoreRagResource = z.object({
|
|
1228
|
-
ragCorpus: z.union([z.string(), z.null()]).optional(),
|
|
1229
|
-
ragFileIds: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1230
|
-
});
|
|
1231
|
-
/**
|
|
1232
|
-
* RagRetrievalConfigFilter
|
|
1233
|
-
* Config for filters.
|
|
1234
|
-
*/
|
|
1235
|
-
export const zRagRetrievalConfigFilter = z.object({
|
|
1236
|
-
metadataFilter: z.union([z.string(), z.null()]).optional(),
|
|
1237
|
-
vectorDistanceThreshold: z.union([z.number(), z.null()]).optional(),
|
|
1238
|
-
vectorSimilarityThreshold: z.union([z.number(), z.null()]).optional(),
|
|
1239
|
-
});
|
|
1240
|
-
/**
|
|
1241
|
-
* RagRetrievalConfigHybridSearch
|
|
1242
|
-
* Config for Hybrid Search.
|
|
1243
|
-
*/
|
|
1244
|
-
export const zRagRetrievalConfigHybridSearch = z.object({
|
|
1245
|
-
alpha: z.union([z.number(), z.null()]).optional(),
|
|
1246
|
-
});
|
|
1247
|
-
/**
|
|
1248
|
-
* RagRetrievalConfigRankingLlmRanker
|
|
1249
|
-
* Config for LlmRanker.
|
|
1250
|
-
*/
|
|
1251
|
-
export const zRagRetrievalConfigRankingLlmRanker = z.object({
|
|
1252
|
-
modelName: z.union([z.string(), z.null()]).optional(),
|
|
1253
|
-
});
|
|
1254
|
-
/**
|
|
1255
|
-
* RagRetrievalConfigRankingRankService
|
|
1256
|
-
* Config for Rank Service.
|
|
1257
|
-
*/
|
|
1258
|
-
export const zRagRetrievalConfigRankingRankService = z.object({
|
|
1259
|
-
modelName: z.union([z.string(), z.null()]).optional(),
|
|
1260
|
-
});
|
|
1261
|
-
/**
|
|
1262
|
-
* RagRetrievalConfigRanking
|
|
1263
|
-
* Config for ranking and reranking.
|
|
1264
|
-
*/
|
|
1265
|
-
export const zRagRetrievalConfigRanking = z.object({
|
|
1266
|
-
llmRanker: z
|
|
1267
|
-
.union([zRagRetrievalConfigRankingLlmRanker, z.null()])
|
|
1268
|
-
.optional(),
|
|
1269
|
-
rankService: z
|
|
1270
|
-
.union([zRagRetrievalConfigRankingRankService, z.null()])
|
|
1271
|
-
.optional(),
|
|
1272
|
-
});
|
|
1273
|
-
/**
|
|
1274
|
-
* RagRetrievalConfig
|
|
1275
|
-
* Specifies the context retrieval config.
|
|
1276
|
-
*/
|
|
1277
|
-
export const zRagRetrievalConfigOutput = z.object({
|
|
1278
|
-
filter: z.union([zRagRetrievalConfigFilter, z.null()]).optional(),
|
|
1279
|
-
hybridSearch: z.union([zRagRetrievalConfigHybridSearch, z.null()]).optional(),
|
|
1280
|
-
ranking: z.union([zRagRetrievalConfigRanking, z.null()]).optional(),
|
|
1281
|
-
topK: z.union([z.number().int(), z.null()]).optional(),
|
|
1282
|
-
});
|
|
1283
|
-
/**
|
|
1284
|
-
* VertexRagStore
|
|
1285
|
-
* Retrieve from Vertex RAG Store for grounding.
|
|
1286
|
-
*/
|
|
1287
|
-
export const zVertexRagStoreOutput = z.object({
|
|
1288
|
-
ragCorpora: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1289
|
-
ragResources: z
|
|
1290
|
-
.union([z.array(zVertexRagStoreRagResource), z.null()])
|
|
1291
|
-
.optional(),
|
|
1292
|
-
ragRetrievalConfig: z.union([zRagRetrievalConfigOutput, z.null()]).optional(),
|
|
1293
|
-
similarityTopK: z.union([z.number().int(), z.null()]).optional(),
|
|
1294
|
-
storeContext: z.union([z.boolean(), z.null()]).optional(),
|
|
1295
|
-
vectorDistanceThreshold: z.union([z.number(), z.null()]).optional(),
|
|
1296
|
-
});
|
|
1297
|
-
/**
|
|
1298
|
-
* Retrieval
|
|
1299
|
-
* Defines a retrieval tool that model can call to access external knowledge.
|
|
1300
|
-
*/
|
|
1301
|
-
export const zRetrievalOutput = z.object({
|
|
1302
|
-
disableAttribution: z.union([z.boolean(), z.null()]).optional(),
|
|
1303
|
-
vertexAiSearch: z.union([zVertexAiSearch, z.null()]).optional(),
|
|
1304
|
-
vertexRagStore: z.union([zVertexRagStoreOutput, z.null()]).optional(),
|
|
1305
|
-
});
|
|
1306
|
-
/**
|
|
1307
|
-
* Interval
|
|
1308
|
-
* Represents a time interval, encoded as a start time (inclusive) and an end time (exclusive).
|
|
1309
|
-
*
|
|
1310
|
-
* The start time must be less than or equal to the end time.
|
|
1311
|
-
* When the start equals the end time, the interval is an empty interval.
|
|
1312
|
-
* (matches no time)
|
|
1313
|
-
* When both start and end are unspecified, the interval matches any time.
|
|
1314
|
-
*/
|
|
1315
|
-
export const zGoogleGenaiTypesInterval = z.object({
|
|
1316
|
-
startTime: z.union([z.string().datetime(), z.null()]).optional(),
|
|
1317
|
-
endTime: z.union([z.string().datetime(), z.null()]).optional(),
|
|
1318
|
-
});
|
|
1319
|
-
/**
|
|
1320
|
-
* GoogleSearch
|
|
1321
|
-
* Tool to support Google Search in Model. Powered by Google.
|
|
1322
|
-
*/
|
|
1323
|
-
export const zGoogleSearchOutput = z.object({
|
|
1324
|
-
timeRangeFilter: z.union([zGoogleGenaiTypesInterval, z.null()]).optional(),
|
|
1325
|
-
});
|
|
1326
|
-
/**
|
|
1327
|
-
* GoogleSearchRetrieval
|
|
1328
|
-
* Tool to retrieve public web data for grounding, powered by Google.
|
|
1329
|
-
*/
|
|
1330
|
-
export const zGoogleSearchRetrievalOutput = z.object({
|
|
1331
|
-
dynamicRetrievalConfig: z
|
|
1332
|
-
.union([zDynamicRetrievalConfig, z.null()])
|
|
1333
|
-
.optional(),
|
|
1334
|
-
});
|
|
1335
|
-
/**
|
|
1336
|
-
* AuthConfig
|
|
1337
|
-
* Auth configuration to run the extension.
|
|
1338
|
-
*/
|
|
1339
|
-
export const zGoogleGenaiTypesAuthConfig = z.object({
|
|
1340
|
-
apiKeyConfig: z.union([zApiKeyConfig, z.null()]).optional(),
|
|
1341
|
-
authType: z.union([zAuthType, z.null()]).optional(),
|
|
1342
|
-
googleServiceAccountConfig: z
|
|
1343
|
-
.union([zAuthConfigGoogleServiceAccountConfig, z.null()])
|
|
1344
|
-
.optional(),
|
|
1345
|
-
httpBasicAuthConfig: z
|
|
1346
|
-
.union([zAuthConfigHttpBasicAuthConfig, z.null()])
|
|
1347
|
-
.optional(),
|
|
1348
|
-
oauthConfig: z.union([zAuthConfigOauthConfig, z.null()]).optional(),
|
|
1349
|
-
oidcConfig: z.union([zAuthConfigOidcConfig, z.null()]).optional(),
|
|
1350
|
-
});
|
|
1351
|
-
/**
|
|
1352
|
-
* GoogleMaps
|
|
1353
|
-
* Tool to support Google Maps in Model.
|
|
1354
|
-
*/
|
|
1355
|
-
export const zGoogleMapsOutput = z.object({
|
|
1356
|
-
authConfig: z.union([zGoogleGenaiTypesAuthConfig, z.null()]).optional(),
|
|
1357
|
-
});
|
|
1358
|
-
/**
|
|
1359
|
-
* UrlContext
|
|
1360
|
-
* Tool to support URL context retrieval.
|
|
1361
|
-
*/
|
|
1362
|
-
export const zUrlContext = z.object({});
|
|
1363
|
-
/**
|
|
1364
|
-
* ToolCodeExecution
|
|
1365
|
-
* Tool that executes code generated by the model, and automatically returns the result to the model.
|
|
1366
|
-
*
|
|
1367
|
-
* See also [ExecutableCode]and [CodeExecutionResult] which are input and output
|
|
1368
|
-
* to this tool.
|
|
1369
|
-
*/
|
|
1370
|
-
export const zToolCodeExecution = z.object({});
|
|
1371
|
-
/**
|
|
1372
|
-
* Tool
|
|
1373
|
-
* Tool details of a tool that the model may use to generate a response.
|
|
1374
|
-
*/
|
|
1375
|
-
export const zGoogleGenaiTypesToolOutput = z.object({
|
|
1376
|
-
functionDeclarations: z
|
|
1377
|
-
.union([z.array(zFunctionDeclarationOutput), z.null()])
|
|
1378
|
-
.optional(),
|
|
1379
|
-
retrieval: z.union([zRetrievalOutput, z.null()]).optional(),
|
|
1380
|
-
googleSearch: z.union([zGoogleSearchOutput, z.null()]).optional(),
|
|
1381
|
-
googleSearchRetrieval: z
|
|
1382
|
-
.union([zGoogleSearchRetrievalOutput, z.null()])
|
|
1383
|
-
.optional(),
|
|
1384
|
-
enterpriseWebSearch: z.union([zEnterpriseWebSearch, z.null()]).optional(),
|
|
1385
|
-
googleMaps: z.union([zGoogleMapsOutput, z.null()]).optional(),
|
|
1386
|
-
urlContext: z.union([zUrlContext, z.null()]).optional(),
|
|
1387
|
-
codeExecution: z.union([zToolCodeExecution, z.null()]).optional(),
|
|
1388
|
-
});
|
|
1750
|
+
"HARM_CATEGORY_UNSPECIFIED",
|
|
1751
|
+
"HARM_CATEGORY_HATE_SPEECH",
|
|
1752
|
+
"HARM_CATEGORY_DANGEROUS_CONTENT",
|
|
1753
|
+
"HARM_CATEGORY_HARASSMENT",
|
|
1754
|
+
"HARM_CATEGORY_SEXUALLY_EXPLICIT",
|
|
1755
|
+
"HARM_CATEGORY_CIVIC_INTEGRITY",
|
|
1756
|
+
]);
|
|
1389
1757
|
/**
|
|
1390
|
-
*
|
|
1391
|
-
*
|
|
1392
|
-
*
|
|
1393
|
-
* NOTE: all properties in ToolAnnotations are **hints**.
|
|
1394
|
-
* They are not guaranteed to provide a faithful description of
|
|
1395
|
-
* tool behavior (including descriptive properties like `title`).
|
|
1396
|
-
*
|
|
1397
|
-
* Clients should never make tool use decisions based on ToolAnnotations
|
|
1398
|
-
* received from untrusted servers.
|
|
1758
|
+
* HarmBlockThreshold
|
|
1759
|
+
* Required. The harm block threshold.
|
|
1399
1760
|
*/
|
|
1400
|
-
export const
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1761
|
+
export const zHarmBlockThreshold = z.enum([
|
|
1762
|
+
"HARM_BLOCK_THRESHOLD_UNSPECIFIED",
|
|
1763
|
+
"BLOCK_LOW_AND_ABOVE",
|
|
1764
|
+
"BLOCK_MEDIUM_AND_ABOVE",
|
|
1765
|
+
"BLOCK_ONLY_HIGH",
|
|
1766
|
+
"BLOCK_NONE",
|
|
1767
|
+
"OFF",
|
|
1768
|
+
]);
|
|
1407
1769
|
/**
|
|
1408
|
-
*
|
|
1409
|
-
*
|
|
1770
|
+
* SafetySetting
|
|
1771
|
+
* Safety settings.
|
|
1410
1772
|
*/
|
|
1411
|
-
export const
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
annotations: z.union([zToolAnnotations, z.null()]).optional(),
|
|
1773
|
+
export const zSafetySetting = z.object({
|
|
1774
|
+
method: z.optional(z.union([zHarmBlockMethod, z.null()])),
|
|
1775
|
+
category: z.optional(z.union([zHarmCategory, z.null()])),
|
|
1776
|
+
threshold: z.optional(z.union([zHarmBlockThreshold, z.null()])),
|
|
1416
1777
|
});
|
|
1417
1778
|
/**
|
|
1418
1779
|
* FunctionCallingConfigMode
|
|
@@ -1429,8 +1790,8 @@ export const zFunctionCallingConfigMode = z.enum([
|
|
|
1429
1790
|
* Function calling config.
|
|
1430
1791
|
*/
|
|
1431
1792
|
export const zFunctionCallingConfig = z.object({
|
|
1432
|
-
mode: z.union([zFunctionCallingConfigMode, z.null()])
|
|
1433
|
-
allowedFunctionNames: z.union([z.array(z.string()), z.null()])
|
|
1793
|
+
mode: z.optional(z.union([zFunctionCallingConfigMode, z.null()])),
|
|
1794
|
+
allowedFunctionNames: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
1434
1795
|
});
|
|
1435
1796
|
/**
|
|
1436
1797
|
* LatLng
|
|
@@ -1442,16 +1803,16 @@ export const zFunctionCallingConfig = z.object({
|
|
|
1442
1803
|
* WGS84 standard</a>. Values must be within normalized ranges.
|
|
1443
1804
|
*/
|
|
1444
1805
|
export const zLatLng = z.object({
|
|
1445
|
-
latitude: z.union([z.number(), z.null()])
|
|
1446
|
-
longitude: z.union([z.number(), z.null()])
|
|
1806
|
+
latitude: z.optional(z.union([z.number(), z.null()])),
|
|
1807
|
+
longitude: z.optional(z.union([z.number(), z.null()])),
|
|
1447
1808
|
});
|
|
1448
1809
|
/**
|
|
1449
1810
|
* RetrievalConfig
|
|
1450
1811
|
* Retrieval config.
|
|
1451
1812
|
*/
|
|
1452
1813
|
export const zRetrievalConfig = z.object({
|
|
1453
|
-
latLng: z.union([zLatLng, z.null()])
|
|
1454
|
-
languageCode: z.union([z.string(), z.null()])
|
|
1814
|
+
latLng: z.optional(z.union([zLatLng, z.null()])),
|
|
1815
|
+
languageCode: z.optional(z.union([z.string(), z.null()])),
|
|
1455
1816
|
});
|
|
1456
1817
|
/**
|
|
1457
1818
|
* ToolConfig
|
|
@@ -1460,8 +1821,8 @@ export const zRetrievalConfig = z.object({
|
|
|
1460
1821
|
* This config is shared for all tools provided in the request.
|
|
1461
1822
|
*/
|
|
1462
1823
|
export const zToolConfigOutput = z.object({
|
|
1463
|
-
functionCallingConfig: z.union([zFunctionCallingConfig, z.null()])
|
|
1464
|
-
retrievalConfig: z.union([zRetrievalConfig, z.null()])
|
|
1824
|
+
functionCallingConfig: z.optional(z.union([zFunctionCallingConfig, z.null()])),
|
|
1825
|
+
retrievalConfig: z.optional(z.union([zRetrievalConfig, z.null()])),
|
|
1465
1826
|
});
|
|
1466
1827
|
/**
|
|
1467
1828
|
* MediaResolution
|
|
@@ -1478,50 +1839,46 @@ export const zMediaResolution = z.enum([
|
|
|
1478
1839
|
* The configuration for the prebuilt speaker to use.
|
|
1479
1840
|
*/
|
|
1480
1841
|
export const zPrebuiltVoiceConfig = z.object({
|
|
1481
|
-
voiceName: z.union([z.string(), z.null()])
|
|
1842
|
+
voiceName: z.optional(z.union([z.string(), z.null()])),
|
|
1482
1843
|
});
|
|
1483
1844
|
/**
|
|
1484
1845
|
* VoiceConfig
|
|
1485
1846
|
* The configuration for the voice to use.
|
|
1486
1847
|
*/
|
|
1487
1848
|
export const zVoiceConfig = z.object({
|
|
1488
|
-
prebuiltVoiceConfig: z.union([zPrebuiltVoiceConfig, z.null()])
|
|
1849
|
+
prebuiltVoiceConfig: z.optional(z.union([zPrebuiltVoiceConfig, z.null()])),
|
|
1489
1850
|
});
|
|
1490
1851
|
/**
|
|
1491
1852
|
* SpeakerVoiceConfig
|
|
1492
1853
|
* The configuration for the speaker to use.
|
|
1493
1854
|
*/
|
|
1494
1855
|
export const zSpeakerVoiceConfigOutput = z.object({
|
|
1495
|
-
speaker: z.union([z.string(), z.null()])
|
|
1496
|
-
voiceConfig: z.union([zVoiceConfig, z.null()])
|
|
1856
|
+
speaker: z.optional(z.union([z.string(), z.null()])),
|
|
1857
|
+
voiceConfig: z.optional(z.union([zVoiceConfig, z.null()])),
|
|
1497
1858
|
});
|
|
1498
1859
|
/**
|
|
1499
1860
|
* MultiSpeakerVoiceConfig
|
|
1500
1861
|
* The configuration for the multi-speaker setup.
|
|
1501
1862
|
*/
|
|
1502
1863
|
export const zMultiSpeakerVoiceConfigOutput = z.object({
|
|
1503
|
-
speakerVoiceConfigs: z
|
|
1504
|
-
.union([z.array(zSpeakerVoiceConfigOutput), z.null()])
|
|
1505
|
-
.optional(),
|
|
1864
|
+
speakerVoiceConfigs: z.optional(z.union([z.array(zSpeakerVoiceConfigOutput), z.null()])),
|
|
1506
1865
|
});
|
|
1507
1866
|
/**
|
|
1508
1867
|
* SpeechConfig
|
|
1509
1868
|
* The speech generation configuration.
|
|
1510
1869
|
*/
|
|
1511
1870
|
export const zSpeechConfigOutput = z.object({
|
|
1512
|
-
voiceConfig: z.union([zVoiceConfig, z.null()])
|
|
1513
|
-
multiSpeakerVoiceConfig: z
|
|
1514
|
-
|
|
1515
|
-
.optional(),
|
|
1516
|
-
languageCode: z.union([z.string(), z.null()]).optional(),
|
|
1871
|
+
voiceConfig: z.optional(z.union([zVoiceConfig, z.null()])),
|
|
1872
|
+
multiSpeakerVoiceConfig: z.optional(z.union([zMultiSpeakerVoiceConfigOutput, z.null()])),
|
|
1873
|
+
languageCode: z.optional(z.union([z.string(), z.null()])),
|
|
1517
1874
|
});
|
|
1518
1875
|
/**
|
|
1519
1876
|
* ThinkingConfig
|
|
1520
1877
|
* The thinking features configuration.
|
|
1521
1878
|
*/
|
|
1522
1879
|
export const zThinkingConfig = z.object({
|
|
1523
|
-
includeThoughts: z.union([z.boolean(), z.null()])
|
|
1524
|
-
thinkingBudget: z.union([z.
|
|
1880
|
+
includeThoughts: z.optional(z.union([z.boolean(), z.null()])),
|
|
1881
|
+
thinkingBudget: z.optional(z.union([z.int(), z.null()])),
|
|
1525
1882
|
});
|
|
1526
1883
|
/**
|
|
1527
1884
|
* GenerateContentConfig
|
|
@@ -1531,62 +1888,54 @@ export const zThinkingConfig = z.object({
|
|
|
1531
1888
|
* <https://cloud.google.com/vertex-ai/generative-ai/docs/multimodal/content-generation-parameters>`_.
|
|
1532
1889
|
*/
|
|
1533
1890
|
export const zGenerateContentConfigOutput = z.object({
|
|
1534
|
-
httpOptions: z.union([zHttpOptions, z.null()])
|
|
1535
|
-
systemInstruction: z
|
|
1536
|
-
.union([
|
|
1891
|
+
httpOptions: z.optional(z.union([zHttpOptions, z.null()])),
|
|
1892
|
+
systemInstruction: z.optional(z.union([
|
|
1537
1893
|
zContentOutput,
|
|
1538
1894
|
z.array(z.union([zFile, zPartOutput, z.string()])),
|
|
1539
1895
|
zFile,
|
|
1540
1896
|
zPartOutput,
|
|
1541
1897
|
z.string(),
|
|
1542
1898
|
z.null(),
|
|
1543
|
-
])
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
tools: z
|
|
1563
|
-
.union([
|
|
1899
|
+
])),
|
|
1900
|
+
temperature: z.optional(z.union([z.number(), z.null()])),
|
|
1901
|
+
topP: z.optional(z.union([z.number(), z.null()])),
|
|
1902
|
+
topK: z.optional(z.union([z.number(), z.null()])),
|
|
1903
|
+
candidateCount: z.optional(z.union([z.int(), z.null()])),
|
|
1904
|
+
maxOutputTokens: z.optional(z.union([z.int(), z.null()])),
|
|
1905
|
+
stopSequences: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
1906
|
+
responseLogprobs: z.optional(z.union([z.boolean(), z.null()])),
|
|
1907
|
+
logprobs: z.optional(z.union([z.int(), z.null()])),
|
|
1908
|
+
presencePenalty: z.optional(z.union([z.number(), z.null()])),
|
|
1909
|
+
frequencyPenalty: z.optional(z.union([z.number(), z.null()])),
|
|
1910
|
+
seed: z.optional(z.union([z.int(), z.null()])),
|
|
1911
|
+
responseMimeType: z.optional(z.union([z.string(), z.null()])),
|
|
1912
|
+
responseSchema: z.optional(z.union([z.record(z.string(), z.unknown()), zSchemaOutput, z.null()])),
|
|
1913
|
+
responseJsonSchema: z.optional(z.union([z.unknown(), z.null()])),
|
|
1914
|
+
routingConfig: z.optional(z.union([zGenerationConfigRoutingConfig, z.null()])),
|
|
1915
|
+
modelSelectionConfig: z.optional(z.union([zModelSelectionConfig, z.null()])),
|
|
1916
|
+
safetySettings: z.optional(z.union([z.array(zSafetySetting), z.null()])),
|
|
1917
|
+
tools: z.optional(z.union([
|
|
1564
1918
|
z.array(z.union([zGoogleGenaiTypesToolOutput, zMcpTypesTool])),
|
|
1565
1919
|
z.null(),
|
|
1566
|
-
])
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
.union([zAutomaticFunctionCallingConfig, z.null()])
|
|
1577
|
-
.optional(),
|
|
1578
|
-
thinkingConfig: z.union([zThinkingConfig, z.null()]).optional(),
|
|
1920
|
+
])),
|
|
1921
|
+
toolConfig: z.optional(z.union([zToolConfigOutput, z.null()])),
|
|
1922
|
+
labels: z.optional(z.union([z.record(z.string(), z.string()), z.null()])),
|
|
1923
|
+
cachedContent: z.optional(z.union([z.string(), z.null()])),
|
|
1924
|
+
responseModalities: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
1925
|
+
mediaResolution: z.optional(z.union([zMediaResolution, z.null()])),
|
|
1926
|
+
speechConfig: z.optional(z.union([zSpeechConfigOutput, z.string(), z.null()])),
|
|
1927
|
+
audioTimestamp: z.optional(z.union([z.boolean(), z.null()])),
|
|
1928
|
+
automaticFunctionCalling: z.optional(z.union([zAutomaticFunctionCallingConfig, z.null()])),
|
|
1929
|
+
thinkingConfig: z.optional(z.union([zThinkingConfig, z.null()])),
|
|
1579
1930
|
});
|
|
1580
1931
|
/**
|
|
1581
1932
|
* JudgeModelOptions
|
|
1582
1933
|
* Options for an eval metric's judge model.
|
|
1583
1934
|
*/
|
|
1584
1935
|
export const zJudgeModelOptionsOutput = z.object({
|
|
1585
|
-
judgeModel: z.
|
|
1586
|
-
judgeModelConfig: z
|
|
1587
|
-
|
|
1588
|
-
.optional(),
|
|
1589
|
-
numSamples: z.number().int().optional().default(5),
|
|
1936
|
+
judgeModel: z.optional(z.string()).default("gemini-2.5-flash"),
|
|
1937
|
+
judgeModelConfig: z.optional(z.union([zGenerateContentConfigOutput, z.null()])),
|
|
1938
|
+
numSamples: z.optional(z.int()).default(5),
|
|
1590
1939
|
});
|
|
1591
1940
|
/**
|
|
1592
1941
|
* EvalMetric
|
|
@@ -1595,8 +1944,8 @@ export const zJudgeModelOptionsOutput = z.object({
|
|
|
1595
1944
|
export const zEvalMetricOutput = z.object({
|
|
1596
1945
|
metricName: z.string(),
|
|
1597
1946
|
threshold: z.number(),
|
|
1598
|
-
judgeModelOptions: z.union([zJudgeModelOptionsOutput, z.null()])
|
|
1599
|
-
criterion: z.union([zBaseCriterion, z.null()])
|
|
1947
|
+
judgeModelOptions: z.optional(z.union([zJudgeModelOptionsOutput, z.null()])),
|
|
1948
|
+
criterion: z.optional(z.union([zBaseCriterion, z.null()])),
|
|
1600
1949
|
});
|
|
1601
1950
|
/**
|
|
1602
1951
|
* RubricScore
|
|
@@ -1604,14 +1953,14 @@ export const zEvalMetricOutput = z.object({
|
|
|
1604
1953
|
*/
|
|
1605
1954
|
export const zRubricScore = z.object({
|
|
1606
1955
|
rubricId: z.string(),
|
|
1607
|
-
rationale: z.union([z.string(), z.null()])
|
|
1608
|
-
score: z.union([z.number(), z.null()])
|
|
1956
|
+
rationale: z.optional(z.union([z.string(), z.null()])),
|
|
1957
|
+
score: z.optional(z.union([z.number(), z.null()])),
|
|
1609
1958
|
});
|
|
1610
1959
|
/**
|
|
1611
1960
|
* EvalMetricResultDetails
|
|
1612
1961
|
*/
|
|
1613
1962
|
export const zEvalMetricResultDetails = z.object({
|
|
1614
|
-
rubricScores: z.union([z.array(zRubricScore), z.null()])
|
|
1963
|
+
rubricScores: z.optional(z.union([z.array(zRubricScore), z.null()])),
|
|
1615
1964
|
});
|
|
1616
1965
|
/**
|
|
1617
1966
|
* EvalMetricResult
|
|
@@ -1620,11 +1969,11 @@ export const zEvalMetricResultDetails = z.object({
|
|
|
1620
1969
|
export const zEvalMetricResult = z.object({
|
|
1621
1970
|
metricName: z.string(),
|
|
1622
1971
|
threshold: z.number(),
|
|
1623
|
-
judgeModelOptions: z.union([zJudgeModelOptionsOutput, z.null()])
|
|
1624
|
-
criterion: z.union([zBaseCriterion, z.null()])
|
|
1625
|
-
score: z.union([z.number(), z.null()])
|
|
1972
|
+
judgeModelOptions: z.optional(z.union([zJudgeModelOptionsOutput, z.null()])),
|
|
1973
|
+
criterion: z.optional(z.union([zBaseCriterion, z.null()])),
|
|
1974
|
+
score: z.optional(z.union([z.number(), z.null()])),
|
|
1626
1975
|
evalStatus: zEvalStatus,
|
|
1627
|
-
details:
|
|
1976
|
+
details: z.optional(zEvalMetricResultDetails),
|
|
1628
1977
|
});
|
|
1629
1978
|
/**
|
|
1630
1979
|
* EvalMetricResultPerInvocation
|
|
@@ -1633,79 +1982,112 @@ export const zEvalMetricResult = z.object({
|
|
|
1633
1982
|
export const zEvalMetricResultPerInvocation = z.object({
|
|
1634
1983
|
actualInvocation: zInvocationOutput,
|
|
1635
1984
|
expectedInvocation: zInvocationOutput,
|
|
1636
|
-
evalMetricResults: z.array(zEvalMetricResult)
|
|
1985
|
+
evalMetricResults: z.optional(z.array(zEvalMetricResult)).default([]),
|
|
1637
1986
|
});
|
|
1638
1987
|
/**
|
|
1639
1988
|
* GroundingChunkRetrievedContext
|
|
1640
1989
|
* Chunk from context retrieved by the retrieval tools.
|
|
1641
1990
|
*/
|
|
1642
1991
|
export const zGroundingChunkRetrievedContextOutput = z.object({
|
|
1643
|
-
ragChunk: z.union([zRagChunk, z.null()])
|
|
1644
|
-
text: z.union([z.string(), z.null()])
|
|
1645
|
-
title: z.union([z.string(), z.null()])
|
|
1646
|
-
uri: z.union([z.string(), z.null()])
|
|
1992
|
+
ragChunk: z.optional(z.union([zRagChunk, z.null()])),
|
|
1993
|
+
text: z.optional(z.union([z.string(), z.null()])),
|
|
1994
|
+
title: z.optional(z.union([z.string(), z.null()])),
|
|
1995
|
+
uri: z.optional(z.union([z.string(), z.null()])),
|
|
1647
1996
|
});
|
|
1648
1997
|
/**
|
|
1649
1998
|
* GroundingChunk
|
|
1650
1999
|
* Grounding chunk.
|
|
1651
2000
|
*/
|
|
1652
2001
|
export const zGroundingChunkOutput = z.object({
|
|
1653
|
-
retrievedContext: z
|
|
1654
|
-
|
|
1655
|
-
.optional(),
|
|
1656
|
-
web: z.union([zGroundingChunkWeb, z.null()]).optional(),
|
|
2002
|
+
retrievedContext: z.optional(z.union([zGroundingChunkRetrievedContextOutput, z.null()])),
|
|
2003
|
+
web: z.optional(z.union([zGroundingChunkWeb, z.null()])),
|
|
1657
2004
|
});
|
|
1658
2005
|
/**
|
|
1659
2006
|
* GroundingMetadata
|
|
1660
2007
|
* Metadata returned to client when grounding is enabled.
|
|
1661
2008
|
*/
|
|
1662
2009
|
export const zGroundingMetadataOutput = z.object({
|
|
1663
|
-
groundingChunks: z
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
searchEntryPoint: z.union([zSearchEntryPoint, z.null()]).optional(),
|
|
1670
|
-
webSearchQueries: z.union([z.array(z.string()), z.null()]).optional(),
|
|
2010
|
+
groundingChunks: z.optional(z.union([z.array(zGroundingChunkOutput), z.null()])),
|
|
2011
|
+
groundingSupports: z.optional(z.union([z.array(zGroundingSupport), z.null()])),
|
|
2012
|
+
retrievalMetadata: z.optional(z.union([zRetrievalMetadata, z.null()])),
|
|
2013
|
+
retrievalQueries: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
2014
|
+
searchEntryPoint: z.optional(z.union([zSearchEntryPoint, z.null()])),
|
|
2015
|
+
webSearchQueries: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
1671
2016
|
});
|
|
1672
2017
|
/**
|
|
1673
2018
|
* GenerateContentResponseUsageMetadata
|
|
1674
2019
|
* Usage metadata about response(s).
|
|
1675
2020
|
*/
|
|
1676
2021
|
export const zGenerateContentResponseUsageMetadataOutput = z.object({
|
|
1677
|
-
cacheTokensDetails: z
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
2022
|
+
cacheTokensDetails: z.optional(z.union([z.array(zModalityTokenCount), z.null()])),
|
|
2023
|
+
cachedContentTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
2024
|
+
candidatesTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
2025
|
+
candidatesTokensDetails: z.optional(z.union([z.array(zModalityTokenCount), z.null()])),
|
|
2026
|
+
promptTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
2027
|
+
promptTokensDetails: z.optional(z.union([z.array(zModalityTokenCount), z.null()])),
|
|
2028
|
+
thoughtsTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
2029
|
+
toolUsePromptTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
2030
|
+
toolUsePromptTokensDetails: z.optional(z.union([z.array(zModalityTokenCount), z.null()])),
|
|
2031
|
+
totalTokenCount: z.optional(z.union([z.int(), z.null()])),
|
|
2032
|
+
trafficType: z.optional(z.union([zTrafficType, z.null()])),
|
|
2033
|
+
});
|
|
2034
|
+
/**
|
|
2035
|
+
* LogprobsResult
|
|
2036
|
+
* Logprobs Result
|
|
2037
|
+
*/
|
|
2038
|
+
export const zLogprobsResultOutput = z.object({
|
|
2039
|
+
chosenCandidates: z.optional(z.union([z.array(zLogprobsResultCandidate), z.null()])),
|
|
2040
|
+
topCandidates: z.optional(z.union([z.array(zLogprobsResultTopCandidates), z.null()])),
|
|
2041
|
+
});
|
|
2042
|
+
/**
|
|
2043
|
+
* OAuth2
|
|
2044
|
+
*/
|
|
2045
|
+
export const zOAuth2Output = z.object({
|
|
2046
|
+
type: z.optional(zSecuritySchemeType),
|
|
2047
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
2048
|
+
flows: zOAuthFlows,
|
|
2049
|
+
});
|
|
2050
|
+
/**
|
|
2051
|
+
* AuthConfig
|
|
2052
|
+
* The auth config sent by tool asking client to collect auth credentials and
|
|
2053
|
+
*
|
|
2054
|
+
* adk and client will help to fill in the response
|
|
2055
|
+
*/
|
|
2056
|
+
export const zGoogleAdkAuthAuthToolAuthConfigOutput = z.object({
|
|
2057
|
+
authScheme: z.union([
|
|
2058
|
+
zApiKey,
|
|
2059
|
+
zHttpBase,
|
|
2060
|
+
zOAuth2Output,
|
|
2061
|
+
zOpenIdConnect,
|
|
2062
|
+
zHttpBearer,
|
|
2063
|
+
zOpenIdConnectWithConfig,
|
|
2064
|
+
]),
|
|
2065
|
+
rawAuthCredential: z.optional(z.union([zAuthCredentialOutput, z.null()])),
|
|
2066
|
+
exchangedAuthCredential: z.optional(z.union([zAuthCredentialOutput, z.null()])),
|
|
2067
|
+
credentialKey: z.optional(z.union([z.string(), z.null()])),
|
|
2068
|
+
});
|
|
2069
|
+
/**
|
|
2070
|
+
* EventCompaction
|
|
2071
|
+
* The compaction of the events.
|
|
2072
|
+
*/
|
|
2073
|
+
export const zEventCompactionOutput = z.object({
|
|
2074
|
+
startTimestamp: z.number(),
|
|
2075
|
+
endTimestamp: z.number(),
|
|
2076
|
+
compactedContent: zContentOutput,
|
|
1696
2077
|
});
|
|
1697
2078
|
/**
|
|
1698
2079
|
* EventActions
|
|
1699
2080
|
* Represents the actions attached to an event.
|
|
1700
2081
|
*/
|
|
1701
2082
|
export const zEventActionsOutput = z.object({
|
|
1702
|
-
skipSummarization: z.union([z.boolean(), z.null()])
|
|
1703
|
-
stateDelta: z.
|
|
1704
|
-
artifactDelta: z.
|
|
1705
|
-
transferToAgent: z.union([z.string(), z.null()])
|
|
1706
|
-
escalate: z.union([z.boolean(), z.null()])
|
|
1707
|
-
requestedAuthConfigs: z.
|
|
1708
|
-
requestedToolConfirmations: z.
|
|
2083
|
+
skipSummarization: z.optional(z.union([z.boolean(), z.null()])),
|
|
2084
|
+
stateDelta: z.optional(z.record(z.string(), z.unknown())),
|
|
2085
|
+
artifactDelta: z.optional(z.record(z.string(), z.int())),
|
|
2086
|
+
transferToAgent: z.optional(z.union([z.string(), z.null()])),
|
|
2087
|
+
escalate: z.optional(z.union([z.boolean(), z.null()])),
|
|
2088
|
+
requestedAuthConfigs: z.optional(z.record(z.string(), zGoogleAdkAuthAuthToolAuthConfigOutput)),
|
|
2089
|
+
requestedToolConfirmations: z.optional(z.record(z.string(), zToolConfirmation)),
|
|
2090
|
+
compaction: z.optional(z.union([zEventCompactionOutput, z.null()])),
|
|
1709
2091
|
});
|
|
1710
2092
|
/**
|
|
1711
2093
|
* Event
|
|
@@ -1715,30 +2097,29 @@ export const zEventActionsOutput = z.object({
|
|
|
1715
2097
|
* taken by the agents like function calls, etc.
|
|
1716
2098
|
*/
|
|
1717
2099
|
export const zEventOutput = z.object({
|
|
1718
|
-
content: z.union([zContentOutput, z.null()])
|
|
1719
|
-
groundingMetadata: z.union([zGroundingMetadataOutput, z.null()])
|
|
1720
|
-
partial: z.union([z.boolean(), z.null()])
|
|
1721
|
-
turnComplete: z.union([z.boolean(), z.null()])
|
|
1722
|
-
finishReason: z.union([zFinishReason, z.null()])
|
|
1723
|
-
errorCode: z.union([z.string(), z.null()])
|
|
1724
|
-
errorMessage: z.union([z.string(), z.null()])
|
|
1725
|
-
interrupted: z.union([z.boolean(), z.null()])
|
|
1726
|
-
customMetadata: z.union([z.
|
|
1727
|
-
usageMetadata: z
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
invocationId: z.string().optional().default(""),
|
|
2100
|
+
content: z.optional(z.union([zContentOutput, z.null()])),
|
|
2101
|
+
groundingMetadata: z.optional(z.union([zGroundingMetadataOutput, z.null()])),
|
|
2102
|
+
partial: z.optional(z.union([z.boolean(), z.null()])),
|
|
2103
|
+
turnComplete: z.optional(z.union([z.boolean(), z.null()])),
|
|
2104
|
+
finishReason: z.optional(z.union([zFinishReason, z.null()])),
|
|
2105
|
+
errorCode: z.optional(z.union([z.string(), z.null()])),
|
|
2106
|
+
errorMessage: z.optional(z.union([z.string(), z.null()])),
|
|
2107
|
+
interrupted: z.optional(z.union([z.boolean(), z.null()])),
|
|
2108
|
+
customMetadata: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
2109
|
+
usageMetadata: z.optional(z.union([zGenerateContentResponseUsageMetadataOutput, z.null()])),
|
|
2110
|
+
liveSessionResumptionUpdate: z.optional(z.union([zLiveServerSessionResumptionUpdate, z.null()])),
|
|
2111
|
+
inputTranscription: z.optional(z.union([zTranscription, z.null()])),
|
|
2112
|
+
outputTranscription: z.optional(z.union([zTranscription, z.null()])),
|
|
2113
|
+
avgLogprobs: z.optional(z.union([z.number(), z.null()])),
|
|
2114
|
+
logprobsResult: z.optional(z.union([zLogprobsResultOutput, z.null()])),
|
|
2115
|
+
cacheMetadata: z.optional(z.union([zCacheMetadata, z.null()])),
|
|
2116
|
+
invocationId: z.optional(z.string()).default(""),
|
|
1736
2117
|
author: z.string(),
|
|
1737
|
-
actions:
|
|
1738
|
-
longRunningToolIds: z.union([z.array(z.string()), z.null()])
|
|
1739
|
-
branch: z.union([z.string(), z.null()])
|
|
1740
|
-
id: z.
|
|
1741
|
-
timestamp: z.
|
|
2118
|
+
actions: z.optional(zEventActionsOutput),
|
|
2119
|
+
longRunningToolIds: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
2120
|
+
branch: z.optional(z.union([z.string(), z.null()])),
|
|
2121
|
+
id: z.optional(z.string()).default(""),
|
|
2122
|
+
timestamp: z.optional(z.number()),
|
|
1742
2123
|
});
|
|
1743
2124
|
/**
|
|
1744
2125
|
* Session
|
|
@@ -1748,179 +2129,28 @@ export const zSession = z.object({
|
|
|
1748
2129
|
id: z.string(),
|
|
1749
2130
|
appName: z.string(),
|
|
1750
2131
|
userId: z.string(),
|
|
1751
|
-
state: z.
|
|
1752
|
-
events: z.array(zEventOutput)
|
|
1753
|
-
lastUpdateTime: z.
|
|
2132
|
+
state: z.optional(z.record(z.string(), z.unknown())),
|
|
2133
|
+
events: z.optional(z.array(zEventOutput)),
|
|
2134
|
+
lastUpdateTime: z.optional(z.number()).default(0),
|
|
1754
2135
|
});
|
|
1755
2136
|
/**
|
|
1756
2137
|
* EvalCaseResult
|
|
1757
2138
|
* Case level evaluation results.
|
|
1758
2139
|
*/
|
|
1759
2140
|
export const zEvalCaseResult = z.object({
|
|
1760
|
-
evalSetFile: z.union([z.string(), z.null()])
|
|
1761
|
-
evalSetId: z.
|
|
1762
|
-
evalId: z.
|
|
2141
|
+
evalSetFile: z.optional(z.union([z.string(), z.null()])),
|
|
2142
|
+
evalSetId: z.optional(z.string()).default(""),
|
|
2143
|
+
evalId: z.optional(z.string()).default(""),
|
|
1763
2144
|
finalEvalStatus: zEvalStatus,
|
|
1764
|
-
evalMetricResults: z
|
|
1765
|
-
|
|
1766
|
-
.
|
|
2145
|
+
evalMetricResults: z.optional(z.union([
|
|
2146
|
+
z.array(z.tuple([zEvalMetricOutput, zEvalMetricResult])),
|
|
2147
|
+
z.null(),
|
|
2148
|
+
])),
|
|
1767
2149
|
overallEvalMetricResults: z.array(zEvalMetricResult),
|
|
1768
2150
|
evalMetricResultPerInvocation: z.array(zEvalMetricResultPerInvocation),
|
|
1769
2151
|
sessionId: z.string(),
|
|
1770
|
-
sessionDetails: z.union([zSession, z.null()])
|
|
1771
|
-
userId: z.union([z.string(), z.null()])
|
|
1772
|
-
});
|
|
1773
|
-
/**
|
|
1774
|
-
* Schema
|
|
1775
|
-
* Schema is used to define the format of input/output data.
|
|
1776
|
-
*
|
|
1777
|
-
* Represents a select subset of an [OpenAPI 3.0 schema
|
|
1778
|
-
* object](https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may
|
|
1779
|
-
* be added in the future as needed.
|
|
1780
|
-
*/
|
|
1781
|
-
export const zSchemaInput = z.object({
|
|
1782
|
-
additionalProperties: z.union([z.unknown(), z.null()]).optional(),
|
|
1783
|
-
defs: z.union([z.object({}), z.null()]).optional(),
|
|
1784
|
-
ref: z.union([z.string(), z.null()]).optional(),
|
|
1785
|
-
anyOf: z
|
|
1786
|
-
.union([
|
|
1787
|
-
z.array(z.lazy(() => {
|
|
1788
|
-
return zSchemaInput;
|
|
1789
|
-
})),
|
|
1790
|
-
z.null(),
|
|
1791
|
-
])
|
|
1792
|
-
.optional(),
|
|
1793
|
-
default: z.union([z.unknown(), z.null()]).optional(),
|
|
1794
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
1795
|
-
enum: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1796
|
-
example: z.union([z.unknown(), z.null()]).optional(),
|
|
1797
|
-
format: z.union([z.string(), z.null()]).optional(),
|
|
1798
|
-
items: z
|
|
1799
|
-
.union([
|
|
1800
|
-
z.lazy(() => {
|
|
1801
|
-
return zSchemaInput;
|
|
1802
|
-
}),
|
|
1803
|
-
z.null(),
|
|
1804
|
-
])
|
|
1805
|
-
.optional(),
|
|
1806
|
-
maxItems: z.union([z.number().int(), z.null()]).optional(),
|
|
1807
|
-
maxLength: z.union([z.number().int(), z.null()]).optional(),
|
|
1808
|
-
maxProperties: z.union([z.number().int(), z.null()]).optional(),
|
|
1809
|
-
maximum: z.union([z.number(), z.null()]).optional(),
|
|
1810
|
-
minItems: z.union([z.number().int(), z.null()]).optional(),
|
|
1811
|
-
minLength: z.union([z.number().int(), z.null()]).optional(),
|
|
1812
|
-
minProperties: z.union([z.number().int(), z.null()]).optional(),
|
|
1813
|
-
minimum: z.union([z.number(), z.null()]).optional(),
|
|
1814
|
-
nullable: z.union([z.boolean(), z.null()]).optional(),
|
|
1815
|
-
pattern: z.union([z.string(), z.null()]).optional(),
|
|
1816
|
-
properties: z.union([z.object({}), z.null()]).optional(),
|
|
1817
|
-
propertyOrdering: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1818
|
-
required: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1819
|
-
title: z.union([z.string(), z.null()]).optional(),
|
|
1820
|
-
type: z.union([zType, z.null()]).optional(),
|
|
1821
|
-
});
|
|
1822
|
-
/**
|
|
1823
|
-
* FunctionDeclaration
|
|
1824
|
-
* Defines a function that the model can generate JSON inputs for.
|
|
1825
|
-
*
|
|
1826
|
-
* The inputs are based on `OpenAPI 3.0 specifications
|
|
1827
|
-
* <https://spec.openapis.org/oas/v3.0.3>`_.
|
|
1828
|
-
*/
|
|
1829
|
-
export const zFunctionDeclarationInput = z.object({
|
|
1830
|
-
behavior: z.union([zBehavior, z.null()]).optional(),
|
|
1831
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
1832
|
-
name: z.union([z.string(), z.null()]).optional(),
|
|
1833
|
-
parameters: z.union([zSchemaInput, z.null()]).optional(),
|
|
1834
|
-
parametersJsonSchema: z.union([z.unknown(), z.null()]).optional(),
|
|
1835
|
-
response: z.union([zSchemaInput, z.null()]).optional(),
|
|
1836
|
-
responseJsonSchema: z.union([z.unknown(), z.null()]).optional(),
|
|
1837
|
-
});
|
|
1838
|
-
/**
|
|
1839
|
-
* RagRetrievalConfig
|
|
1840
|
-
* Specifies the context retrieval config.
|
|
1841
|
-
*/
|
|
1842
|
-
export const zRagRetrievalConfigInput = z.object({
|
|
1843
|
-
filter: z.union([zRagRetrievalConfigFilter, z.null()]).optional(),
|
|
1844
|
-
hybridSearch: z.union([zRagRetrievalConfigHybridSearch, z.null()]).optional(),
|
|
1845
|
-
ranking: z.union([zRagRetrievalConfigRanking, z.null()]).optional(),
|
|
1846
|
-
topK: z.union([z.number().int(), z.null()]).optional(),
|
|
1847
|
-
});
|
|
1848
|
-
/**
|
|
1849
|
-
* VertexRagStore
|
|
1850
|
-
* Retrieve from Vertex RAG Store for grounding.
|
|
1851
|
-
*/
|
|
1852
|
-
export const zVertexRagStoreInput = z.object({
|
|
1853
|
-
ragCorpora: z.union([z.array(z.string()), z.null()]).optional(),
|
|
1854
|
-
ragResources: z
|
|
1855
|
-
.union([z.array(zVertexRagStoreRagResource), z.null()])
|
|
1856
|
-
.optional(),
|
|
1857
|
-
ragRetrievalConfig: z.union([zRagRetrievalConfigInput, z.null()]).optional(),
|
|
1858
|
-
similarityTopK: z.union([z.number().int(), z.null()]).optional(),
|
|
1859
|
-
storeContext: z.union([z.boolean(), z.null()]).optional(),
|
|
1860
|
-
vectorDistanceThreshold: z.union([z.number(), z.null()]).optional(),
|
|
1861
|
-
});
|
|
1862
|
-
/**
|
|
1863
|
-
* Retrieval
|
|
1864
|
-
* Defines a retrieval tool that model can call to access external knowledge.
|
|
1865
|
-
*/
|
|
1866
|
-
export const zRetrievalInput = z.object({
|
|
1867
|
-
disableAttribution: z.union([z.boolean(), z.null()]).optional(),
|
|
1868
|
-
vertexAiSearch: z.union([zVertexAiSearch, z.null()]).optional(),
|
|
1869
|
-
vertexRagStore: z.union([zVertexRagStoreInput, z.null()]).optional(),
|
|
1870
|
-
});
|
|
1871
|
-
/**
|
|
1872
|
-
* Interval
|
|
1873
|
-
* Represents a time interval, encoded as a start time (inclusive) and an end time (exclusive).
|
|
1874
|
-
*
|
|
1875
|
-
* The start time must be less than or equal to the end time.
|
|
1876
|
-
* When the start equals the end time, the interval is an empty interval.
|
|
1877
|
-
* (matches no time)
|
|
1878
|
-
* When both start and end are unspecified, the interval matches any time.
|
|
1879
|
-
*/
|
|
1880
|
-
export const zIntervalInput = z.object({
|
|
1881
|
-
startTime: z.union([z.string().datetime(), z.null()]).optional(),
|
|
1882
|
-
endTime: z.union([z.string().datetime(), z.null()]).optional(),
|
|
1883
|
-
});
|
|
1884
|
-
/**
|
|
1885
|
-
* GoogleSearch
|
|
1886
|
-
* Tool to support Google Search in Model. Powered by Google.
|
|
1887
|
-
*/
|
|
1888
|
-
export const zGoogleSearchInput = z.object({
|
|
1889
|
-
timeRangeFilter: z.union([zIntervalInput, z.null()]).optional(),
|
|
1890
|
-
});
|
|
1891
|
-
/**
|
|
1892
|
-
* GoogleSearchRetrieval
|
|
1893
|
-
* Tool to retrieve public web data for grounding, powered by Google.
|
|
1894
|
-
*/
|
|
1895
|
-
export const zGoogleSearchRetrievalInput = z.object({
|
|
1896
|
-
dynamicRetrievalConfig: z
|
|
1897
|
-
.union([zDynamicRetrievalConfig, z.null()])
|
|
1898
|
-
.optional(),
|
|
1899
|
-
});
|
|
1900
|
-
/**
|
|
1901
|
-
* GoogleMaps
|
|
1902
|
-
* Tool to support Google Maps in Model.
|
|
1903
|
-
*/
|
|
1904
|
-
export const zGoogleMapsInput = z.object({
|
|
1905
|
-
authConfig: z.union([zGoogleGenaiTypesAuthConfig, z.null()]).optional(),
|
|
1906
|
-
});
|
|
1907
|
-
/**
|
|
1908
|
-
* Tool
|
|
1909
|
-
* Tool details of a tool that the model may use to generate a response.
|
|
1910
|
-
*/
|
|
1911
|
-
export const zGoogleGenaiTypesToolInput = z.object({
|
|
1912
|
-
functionDeclarations: z
|
|
1913
|
-
.union([z.array(zFunctionDeclarationInput), z.null()])
|
|
1914
|
-
.optional(),
|
|
1915
|
-
retrieval: z.union([zRetrievalInput, z.null()]).optional(),
|
|
1916
|
-
googleSearch: z.union([zGoogleSearchInput, z.null()]).optional(),
|
|
1917
|
-
googleSearchRetrieval: z
|
|
1918
|
-
.union([zGoogleSearchRetrievalInput, z.null()])
|
|
1919
|
-
.optional(),
|
|
1920
|
-
enterpriseWebSearch: z.union([zEnterpriseWebSearch, z.null()]).optional(),
|
|
1921
|
-
googleMaps: z.union([zGoogleMapsInput, z.null()]).optional(),
|
|
1922
|
-
urlContext: z.union([zUrlContext, z.null()]).optional(),
|
|
1923
|
-
codeExecution: z.union([zToolCodeExecution, z.null()]).optional(),
|
|
2152
|
+
sessionDetails: z.optional(z.union([zSession, z.null()])),
|
|
2153
|
+
userId: z.optional(z.union([z.string(), z.null()])),
|
|
1924
2154
|
});
|
|
1925
2155
|
/**
|
|
1926
2156
|
* ToolConfig
|
|
@@ -1929,36 +2159,32 @@ export const zGoogleGenaiTypesToolInput = z.object({
|
|
|
1929
2159
|
* This config is shared for all tools provided in the request.
|
|
1930
2160
|
*/
|
|
1931
2161
|
export const zToolConfigInput = z.object({
|
|
1932
|
-
functionCallingConfig: z.union([zFunctionCallingConfig, z.null()])
|
|
1933
|
-
retrievalConfig: z.union([zRetrievalConfig, z.null()])
|
|
2162
|
+
functionCallingConfig: z.optional(z.union([zFunctionCallingConfig, z.null()])),
|
|
2163
|
+
retrievalConfig: z.optional(z.union([zRetrievalConfig, z.null()])),
|
|
1934
2164
|
});
|
|
1935
2165
|
/**
|
|
1936
2166
|
* SpeakerVoiceConfig
|
|
1937
2167
|
* The configuration for the speaker to use.
|
|
1938
2168
|
*/
|
|
1939
2169
|
export const zSpeakerVoiceConfigInput = z.object({
|
|
1940
|
-
speaker: z.union([z.string(), z.null()])
|
|
1941
|
-
voiceConfig: z.union([zVoiceConfig, z.null()])
|
|
2170
|
+
speaker: z.optional(z.union([z.string(), z.null()])),
|
|
2171
|
+
voiceConfig: z.optional(z.union([zVoiceConfig, z.null()])),
|
|
1942
2172
|
});
|
|
1943
2173
|
/**
|
|
1944
2174
|
* MultiSpeakerVoiceConfig
|
|
1945
2175
|
* The configuration for the multi-speaker setup.
|
|
1946
2176
|
*/
|
|
1947
2177
|
export const zMultiSpeakerVoiceConfigInput = z.object({
|
|
1948
|
-
speakerVoiceConfigs: z
|
|
1949
|
-
.union([z.array(zSpeakerVoiceConfigInput), z.null()])
|
|
1950
|
-
.optional(),
|
|
2178
|
+
speakerVoiceConfigs: z.optional(z.union([z.array(zSpeakerVoiceConfigInput), z.null()])),
|
|
1951
2179
|
});
|
|
1952
2180
|
/**
|
|
1953
2181
|
* SpeechConfig
|
|
1954
2182
|
* The speech generation configuration.
|
|
1955
2183
|
*/
|
|
1956
2184
|
export const zSpeechConfigInput = z.object({
|
|
1957
|
-
voiceConfig: z.union([zVoiceConfig, z.null()])
|
|
1958
|
-
multiSpeakerVoiceConfig: z
|
|
1959
|
-
|
|
1960
|
-
.optional(),
|
|
1961
|
-
languageCode: z.union([z.string(), z.null()]).optional(),
|
|
2185
|
+
voiceConfig: z.optional(z.union([zVoiceConfig, z.null()])),
|
|
2186
|
+
multiSpeakerVoiceConfig: z.optional(z.union([zMultiSpeakerVoiceConfigInput, z.null()])),
|
|
2187
|
+
languageCode: z.optional(z.union([z.string(), z.null()])),
|
|
1962
2188
|
});
|
|
1963
2189
|
/**
|
|
1964
2190
|
* GenerateContentConfig
|
|
@@ -1968,60 +2194,54 @@ export const zSpeechConfigInput = z.object({
|
|
|
1968
2194
|
* <https://cloud.google.com/vertex-ai/generative-ai/docs/multimodal/content-generation-parameters>`_.
|
|
1969
2195
|
*/
|
|
1970
2196
|
export const zGenerateContentConfigInput = z.object({
|
|
1971
|
-
httpOptions: z.union([zHttpOptions, z.null()])
|
|
1972
|
-
systemInstruction: z
|
|
1973
|
-
.union([
|
|
2197
|
+
httpOptions: z.optional(z.union([zHttpOptions, z.null()])),
|
|
2198
|
+
systemInstruction: z.optional(z.union([
|
|
1974
2199
|
zContentInput,
|
|
1975
2200
|
z.array(z.union([zFile, zPartInput, z.string()])),
|
|
1976
2201
|
zFile,
|
|
1977
2202
|
zPartInput,
|
|
1978
2203
|
z.string(),
|
|
1979
2204
|
z.null(),
|
|
1980
|
-
])
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
tools: z
|
|
2000
|
-
.union([
|
|
2205
|
+
])),
|
|
2206
|
+
temperature: z.optional(z.union([z.number(), z.null()])),
|
|
2207
|
+
topP: z.optional(z.union([z.number(), z.null()])),
|
|
2208
|
+
topK: z.optional(z.union([z.number(), z.null()])),
|
|
2209
|
+
candidateCount: z.optional(z.union([z.int(), z.null()])),
|
|
2210
|
+
maxOutputTokens: z.optional(z.union([z.int(), z.null()])),
|
|
2211
|
+
stopSequences: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
2212
|
+
responseLogprobs: z.optional(z.union([z.boolean(), z.null()])),
|
|
2213
|
+
logprobs: z.optional(z.union([z.int(), z.null()])),
|
|
2214
|
+
presencePenalty: z.optional(z.union([z.number(), z.null()])),
|
|
2215
|
+
frequencyPenalty: z.optional(z.union([z.number(), z.null()])),
|
|
2216
|
+
seed: z.optional(z.union([z.int(), z.null()])),
|
|
2217
|
+
responseMimeType: z.optional(z.union([z.string(), z.null()])),
|
|
2218
|
+
responseSchema: z.optional(z.union([z.record(z.string(), z.unknown()), zSchemaInput, z.null()])),
|
|
2219
|
+
responseJsonSchema: z.optional(z.union([z.unknown(), z.null()])),
|
|
2220
|
+
routingConfig: z.optional(z.union([zGenerationConfigRoutingConfig, z.null()])),
|
|
2221
|
+
modelSelectionConfig: z.optional(z.union([zModelSelectionConfig, z.null()])),
|
|
2222
|
+
safetySettings: z.optional(z.union([z.array(zSafetySetting), z.null()])),
|
|
2223
|
+
tools: z.optional(z.union([
|
|
2001
2224
|
z.array(z.union([zGoogleGenaiTypesToolInput, zMcpTypesTool])),
|
|
2002
2225
|
z.null(),
|
|
2003
|
-
])
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
.union([zAutomaticFunctionCallingConfig, z.null()])
|
|
2014
|
-
.optional(),
|
|
2015
|
-
thinkingConfig: z.union([zThinkingConfig, z.null()]).optional(),
|
|
2226
|
+
])),
|
|
2227
|
+
toolConfig: z.optional(z.union([zToolConfigInput, z.null()])),
|
|
2228
|
+
labels: z.optional(z.union([z.record(z.string(), z.string()), z.null()])),
|
|
2229
|
+
cachedContent: z.optional(z.union([z.string(), z.null()])),
|
|
2230
|
+
responseModalities: z.optional(z.union([z.array(z.string()), z.null()])),
|
|
2231
|
+
mediaResolution: z.optional(z.union([zMediaResolution, z.null()])),
|
|
2232
|
+
speechConfig: z.optional(z.union([zSpeechConfigInput, z.string(), z.null()])),
|
|
2233
|
+
audioTimestamp: z.optional(z.union([z.boolean(), z.null()])),
|
|
2234
|
+
automaticFunctionCalling: z.optional(z.union([zAutomaticFunctionCallingConfig, z.null()])),
|
|
2235
|
+
thinkingConfig: z.optional(z.union([zThinkingConfig, z.null()])),
|
|
2016
2236
|
});
|
|
2017
2237
|
/**
|
|
2018
2238
|
* JudgeModelOptions
|
|
2019
2239
|
* Options for an eval metric's judge model.
|
|
2020
2240
|
*/
|
|
2021
2241
|
export const zJudgeModelOptionsInput = z.object({
|
|
2022
|
-
judgeModel: z.
|
|
2023
|
-
judgeModelConfig: z.union([zGenerateContentConfigInput, z.null()])
|
|
2024
|
-
numSamples: z.
|
|
2242
|
+
judgeModel: z.optional(z.string()).default("gemini-2.5-flash"),
|
|
2243
|
+
judgeModelConfig: z.optional(z.union([zGenerateContentConfigInput, z.null()])),
|
|
2244
|
+
numSamples: z.optional(z.int()).default(5),
|
|
2025
2245
|
});
|
|
2026
2246
|
/**
|
|
2027
2247
|
* EvalMetric
|
|
@@ -2030,8 +2250,8 @@ export const zJudgeModelOptionsInput = z.object({
|
|
|
2030
2250
|
export const zEvalMetricInput = z.object({
|
|
2031
2251
|
metricName: z.string(),
|
|
2032
2252
|
threshold: z.number(),
|
|
2033
|
-
judgeModelOptions: z.union([zJudgeModelOptionsInput, z.null()])
|
|
2034
|
-
criterion: z.union([zBaseCriterion, z.null()])
|
|
2253
|
+
judgeModelOptions: z.optional(z.union([zJudgeModelOptionsInput, z.null()])),
|
|
2254
|
+
criterion: z.optional(z.union([zBaseCriterion, z.null()])),
|
|
2035
2255
|
});
|
|
2036
2256
|
/**
|
|
2037
2257
|
* EvalResult
|
|
@@ -2042,10 +2262,10 @@ export const zEvalMetricInput = z.object({
|
|
|
2042
2262
|
*/
|
|
2043
2263
|
export const zEvalResult = z.object({
|
|
2044
2264
|
evalSetResultId: z.string(),
|
|
2045
|
-
evalSetResultName: z.union([z.string(), z.null()])
|
|
2265
|
+
evalSetResultName: z.optional(z.union([z.string(), z.null()])),
|
|
2046
2266
|
evalSetId: z.string(),
|
|
2047
|
-
evalCaseResults: z.array(zEvalCaseResult)
|
|
2048
|
-
creationTimestamp: z.
|
|
2267
|
+
evalCaseResults: z.optional(z.array(zEvalCaseResult)),
|
|
2268
|
+
creationTimestamp: z.optional(z.number()).default(0),
|
|
2049
2269
|
});
|
|
2050
2270
|
/**
|
|
2051
2271
|
* EvalSet
|
|
@@ -2053,10 +2273,10 @@ export const zEvalResult = z.object({
|
|
|
2053
2273
|
*/
|
|
2054
2274
|
export const zEvalSetOutput = z.object({
|
|
2055
2275
|
eval_set_id: z.string(),
|
|
2056
|
-
name: z.union([z.string(), z.null()])
|
|
2057
|
-
description: z.union([z.string(), z.null()])
|
|
2276
|
+
name: z.optional(z.union([z.string(), z.null()])),
|
|
2277
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
2058
2278
|
eval_cases: z.array(zEvalCaseOutput),
|
|
2059
|
-
creation_timestamp: z.
|
|
2279
|
+
creation_timestamp: z.optional(z.number()).default(0),
|
|
2060
2280
|
});
|
|
2061
2281
|
/**
|
|
2062
2282
|
* EvalSetResult
|
|
@@ -2064,33 +2284,16 @@ export const zEvalSetOutput = z.object({
|
|
|
2064
2284
|
*/
|
|
2065
2285
|
export const zEvalSetResult = z.object({
|
|
2066
2286
|
evalSetResultId: z.string(),
|
|
2067
|
-
evalSetResultName: z.union([z.string(), z.null()])
|
|
2287
|
+
evalSetResultName: z.optional(z.union([z.string(), z.null()])),
|
|
2068
2288
|
evalSetId: z.string(),
|
|
2069
|
-
evalCaseResults: z.array(zEvalCaseResult)
|
|
2070
|
-
creationTimestamp: z.
|
|
2071
|
-
});
|
|
2072
|
-
/**
|
|
2073
|
-
* HTTPBase
|
|
2074
|
-
*/
|
|
2075
|
-
export const zHttpBase = z.object({
|
|
2076
|
-
type: zSecuritySchemeType.optional(),
|
|
2077
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
2078
|
-
scheme: z.string(),
|
|
2079
|
-
});
|
|
2080
|
-
/**
|
|
2081
|
-
* HTTPBearer
|
|
2082
|
-
*/
|
|
2083
|
-
export const zHttpBearer = z.object({
|
|
2084
|
-
type: zSecuritySchemeType.optional(),
|
|
2085
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
2086
|
-
scheme: z.literal("bearer").optional().default("bearer"),
|
|
2087
|
-
bearerFormat: z.union([z.string(), z.null()]).optional(),
|
|
2289
|
+
evalCaseResults: z.optional(z.array(zEvalCaseResult)),
|
|
2290
|
+
creationTimestamp: z.optional(z.number()).default(0),
|
|
2088
2291
|
});
|
|
2089
2292
|
/**
|
|
2090
2293
|
* ValidationError
|
|
2091
2294
|
*/
|
|
2092
2295
|
export const zValidationError = z.object({
|
|
2093
|
-
loc: z.array(z.union([z.string(), z.
|
|
2296
|
+
loc: z.array(z.union([z.string(), z.int()])),
|
|
2094
2297
|
msg: z.string(),
|
|
2095
2298
|
type: z.string(),
|
|
2096
2299
|
});
|
|
@@ -2098,17 +2301,17 @@ export const zValidationError = z.object({
|
|
|
2098
2301
|
* HTTPValidationError
|
|
2099
2302
|
*/
|
|
2100
2303
|
export const zHttpValidationError = z.object({
|
|
2101
|
-
detail: z.array(zValidationError)
|
|
2304
|
+
detail: z.optional(z.array(zValidationError)),
|
|
2102
2305
|
});
|
|
2103
2306
|
/**
|
|
2104
2307
|
* Item
|
|
2105
2308
|
*/
|
|
2106
2309
|
export const zItem = z.object({
|
|
2107
|
-
id: z.
|
|
2310
|
+
id: z.int(),
|
|
2108
2311
|
name: z.string(),
|
|
2109
|
-
description: z.union([z.string(), z.null()])
|
|
2312
|
+
description: z.optional(z.union([z.string(), z.null()])),
|
|
2110
2313
|
price: z.number(),
|
|
2111
|
-
tags: z.array(z.string())
|
|
2314
|
+
tags: z.optional(z.array(z.string())).default([]),
|
|
2112
2315
|
});
|
|
2113
2316
|
/**
|
|
2114
2317
|
* ListEvalResultsResponse
|
|
@@ -2128,18 +2331,16 @@ export const zListEvalSetsResponse = z.object({
|
|
|
2128
2331
|
*/
|
|
2129
2332
|
export const zGoogleAdkEvaluationEvalMetricsInterval = z.object({
|
|
2130
2333
|
minValue: z.number(),
|
|
2131
|
-
openAtMin: z.
|
|
2334
|
+
openAtMin: z.optional(z.boolean()).default(false),
|
|
2132
2335
|
maxValue: z.number(),
|
|
2133
|
-
openAtMax: z.
|
|
2336
|
+
openAtMax: z.optional(z.boolean()).default(false),
|
|
2134
2337
|
});
|
|
2135
2338
|
/**
|
|
2136
2339
|
* MetricValueInfo
|
|
2137
2340
|
* Information about the type of metric value.
|
|
2138
2341
|
*/
|
|
2139
2342
|
export const zMetricValueInfo = z.object({
|
|
2140
|
-
interval: z
|
|
2141
|
-
.union([zGoogleAdkEvaluationEvalMetricsInterval, z.null()])
|
|
2142
|
-
.optional(),
|
|
2343
|
+
interval: z.optional(z.union([zGoogleAdkEvaluationEvalMetricsInterval, z.null()])),
|
|
2143
2344
|
});
|
|
2144
2345
|
/**
|
|
2145
2346
|
* MetricInfo
|
|
@@ -2147,7 +2348,7 @@ export const zMetricValueInfo = z.object({
|
|
|
2147
2348
|
*/
|
|
2148
2349
|
export const zMetricInfo = z.object({
|
|
2149
2350
|
metricName: z.string(),
|
|
2150
|
-
description: z.
|
|
2351
|
+
description: z.optional(z.string()),
|
|
2151
2352
|
metricValueInfo: zMetricValueInfo,
|
|
2152
2353
|
});
|
|
2153
2354
|
/**
|
|
@@ -2156,92 +2357,6 @@ export const zMetricInfo = z.object({
|
|
|
2156
2357
|
export const zListMetricsInfoResponse = z.object({
|
|
2157
2358
|
metricsInfo: z.array(zMetricInfo),
|
|
2158
2359
|
});
|
|
2159
|
-
/**
|
|
2160
|
-
* OAuthFlowImplicit
|
|
2161
|
-
*/
|
|
2162
|
-
export const zOAuthFlowImplicit = z.object({
|
|
2163
|
-
refreshUrl: z.union([z.string(), z.null()]).optional(),
|
|
2164
|
-
scopes: z.object({}).optional().default({}),
|
|
2165
|
-
authorizationUrl: z.string(),
|
|
2166
|
-
});
|
|
2167
|
-
/**
|
|
2168
|
-
* OAuthFlowPassword
|
|
2169
|
-
*/
|
|
2170
|
-
export const zOAuthFlowPassword = z.object({
|
|
2171
|
-
refreshUrl: z.union([z.string(), z.null()]).optional(),
|
|
2172
|
-
scopes: z.object({}).optional().default({}),
|
|
2173
|
-
tokenUrl: z.string(),
|
|
2174
|
-
});
|
|
2175
|
-
/**
|
|
2176
|
-
* OAuthFlowClientCredentials
|
|
2177
|
-
*/
|
|
2178
|
-
export const zOAuthFlowClientCredentials = z.object({
|
|
2179
|
-
refreshUrl: z.union([z.string(), z.null()]).optional(),
|
|
2180
|
-
scopes: z.object({}).optional().default({}),
|
|
2181
|
-
tokenUrl: z.string(),
|
|
2182
|
-
});
|
|
2183
|
-
/**
|
|
2184
|
-
* OAuthFlowAuthorizationCode
|
|
2185
|
-
*/
|
|
2186
|
-
export const zOAuthFlowAuthorizationCode = z.object({
|
|
2187
|
-
refreshUrl: z.union([z.string(), z.null()]).optional(),
|
|
2188
|
-
scopes: z.object({}).optional().default({}),
|
|
2189
|
-
authorizationUrl: z.string(),
|
|
2190
|
-
tokenUrl: z.string(),
|
|
2191
|
-
});
|
|
2192
|
-
/**
|
|
2193
|
-
* OAuthFlows
|
|
2194
|
-
*/
|
|
2195
|
-
export const zOAuthFlows = z.object({
|
|
2196
|
-
implicit: z.union([zOAuthFlowImplicit, z.null()]).optional(),
|
|
2197
|
-
password: z.union([zOAuthFlowPassword, z.null()]).optional(),
|
|
2198
|
-
clientCredentials: z
|
|
2199
|
-
.union([zOAuthFlowClientCredentials, z.null()])
|
|
2200
|
-
.optional(),
|
|
2201
|
-
authorizationCode: z
|
|
2202
|
-
.union([zOAuthFlowAuthorizationCode, z.null()])
|
|
2203
|
-
.optional(),
|
|
2204
|
-
});
|
|
2205
|
-
/**
|
|
2206
|
-
* OAuth2
|
|
2207
|
-
*/
|
|
2208
|
-
export const zOAuth2Input = z.object({
|
|
2209
|
-
type: zSecuritySchemeType.optional(),
|
|
2210
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
2211
|
-
flows: zOAuthFlows,
|
|
2212
|
-
});
|
|
2213
|
-
/**
|
|
2214
|
-
* OAuth2
|
|
2215
|
-
*/
|
|
2216
|
-
export const zOAuth2Output = z.object({
|
|
2217
|
-
type: zSecuritySchemeType.optional(),
|
|
2218
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
2219
|
-
flows: zOAuthFlows,
|
|
2220
|
-
});
|
|
2221
|
-
/**
|
|
2222
|
-
* OpenIdConnect
|
|
2223
|
-
*/
|
|
2224
|
-
export const zOpenIdConnect = z.object({
|
|
2225
|
-
type: zSecuritySchemeType.optional(),
|
|
2226
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
2227
|
-
openIdConnectUrl: z.string(),
|
|
2228
|
-
});
|
|
2229
|
-
/**
|
|
2230
|
-
* OpenIdConnectWithConfig
|
|
2231
|
-
*/
|
|
2232
|
-
export const zOpenIdConnectWithConfig = z.object({
|
|
2233
|
-
type: zSecuritySchemeType.optional(),
|
|
2234
|
-
description: z.union([z.string(), z.null()]).optional(),
|
|
2235
|
-
authorization_endpoint: z.string(),
|
|
2236
|
-
token_endpoint: z.string(),
|
|
2237
|
-
userinfo_endpoint: z.union([z.string(), z.null()]).optional(),
|
|
2238
|
-
revocation_endpoint: z.union([z.string(), z.null()]).optional(),
|
|
2239
|
-
token_endpoint_auth_methods_supported: z
|
|
2240
|
-
.union([z.array(z.string()), z.null()])
|
|
2241
|
-
.optional(),
|
|
2242
|
-
grant_types_supported: z.union([z.array(z.string()), z.null()]).optional(),
|
|
2243
|
-
scopes: z.union([z.array(z.string()), z.null()]).optional(),
|
|
2244
|
-
});
|
|
2245
2360
|
/**
|
|
2246
2361
|
* RunAgentRequest
|
|
2247
2362
|
*/
|
|
@@ -2250,15 +2365,15 @@ export const zRunAgentRequest = z.object({
|
|
|
2250
2365
|
userId: z.string(),
|
|
2251
2366
|
sessionId: z.string(),
|
|
2252
2367
|
newMessage: zContentInput,
|
|
2253
|
-
streaming: z.
|
|
2254
|
-
stateDelta: z.union([z.
|
|
2368
|
+
streaming: z.optional(z.boolean()).default(false),
|
|
2369
|
+
stateDelta: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
2255
2370
|
});
|
|
2256
2371
|
/**
|
|
2257
2372
|
* RunEvalRequest
|
|
2258
2373
|
*/
|
|
2259
2374
|
export const zRunEvalRequest = z.object({
|
|
2260
|
-
evalIds: z.array(z.string())
|
|
2261
|
-
evalCaseIds: z.array(z.string())
|
|
2375
|
+
evalIds: z.optional(z.array(z.string())),
|
|
2376
|
+
evalCaseIds: z.optional(z.array(z.string())),
|
|
2262
2377
|
evalMetrics: z.array(zEvalMetricInput),
|
|
2263
2378
|
});
|
|
2264
2379
|
/**
|
|
@@ -2270,8 +2385,7 @@ export const zRunEvalResult = z.object({
|
|
|
2270
2385
|
evalId: z.string(),
|
|
2271
2386
|
finalEvalStatus: zEvalStatus,
|
|
2272
2387
|
evalMetricResults: z
|
|
2273
|
-
.array(z.tuple([zEvalMetricOutput, zEvalMetricResult]))
|
|
2274
|
-
.optional()
|
|
2388
|
+
.optional(z.array(z.tuple([zEvalMetricOutput, zEvalMetricResult])))
|
|
2275
2389
|
.default([]),
|
|
2276
2390
|
overallEvalMetricResults: z.array(zEvalMetricResult),
|
|
2277
2391
|
evalMetricResultPerInvocation: z.array(zEvalMetricResultPerInvocation),
|
|
@@ -2298,75 +2412,12 @@ export const zStartNapcatRequest = z.object({
|
|
|
2298
2412
|
*/
|
|
2299
2413
|
export const zStartNapcatResponse = z.object({
|
|
2300
2414
|
sandboxId: z.string(),
|
|
2301
|
-
error: z.union([z.string(), z.null()])
|
|
2302
|
-
});
|
|
2303
|
-
/**
|
|
2304
|
-
* ToolConfirmation
|
|
2305
|
-
* Represents a tool confirmation configuration.
|
|
2306
|
-
*/
|
|
2307
|
-
export const zToolConfirmation = z.object({
|
|
2308
|
-
hint: z.string().optional().default(""),
|
|
2309
|
-
confirmed: z.boolean().optional().default(false),
|
|
2310
|
-
payload: z.union([z.unknown(), z.null()]).optional(),
|
|
2311
|
-
});
|
|
2312
|
-
/**
|
|
2313
|
-
* UserCreate
|
|
2314
|
-
*/
|
|
2315
|
-
export const zUserCreate = z.object({
|
|
2316
|
-
email: z.string().email().max(255),
|
|
2317
|
-
is_active: z.boolean().optional().default(true),
|
|
2318
|
-
is_superuser: z.boolean().optional().default(false),
|
|
2319
|
-
full_name: z.union([z.string().max(255), z.null()]).optional(),
|
|
2320
|
-
username: z.union([z.string().max(255), z.null()]).optional(),
|
|
2321
|
-
identifier: z.union([z.string().max(255), z.null()]).optional(),
|
|
2322
|
-
meta: z.union([z.object({}), z.null()]).optional(),
|
|
2323
|
-
organization_id: z.union([z.string().max(255), z.null()]).optional(),
|
|
2324
|
-
password: z.string().min(6).max(40),
|
|
2325
|
-
});
|
|
2326
|
-
/**
|
|
2327
|
-
* AuthConfig
|
|
2328
|
-
* The auth config sent by tool asking client to collect auth credentials and
|
|
2329
|
-
*
|
|
2330
|
-
* adk and client will help to fill in the response
|
|
2331
|
-
*/
|
|
2332
|
-
export const zGoogleAdkAuthAuthToolAuthConfigInput = z.object({
|
|
2333
|
-
authScheme: z.union([
|
|
2334
|
-
zApiKey,
|
|
2335
|
-
zHttpBase,
|
|
2336
|
-
zOAuth2Input,
|
|
2337
|
-
zOpenIdConnect,
|
|
2338
|
-
zHttpBearer,
|
|
2339
|
-
zOpenIdConnectWithConfig,
|
|
2340
|
-
]),
|
|
2341
|
-
rawAuthCredential: z.union([zAuthCredentialInput, z.null()]).optional(),
|
|
2342
|
-
exchangedAuthCredential: z.union([zAuthCredentialInput, z.null()]).optional(),
|
|
2343
|
-
credentialKey: z.union([z.string(), z.null()]).optional(),
|
|
2344
|
-
});
|
|
2345
|
-
/**
|
|
2346
|
-
* AuthConfig
|
|
2347
|
-
* The auth config sent by tool asking client to collect auth credentials and
|
|
2348
|
-
*
|
|
2349
|
-
* adk and client will help to fill in the response
|
|
2350
|
-
*/
|
|
2351
|
-
export const zGoogleAdkAuthAuthToolAuthConfigOutput = z.object({
|
|
2352
|
-
authScheme: z.union([
|
|
2353
|
-
zApiKey,
|
|
2354
|
-
zHttpBase,
|
|
2355
|
-
zOAuth2Output,
|
|
2356
|
-
zOpenIdConnect,
|
|
2357
|
-
zHttpBearer,
|
|
2358
|
-
zOpenIdConnectWithConfig,
|
|
2359
|
-
]),
|
|
2360
|
-
rawAuthCredential: z.union([zAuthCredentialOutput, z.null()]).optional(),
|
|
2361
|
-
exchangedAuthCredential: z
|
|
2362
|
-
.union([zAuthCredentialOutput, z.null()])
|
|
2363
|
-
.optional(),
|
|
2364
|
-
credentialKey: z.union([z.string(), z.null()]).optional(),
|
|
2415
|
+
error: z.optional(z.union([z.string(), z.null()])),
|
|
2365
2416
|
});
|
|
2366
2417
|
export const zListAppsData = z.object({
|
|
2367
|
-
body: z.
|
|
2368
|
-
path: z.
|
|
2369
|
-
query: z.
|
|
2418
|
+
body: z.optional(z.never()),
|
|
2419
|
+
path: z.optional(z.never()),
|
|
2420
|
+
query: z.optional(z.never()),
|
|
2370
2421
|
});
|
|
2371
2422
|
/**
|
|
2372
2423
|
* Response List Apps
|
|
@@ -2374,27 +2425,27 @@ export const zListAppsData = z.object({
|
|
|
2374
2425
|
*/
|
|
2375
2426
|
export const zListAppsResponse = z.array(z.string());
|
|
2376
2427
|
export const zDebugGetTraceDictData = z.object({
|
|
2377
|
-
body: z.
|
|
2428
|
+
body: z.optional(z.never()),
|
|
2378
2429
|
path: z.object({
|
|
2379
2430
|
event_id: z.string(),
|
|
2380
2431
|
}),
|
|
2381
|
-
query: z.
|
|
2432
|
+
query: z.optional(z.never()),
|
|
2382
2433
|
});
|
|
2383
2434
|
export const zDebugGetSessionTraceData = z.object({
|
|
2384
|
-
body: z.
|
|
2435
|
+
body: z.optional(z.never()),
|
|
2385
2436
|
path: z.object({
|
|
2386
2437
|
session_id: z.string(),
|
|
2387
2438
|
}),
|
|
2388
|
-
query: z.
|
|
2439
|
+
query: z.optional(z.never()),
|
|
2389
2440
|
});
|
|
2390
2441
|
export const zDeleteSessionData = z.object({
|
|
2391
|
-
body: z.
|
|
2442
|
+
body: z.optional(z.never()),
|
|
2392
2443
|
path: z.object({
|
|
2393
2444
|
app_name: z.string(),
|
|
2394
2445
|
user_id: z.string(),
|
|
2395
2446
|
session_id: z.string(),
|
|
2396
2447
|
}),
|
|
2397
|
-
query: z.
|
|
2448
|
+
query: z.optional(z.never()),
|
|
2398
2449
|
});
|
|
2399
2450
|
/**
|
|
2400
2451
|
* Response Delete Session
|
|
@@ -2402,38 +2453,38 @@ export const zDeleteSessionData = z.object({
|
|
|
2402
2453
|
*/
|
|
2403
2454
|
export const zDeleteSessionResponse = z.null();
|
|
2404
2455
|
export const zGetSessionData = z.object({
|
|
2405
|
-
body: z.
|
|
2456
|
+
body: z.optional(z.never()),
|
|
2406
2457
|
path: z.object({
|
|
2407
2458
|
app_name: z.string(),
|
|
2408
2459
|
user_id: z.string(),
|
|
2409
2460
|
session_id: z.string(),
|
|
2410
2461
|
}),
|
|
2411
|
-
query: z.
|
|
2462
|
+
query: z.optional(z.never()),
|
|
2412
2463
|
});
|
|
2413
2464
|
/**
|
|
2414
2465
|
* Successful Response
|
|
2415
2466
|
*/
|
|
2416
2467
|
export const zGetSessionResponse = zSession;
|
|
2417
2468
|
export const zCreateSessionWithIdData = z.object({
|
|
2418
|
-
body: z.union([z.
|
|
2469
|
+
body: z.optional(z.union([z.record(z.string(), z.unknown()), z.null()])),
|
|
2419
2470
|
path: z.object({
|
|
2420
2471
|
app_name: z.string(),
|
|
2421
2472
|
user_id: z.string(),
|
|
2422
2473
|
session_id: z.string(),
|
|
2423
2474
|
}),
|
|
2424
|
-
query: z.
|
|
2475
|
+
query: z.optional(z.never()),
|
|
2425
2476
|
});
|
|
2426
2477
|
/**
|
|
2427
2478
|
* Successful Response
|
|
2428
2479
|
*/
|
|
2429
2480
|
export const zCreateSessionWithIdResponse = zSession;
|
|
2430
2481
|
export const zListSessionsData = z.object({
|
|
2431
|
-
body: z.
|
|
2482
|
+
body: z.optional(z.never()),
|
|
2432
2483
|
path: z.object({
|
|
2433
2484
|
app_name: z.string(),
|
|
2434
2485
|
user_id: z.string(),
|
|
2435
2486
|
}),
|
|
2436
|
-
query: z.
|
|
2487
|
+
query: z.optional(z.never()),
|
|
2437
2488
|
});
|
|
2438
2489
|
/**
|
|
2439
2490
|
* Response List Sessions
|
|
@@ -2441,23 +2492,23 @@ export const zListSessionsData = z.object({
|
|
|
2441
2492
|
*/
|
|
2442
2493
|
export const zListSessionsResponse = z.array(zSession);
|
|
2443
2494
|
export const zCreateSessionData = z.object({
|
|
2444
|
-
body: z.union([zCreateSessionRequest, z.null()])
|
|
2495
|
+
body: z.optional(z.union([zCreateSessionRequest, z.null()])),
|
|
2445
2496
|
path: z.object({
|
|
2446
2497
|
app_name: z.string(),
|
|
2447
2498
|
user_id: z.string(),
|
|
2448
2499
|
}),
|
|
2449
|
-
query: z.
|
|
2500
|
+
query: z.optional(z.never()),
|
|
2450
2501
|
});
|
|
2451
2502
|
/**
|
|
2452
2503
|
* Successful Response
|
|
2453
2504
|
*/
|
|
2454
2505
|
export const zCreateSessionResponse = zSession;
|
|
2455
2506
|
export const zEvaluationListEvalSetsData = z.object({
|
|
2456
|
-
body: z.
|
|
2507
|
+
body: z.optional(z.never()),
|
|
2457
2508
|
path: z.object({
|
|
2458
2509
|
app_name: z.string(),
|
|
2459
2510
|
}),
|
|
2460
|
-
query: z.
|
|
2511
|
+
query: z.optional(z.never()),
|
|
2461
2512
|
});
|
|
2462
2513
|
/**
|
|
2463
2514
|
* Successful Response
|
|
@@ -2468,26 +2519,26 @@ export const zEvaluationCreateEvalSetData = z.object({
|
|
|
2468
2519
|
path: z.object({
|
|
2469
2520
|
app_name: z.string(),
|
|
2470
2521
|
}),
|
|
2471
|
-
query: z.
|
|
2522
|
+
query: z.optional(z.never()),
|
|
2472
2523
|
});
|
|
2473
2524
|
/**
|
|
2474
2525
|
* Successful Response
|
|
2475
2526
|
*/
|
|
2476
2527
|
export const zEvaluationCreateEvalSetResponse = zEvalSetOutput;
|
|
2477
2528
|
export const zEvaluationCreateEvalSetLegacyData = z.object({
|
|
2478
|
-
body: z.
|
|
2529
|
+
body: z.optional(z.never()),
|
|
2479
2530
|
path: z.object({
|
|
2480
2531
|
app_name: z.string(),
|
|
2481
2532
|
eval_set_id: z.string(),
|
|
2482
2533
|
}),
|
|
2483
|
-
query: z.
|
|
2534
|
+
query: z.optional(z.never()),
|
|
2484
2535
|
});
|
|
2485
2536
|
export const zEvaluationListEvalSetsLegacyData = z.object({
|
|
2486
|
-
body: z.
|
|
2537
|
+
body: z.optional(z.never()),
|
|
2487
2538
|
path: z.object({
|
|
2488
2539
|
app_name: z.string(),
|
|
2489
2540
|
}),
|
|
2490
|
-
query: z.
|
|
2541
|
+
query: z.optional(z.never()),
|
|
2491
2542
|
});
|
|
2492
2543
|
/**
|
|
2493
2544
|
* Response Evaluation-List Eval Sets Legacy
|
|
@@ -2500,15 +2551,15 @@ export const zEvaluationAddSessionToEvalSetData = z.object({
|
|
|
2500
2551
|
app_name: z.string(),
|
|
2501
2552
|
eval_set_id: z.string(),
|
|
2502
2553
|
}),
|
|
2503
|
-
query: z.
|
|
2554
|
+
query: z.optional(z.never()),
|
|
2504
2555
|
});
|
|
2505
2556
|
export const zEvaluationListEvalsInEvalSetData = z.object({
|
|
2506
|
-
body: z.
|
|
2557
|
+
body: z.optional(z.never()),
|
|
2507
2558
|
path: z.object({
|
|
2508
2559
|
app_name: z.string(),
|
|
2509
2560
|
eval_set_id: z.string(),
|
|
2510
2561
|
}),
|
|
2511
|
-
query: z.
|
|
2562
|
+
query: z.optional(z.never()),
|
|
2512
2563
|
});
|
|
2513
2564
|
/**
|
|
2514
2565
|
* Response Evaluation-List Evals In Eval Set
|
|
@@ -2516,13 +2567,13 @@ export const zEvaluationListEvalsInEvalSetData = z.object({
|
|
|
2516
2567
|
*/
|
|
2517
2568
|
export const zEvaluationListEvalsInEvalSetResponse = z.array(z.string());
|
|
2518
2569
|
export const zEvaluationDeleteEvalData = z.object({
|
|
2519
|
-
body: z.
|
|
2570
|
+
body: z.optional(z.never()),
|
|
2520
2571
|
path: z.object({
|
|
2521
2572
|
app_name: z.string(),
|
|
2522
2573
|
eval_set_id: z.string(),
|
|
2523
2574
|
eval_case_id: z.string(),
|
|
2524
2575
|
}),
|
|
2525
|
-
query: z.
|
|
2576
|
+
query: z.optional(z.never()),
|
|
2526
2577
|
});
|
|
2527
2578
|
/**
|
|
2528
2579
|
* Response Evaluation-Delete Eval
|
|
@@ -2530,13 +2581,13 @@ export const zEvaluationDeleteEvalData = z.object({
|
|
|
2530
2581
|
*/
|
|
2531
2582
|
export const zEvaluationDeleteEvalResponse = z.null();
|
|
2532
2583
|
export const zEvaluationGetEvalData = z.object({
|
|
2533
|
-
body: z.
|
|
2584
|
+
body: z.optional(z.never()),
|
|
2534
2585
|
path: z.object({
|
|
2535
2586
|
app_name: z.string(),
|
|
2536
2587
|
eval_set_id: z.string(),
|
|
2537
2588
|
eval_case_id: z.string(),
|
|
2538
2589
|
}),
|
|
2539
|
-
query: z.
|
|
2590
|
+
query: z.optional(z.never()),
|
|
2540
2591
|
});
|
|
2541
2592
|
/**
|
|
2542
2593
|
* Successful Response
|
|
@@ -2549,7 +2600,7 @@ export const zEvaluationUpdateEvalData = z.object({
|
|
|
2549
2600
|
eval_set_id: z.string(),
|
|
2550
2601
|
eval_case_id: z.string(),
|
|
2551
2602
|
}),
|
|
2552
|
-
query: z.
|
|
2603
|
+
query: z.optional(z.never()),
|
|
2553
2604
|
});
|
|
2554
2605
|
export const zEvaluationRunEvalLegacyData = z.object({
|
|
2555
2606
|
body: zRunEvalRequest,
|
|
@@ -2557,7 +2608,7 @@ export const zEvaluationRunEvalLegacyData = z.object({
|
|
|
2557
2608
|
app_name: z.string(),
|
|
2558
2609
|
eval_set_id: z.string(),
|
|
2559
2610
|
}),
|
|
2560
|
-
query: z.
|
|
2611
|
+
query: z.optional(z.never()),
|
|
2561
2612
|
});
|
|
2562
2613
|
/**
|
|
2563
2614
|
* Response Evaluation-Run Eval Legacy
|
|
@@ -2570,53 +2621,53 @@ export const zEvaluationRunEvalData = z.object({
|
|
|
2570
2621
|
app_name: z.string(),
|
|
2571
2622
|
eval_set_id: z.string(),
|
|
2572
2623
|
}),
|
|
2573
|
-
query: z.
|
|
2624
|
+
query: z.optional(z.never()),
|
|
2574
2625
|
});
|
|
2575
2626
|
/**
|
|
2576
2627
|
* Successful Response
|
|
2577
2628
|
*/
|
|
2578
2629
|
export const zEvaluationRunEvalResponse = zRunEvalResponse;
|
|
2579
2630
|
export const zEvaluationGetEvalResultData = z.object({
|
|
2580
|
-
body: z.
|
|
2631
|
+
body: z.optional(z.never()),
|
|
2581
2632
|
path: z.object({
|
|
2582
2633
|
app_name: z.string(),
|
|
2583
2634
|
eval_result_id: z.string(),
|
|
2584
2635
|
}),
|
|
2585
|
-
query: z.
|
|
2636
|
+
query: z.optional(z.never()),
|
|
2586
2637
|
});
|
|
2587
2638
|
/**
|
|
2588
2639
|
* Successful Response
|
|
2589
2640
|
*/
|
|
2590
2641
|
export const zEvaluationGetEvalResultResponse = zEvalResult;
|
|
2591
2642
|
export const zEvaluationGetEvalResultLegacyData = z.object({
|
|
2592
|
-
body: z.
|
|
2643
|
+
body: z.optional(z.never()),
|
|
2593
2644
|
path: z.object({
|
|
2594
2645
|
app_name: z.string(),
|
|
2595
2646
|
eval_result_id: z.string(),
|
|
2596
2647
|
}),
|
|
2597
|
-
query: z.
|
|
2648
|
+
query: z.optional(z.never()),
|
|
2598
2649
|
});
|
|
2599
2650
|
/**
|
|
2600
2651
|
* Successful Response
|
|
2601
2652
|
*/
|
|
2602
2653
|
export const zEvaluationGetEvalResultLegacyResponse = zEvalSetResult;
|
|
2603
2654
|
export const zEvaluationListEvalResultsData = z.object({
|
|
2604
|
-
body: z.
|
|
2655
|
+
body: z.optional(z.never()),
|
|
2605
2656
|
path: z.object({
|
|
2606
2657
|
app_name: z.string(),
|
|
2607
2658
|
}),
|
|
2608
|
-
query: z.
|
|
2659
|
+
query: z.optional(z.never()),
|
|
2609
2660
|
});
|
|
2610
2661
|
/**
|
|
2611
2662
|
* Successful Response
|
|
2612
2663
|
*/
|
|
2613
2664
|
export const zEvaluationListEvalResultsResponse = zListEvalResultsResponse;
|
|
2614
2665
|
export const zEvaluationListEvalResultsLegacyData = z.object({
|
|
2615
|
-
body: z.
|
|
2666
|
+
body: z.optional(z.never()),
|
|
2616
2667
|
path: z.object({
|
|
2617
2668
|
app_name: z.string(),
|
|
2618
2669
|
}),
|
|
2619
|
-
query: z.
|
|
2670
|
+
query: z.optional(z.never()),
|
|
2620
2671
|
});
|
|
2621
2672
|
/**
|
|
2622
2673
|
* Response Evaluation-List Eval Results Legacy
|
|
@@ -2624,25 +2675,25 @@ export const zEvaluationListEvalResultsLegacyData = z.object({
|
|
|
2624
2675
|
*/
|
|
2625
2676
|
export const zEvaluationListEvalResultsLegacyResponse = z.array(z.string());
|
|
2626
2677
|
export const zEvaluationListMetricsInfoData = z.object({
|
|
2627
|
-
body: z.
|
|
2678
|
+
body: z.optional(z.never()),
|
|
2628
2679
|
path: z.object({
|
|
2629
2680
|
app_name: z.string(),
|
|
2630
2681
|
}),
|
|
2631
|
-
query: z.
|
|
2682
|
+
query: z.optional(z.never()),
|
|
2632
2683
|
});
|
|
2633
2684
|
/**
|
|
2634
2685
|
* Successful Response
|
|
2635
2686
|
*/
|
|
2636
2687
|
export const zEvaluationListMetricsInfoResponse = zListMetricsInfoResponse;
|
|
2637
2688
|
export const zDeleteArtifactData = z.object({
|
|
2638
|
-
body: z.
|
|
2689
|
+
body: z.optional(z.never()),
|
|
2639
2690
|
path: z.object({
|
|
2640
2691
|
app_name: z.string(),
|
|
2641
2692
|
user_id: z.string(),
|
|
2642
2693
|
session_id: z.string(),
|
|
2643
2694
|
artifact_name: z.string(),
|
|
2644
2695
|
}),
|
|
2645
|
-
query: z.
|
|
2696
|
+
query: z.optional(z.never()),
|
|
2646
2697
|
});
|
|
2647
2698
|
/**
|
|
2648
2699
|
* Response Delete Artifact
|
|
@@ -2650,18 +2701,16 @@ export const zDeleteArtifactData = z.object({
|
|
|
2650
2701
|
*/
|
|
2651
2702
|
export const zDeleteArtifactResponse = z.null();
|
|
2652
2703
|
export const zLoadArtifactData = z.object({
|
|
2653
|
-
body: z.
|
|
2704
|
+
body: z.optional(z.never()),
|
|
2654
2705
|
path: z.object({
|
|
2655
2706
|
app_name: z.string(),
|
|
2656
2707
|
user_id: z.string(),
|
|
2657
2708
|
session_id: z.string(),
|
|
2658
2709
|
artifact_name: z.string(),
|
|
2659
2710
|
}),
|
|
2660
|
-
query: z
|
|
2661
|
-
.
|
|
2662
|
-
|
|
2663
|
-
})
|
|
2664
|
-
.optional(),
|
|
2711
|
+
query: z.optional(z.object({
|
|
2712
|
+
version: z.optional(z.union([z.int(), z.null()])),
|
|
2713
|
+
})),
|
|
2665
2714
|
});
|
|
2666
2715
|
/**
|
|
2667
2716
|
* Response Load Artifact
|
|
@@ -2669,15 +2718,15 @@ export const zLoadArtifactData = z.object({
|
|
|
2669
2718
|
*/
|
|
2670
2719
|
export const zLoadArtifactResponse = z.union([zPartOutput, z.null()]);
|
|
2671
2720
|
export const zLoadArtifactVersionData = z.object({
|
|
2672
|
-
body: z.
|
|
2721
|
+
body: z.optional(z.never()),
|
|
2673
2722
|
path: z.object({
|
|
2674
2723
|
app_name: z.string(),
|
|
2675
2724
|
user_id: z.string(),
|
|
2676
2725
|
session_id: z.string(),
|
|
2677
2726
|
artifact_name: z.string(),
|
|
2678
|
-
version_id: z.
|
|
2727
|
+
version_id: z.int(),
|
|
2679
2728
|
}),
|
|
2680
|
-
query: z.
|
|
2729
|
+
query: z.optional(z.never()),
|
|
2681
2730
|
});
|
|
2682
2731
|
/**
|
|
2683
2732
|
* Response Load Artifact Version
|
|
@@ -2685,13 +2734,13 @@ export const zLoadArtifactVersionData = z.object({
|
|
|
2685
2734
|
*/
|
|
2686
2735
|
export const zLoadArtifactVersionResponse = z.union([zPartOutput, z.null()]);
|
|
2687
2736
|
export const zListArtifactNamesData = z.object({
|
|
2688
|
-
body: z.
|
|
2737
|
+
body: z.optional(z.never()),
|
|
2689
2738
|
path: z.object({
|
|
2690
2739
|
app_name: z.string(),
|
|
2691
2740
|
user_id: z.string(),
|
|
2692
2741
|
session_id: z.string(),
|
|
2693
2742
|
}),
|
|
2694
|
-
query: z.
|
|
2743
|
+
query: z.optional(z.never()),
|
|
2695
2744
|
});
|
|
2696
2745
|
/**
|
|
2697
2746
|
* Response List Artifact Names
|
|
@@ -2699,24 +2748,24 @@ export const zListArtifactNamesData = z.object({
|
|
|
2699
2748
|
*/
|
|
2700
2749
|
export const zListArtifactNamesResponse = z.array(z.string());
|
|
2701
2750
|
export const zListArtifactVersionsData = z.object({
|
|
2702
|
-
body: z.
|
|
2751
|
+
body: z.optional(z.never()),
|
|
2703
2752
|
path: z.object({
|
|
2704
2753
|
app_name: z.string(),
|
|
2705
2754
|
user_id: z.string(),
|
|
2706
2755
|
session_id: z.string(),
|
|
2707
2756
|
artifact_name: z.string(),
|
|
2708
2757
|
}),
|
|
2709
|
-
query: z.
|
|
2758
|
+
query: z.optional(z.never()),
|
|
2710
2759
|
});
|
|
2711
2760
|
/**
|
|
2712
2761
|
* Response List Artifact Versions
|
|
2713
2762
|
* Successful Response
|
|
2714
2763
|
*/
|
|
2715
|
-
export const zListArtifactVersionsResponse = z.array(z.
|
|
2764
|
+
export const zListArtifactVersionsResponse = z.array(z.int());
|
|
2716
2765
|
export const zRunAgentData = z.object({
|
|
2717
2766
|
body: zRunAgentRequest,
|
|
2718
|
-
path: z.
|
|
2719
|
-
query: z.
|
|
2767
|
+
path: z.optional(z.never()),
|
|
2768
|
+
query: z.optional(z.never()),
|
|
2720
2769
|
});
|
|
2721
2770
|
/**
|
|
2722
2771
|
* Response Run Agent
|
|
@@ -2725,33 +2774,33 @@ export const zRunAgentData = z.object({
|
|
|
2725
2774
|
export const zRunAgentResponse = z.array(zEventOutput);
|
|
2726
2775
|
export const zRunAgentSseData = z.object({
|
|
2727
2776
|
body: zRunAgentRequest,
|
|
2728
|
-
path: z.
|
|
2729
|
-
query: z.
|
|
2777
|
+
path: z.optional(z.never()),
|
|
2778
|
+
query: z.optional(z.never()),
|
|
2730
2779
|
});
|
|
2731
2780
|
export const zDebugGetEventGraphData = z.object({
|
|
2732
|
-
body: z.
|
|
2781
|
+
body: z.optional(z.never()),
|
|
2733
2782
|
path: z.object({
|
|
2734
2783
|
app_name: z.string(),
|
|
2735
2784
|
user_id: z.string(),
|
|
2736
2785
|
session_id: z.string(),
|
|
2737
2786
|
event_id: z.string(),
|
|
2738
2787
|
}),
|
|
2739
|
-
query: z.
|
|
2788
|
+
query: z.optional(z.never()),
|
|
2740
2789
|
});
|
|
2741
2790
|
export const zRedirectRootToDevUiData = z.object({
|
|
2742
|
-
body: z.
|
|
2743
|
-
path: z.
|
|
2744
|
-
query: z.
|
|
2791
|
+
body: z.optional(z.never()),
|
|
2792
|
+
path: z.optional(z.never()),
|
|
2793
|
+
query: z.optional(z.never()),
|
|
2745
2794
|
});
|
|
2746
2795
|
export const zRedirectDevUiAddSlashData = z.object({
|
|
2747
|
-
body: z.
|
|
2748
|
-
path: z.
|
|
2749
|
-
query: z.
|
|
2796
|
+
body: z.optional(z.never()),
|
|
2797
|
+
path: z.optional(z.never()),
|
|
2798
|
+
query: z.optional(z.never()),
|
|
2750
2799
|
});
|
|
2751
2800
|
export const zBuilderBuildData = z.object({
|
|
2752
2801
|
body: zBodyBuilderBuild,
|
|
2753
|
-
path: z.
|
|
2754
|
-
query: z.
|
|
2802
|
+
path: z.optional(z.never()),
|
|
2803
|
+
query: z.optional(z.never()),
|
|
2755
2804
|
});
|
|
2756
2805
|
/**
|
|
2757
2806
|
* Response Builder Build
|
|
@@ -2759,24 +2808,22 @@ export const zBuilderBuildData = z.object({
|
|
|
2759
2808
|
*/
|
|
2760
2809
|
export const zBuilderBuildResponse = z.boolean();
|
|
2761
2810
|
export const zGetAgentBuilderData = z.object({
|
|
2762
|
-
body: z.
|
|
2811
|
+
body: z.optional(z.never()),
|
|
2763
2812
|
path: z.object({
|
|
2764
2813
|
app_name: z.string(),
|
|
2765
2814
|
}),
|
|
2766
|
-
query: z
|
|
2767
|
-
.
|
|
2768
|
-
|
|
2769
|
-
})
|
|
2770
|
-
.optional(),
|
|
2815
|
+
query: z.optional(z.object({
|
|
2816
|
+
file_path: z.optional(z.union([z.string(), z.null()])),
|
|
2817
|
+
})),
|
|
2771
2818
|
});
|
|
2772
2819
|
/**
|
|
2773
2820
|
* Successful Response
|
|
2774
2821
|
*/
|
|
2775
2822
|
export const zGetAgentBuilderResponse = z.string();
|
|
2776
2823
|
export const zChatAgentGetChatConfigData = z.object({
|
|
2777
|
-
body: z.
|
|
2778
|
-
path: z.
|
|
2779
|
-
query: z.
|
|
2824
|
+
body: z.optional(z.never()),
|
|
2825
|
+
path: z.optional(z.never()),
|
|
2826
|
+
query: z.optional(z.never()),
|
|
2780
2827
|
});
|
|
2781
2828
|
/**
|
|
2782
2829
|
* Successful Response
|
|
@@ -2784,51 +2831,49 @@ export const zChatAgentGetChatConfigData = z.object({
|
|
|
2784
2831
|
export const zChatAgentGetChatConfigResponse = zChatConfig;
|
|
2785
2832
|
export const zChatAgentUpdateChatConfigData = z.object({
|
|
2786
2833
|
body: zChatConfig,
|
|
2787
|
-
path: z.
|
|
2788
|
-
query: z.
|
|
2834
|
+
path: z.optional(z.never()),
|
|
2835
|
+
query: z.optional(z.never()),
|
|
2789
2836
|
});
|
|
2790
2837
|
/**
|
|
2791
2838
|
* Successful Response
|
|
2792
2839
|
*/
|
|
2793
2840
|
export const zChatAgentUpdateChatConfigResponse = zChatConfig;
|
|
2794
2841
|
export const zChatAgentGetProvidersData = z.object({
|
|
2795
|
-
body: z.
|
|
2796
|
-
path: z.
|
|
2797
|
-
query: z.
|
|
2842
|
+
body: z.optional(z.never()),
|
|
2843
|
+
path: z.optional(z.never()),
|
|
2844
|
+
query: z.optional(z.never()),
|
|
2798
2845
|
});
|
|
2799
2846
|
export const zChatAgentValidateApiKeyData = z.object({
|
|
2800
|
-
body: z.
|
|
2801
|
-
path: z.
|
|
2802
|
-
query: z.
|
|
2847
|
+
body: z.record(z.string(), z.unknown()),
|
|
2848
|
+
path: z.optional(z.never()),
|
|
2849
|
+
query: z.optional(z.never()),
|
|
2803
2850
|
});
|
|
2804
2851
|
export const zChatAgentExportConfigData = z.object({
|
|
2805
|
-
body: z.
|
|
2806
|
-
path: z.
|
|
2807
|
-
query: z.
|
|
2852
|
+
body: z.optional(z.never()),
|
|
2853
|
+
path: z.optional(z.never()),
|
|
2854
|
+
query: z.optional(z.never()),
|
|
2808
2855
|
});
|
|
2809
2856
|
export const zChatAgentImportConfigData = z.object({
|
|
2810
|
-
body: z.
|
|
2811
|
-
path: z.
|
|
2812
|
-
query: z.
|
|
2857
|
+
body: z.record(z.string(), z.unknown()),
|
|
2858
|
+
path: z.optional(z.never()),
|
|
2859
|
+
query: z.optional(z.never()),
|
|
2813
2860
|
});
|
|
2814
2861
|
export const zChatAgentChatData = z.object({
|
|
2815
2862
|
body: zChatRequest,
|
|
2816
|
-
path: z.
|
|
2817
|
-
query: z.
|
|
2863
|
+
path: z.optional(z.never()),
|
|
2864
|
+
query: z.optional(z.never()),
|
|
2818
2865
|
});
|
|
2819
2866
|
/**
|
|
2820
2867
|
* Successful Response
|
|
2821
2868
|
*/
|
|
2822
2869
|
export const zChatAgentChatResponse = zChatResponse;
|
|
2823
2870
|
export const zListItemsData = z.object({
|
|
2824
|
-
body: z.
|
|
2825
|
-
path: z.
|
|
2826
|
-
query: z
|
|
2827
|
-
.
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
})
|
|
2831
|
-
.optional(),
|
|
2871
|
+
body: z.optional(z.never()),
|
|
2872
|
+
path: z.optional(z.never()),
|
|
2873
|
+
query: z.optional(z.object({
|
|
2874
|
+
skip: z.optional(z.int()).default(0),
|
|
2875
|
+
limit: z.optional(z.int()).default(10),
|
|
2876
|
+
})),
|
|
2832
2877
|
});
|
|
2833
2878
|
/**
|
|
2834
2879
|
* Response List Items
|
|
@@ -2837,26 +2882,26 @@ export const zListItemsData = z.object({
|
|
|
2837
2882
|
export const zListItemsResponse = z.array(zItem);
|
|
2838
2883
|
export const zCreateItemData = z.object({
|
|
2839
2884
|
body: zItem,
|
|
2840
|
-
path: z.
|
|
2841
|
-
query: z.
|
|
2885
|
+
path: z.optional(z.never()),
|
|
2886
|
+
query: z.optional(z.never()),
|
|
2842
2887
|
});
|
|
2843
2888
|
/**
|
|
2844
2889
|
* Successful Response
|
|
2845
2890
|
*/
|
|
2846
2891
|
export const zCreateItemResponse = zItem;
|
|
2847
2892
|
export const zDeleteItemData = z.object({
|
|
2848
|
-
body: z.
|
|
2893
|
+
body: z.optional(z.never()),
|
|
2849
2894
|
path: z.object({
|
|
2850
|
-
item_id: z.
|
|
2895
|
+
item_id: z.int(),
|
|
2851
2896
|
}),
|
|
2852
|
-
query: z.
|
|
2897
|
+
query: z.optional(z.never()),
|
|
2853
2898
|
});
|
|
2854
2899
|
export const zGetItemData = z.object({
|
|
2855
|
-
body: z.
|
|
2900
|
+
body: z.optional(z.never()),
|
|
2856
2901
|
path: z.object({
|
|
2857
|
-
item_id: z.
|
|
2902
|
+
item_id: z.int(),
|
|
2858
2903
|
}),
|
|
2859
|
-
query: z.
|
|
2904
|
+
query: z.optional(z.never()),
|
|
2860
2905
|
});
|
|
2861
2906
|
/**
|
|
2862
2907
|
* Successful Response
|
|
@@ -2865,25 +2910,23 @@ export const zGetItemResponse = zItem;
|
|
|
2865
2910
|
export const zUpdateItemData = z.object({
|
|
2866
2911
|
body: zItem,
|
|
2867
2912
|
path: z.object({
|
|
2868
|
-
item_id: z.
|
|
2913
|
+
item_id: z.int(),
|
|
2869
2914
|
}),
|
|
2870
|
-
query: z.
|
|
2915
|
+
query: z.optional(z.never()),
|
|
2871
2916
|
});
|
|
2872
2917
|
/**
|
|
2873
2918
|
* Successful Response
|
|
2874
2919
|
*/
|
|
2875
2920
|
export const zUpdateItemResponse = zItem;
|
|
2876
2921
|
export const zSearchItemsData = z.object({
|
|
2877
|
-
body: z.
|
|
2878
|
-
path: z.
|
|
2879
|
-
query: z
|
|
2880
|
-
.
|
|
2881
|
-
|
|
2882
|
-
|
|
2883
|
-
|
|
2884
|
-
|
|
2885
|
-
})
|
|
2886
|
-
.optional(),
|
|
2922
|
+
body: z.optional(z.never()),
|
|
2923
|
+
path: z.optional(z.never()),
|
|
2924
|
+
query: z.optional(z.object({
|
|
2925
|
+
q: z.optional(z.union([z.string(), z.null()])),
|
|
2926
|
+
min_price: z.optional(z.union([z.number(), z.null()])),
|
|
2927
|
+
max_price: z.optional(z.union([z.number(), z.null()])),
|
|
2928
|
+
tags: z.optional(z.array(z.string())).default([]),
|
|
2929
|
+
})),
|
|
2887
2930
|
});
|
|
2888
2931
|
/**
|
|
2889
2932
|
* Response Search Items
|
|
@@ -2892,27 +2935,13 @@ export const zSearchItemsData = z.object({
|
|
|
2892
2935
|
export const zSearchItemsResponse = z.array(zItem);
|
|
2893
2936
|
export const zAgentsAgentrunData = z.object({
|
|
2894
2937
|
body: zRunAgentRequest,
|
|
2895
|
-
path: z.
|
|
2896
|
-
query: z.
|
|
2938
|
+
path: z.optional(z.never()),
|
|
2939
|
+
query: z.optional(z.never()),
|
|
2897
2940
|
});
|
|
2898
|
-
export const zDemoDemo1Data = z.object({
|
|
2899
|
-
body: zUserCreate,
|
|
2900
|
-
path: z.never().optional(),
|
|
2901
|
-
query: z.never().optional(),
|
|
2902
|
-
headers: z
|
|
2903
|
-
.object({
|
|
2904
|
-
authorization: z.string().optional(),
|
|
2905
|
-
})
|
|
2906
|
-
.optional(),
|
|
2907
|
-
});
|
|
2908
|
-
/**
|
|
2909
|
-
* Successful Response
|
|
2910
|
-
*/
|
|
2911
|
-
export const zDemoDemo1Response = zDemoPublic;
|
|
2912
2941
|
export const zSandboxStartNapcatSandboxData = z.object({
|
|
2913
2942
|
body: zStartNapcatRequest,
|
|
2914
|
-
path: z.
|
|
2915
|
-
query: z.
|
|
2943
|
+
path: z.optional(z.never()),
|
|
2944
|
+
query: z.optional(z.never()),
|
|
2916
2945
|
});
|
|
2917
2946
|
/**
|
|
2918
2947
|
* Successful Response
|
|
@@ -2920,8 +2949,8 @@ export const zSandboxStartNapcatSandboxData = z.object({
|
|
|
2920
2949
|
export const zSandboxStartNapcatSandboxResponse = zStartNapcatResponse;
|
|
2921
2950
|
export const zSandboxCheckSandboxStatusData = z.object({
|
|
2922
2951
|
body: zCheckSandboxStatusRequest,
|
|
2923
|
-
path: z.
|
|
2924
|
-
query: z.
|
|
2952
|
+
path: z.optional(z.never()),
|
|
2953
|
+
query: z.optional(z.never()),
|
|
2925
2954
|
});
|
|
2926
2955
|
/**
|
|
2927
2956
|
* Successful Response
|