@songtonyli/dsh-cli 0.1.55 → 0.1.57
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/README.md +1 -1
- package/bin/dsh.mjs +1 -1
- package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/package.json +6 -6
- package/node_modules/@aws-sdk/token-providers/package.json +6 -6
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/symbols.js +17 -1
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/embed.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/file.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/symbols.js +60 -41
- package/node_modules/@bufbuild/protobuf/dist/commonjs/create.js +2 -1
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-binary.js +9 -6
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-json.js +30 -12
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/message.js +3 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-check.js +3 -4
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/unsafe.js +31 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/registry.js +53 -5
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-json.js +27 -5
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/binary-encoding.js +5 -3
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/any.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/duration.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/any_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/api_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/google/protobuf/c_sharp_features_pb.js +33 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/compiler/plugin_pb.js +3 -3
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/cpp_features_pb.js +34 -6
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/google/protobuf/cpp_file_options_pb.js +33 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/google/protobuf/cpp_options_pb.js +22 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/descriptor_pb.js +49 -6
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/duration_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/empty_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/field_mask_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/go_features_pb.js +4 -4
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/java_features_pb.js +4 -4
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/google/protobuf/json_enumvalue_options_pb.js +33 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/google/protobuf/json_options_pb.js +22 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/source_context_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/struct_pb.js +11 -6
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/timestamp_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/type_pb.js +3 -3
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/{gen/google → google}/protobuf/wrappers_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/index.js +15 -15
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/timestamp.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/symbols.js +18 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/embed.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/file.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/symbols.js +60 -41
- package/node_modules/@bufbuild/protobuf/dist/esm/create.js +2 -1
- package/node_modules/@bufbuild/protobuf/dist/esm/from-binary.js +10 -7
- package/node_modules/@bufbuild/protobuf/dist/esm/from-json.js +31 -13
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/message.js +3 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-check.js +4 -5
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect.js +3 -3
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/unsafe.js +29 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/registry.js +53 -5
- package/node_modules/@bufbuild/protobuf/dist/esm/to-json.js +28 -6
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/binary-encoding.js +5 -3
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/any.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/duration.js +1 -1
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/any_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/api_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/google/protobuf/c_sharp_features_pb.js +30 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/compiler/plugin_pb.js +3 -3
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/cpp_features_pb.js +33 -5
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/google/protobuf/cpp_file_options_pb.js +30 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/google/protobuf/cpp_options_pb.js +19 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/descriptor_pb.js +47 -4
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/duration_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/empty_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/field_mask_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/go_features_pb.js +4 -4
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/java_features_pb.js +4 -4
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/google/protobuf/json_enumvalue_options_pb.js +30 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/google/protobuf/json_options_pb.js +19 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/source_context_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/struct_pb.js +11 -6
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/timestamp_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/type_pb.js +3 -3
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/{gen/google → google}/protobuf/wrappers_pb.js +2 -2
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/index.js +15 -15
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/timestamp.js +1 -1
- package/node_modules/@bufbuild/protobuf/package.json +236 -13
- package/node_modules/@deepseek-ai/dsh-client-ui-primitives/package.json +2 -2
- package/node_modules/@deepseek-ai/dsh-client-ui-sidebar/lib/client.js +1 -1
- package/node_modules/@deepseek-ai/dsh-client-ui-slots/package.json +2 -2
- package/node_modules/@deepseek-ai/dsh-llm-pi-ai/README.i18n.yaml +2 -2
- package/node_modules/@deepseek-ai/dsh-llm-pi-ai/README.md +1 -1
- package/node_modules/@deepseek-ai/dsh-llm-pi-ai/README.zh.md +1 -1
- package/node_modules/@deepseek-ai/dsh-llm-pi-ai/lib/index.js +1 -182
- package/node_modules/@deepseek-ai/dsh-llm-pi-ai/package.json +1 -1
- package/node_modules/@deepseek-ai/dsh-tui-app/README.i18n.yaml +8 -8
- package/node_modules/@deepseek-ai/dsh-tui-app/README.md +15 -4
- package/node_modules/@deepseek-ai/dsh-tui-app/README.zh.md +15 -4
- package/node_modules/@deepseek-ai/dsh-tui-app/lib/index.js +692 -43
- package/node_modules/@earendil-works/pi-ai/README.md +207 -27
- package/node_modules/@earendil-works/pi-ai/dist/api/anthropic-messages.js +6 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/azure-openai-responses.js +6 -5
- package/node_modules/@earendil-works/pi-ai/dist/api/bedrock-converse-stream.js +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-workers-ai-system-one.js +43 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare-workers-ai-system-one.lazy.js +4 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/cloudflare.js +2 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/google-generative-ai.js +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/google-vertex.js +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/llama-cpp-classify.js +365 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/llama-cpp-classify.lazy.js +4 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/mistral-conversations.js +18 -17
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-codex-responses.js +20 -4
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-completions.js +4 -4
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses-shared.js +14 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses.js +26 -9
- package/node_modules/@earendil-works/pi-ai/dist/api/openrouter-images.js +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/pi-messages.js +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/simple-options.js +2 -4
- package/node_modules/@earendil-works/pi-ai/dist/api/system-one-shared.js +183 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/typesafe-system-one.js +19 -0
- package/node_modules/@earendil-works/pi-ai/dist/api/typesafe-system-one.lazy.js +4 -0
- package/node_modules/@earendil-works/pi-ai/dist/auth/helpers.js +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/anthropic.js +19 -128
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/callback-server.js +146 -0
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/load.js +5 -0
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/openai-chatgpt.js +266 -0
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/openai-codex.js +20 -124
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/openrouter.js +19 -138
- package/node_modules/@earendil-works/pi-ai/dist/auth/oauth/radius.js +21 -89
- package/node_modules/@earendil-works/pi-ai/dist/auth/resolve.js +3 -19
- package/node_modules/@earendil-works/pi-ai/dist/bun-oauth.js +2 -0
- package/node_modules/@earendil-works/pi-ai/dist/cli.js +3 -1
- package/node_modules/@earendil-works/pi-ai/dist/env-api-keys.js +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/image-models.js +14 -13
- package/node_modules/@earendil-works/pi-ai/dist/images.js +5 -0
- package/node_modules/@earendil-works/pi-ai/dist/index.js +0 -1
- package/node_modules/@earendil-works/pi-ai/dist/model-catalog.js +14 -2
- package/node_modules/@earendil-works/pi-ai/dist/models.generated.js +131 -41
- package/node_modules/@earendil-works/pi-ai/dist/models.js +157 -30
- package/node_modules/@earendil-works/pi-ai/dist/providers/all.js +25 -21
- package/node_modules/@earendil-works/pi-ai/dist/providers/amazon-bedrock.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/ant-ling.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/anthropic.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/azure-openai-responses.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/baseten.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/cerebras.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/cloudflare-ai-gateway.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/cloudflare-stream.js +6 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/cloudflare-workers-ai.js +10 -3
- package/node_modules/@earendil-works/pi-ai/dist/providers/cloudflare-workers-ai.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/.manifest.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/amazon-bedrock.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/ant-ling.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/anthropic.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/azure-openai-responses.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/baseten.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/cerebras.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/cloudflare-ai-gateway.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/cloudflare-workers-ai.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/deepseek.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/fireworks.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/github-copilot.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/google-vertex.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/google.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/groq.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/huggingface.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/kimi-coding.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/meta.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/minimax-cn.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/minimax.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/mistral.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/moonshotai-cn.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/moonshotai.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/nvidia.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/openai-codex.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/openai.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/opencode-go.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/opencode.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/openrouter.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/qwen-token-plan-cn.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/qwen-token-plan-individual.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/qwen-token-plan.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/radius.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/together.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/typesafe.json +1 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/vercel-ai-gateway.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/xai.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/xiaomi-token-plan-ams.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/xiaomi-token-plan-cn.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/xiaomi-token-plan-sgp.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/xiaomi.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/zai-coding-cn.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/data/zai.json +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/deepseek.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/fireworks.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/github-copilot.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/google-vertex.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/google.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/groq.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/huggingface.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/kimi-coding.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/meta.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/minimax-cn.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/minimax.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/mistral.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/moonshotai-cn.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/moonshotai.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/nvidia.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai-codex.js +1 -1
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai-codex.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai.js +11 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/openai.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-go.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode.js +5 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/opencode.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/openrouter.js +11 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/openrouter.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/qwen-token-plan-cn.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/qwen-token-plan-individual.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/qwen-token-plan.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/radius.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/together.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/typesafe.js +18 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/typesafe.models.js +8 -0
- package/node_modules/@earendil-works/pi-ai/dist/providers/vercel-ai-gateway.js +5 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/vercel-ai-gateway.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/xai.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/xiaomi-token-plan-ams.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/xiaomi-token-plan-cn.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/xiaomi-token-plan-sgp.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/xiaomi.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/zai-coding-cn.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/providers/zai.models.js +4 -2
- package/node_modules/@earendil-works/pi-ai/dist/utils/headers.js +10 -8
- package/node_modules/@earendil-works/pi-ai/dist/utils/model-operations.js +47 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/models-error.js +19 -0
- package/node_modules/@earendil-works/pi-ai/dist/utils/retry.js +7 -0
- package/node_modules/@earendil-works/pi-ai/package.json +4 -4
- package/node_modules/@earendil-works/pi-telemetry/package.json +2 -2
- package/node_modules/openai/CHANGELOG.md +1089 -1
- package/node_modules/openai/README.md +201 -102
- package/node_modules/openai/_vendor/partial-json-parser/parser.js +55 -38
- package/node_modules/openai/_vendor/partial-json-parser/parser.mjs +55 -38
- package/node_modules/openai/_vendor/zod-to-json-schema/Options.js +11 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/Options.mjs +11 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/Refs.js +4 -4
- package/node_modules/openai/_vendor/zod-to-json-schema/Refs.mjs +4 -4
- package/node_modules/openai/_vendor/zod-to-json-schema/errorMessages.js +2 -1
- package/node_modules/openai/_vendor/zod-to-json-schema/errorMessages.mjs +2 -1
- package/node_modules/openai/_vendor/zod-to-json-schema/index.js +1 -1
- package/node_modules/openai/_vendor/zod-to-json-schema/index.mjs +1 -1
- package/node_modules/openai/_vendor/zod-to-json-schema/parseDef.js +139 -54
- package/node_modules/openai/_vendor/zod-to-json-schema/parseDef.mjs +139 -54
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/array.js +1 -1
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/array.mjs +1 -1
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/bigint.js +10 -4
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/bigint.mjs +10 -4
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/branded.js +2 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/branded.mjs +2 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/catch.js +1 -3
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/catch.mjs +1 -3
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/date.js +10 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/date.mjs +10 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/default.js +2 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/default.mjs +2 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/intersection.js +6 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/intersection.mjs +6 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/literal.js +5 -0
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/literal.mjs +5 -0
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/nativeEnum.js +7 -9
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/nativeEnum.mjs +7 -9
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/null.js +3 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/null.mjs +3 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/nullable.js +8 -3
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/nullable.mjs +8 -3
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/number.js +12 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/number.mjs +12 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/object.js +43 -38
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/object.mjs +43 -38
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/optional.js +11 -12
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/optional.mjs +11 -12
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/pipeline.js +3 -3
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/pipeline.mjs +3 -3
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/promise.js +2 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/promise.mjs +2 -2
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/readonly.js +1 -3
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/readonly.mjs +1 -3
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/record.js +7 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/record.mjs +7 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/string.js +57 -34
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/string.mjs +57 -34
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/tuple.js +24 -19
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/tuple.mjs +24 -19
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/union.js +46 -24
- package/node_modules/openai/_vendor/zod-to-json-schema/parsers/union.mjs +46 -24
- package/node_modules/openai/_vendor/zod-to-json-schema/util.js +7 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/util.mjs +7 -5
- package/node_modules/openai/_vendor/zod-to-json-schema/zodToJsonSchema.js +110 -38
- package/node_modules/openai/_vendor/zod-to-json-schema/zodToJsonSchema.mjs +110 -38
- package/node_modules/openai/auth/subject-token-providers.js +235 -10
- package/node_modules/openai/auth/subject-token-providers.mjs +235 -10
- package/node_modules/openai/auth/workload-identity-auth.js +185 -24
- package/node_modules/openai/auth/workload-identity-auth.mjs +186 -25
- package/node_modules/openai/auth/x509-transport.js +273 -0
- package/node_modules/openai/auth/x509-transport.mjs +268 -0
- package/node_modules/openai/azure.js +74 -21
- package/node_modules/openai/azure.mjs +75 -22
- package/node_modules/openai/bedrock.js +174 -0
- package/node_modules/openai/bedrock.mjs +169 -0
- package/node_modules/openai/beta/realtime/internal-base.js +71 -10
- package/node_modules/openai/beta/realtime/internal-base.mjs +70 -10
- package/node_modules/openai/beta/realtime/websocket.js +180 -33
- package/node_modules/openai/beta/realtime/websocket.mjs +181 -34
- package/node_modules/openai/beta/realtime/ws.js +93 -14
- package/node_modules/openai/beta/realtime/ws.mjs +94 -15
- package/node_modules/openai/client.js +745 -99
- package/node_modules/openai/client.mjs +747 -101
- package/node_modules/openai/core/EventEmitter.js +127 -16
- package/node_modules/openai/core/EventEmitter.mjs +128 -17
- package/node_modules/openai/core/api-promise.js +0 -1
- package/node_modules/openai/core/api-promise.mjs +0 -1
- package/node_modules/openai/core/error.js +5 -5
- package/node_modules/openai/core/error.mjs +5 -5
- package/node_modules/openai/core/pagination.js +33 -3
- package/node_modules/openai/core/pagination.mjs +31 -2
- package/node_modules/openai/core/resource.js +0 -1
- package/node_modules/openai/core/resource.mjs +0 -1
- package/node_modules/openai/core/streaming.js +453 -88
- package/node_modules/openai/core/streaming.mjs +454 -89
- package/node_modules/openai/core/uploads.js +3 -1
- package/node_modules/openai/core/uploads.mjs +1 -0
- package/node_modules/openai/helpers/audio.js +198 -28
- package/node_modules/openai/helpers/audio.mjs +199 -29
- package/node_modules/openai/helpers/live.js +6 -0
- package/node_modules/openai/helpers/live.mjs +2 -0
- package/node_modules/openai/helpers/standard-schema.js +393 -0
- package/node_modules/openai/helpers/standard-schema.mjs +387 -0
- package/node_modules/openai/helpers/zod-v3-strict-schema.js +408 -0
- package/node_modules/openai/helpers/zod-v3-strict-schema.mjs +404 -0
- package/node_modules/openai/helpers/zod.js +221 -24
- package/node_modules/openai/helpers/zod.mjs +222 -26
- package/node_modules/openai/index.js +8 -7
- package/node_modules/openai/index.mjs +2 -2
- package/node_modules/openai/internal/assistant-stream-delta.js +316 -0
- package/node_modules/openai/internal/assistant-stream-delta.mjs +308 -0
- package/node_modules/openai/internal/auth/x509-api-origin.js +28 -0
- package/node_modules/openai/internal/auth/x509-api-origin.mjs +24 -0
- package/node_modules/openai/internal/auth/x509-credential-options.js +125 -0
- package/node_modules/openai/internal/auth/x509-credential-options.mjs +121 -0
- package/node_modules/openai/internal/auth/x509-token-exchange.js +248 -0
- package/node_modules/openai/internal/auth/x509-token-exchange.mjs +245 -0
- package/node_modules/openai/internal/auth/x509-transport-capability.js +171 -0
- package/node_modules/openai/internal/auth/x509-transport-capability.mjs +166 -0
- package/node_modules/openai/internal/auth/x509-transport-registry.js +53 -0
- package/node_modules/openai/internal/auth/x509-transport-registry.mjs +48 -0
- package/node_modules/openai/internal/auth/x509-transport-state-browser.js +35 -0
- package/node_modules/openai/internal/auth/x509-transport-state-browser.mjs +32 -0
- package/node_modules/openai/internal/auth/x509-transport-state.cjs +35 -0
- package/node_modules/openai/internal/auth/x509-transport-state.js +36 -0
- package/node_modules/openai/internal/auth/x509-transport-state.mjs +20 -0
- package/node_modules/openai/internal/auth/x509-workload-identity-auth.js +787 -0
- package/node_modules/openai/internal/auth/x509-workload-identity-auth.mjs +778 -0
- package/node_modules/openai/internal/bedrock.js +438 -0
- package/node_modules/openai/internal/bedrock.mjs +424 -0
- package/node_modules/openai/internal/builtin-types.js +0 -1
- package/node_modules/openai/internal/builtin-types.mjs +0 -1
- package/node_modules/openai/internal/data-residency.js +34 -0
- package/node_modules/openai/internal/data-residency.mjs +30 -0
- package/node_modules/openai/internal/decoders/line.js +140 -54
- package/node_modules/openai/internal/decoders/line.mjs +141 -55
- package/node_modules/openai/internal/detect-platform.js +3 -4
- package/node_modules/openai/internal/detect-platform.mjs +3 -4
- package/node_modules/openai/internal/errors.js +3 -3
- package/node_modules/openai/internal/errors.mjs +3 -3
- package/node_modules/openai/internal/headers.js +11 -9
- package/node_modules/openai/internal/headers.mjs +11 -9
- package/node_modules/openai/internal/multipart-encoding.js +51 -0
- package/node_modules/openai/internal/multipart-encoding.mjs +48 -0
- package/node_modules/openai/internal/parse.js +35 -11
- package/node_modules/openai/internal/parse.mjs +35 -11
- package/node_modules/openai/internal/provider.js +50 -0
- package/node_modules/openai/internal/provider.mjs +46 -0
- package/node_modules/openai/internal/qs/formats.js +1 -2
- package/node_modules/openai/internal/qs/formats.mjs +1 -1
- package/node_modules/openai/internal/qs/stringify.js +60 -51
- package/node_modules/openai/internal/qs/stringify.mjs +60 -51
- package/node_modules/openai/internal/qs/utils.js +368 -50
- package/node_modules/openai/internal/qs/utils.mjs +368 -50
- package/node_modules/openai/internal/realtime-credentials.js +23 -0
- package/node_modules/openai/internal/realtime-credentials.mjs +19 -0
- package/node_modules/openai/internal/request-options.js +43 -2
- package/node_modules/openai/internal/request-options.mjs +42 -2
- package/node_modules/openai/internal/responses/canonical-output-text.js +123 -0
- package/node_modules/openai/internal/responses/canonical-output-text.mjs +115 -0
- package/node_modules/openai/internal/responses/output-text-index.js +77 -0
- package/node_modules/openai/internal/responses/output-text-index.mjs +73 -0
- package/node_modules/openai/internal/responses/response-accumulator.js +942 -0
- package/node_modules/openai/internal/responses/response-accumulator.mjs +938 -0
- package/node_modules/openai/internal/shim-types.js +6 -1
- package/node_modules/openai/internal/shim-types.mjs +6 -1
- package/node_modules/openai/internal/shims.js +6 -1
- package/node_modules/openai/internal/shims.mjs +6 -1
- package/node_modules/openai/internal/stream-utils.js +35 -7
- package/node_modules/openai/internal/stream-utils.mjs +35 -7
- package/node_modules/openai/internal/to-file.js +47 -24
- package/node_modules/openai/internal/to-file.mjs +47 -24
- package/node_modules/openai/internal/tslib.js +6 -0
- package/node_modules/openai/internal/tslib.mjs +6 -1
- package/node_modules/openai/internal/types.js +0 -1
- package/node_modules/openai/internal/types.mjs +0 -1
- package/node_modules/openai/internal/uploads.js +377 -43
- package/node_modules/openai/internal/uploads.mjs +376 -44
- package/node_modules/openai/internal/utils/abort.js +94 -0
- package/node_modules/openai/internal/utils/abort.mjs +90 -0
- package/node_modules/openai/internal/utils/base64.js +3 -1
- package/node_modules/openai/internal/utils/base64.mjs +3 -1
- package/node_modules/openai/internal/utils/bytes.js +5 -0
- package/node_modules/openai/internal/utils/bytes.mjs +5 -0
- package/node_modules/openai/internal/utils/env.js +9 -5
- package/node_modules/openai/internal/utils/env.mjs +9 -5
- package/node_modules/openai/internal/utils/log.js +73 -11
- package/node_modules/openai/internal/utils/log.mjs +70 -11
- package/node_modules/openai/internal/utils/path.js +50 -30
- package/node_modules/openai/internal/utils/path.mjs +50 -30
- package/node_modules/openai/internal/utils/query.js +0 -1
- package/node_modules/openai/internal/utils/query.mjs +0 -1
- package/node_modules/openai/internal/utils/sleep.js +51 -2
- package/node_modules/openai/internal/utils/sleep.mjs +51 -2
- package/node_modules/openai/internal/utils/uuid.js +0 -1
- package/node_modules/openai/internal/utils/uuid.mjs +0 -1
- package/node_modules/openai/internal/utils/values.js +0 -1
- package/node_modules/openai/internal/utils/values.mjs +0 -1
- package/node_modules/openai/internal/utils.js +0 -1
- package/node_modules/openai/internal/utils.mjs +0 -1
- package/node_modules/openai/internal/ws-adapter-browser.js +66 -21
- package/node_modules/openai/internal/ws-adapter-browser.mjs +66 -21
- package/node_modules/openai/internal/ws-adapter-node.js +90 -24
- package/node_modules/openai/internal/ws-adapter-node.mjs +90 -24
- package/node_modules/openai/internal/ws-adapter.js +4 -0
- package/node_modules/openai/internal/ws-adapter.mjs +4 -0
- package/node_modules/openai/internal/ws.js +193 -48
- package/node_modules/openai/internal/ws.mjs +188 -49
- package/node_modules/openai/lib/AbstractChatCompletionRunner.js +254 -72
- package/node_modules/openai/lib/AbstractChatCompletionRunner.mjs +256 -74
- package/node_modules/openai/lib/AssistantStream.js +430 -259
- package/node_modules/openai/lib/AssistantStream.mjs +432 -261
- package/node_modules/openai/lib/ChatCompletionRunner.js +12 -5
- package/node_modules/openai/lib/ChatCompletionRunner.mjs +13 -6
- package/node_modules/openai/lib/ChatCompletionStream.js +1430 -189
- package/node_modules/openai/lib/ChatCompletionStream.mjs +1433 -193
- package/node_modules/openai/lib/ChatCompletionStreamingRunner.js +40 -2
- package/node_modules/openai/lib/ChatCompletionStreamingRunner.mjs +41 -3
- package/node_modules/openai/lib/EventEmitter.js +124 -16
- package/node_modules/openai/lib/EventEmitter.mjs +125 -17
- package/node_modules/openai/lib/EventStream.js +1533 -55
- package/node_modules/openai/lib/EventStream.mjs +1534 -56
- package/node_modules/openai/lib/ResponsesParser.js +68 -29
- package/node_modules/openai/lib/ResponsesParser.mjs +69 -30
- package/node_modules/openai/lib/RunnableFunction.js +3 -0
- package/node_modules/openai/lib/RunnableFunction.mjs +3 -0
- package/node_modules/openai/lib/Util.js +7 -4
- package/node_modules/openai/lib/Util.mjs +7 -4
- package/node_modules/openai/lib/agents/agent-session-stream.js +274 -0
- package/node_modules/openai/lib/agents/agent-session-stream.mjs +270 -0
- package/node_modules/openai/lib/agents/output-text.js +8 -0
- package/node_modules/openai/lib/agents/output-text.mjs +5 -0
- package/node_modules/openai/lib/agents/turn-state.js +62 -0
- package/node_modules/openai/lib/agents/turn-state.mjs +58 -0
- package/node_modules/openai/lib/assistant-run-polling.js +17 -0
- package/node_modules/openai/lib/assistant-run-polling.mjs +14 -0
- package/node_modules/openai/lib/chatCompletionUtils.js +5 -6
- package/node_modules/openai/lib/chatCompletionUtils.mjs +5 -6
- package/node_modules/openai/lib/embeddings.js +58 -0
- package/node_modules/openai/lib/embeddings.mjs +55 -0
- package/node_modules/openai/lib/file-processing.js +31 -0
- package/node_modules/openai/lib/file-processing.mjs +28 -0
- package/node_modules/openai/lib/live/transcript-grouper.js +229 -0
- package/node_modules/openai/lib/live/transcript-grouper.mjs +225 -0
- package/node_modules/openai/lib/live/transcript-grouping.js +309 -0
- package/node_modules/openai/lib/live/transcript-grouping.mjs +305 -0
- package/node_modules/openai/lib/live/webrtc.js +16 -0
- package/node_modules/openai/lib/live/webrtc.mjs +10 -0
- package/node_modules/openai/lib/parser.js +142 -42
- package/node_modules/openai/lib/parser.mjs +140 -42
- package/node_modules/openai/lib/polling.js +131 -0
- package/node_modules/openai/lib/polling.mjs +128 -0
- package/node_modules/openai/lib/realtime/webrtc.js +16 -0
- package/node_modules/openai/lib/realtime/webrtc.mjs +10 -0
- package/node_modules/openai/lib/responses/ResponseAccumulator.js +15 -0
- package/node_modules/openai/lib/responses/ResponseAccumulator.mjs +12 -0
- package/node_modules/openai/lib/responses/ResponseInputItems.js +139 -0
- package/node_modules/openai/lib/responses/ResponseInputItems.mjs +135 -0
- package/node_modules/openai/lib/responses/ResponseStream.js +85 -159
- package/node_modules/openai/lib/responses/ResponseStream.mjs +86 -160
- package/node_modules/openai/lib/responses/responses-websocket-lane.js +314 -0
- package/node_modules/openai/lib/responses/responses-websocket-lane.mjs +309 -0
- package/node_modules/openai/lib/responses/responses-websocket-session.js +268 -0
- package/node_modules/openai/lib/responses/responses-websocket-session.mjs +263 -0
- package/node_modules/openai/lib/transform.js +1608 -82
- package/node_modules/openai/lib/transform.mjs +1602 -82
- package/node_modules/openai/lib/vector-store-polling.js +24 -0
- package/node_modules/openai/lib/vector-store-polling.mjs +20 -0
- package/node_modules/openai/lib/vector-store-upload.js +41 -0
- package/node_modules/openai/lib/vector-store-upload.mjs +38 -0
- package/node_modules/openai/lib/webhook-signature.js +125 -0
- package/node_modules/openai/lib/webhook-signature.mjs +121 -0
- package/node_modules/openai/lib/webrtc/connection.js +233 -0
- package/node_modules/openai/lib/webrtc/connection.mjs +229 -0
- package/node_modules/openai/lib/webrtc/data-channel.js +133 -0
- package/node_modules/openai/lib/webrtc/data-channel.mjs +129 -0
- package/node_modules/openai/lib/webrtc/errors.js +18 -0
- package/node_modules/openai/lib/webrtc/errors.mjs +14 -0
- package/node_modules/openai/lib/webrtc/subscriptions.js +64 -0
- package/node_modules/openai/lib/webrtc/subscriptions.mjs +60 -0
- package/node_modules/openai/lib/webrtc/types.js +3 -0
- package/node_modules/openai/lib/webrtc/types.mjs +2 -0
- package/node_modules/openai/live/webrtc.js +8 -0
- package/node_modules/openai/live/webrtc.mjs +2 -0
- package/node_modules/openai/package.json +71 -11
- package/node_modules/openai/providers/bedrock/aws.js +211 -0
- package/node_modules/openai/providers/bedrock/aws.mjs +207 -0
- package/node_modules/openai/providers/bedrock.js +43 -0
- package/node_modules/openai/providers/bedrock.mjs +39 -0
- package/node_modules/openai/realtime/internal-base.js +118 -11
- package/node_modules/openai/realtime/internal-base.mjs +116 -11
- package/node_modules/openai/realtime/webrtc.js +8 -0
- package/node_modules/openai/realtime/webrtc.mjs +2 -0
- package/node_modules/openai/realtime/websocket.js +174 -39
- package/node_modules/openai/realtime/websocket.mjs +175 -40
- package/node_modules/openai/realtime/ws.js +86 -18
- package/node_modules/openai/realtime/ws.mjs +87 -19
- package/node_modules/openai/resources/admin/admin.js +1 -1
- package/node_modules/openai/resources/admin/admin.mjs +1 -1
- package/node_modules/openai/resources/admin/index.js +1 -1
- package/node_modules/openai/resources/admin/index.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/admin-api-keys.js +1 -1
- package/node_modules/openai/resources/admin/organization/admin-api-keys.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/audit-logs.js +1 -1
- package/node_modules/openai/resources/admin/organization/audit-logs.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/certificates.js +1 -1
- package/node_modules/openai/resources/admin/organization/certificates.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/data-retention.js +1 -1
- package/node_modules/openai/resources/admin/organization/data-retention.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/groups/groups.js +1 -1
- package/node_modules/openai/resources/admin/organization/groups/groups.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/groups/index.js +1 -1
- package/node_modules/openai/resources/admin/organization/groups/index.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/groups/roles.js +1 -1
- package/node_modules/openai/resources/admin/organization/groups/roles.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/groups/users.js +1 -1
- package/node_modules/openai/resources/admin/organization/groups/users.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/groups.js +1 -1
- package/node_modules/openai/resources/admin/organization/groups.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/index.js +4 -2
- package/node_modules/openai/resources/admin/organization/index.mjs +2 -1
- package/node_modules/openai/resources/admin/organization/invites.js +1 -1
- package/node_modules/openai/resources/admin/organization/invites.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/organization.js +5 -1
- package/node_modules/openai/resources/admin/organization/organization.mjs +5 -1
- package/node_modules/openai/resources/admin/organization/projects/api-keys.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/api-keys.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/certificates.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/certificates.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/data-retention.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/data-retention.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/groups/groups.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/groups/groups.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/groups/index.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/groups/index.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/groups/roles.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/groups/roles.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/groups.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/groups.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/hosted-tool-permissions.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/hosted-tool-permissions.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/index.js +8 -6
- package/node_modules/openai/resources/admin/organization/projects/index.mjs +3 -2
- package/node_modules/openai/resources/admin/organization/projects/model-permissions.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/model-permissions.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/projects.js +7 -3
- package/node_modules/openai/resources/admin/organization/projects/projects.mjs +7 -3
- package/node_modules/openai/resources/admin/organization/projects/rate-limits.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/rate-limits.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/roles.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/roles.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/service-accounts/api-keys.js +26 -0
- package/node_modules/openai/resources/admin/organization/projects/service-accounts/api-keys.mjs +22 -0
- package/node_modules/openai/resources/admin/organization/projects/service-accounts/index.js +9 -0
- package/node_modules/openai/resources/admin/organization/projects/service-accounts/index.mjs +4 -0
- package/node_modules/openai/resources/admin/organization/projects/service-accounts/service-accounts.js +109 -0
- package/node_modules/openai/resources/admin/organization/projects/service-accounts/service-accounts.mjs +104 -0
- package/node_modules/openai/resources/admin/organization/projects/service-accounts.js +3 -98
- package/node_modules/openai/resources/admin/organization/projects/service-accounts.mjs +2 -96
- package/node_modules/openai/resources/admin/organization/projects/spend-alerts.js +20 -1
- package/node_modules/openai/resources/admin/organization/projects/spend-alerts.mjs +20 -1
- package/node_modules/openai/resources/admin/organization/projects/spend-limit.js +67 -0
- package/node_modules/openai/resources/admin/organization/projects/spend-limit.mjs +63 -0
- package/node_modules/openai/resources/admin/organization/projects/users/index.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/users/index.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/users/roles.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/users/roles.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/users/users.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/users/users.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects/users.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects/users.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/projects.js +1 -1
- package/node_modules/openai/resources/admin/organization/projects.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/roles.js +1 -1
- package/node_modules/openai/resources/admin/organization/roles.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/spend-alerts.js +18 -1
- package/node_modules/openai/resources/admin/organization/spend-alerts.mjs +18 -1
- package/node_modules/openai/resources/admin/organization/spend-limit.js +59 -0
- package/node_modules/openai/resources/admin/organization/spend-limit.mjs +55 -0
- package/node_modules/openai/resources/admin/organization/usage.js +1 -1
- package/node_modules/openai/resources/admin/organization/usage.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/users/index.js +1 -1
- package/node_modules/openai/resources/admin/organization/users/index.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/users/roles.js +1 -1
- package/node_modules/openai/resources/admin/organization/users/roles.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/users/users.js +1 -1
- package/node_modules/openai/resources/admin/organization/users/users.mjs +1 -1
- package/node_modules/openai/resources/admin/organization/users.js +1 -1
- package/node_modules/openai/resources/admin/organization/users.mjs +1 -1
- package/node_modules/openai/resources/admin/organization.js +1 -1
- package/node_modules/openai/resources/admin/organization.mjs +1 -1
- package/node_modules/openai/resources/admin.js +1 -1
- package/node_modules/openai/resources/admin.mjs +1 -1
- package/node_modules/openai/resources/audio/audio.js +1 -1
- package/node_modules/openai/resources/audio/audio.mjs +1 -1
- package/node_modules/openai/resources/audio/index.js +1 -1
- package/node_modules/openai/resources/audio/index.mjs +1 -1
- package/node_modules/openai/resources/audio/speech.js +1 -1
- package/node_modules/openai/resources/audio/speech.mjs +1 -1
- package/node_modules/openai/resources/audio/transcriptions.js +1 -1
- package/node_modules/openai/resources/audio/transcriptions.mjs +1 -1
- package/node_modules/openai/resources/audio/translations.js +1 -1
- package/node_modules/openai/resources/audio/translations.mjs +1 -1
- package/node_modules/openai/resources/audio.js +1 -1
- package/node_modules/openai/resources/audio.mjs +1 -1
- package/node_modules/openai/resources/batches.js +1 -1
- package/node_modules/openai/resources/batches.mjs +1 -1
- package/node_modules/openai/resources/beta/agents/agents.js +118 -0
- package/node_modules/openai/resources/beta/agents/agents.mjs +113 -0
- package/node_modules/openai/resources/beta/agents/environments/environments.js +43 -0
- package/node_modules/openai/resources/beta/agents/environments/environments.mjs +38 -0
- package/node_modules/openai/resources/beta/agents/environments/files.js +61 -0
- package/node_modules/openai/resources/beta/agents/environments/files.mjs +57 -0
- package/node_modules/openai/resources/beta/agents/environments/index.js +11 -0
- package/node_modules/openai/resources/beta/agents/environments/index.mjs +5 -0
- package/node_modules/openai/resources/beta/agents/environments/templates.js +112 -0
- package/node_modules/openai/resources/beta/agents/environments/templates.mjs +108 -0
- package/node_modules/openai/resources/beta/agents/environments.js +6 -0
- package/node_modules/openai/resources/beta/agents/environments.mjs +3 -0
- package/node_modules/openai/resources/beta/agents/index.js +13 -0
- package/node_modules/openai/resources/beta/agents/index.mjs +6 -0
- package/node_modules/openai/resources/beta/agents/sessions/artifacts.js +106 -0
- package/node_modules/openai/resources/beta/agents/sessions/artifacts.mjs +102 -0
- package/node_modules/openai/resources/beta/agents/sessions/events.js +75 -0
- package/node_modules/openai/resources/beta/agents/sessions/events.mjs +71 -0
- package/node_modules/openai/resources/beta/agents/sessions/index.js +17 -0
- package/node_modules/openai/resources/beta/agents/sessions/index.mjs +8 -0
- package/node_modules/openai/resources/beta/agents/sessions/items.js +35 -0
- package/node_modules/openai/resources/beta/agents/sessions/items.mjs +31 -0
- package/node_modules/openai/resources/beta/agents/sessions/sessions.js +127 -0
- package/node_modules/openai/resources/beta/agents/sessions/sessions.mjs +122 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/index.js +11 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/index.mjs +5 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/items.js +36 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/items.mjs +32 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/subagents.js +67 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/subagents.mjs +62 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/turns/index.js +9 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/turns/index.mjs +4 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/turns/items.js +36 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/turns/items.mjs +32 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/turns/turns.js +68 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/turns/turns.mjs +63 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/turns.js +6 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents/turns.mjs +3 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents.js +6 -0
- package/node_modules/openai/resources/beta/agents/sessions/subagents.mjs +3 -0
- package/node_modules/openai/resources/beta/agents/sessions/turns.js +57 -0
- package/node_modules/openai/resources/beta/agents/sessions/turns.mjs +53 -0
- package/node_modules/openai/resources/beta/agents/sessions.js +6 -0
- package/node_modules/openai/resources/beta/agents/sessions.mjs +3 -0
- package/node_modules/openai/resources/beta/agents/vaults/credentials.js +132 -0
- package/node_modules/openai/resources/beta/agents/vaults/credentials.mjs +128 -0
- package/node_modules/openai/resources/beta/agents/vaults/index.js +9 -0
- package/node_modules/openai/resources/beta/agents/vaults/index.mjs +4 -0
- package/node_modules/openai/resources/beta/agents/vaults/vaults.js +93 -0
- package/node_modules/openai/resources/beta/agents/vaults/vaults.mjs +88 -0
- package/node_modules/openai/resources/beta/agents/vaults.js +6 -0
- package/node_modules/openai/resources/beta/agents/vaults.mjs +3 -0
- package/node_modules/openai/resources/beta/agents.js +6 -0
- package/node_modules/openai/resources/beta/agents.mjs +3 -0
- package/node_modules/openai/resources/beta/assistants.js +1 -1
- package/node_modules/openai/resources/beta/assistants.mjs +1 -1
- package/node_modules/openai/resources/beta/beta.js +9 -1
- package/node_modules/openai/resources/beta/beta.mjs +9 -1
- package/node_modules/openai/resources/beta/chatkit/chatkit.js +1 -1
- package/node_modules/openai/resources/beta/chatkit/chatkit.mjs +1 -1
- package/node_modules/openai/resources/beta/chatkit/index.js +1 -1
- package/node_modules/openai/resources/beta/chatkit/index.mjs +1 -1
- package/node_modules/openai/resources/beta/chatkit/sessions.js +1 -1
- package/node_modules/openai/resources/beta/chatkit/sessions.mjs +1 -1
- package/node_modules/openai/resources/beta/chatkit/threads.js +1 -1
- package/node_modules/openai/resources/beta/chatkit/threads.mjs +1 -1
- package/node_modules/openai/resources/beta/chatkit.js +1 -1
- package/node_modules/openai/resources/beta/chatkit.mjs +1 -1
- package/node_modules/openai/resources/beta/index.js +12 -8
- package/node_modules/openai/resources/beta/index.mjs +3 -1
- package/node_modules/openai/resources/beta/realtime/index.js +0 -1
- package/node_modules/openai/resources/beta/realtime/index.mjs +0 -1
- package/node_modules/openai/resources/beta/realtime/realtime.js +0 -1
- package/node_modules/openai/resources/beta/realtime/realtime.mjs +0 -1
- package/node_modules/openai/resources/beta/realtime/sessions.js +0 -1
- package/node_modules/openai/resources/beta/realtime/sessions.mjs +0 -1
- package/node_modules/openai/resources/beta/realtime/transcription-sessions.js +0 -1
- package/node_modules/openai/resources/beta/realtime/transcription-sessions.mjs +0 -1
- package/node_modules/openai/resources/beta/realtime.js +0 -1
- package/node_modules/openai/resources/beta/realtime.mjs +0 -1
- package/node_modules/openai/resources/beta/responses/index.js +11 -0
- package/node_modules/openai/resources/beta/responses/index.mjs +5 -0
- package/node_modules/openai/resources/beta/responses/input-items.js +37 -0
- package/node_modules/openai/resources/beta/responses/input-items.mjs +33 -0
- package/node_modules/openai/resources/beta/responses/input-tokens.js +34 -0
- package/node_modules/openai/resources/beta/responses/input-tokens.mjs +30 -0
- package/node_modules/openai/resources/beta/responses/internal-base.js +66 -0
- package/node_modules/openai/resources/beta/responses/internal-base.mjs +60 -0
- package/node_modules/openai/resources/beta/responses/responses.js +121 -0
- package/node_modules/openai/resources/beta/responses/responses.mjs +116 -0
- package/node_modules/openai/resources/beta/responses/ws-base.js +566 -0
- package/node_modules/openai/resources/beta/responses/ws-base.mjs +560 -0
- package/node_modules/openai/resources/beta/responses/ws.js +47 -0
- package/node_modules/openai/resources/beta/responses/ws.mjs +42 -0
- package/node_modules/openai/resources/beta/responses.js +6 -0
- package/node_modules/openai/resources/beta/responses.mjs +3 -0
- package/node_modules/openai/resources/beta/threads/index.js +1 -1
- package/node_modules/openai/resources/beta/threads/index.mjs +1 -1
- package/node_modules/openai/resources/beta/threads/messages.js +1 -1
- package/node_modules/openai/resources/beta/threads/messages.mjs +1 -1
- package/node_modules/openai/resources/beta/threads/runs/index.js +1 -1
- package/node_modules/openai/resources/beta/threads/runs/index.mjs +1 -1
- package/node_modules/openai/resources/beta/threads/runs/runs.js +3 -44
- package/node_modules/openai/resources/beta/threads/runs/runs.mjs +3 -44
- package/node_modules/openai/resources/beta/threads/runs/steps.js +1 -1
- package/node_modules/openai/resources/beta/threads/runs/steps.mjs +1 -1
- package/node_modules/openai/resources/beta/threads/runs.js +1 -1
- package/node_modules/openai/resources/beta/threads/runs.mjs +1 -1
- package/node_modules/openai/resources/beta/threads/threads.js +1 -1
- package/node_modules/openai/resources/beta/threads/threads.mjs +1 -1
- package/node_modules/openai/resources/beta/threads.js +1 -1
- package/node_modules/openai/resources/beta/threads.mjs +1 -1
- package/node_modules/openai/resources/beta.js +1 -1
- package/node_modules/openai/resources/beta.mjs +1 -1
- package/node_modules/openai/resources/chat/chat.js +1 -1
- package/node_modules/openai/resources/chat/chat.mjs +1 -1
- package/node_modules/openai/resources/chat/completions/completions.js +2 -5
- package/node_modules/openai/resources/chat/completions/completions.mjs +2 -5
- package/node_modules/openai/resources/chat/completions/index.js +1 -1
- package/node_modules/openai/resources/chat/completions/index.mjs +1 -1
- package/node_modules/openai/resources/chat/completions/messages.js +1 -1
- package/node_modules/openai/resources/chat/completions/messages.mjs +1 -1
- package/node_modules/openai/resources/chat/completions.js +1 -1
- package/node_modules/openai/resources/chat/completions.mjs +1 -1
- package/node_modules/openai/resources/chat/index.js +1 -1
- package/node_modules/openai/resources/chat/index.mjs +1 -1
- package/node_modules/openai/resources/chat.js +1 -1
- package/node_modules/openai/resources/chat.mjs +1 -1
- package/node_modules/openai/resources/completions.js +1 -1
- package/node_modules/openai/resources/completions.mjs +1 -1
- package/node_modules/openai/resources/containers/containers.js +1 -1
- package/node_modules/openai/resources/containers/containers.mjs +1 -1
- package/node_modules/openai/resources/containers/files/content.js +1 -1
- package/node_modules/openai/resources/containers/files/content.mjs +1 -1
- package/node_modules/openai/resources/containers/files/files.js +1 -1
- package/node_modules/openai/resources/containers/files/files.mjs +1 -1
- package/node_modules/openai/resources/containers/files/index.js +1 -1
- package/node_modules/openai/resources/containers/files/index.mjs +1 -1
- package/node_modules/openai/resources/containers/files.js +1 -1
- package/node_modules/openai/resources/containers/files.mjs +1 -1
- package/node_modules/openai/resources/containers/index.js +1 -1
- package/node_modules/openai/resources/containers/index.mjs +1 -1
- package/node_modules/openai/resources/containers.js +1 -1
- package/node_modules/openai/resources/containers.mjs +1 -1
- package/node_modules/openai/resources/content-provenance-checks.js +24 -0
- package/node_modules/openai/resources/content-provenance-checks.mjs +20 -0
- package/node_modules/openai/resources/conversations/conversations.js +1 -1
- package/node_modules/openai/resources/conversations/conversations.mjs +1 -1
- package/node_modules/openai/resources/conversations/index.js +1 -1
- package/node_modules/openai/resources/conversations/index.mjs +1 -1
- package/node_modules/openai/resources/conversations/items.js +1 -1
- package/node_modules/openai/resources/conversations/items.mjs +1 -1
- package/node_modules/openai/resources/conversations.js +1 -1
- package/node_modules/openai/resources/conversations.mjs +1 -1
- package/node_modules/openai/resources/embeddings.js +3 -47
- package/node_modules/openai/resources/embeddings.mjs +3 -47
- package/node_modules/openai/resources/evals/evals.js +2 -2
- package/node_modules/openai/resources/evals/evals.mjs +2 -2
- package/node_modules/openai/resources/evals/index.js +1 -1
- package/node_modules/openai/resources/evals/index.mjs +1 -1
- package/node_modules/openai/resources/evals/runs/index.js +1 -1
- package/node_modules/openai/resources/evals/runs/index.mjs +1 -1
- package/node_modules/openai/resources/evals/runs/output-items.js +1 -1
- package/node_modules/openai/resources/evals/runs/output-items.mjs +1 -1
- package/node_modules/openai/resources/evals/runs/runs.js +1 -1
- package/node_modules/openai/resources/evals/runs/runs.mjs +1 -1
- package/node_modules/openai/resources/evals/runs.js +1 -1
- package/node_modules/openai/resources/evals/runs.mjs +1 -1
- package/node_modules/openai/resources/evals.js +1 -1
- package/node_modules/openai/resources/evals.mjs +1 -1
- package/node_modules/openai/resources/files.js +9 -22
- package/node_modules/openai/resources/files.mjs +9 -22
- package/node_modules/openai/resources/fine-tuning/alpha/alpha.js +1 -1
- package/node_modules/openai/resources/fine-tuning/alpha/alpha.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/alpha/graders.js +1 -1
- package/node_modules/openai/resources/fine-tuning/alpha/graders.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/alpha/index.js +1 -1
- package/node_modules/openai/resources/fine-tuning/alpha/index.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/alpha.js +1 -1
- package/node_modules/openai/resources/fine-tuning/alpha.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/checkpoints/checkpoints.js +1 -1
- package/node_modules/openai/resources/fine-tuning/checkpoints/checkpoints.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/checkpoints/index.js +1 -1
- package/node_modules/openai/resources/fine-tuning/checkpoints/index.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/checkpoints/permissions.js +9 -5
- package/node_modules/openai/resources/fine-tuning/checkpoints/permissions.mjs +9 -5
- package/node_modules/openai/resources/fine-tuning/checkpoints.js +1 -1
- package/node_modules/openai/resources/fine-tuning/checkpoints.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/fine-tuning.js +1 -1
- package/node_modules/openai/resources/fine-tuning/fine-tuning.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/index.js +1 -1
- package/node_modules/openai/resources/fine-tuning/index.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/jobs/checkpoints.js +1 -1
- package/node_modules/openai/resources/fine-tuning/jobs/checkpoints.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/jobs/index.js +1 -1
- package/node_modules/openai/resources/fine-tuning/jobs/index.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/jobs/jobs.js +3 -3
- package/node_modules/openai/resources/fine-tuning/jobs/jobs.mjs +3 -3
- package/node_modules/openai/resources/fine-tuning/jobs.js +1 -1
- package/node_modules/openai/resources/fine-tuning/jobs.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning/methods.js +1 -1
- package/node_modules/openai/resources/fine-tuning/methods.mjs +1 -1
- package/node_modules/openai/resources/fine-tuning.js +1 -1
- package/node_modules/openai/resources/fine-tuning.mjs +1 -1
- package/node_modules/openai/resources/graders/grader-models.js +1 -1
- package/node_modules/openai/resources/graders/grader-models.mjs +1 -1
- package/node_modules/openai/resources/graders/graders.js +1 -1
- package/node_modules/openai/resources/graders/graders.mjs +1 -1
- package/node_modules/openai/resources/graders/index.js +1 -1
- package/node_modules/openai/resources/graders/index.mjs +1 -1
- package/node_modules/openai/resources/graders.js +1 -1
- package/node_modules/openai/resources/graders.mjs +1 -1
- package/node_modules/openai/resources/images.js +8 -2
- package/node_modules/openai/resources/images.mjs +8 -2
- package/node_modules/openai/resources/index.js +9 -3
- package/node_modules/openai/resources/index.mjs +5 -2
- package/node_modules/openai/resources/live/forks/forks.js +9 -0
- package/node_modules/openai/resources/live/forks/forks.mjs +5 -0
- package/node_modules/openai/resources/live/forks/index.js +7 -0
- package/node_modules/openai/resources/live/forks/index.mjs +3 -0
- package/node_modules/openai/resources/live/forks/internal-base.js +65 -0
- package/node_modules/openai/resources/live/forks/internal-base.mjs +59 -0
- package/node_modules/openai/resources/live/forks/ws-base.js +547 -0
- package/node_modules/openai/resources/live/forks/ws-base.mjs +543 -0
- package/node_modules/openai/resources/live/forks/ws.js +32 -0
- package/node_modules/openai/resources/live/forks/ws.mjs +27 -0
- package/node_modules/openai/resources/live/forks.js +6 -0
- package/node_modules/openai/resources/live/forks.mjs +3 -0
- package/node_modules/openai/resources/live/index.js +13 -0
- package/node_modules/openai/resources/live/index.mjs +6 -0
- package/node_modules/openai/resources/live/internal-base.js +64 -0
- package/node_modules/openai/resources/live/internal-base.mjs +58 -0
- package/node_modules/openai/resources/live/live.js +40 -0
- package/node_modules/openai/resources/live/live.mjs +35 -0
- package/node_modules/openai/resources/live/sessions.js +124 -0
- package/node_modules/openai/resources/live/sessions.mjs +120 -0
- package/node_modules/openai/resources/live/sideband/index.js +7 -0
- package/node_modules/openai/resources/live/sideband/index.mjs +3 -0
- package/node_modules/openai/resources/live/sideband/internal-base.js +65 -0
- package/node_modules/openai/resources/live/sideband/internal-base.mjs +59 -0
- package/node_modules/openai/resources/live/sideband/sideband.js +9 -0
- package/node_modules/openai/resources/live/sideband/sideband.mjs +5 -0
- package/node_modules/openai/resources/live/sideband/ws-base.js +547 -0
- package/node_modules/openai/resources/live/sideband/ws-base.mjs +543 -0
- package/node_modules/openai/resources/live/sideband/ws.js +32 -0
- package/node_modules/openai/resources/live/sideband/ws.mjs +27 -0
- package/node_modules/openai/resources/live/sideband.js +6 -0
- package/node_modules/openai/resources/live/sideband.mjs +3 -0
- package/node_modules/openai/resources/live/ws-base.js +547 -0
- package/node_modules/openai/resources/live/ws-base.mjs +543 -0
- package/node_modules/openai/resources/live/ws.js +32 -0
- package/node_modules/openai/resources/live/ws.mjs +27 -0
- package/node_modules/openai/resources/live.js +6 -0
- package/node_modules/openai/resources/live.mjs +3 -0
- package/node_modules/openai/resources/models.js +1 -1
- package/node_modules/openai/resources/models.mjs +1 -1
- package/node_modules/openai/resources/moderations.js +3 -2
- package/node_modules/openai/resources/moderations.mjs +3 -2
- package/node_modules/openai/resources/realtime/calls.js +25 -1
- package/node_modules/openai/resources/realtime/calls.mjs +25 -1
- package/node_modules/openai/resources/realtime/client-secrets.js +2 -2
- package/node_modules/openai/resources/realtime/client-secrets.mjs +2 -2
- package/node_modules/openai/resources/realtime/index.js +1 -1
- package/node_modules/openai/resources/realtime/index.mjs +2 -2
- package/node_modules/openai/resources/realtime/realtime.js +1 -1
- package/node_modules/openai/resources/realtime/realtime.mjs +1 -1
- package/node_modules/openai/resources/realtime.js +1 -1
- package/node_modules/openai/resources/realtime.mjs +1 -1
- package/node_modules/openai/resources/responses/index.js +1 -1
- package/node_modules/openai/resources/responses/index.mjs +1 -1
- package/node_modules/openai/resources/responses/input-items.js +1 -1
- package/node_modules/openai/resources/responses/input-items.mjs +1 -1
- package/node_modules/openai/resources/responses/input-tokens.js +1 -1
- package/node_modules/openai/resources/responses/input-tokens.mjs +1 -1
- package/node_modules/openai/resources/responses/internal-base.js +24 -6
- package/node_modules/openai/resources/responses/internal-base.mjs +24 -6
- package/node_modules/openai/resources/responses/responses.js +5 -5
- package/node_modules/openai/resources/responses/responses.mjs +5 -5
- package/node_modules/openai/resources/responses/ws-base.js +115 -23
- package/node_modules/openai/resources/responses/ws-base.mjs +115 -25
- package/node_modules/openai/resources/responses/ws.js +23 -7
- package/node_modules/openai/resources/responses/ws.mjs +23 -7
- package/node_modules/openai/resources/responses.js +1 -1
- package/node_modules/openai/resources/responses.mjs +1 -1
- package/node_modules/openai/resources/safety/alerts.js +16 -0
- package/node_modules/openai/resources/safety/alerts.mjs +12 -0
- package/node_modules/openai/resources/safety/index.js +9 -0
- package/node_modules/openai/resources/safety/index.mjs +4 -0
- package/node_modules/openai/resources/safety/safety.js +17 -0
- package/node_modules/openai/resources/safety/safety.mjs +12 -0
- package/node_modules/openai/resources/safety.js +6 -0
- package/node_modules/openai/resources/safety.mjs +3 -0
- package/node_modules/openai/resources/shared.js +1 -1
- package/node_modules/openai/resources/shared.mjs +1 -1
- package/node_modules/openai/resources/skills/content.js +1 -1
- package/node_modules/openai/resources/skills/content.mjs +1 -1
- package/node_modules/openai/resources/skills/index.js +1 -1
- package/node_modules/openai/resources/skills/index.mjs +1 -1
- package/node_modules/openai/resources/skills/skills.js +4 -2
- package/node_modules/openai/resources/skills/skills.mjs +4 -2
- package/node_modules/openai/resources/skills/versions/content.js +1 -1
- package/node_modules/openai/resources/skills/versions/content.mjs +1 -1
- package/node_modules/openai/resources/skills/versions/index.js +1 -1
- package/node_modules/openai/resources/skills/versions/index.mjs +1 -1
- package/node_modules/openai/resources/skills/versions/versions.js +4 -2
- package/node_modules/openai/resources/skills/versions/versions.mjs +4 -2
- package/node_modules/openai/resources/skills/versions.js +1 -1
- package/node_modules/openai/resources/skills/versions.mjs +1 -1
- package/node_modules/openai/resources/skills.js +1 -1
- package/node_modules/openai/resources/skills.mjs +1 -1
- package/node_modules/openai/resources/uploads/index.js +1 -1
- package/node_modules/openai/resources/uploads/index.mjs +1 -1
- package/node_modules/openai/resources/uploads/parts.js +6 -5
- package/node_modules/openai/resources/uploads/parts.mjs +6 -5
- package/node_modules/openai/resources/uploads/uploads.js +10 -10
- package/node_modules/openai/resources/uploads/uploads.mjs +10 -10
- package/node_modules/openai/resources/uploads.js +1 -1
- package/node_modules/openai/resources/uploads.mjs +1 -1
- package/node_modules/openai/resources/vector-stores/file-batches.js +6 -63
- package/node_modules/openai/resources/vector-stores/file-batches.mjs +6 -63
- package/node_modules/openai/resources/vector-stores/files.js +6 -39
- package/node_modules/openai/resources/vector-stores/files.mjs +6 -39
- package/node_modules/openai/resources/vector-stores/index.js +1 -1
- package/node_modules/openai/resources/vector-stores/index.mjs +1 -1
- package/node_modules/openai/resources/vector-stores/vector-stores.js +1 -1
- package/node_modules/openai/resources/vector-stores/vector-stores.mjs +1 -1
- package/node_modules/openai/resources/vector-stores.js +1 -1
- package/node_modules/openai/resources/vector-stores.mjs +1 -1
- package/node_modules/openai/resources/videos.js +24 -1
- package/node_modules/openai/resources/videos.mjs +24 -1
- package/node_modules/openai/resources/webhooks/event-types.js +21 -0
- package/node_modules/openai/resources/webhooks/event-types.mjs +17 -0
- package/node_modules/openai/resources/webhooks/index.js +4 -1
- package/node_modules/openai/resources/webhooks/index.mjs +2 -1
- package/node_modules/openai/resources/webhooks/webhooks.js +127 -43
- package/node_modules/openai/resources/webhooks/webhooks.mjs +127 -43
- package/node_modules/openai/resources/webhooks.js +1 -1
- package/node_modules/openai/resources/webhooks.mjs +1 -1
- package/node_modules/openai/src/_vendor/partial-json-parser/LICENSE +21 -0
- package/node_modules/openai/src/_vendor/partial-json-parser/README.md +11 -1
- package/node_modules/openai/src/_vendor/partial-json-parser/parser.ts +66 -35
- package/node_modules/openai/src/_vendor/zod-to-json-schema/Options.ts +32 -18
- package/node_modules/openai/src/_vendor/zod-to-json-schema/Refs.ts +7 -6
- package/node_modules/openai/src/_vendor/zod-to-json-schema/errorMessages.ts +5 -3
- package/node_modules/openai/src/_vendor/zod-to-json-schema/index.ts +3 -1
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parseDef.ts +194 -79
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/array.ts +8 -5
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/bigint.ts +20 -12
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/branded.ts +4 -4
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/catch.ts +4 -5
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/date.ts +16 -10
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/default.ts +10 -5
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/effects.ts +4 -3
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/enum.ts +1 -1
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/intersection.ts +12 -9
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/literal.ts +12 -2
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/map.ts +6 -4
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/nativeEnum.ts +10 -11
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/null.ts +4 -3
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/nullable.ts +25 -10
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/number.ts +17 -8
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/object.ts +57 -54
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/optional.ts +25 -17
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/pipeline.ts +8 -6
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/promise.ts +10 -5
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/readonly.ts +4 -5
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/record.ts +22 -19
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/set.ts +6 -4
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/string.ts +62 -37
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/tuple.ts +32 -25
- package/node_modules/openai/src/_vendor/zod-to-json-schema/parsers/union.ts +51 -33
- package/node_modules/openai/src/_vendor/zod-to-json-schema/util.ts +11 -6
- package/node_modules/openai/src/_vendor/zod-to-json-schema/zodToJsonSchema.ts +133 -52
- package/node_modules/openai/src/auth/index.ts +7 -1
- package/node_modules/openai/src/auth/subject-token-providers.ts +281 -16
- package/node_modules/openai/src/auth/types.ts +48 -5
- package/node_modules/openai/src/auth/workload-identity-auth.ts +227 -26
- package/node_modules/openai/src/auth/x509-transport.ts +369 -0
- package/node_modules/openai/src/azure.ts +127 -28
- package/node_modules/openai/src/bedrock.ts +294 -0
- package/node_modules/openai/src/beta/realtime/internal-base.ts +136 -16
- package/node_modules/openai/src/beta/realtime/websocket.ts +264 -48
- package/node_modules/openai/src/beta/realtime/ws.ts +138 -25
- package/node_modules/openai/src/client.ts +975 -124
- package/node_modules/openai/src/core/EventEmitter.ts +162 -26
- package/node_modules/openai/src/core/api-promise.ts +0 -2
- package/node_modules/openai/src/core/error.ts +6 -8
- package/node_modules/openai/src/core/pagination.ts +67 -7
- package/node_modules/openai/src/core/resource.ts +0 -2
- package/node_modules/openai/src/core/streaming.ts +490 -100
- package/node_modules/openai/src/core/uploads.ts +6 -1
- package/node_modules/openai/src/helpers/audio.ts +215 -32
- package/node_modules/openai/src/helpers/live.ts +8 -0
- package/node_modules/openai/src/helpers/standard-schema.ts +819 -0
- package/node_modules/openai/src/helpers/zod-v3-strict-schema.ts +520 -0
- package/node_modules/openai/src/helpers/zod.ts +418 -56
- package/node_modules/openai/src/index.ts +4 -5
- package/node_modules/openai/src/internal/assistant-stream-delta.ts +440 -0
- package/node_modules/openai/src/internal/auth/x509-api-origin.ts +27 -0
- package/node_modules/openai/src/internal/auth/x509-credential-options.ts +149 -0
- package/node_modules/openai/src/internal/auth/x509-token-exchange.ts +319 -0
- package/node_modules/openai/src/internal/auth/x509-transport-capability.ts +227 -0
- package/node_modules/openai/src/internal/auth/x509-transport-registry.ts +127 -0
- package/node_modules/openai/src/internal/auth/x509-transport-state-browser.ts +43 -0
- package/node_modules/openai/src/internal/auth/x509-transport-state.cts +43 -0
- package/node_modules/openai/src/internal/auth/x509-workload-identity-auth.ts +972 -0
- package/node_modules/openai/src/internal/bedrock.ts +586 -0
- package/node_modules/openai/src/internal/builtin-types.ts +0 -2
- package/node_modules/openai/src/internal/data-residency.ts +44 -0
- package/node_modules/openai/src/internal/decoders/line.ts +145 -61
- package/node_modules/openai/src/internal/detect-platform.ts +3 -5
- package/node_modules/openai/src/internal/errors.ts +3 -4
- package/node_modules/openai/src/internal/headers.ts +14 -10
- package/node_modules/openai/src/internal/multipart-encoding.ts +53 -0
- package/node_modules/openai/src/internal/parse.ts +47 -19
- package/node_modules/openai/src/internal/provider.ts +92 -0
- package/node_modules/openai/src/internal/qs/formats.ts +1 -1
- package/node_modules/openai/src/internal/qs/stringify.ts +57 -53
- package/node_modules/openai/src/internal/qs/types.ts +1 -1
- package/node_modules/openai/src/internal/qs/utils.ts +443 -54
- package/node_modules/openai/src/internal/realtime-credentials.ts +27 -0
- package/node_modules/openai/src/internal/request-options.ts +52 -3
- package/node_modules/openai/src/internal/responses/canonical-output-text.ts +160 -0
- package/node_modules/openai/src/internal/responses/output-text-index.ts +84 -0
- package/node_modules/openai/src/internal/responses/response-accumulator.ts +1263 -0
- package/node_modules/openai/src/internal/shim-types.ts +3 -4
- package/node_modules/openai/src/internal/shims.ts +0 -2
- package/node_modules/openai/src/internal/stream-utils.ts +37 -5
- package/node_modules/openai/src/internal/to-file.ts +90 -35
- package/node_modules/openai/src/internal/types.ts +21 -29
- package/node_modules/openai/src/internal/uploads.ts +533 -59
- package/node_modules/openai/src/internal/utils/abort.ts +116 -0
- package/node_modules/openai/src/internal/utils/base64.ts +3 -2
- package/node_modules/openai/src/internal/utils/bytes.ts +7 -0
- package/node_modules/openai/src/internal/utils/env.ts +9 -7
- package/node_modules/openai/src/internal/utils/log.ts +77 -14
- package/node_modules/openai/src/internal/utils/path.ts +53 -32
- package/node_modules/openai/src/internal/utils/query.ts +0 -2
- package/node_modules/openai/src/internal/utils/sleep.ts +51 -2
- package/node_modules/openai/src/internal/utils/uuid.ts +0 -2
- package/node_modules/openai/src/internal/utils/values.ts +0 -2
- package/node_modules/openai/src/internal/utils.ts +0 -2
- package/node_modules/openai/src/internal/ws-adapter-browser.ts +83 -24
- package/node_modules/openai/src/internal/ws-adapter-node.ts +105 -26
- package/node_modules/openai/src/internal/ws-adapter.ts +23 -0
- package/node_modules/openai/src/internal/ws.ts +250 -51
- package/node_modules/openai/src/lib/.keep +2 -2
- package/node_modules/openai/src/lib/AbstractChatCompletionRunner.ts +349 -102
- package/node_modules/openai/src/lib/AssistantStream.ts +537 -268
- package/node_modules/openai/src/lib/ChatCompletionRunner.ts +75 -22
- package/node_modules/openai/src/lib/ChatCompletionStream.ts +2016 -268
- package/node_modules/openai/src/lib/ChatCompletionStreamingRunner.ts +115 -17
- package/node_modules/openai/src/lib/EventEmitter.ts +171 -26
- package/node_modules/openai/src/lib/EventStream.ts +1979 -64
- package/node_modules/openai/src/lib/ResponsesParser.ts +153 -56
- package/node_modules/openai/src/lib/RunnableFunction.ts +99 -37
- package/node_modules/openai/src/lib/Util.ts +7 -5
- package/node_modules/openai/src/lib/agents/agent-session-stream.ts +328 -0
- package/node_modules/openai/src/lib/agents/output-text.ts +6 -0
- package/node_modules/openai/src/lib/agents/turn-state.ts +61 -0
- package/node_modules/openai/src/lib/assistant-run-polling.ts +27 -0
- package/node_modules/openai/src/lib/chatCompletionUtils.ts +9 -10
- package/node_modules/openai/src/lib/embeddings.ts +73 -0
- package/node_modules/openai/src/lib/file-processing.ts +37 -0
- package/node_modules/openai/src/lib/jsonschema.ts +77 -34
- package/node_modules/openai/src/lib/live/transcript-grouper.ts +307 -0
- package/node_modules/openai/src/lib/live/transcript-grouping.ts +394 -0
- package/node_modules/openai/src/lib/live/webrtc.ts +23 -0
- package/node_modules/openai/src/lib/parser.ts +247 -69
- package/node_modules/openai/src/lib/polling.ts +145 -0
- package/node_modules/openai/src/lib/realtime/webrtc.ts +20 -0
- package/node_modules/openai/src/lib/responses/EventTypes.ts +9 -60
- package/node_modules/openai/src/lib/responses/ResponseAccumulator.ts +27 -0
- package/node_modules/openai/src/lib/responses/ResponseInputItems.ts +167 -0
- package/node_modules/openai/src/lib/responses/ResponseStream.ts +135 -179
- package/node_modules/openai/src/lib/responses/responses-websocket-lane.ts +388 -0
- package/node_modules/openai/src/lib/responses/responses-websocket-session.ts +317 -0
- package/node_modules/openai/src/lib/transform.ts +2015 -100
- package/node_modules/openai/src/lib/vector-store-polling.ts +46 -0
- package/node_modules/openai/src/lib/vector-store-upload.ts +57 -0
- package/node_modules/openai/src/lib/webhook-signature.ts +164 -0
- package/node_modules/openai/src/lib/webrtc/connection.ts +313 -0
- package/node_modules/openai/src/lib/webrtc/data-channel.ts +151 -0
- package/node_modules/openai/src/lib/webrtc/errors.ts +38 -0
- package/node_modules/openai/src/lib/webrtc/subscriptions.ts +65 -0
- package/node_modules/openai/src/lib/webrtc/types.ts +110 -0
- package/node_modules/openai/src/live/webrtc.ts +10 -0
- package/node_modules/openai/src/providers/bedrock/aws.ts +331 -0
- package/node_modules/openai/src/providers/bedrock.ts +51 -0
- package/node_modules/openai/src/realtime/internal-base.ts +265 -17
- package/node_modules/openai/src/realtime/webrtc.ts +10 -0
- package/node_modules/openai/src/realtime/websocket.ts +259 -54
- package/node_modules/openai/src/realtime/ws.ts +135 -29
- package/node_modules/openai/src/resources/admin/admin.ts +1 -1
- package/node_modules/openai/src/resources/admin/index.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/admin-api-keys.ts +18 -2
- package/node_modules/openai/src/resources/admin/organization/audit-logs.ts +327 -4
- package/node_modules/openai/src/resources/admin/organization/certificates.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/data-retention.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/groups/groups.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/groups/index.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/groups/roles.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/groups/users.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/groups.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/index.ts +9 -1
- package/node_modules/openai/src/resources/admin/organization/invites.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/organization.ts +21 -1
- package/node_modules/openai/src/resources/admin/organization/projects/api-keys.ts +22 -2
- package/node_modules/openai/src/resources/admin/organization/projects/certificates.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/data-retention.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/groups/groups.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/groups/index.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/groups/roles.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/groups.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/hosted-tool-permissions.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/index.ts +10 -2
- package/node_modules/openai/src/resources/admin/organization/projects/model-permissions.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/projects.ts +70 -19
- package/node_modules/openai/src/resources/admin/organization/projects/rate-limits.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/roles.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/service-accounts/api-keys.ts +91 -0
- package/node_modules/openai/src/resources/admin/organization/projects/service-accounts/index.ts +15 -0
- package/node_modules/openai/src/resources/admin/organization/projects/service-accounts/service-accounts.ts +299 -0
- package/node_modules/openai/src/resources/admin/organization/projects/service-accounts.ts +2 -265
- package/node_modules/openai/src/resources/admin/organization/projects/spend-alerts.ts +33 -1
- package/node_modules/openai/src/resources/admin/organization/projects/spend-limit.ts +156 -0
- package/node_modules/openai/src/resources/admin/organization/projects/users/index.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/users/roles.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/users/users.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects/users.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/projects.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/roles.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/spend-alerts.ts +19 -1
- package/node_modules/openai/src/resources/admin/organization/spend-limit.ts +144 -0
- package/node_modules/openai/src/resources/admin/organization/usage.ts +706 -89
- package/node_modules/openai/src/resources/admin/organization/users/index.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/users/roles.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/users/users.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization/users.ts +1 -1
- package/node_modules/openai/src/resources/admin/organization.ts +1 -1
- package/node_modules/openai/src/resources/admin.ts +1 -1
- package/node_modules/openai/src/resources/audio/audio.ts +4 -1
- package/node_modules/openai/src/resources/audio/index.ts +2 -1
- package/node_modules/openai/src/resources/audio/speech.ts +4 -3
- package/node_modules/openai/src/resources/audio/transcriptions.ts +51 -13
- package/node_modules/openai/src/resources/audio/translations.ts +5 -3
- package/node_modules/openai/src/resources/audio.ts +1 -1
- package/node_modules/openai/src/resources/batches.ts +10 -9
- package/node_modules/openai/src/resources/beta/agents/agents.ts +4627 -0
- package/node_modules/openai/src/resources/beta/agents/environments/environments.ts +111 -0
- package/node_modules/openai/src/resources/beta/agents/environments/files.ts +169 -0
- package/node_modules/openai/src/resources/beta/agents/environments/index.ts +19 -0
- package/node_modules/openai/src/resources/beta/agents/environments/templates.ts +535 -0
- package/node_modules/openai/src/resources/beta/agents/environments.ts +3 -0
- package/node_modules/openai/src/resources/beta/agents/index.ts +127 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/artifacts.ts +249 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/events.ts +94 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/index.ts +24 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/items.ts +59 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/sessions.ts +403 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/subagents/index.ts +5 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/subagents/items.ts +65 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/subagents/subagents.ts +113 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/subagents/turns/index.ts +4 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/subagents/turns/items.ts +70 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/subagents/turns/turns.ts +111 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/subagents/turns.ts +3 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/subagents.ts +3 -0
- package/node_modules/openai/src/resources/beta/agents/sessions/turns.ts +159 -0
- package/node_modules/openai/src/resources/beta/agents/sessions.ts +3 -0
- package/node_modules/openai/src/resources/beta/agents/vaults/credentials.ts +693 -0
- package/node_modules/openai/src/resources/beta/agents/vaults/index.ts +29 -0
- package/node_modules/openai/src/resources/beta/agents/vaults/vaults.ts +243 -0
- package/node_modules/openai/src/resources/beta/agents/vaults.ts +3 -0
- package/node_modules/openai/src/resources/beta/agents.ts +3 -0
- package/node_modules/openai/src/resources/beta/assistants.ts +154 -172
- package/node_modules/openai/src/resources/beta/beta.ts +578 -3
- package/node_modules/openai/src/resources/beta/chatkit/chatkit.ts +1 -1
- package/node_modules/openai/src/resources/beta/chatkit/index.ts +1 -1
- package/node_modules/openai/src/resources/beta/chatkit/sessions.ts +1 -1
- package/node_modules/openai/src/resources/beta/chatkit/threads.ts +1 -1
- package/node_modules/openai/src/resources/beta/chatkit.ts +1 -1
- package/node_modules/openai/src/resources/beta/index.ts +290 -1
- package/node_modules/openai/src/resources/beta/realtime/index.ts +0 -2
- package/node_modules/openai/src/resources/beta/realtime/realtime.ts +0 -2
- package/node_modules/openai/src/resources/beta/realtime/sessions.ts +0 -2
- package/node_modules/openai/src/resources/beta/realtime/transcription-sessions.ts +0 -2
- package/node_modules/openai/src/resources/beta/realtime.ts +0 -2
- package/node_modules/openai/src/resources/beta/responses/index.ts +189 -0
- package/node_modules/openai/src/resources/beta/responses/input-items.ts +105 -0
- package/node_modules/openai/src/resources/beta/responses/input-tokens.ts +249 -0
- package/node_modules/openai/src/resources/beta/responses/internal-base.ts +136 -0
- package/node_modules/openai/src/resources/beta/responses/responses.ts +15060 -0
- package/node_modules/openai/src/resources/beta/responses/ws-base.ts +729 -0
- package/node_modules/openai/src/resources/beta/responses/ws.ts +62 -0
- package/node_modules/openai/src/resources/beta/responses.ts +3 -0
- package/node_modules/openai/src/resources/beta/threads/index.ts +1 -1
- package/node_modules/openai/src/resources/beta/threads/messages.ts +30 -24
- package/node_modules/openai/src/resources/beta/threads/runs/index.ts +2 -2
- package/node_modules/openai/src/resources/beta/threads/runs/runs.ts +47 -93
- package/node_modules/openai/src/resources/beta/threads/runs/steps.ts +15 -16
- package/node_modules/openai/src/resources/beta/threads/runs.ts +1 -1
- package/node_modules/openai/src/resources/beta/threads/threads.ts +54 -51
- package/node_modules/openai/src/resources/beta/threads.ts +1 -1
- package/node_modules/openai/src/resources/beta.ts +1 -1
- package/node_modules/openai/src/resources/chat/chat.ts +1 -1
- package/node_modules/openai/src/resources/chat/completions/completions.ts +762 -108
- package/node_modules/openai/src/resources/chat/completions/index.ts +1 -1
- package/node_modules/openai/src/resources/chat/completions/messages.ts +1 -1
- package/node_modules/openai/src/resources/chat/completions.ts +1 -1
- package/node_modules/openai/src/resources/chat/index.ts +1 -1
- package/node_modules/openai/src/resources/chat.ts +1 -1
- package/node_modules/openai/src/resources/completions.ts +36 -15
- package/node_modules/openai/src/resources/containers/containers.ts +1 -1
- package/node_modules/openai/src/resources/containers/files/content.ts +1 -1
- package/node_modules/openai/src/resources/containers/files/files.ts +1 -1
- package/node_modules/openai/src/resources/containers/files/index.ts +1 -1
- package/node_modules/openai/src/resources/containers/files.ts +1 -1
- package/node_modules/openai/src/resources/containers/index.ts +1 -1
- package/node_modules/openai/src/resources/containers.ts +1 -1
- package/node_modules/openai/src/resources/content-provenance-checks.ts +132 -0
- package/node_modules/openai/src/resources/conversations/conversations.ts +23 -2
- package/node_modules/openai/src/resources/conversations/index.ts +1 -1
- package/node_modules/openai/src/resources/conversations/items.ts +93 -5
- package/node_modules/openai/src/resources/conversations.ts +1 -1
- package/node_modules/openai/src/resources/embeddings.ts +22 -49
- package/node_modules/openai/src/resources/evals/evals.ts +6 -6
- package/node_modules/openai/src/resources/evals/index.ts +1 -1
- package/node_modules/openai/src/resources/evals/runs/index.ts +1 -1
- package/node_modules/openai/src/resources/evals/runs/output-items.ts +1 -1
- package/node_modules/openai/src/resources/evals/runs/runs.ts +119 -191
- package/node_modules/openai/src/resources/evals/runs.ts +1 -1
- package/node_modules/openai/src/resources/evals.ts +1 -1
- package/node_modules/openai/src/resources/files.ts +9 -26
- package/node_modules/openai/src/resources/fine-tuning/alpha/alpha.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/alpha/graders.ts +6 -5
- package/node_modules/openai/src/resources/fine-tuning/alpha/index.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/alpha.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/checkpoints/checkpoints.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/checkpoints/index.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/checkpoints/permissions.ts +9 -5
- package/node_modules/openai/src/resources/fine-tuning/checkpoints.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/fine-tuning.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/index.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/jobs/checkpoints.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/jobs/index.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/jobs/jobs.ts +14 -13
- package/node_modules/openai/src/resources/fine-tuning/jobs.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning/methods.ts +1 -1
- package/node_modules/openai/src/resources/fine-tuning.ts +1 -1
- package/node_modules/openai/src/resources/graders/grader-models.ts +7 -14
- package/node_modules/openai/src/resources/graders/graders.ts +1 -1
- package/node_modules/openai/src/resources/graders/index.ts +1 -1
- package/node_modules/openai/src/resources/graders.ts +1 -1
- package/node_modules/openai/src/resources/images.ts +100 -85
- package/node_modules/openai/src/resources/index.ts +9 -2
- package/node_modules/openai/src/resources/live/api.md +87 -0
- package/node_modules/openai/src/resources/live/forks/forks.ts +169 -0
- package/node_modules/openai/src/resources/live/forks/index.ts +5 -0
- package/node_modules/openai/src/resources/live/forks/internal-base.ts +126 -0
- package/node_modules/openai/src/resources/live/forks/ws-base.ts +700 -0
- package/node_modules/openai/src/resources/live/forks/ws.ts +47 -0
- package/node_modules/openai/src/resources/live/forks.ts +3 -0
- package/node_modules/openai/src/resources/live/index.ts +20 -0
- package/node_modules/openai/src/resources/live/internal-base.ts +123 -0
- package/node_modules/openai/src/resources/live/live.ts +2296 -0
- package/node_modules/openai/src/resources/live/sessions.ts +343 -0
- package/node_modules/openai/src/resources/live/sideband/index.ts +10 -0
- package/node_modules/openai/src/resources/live/sideband/internal-base.ts +126 -0
- package/node_modules/openai/src/resources/live/sideband/sideband.ts +58 -0
- package/node_modules/openai/src/resources/live/sideband/ws-base.ts +710 -0
- package/node_modules/openai/src/resources/live/sideband/ws.ts +47 -0
- package/node_modules/openai/src/resources/live/sideband.ts +3 -0
- package/node_modules/openai/src/resources/live/ws-base.ts +696 -0
- package/node_modules/openai/src/resources/live/ws.ts +43 -0
- package/node_modules/openai/src/resources/live.ts +3 -0
- package/node_modules/openai/src/resources/models.ts +6 -1
- package/node_modules/openai/src/resources/moderations.ts +6 -5
- package/node_modules/openai/src/resources/realtime/api.md +1 -0
- package/node_modules/openai/src/resources/realtime/calls.ts +50 -2
- package/node_modules/openai/src/resources/realtime/client-secrets.ts +27 -10
- package/node_modules/openai/src/resources/realtime/index.ts +8 -2
- package/node_modules/openai/src/resources/realtime/realtime.ts +93 -35
- package/node_modules/openai/src/resources/realtime.ts +1 -1
- package/node_modules/openai/src/resources/responses/api.md +20 -0
- package/node_modules/openai/src/resources/responses/index.ts +1 -1
- package/node_modules/openai/src/resources/responses/input-items.ts +1 -1
- package/node_modules/openai/src/resources/responses/input-tokens.ts +26 -16
- package/node_modules/openai/src/resources/responses/internal-base.ts +33 -14
- package/node_modules/openai/src/resources/responses/responses.ts +4150 -792
- package/node_modules/openai/src/resources/responses/ws-base.ts +147 -31
- package/node_modules/openai/src/resources/responses/ws.ts +33 -9
- package/node_modules/openai/src/resources/responses.ts +1 -1
- package/node_modules/openai/src/resources/safety/alerts.ts +51 -0
- package/node_modules/openai/src/resources/safety/index.ts +4 -0
- package/node_modules/openai/src/resources/safety/safety.ts +15 -0
- package/node_modules/openai/src/resources/safety.ts +3 -0
- package/node_modules/openai/src/resources/shared.ts +98 -41
- package/node_modules/openai/src/resources/skills/content.ts +1 -1
- package/node_modules/openai/src/resources/skills/index.ts +1 -1
- package/node_modules/openai/src/resources/skills/skills.ts +4 -2
- package/node_modules/openai/src/resources/skills/versions/content.ts +1 -1
- package/node_modules/openai/src/resources/skills/versions/index.ts +1 -1
- package/node_modules/openai/src/resources/skills/versions/versions.ts +4 -2
- package/node_modules/openai/src/resources/skills/versions.ts +1 -1
- package/node_modules/openai/src/resources/skills.ts +1 -1
- package/node_modules/openai/src/resources/uploads/index.ts +1 -1
- package/node_modules/openai/src/resources/uploads/parts.ts +6 -5
- package/node_modules/openai/src/resources/uploads/uploads.ts +12 -12
- package/node_modules/openai/src/resources/uploads.ts +1 -1
- package/node_modules/openai/src/resources/vector-stores/file-batches.ts +24 -89
- package/node_modules/openai/src/resources/vector-stores/files.ts +12 -52
- package/node_modules/openai/src/resources/vector-stores/index.ts +1 -1
- package/node_modules/openai/src/resources/vector-stores/vector-stores.ts +4 -4
- package/node_modules/openai/src/resources/vector-stores.ts +1 -1
- package/node_modules/openai/src/resources/videos.ts +63 -2
- package/node_modules/openai/src/resources/webhooks/api.md +40 -17
- package/node_modules/openai/src/resources/webhooks/event-types.ts +21 -0
- package/node_modules/openai/src/resources/webhooks/index.ts +2 -1
- package/node_modules/openai/src/resources/webhooks/webhooks.ts +694 -69
- package/node_modules/openai/src/resources/webhooks.ts +1 -1
- package/node_modules/openai/src/tsconfig.json +6 -3
- package/node_modules/openai/src/version.ts +2 -1
- package/node_modules/openai/version.js +2 -1
- package/node_modules/openai/version.mjs +2 -1
- package/package.json +6 -6
- package/node_modules/@earendil-works/pi-ai/dist/image-models.generated.js +0 -832
- package/node_modules/@earendil-works/pi-ai/dist/images-models.js +0 -143
- package/node_modules/@earendil-works/pi-ai/dist/providers/openrouter-images.js +0 -22
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/LICENSE +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/README.md +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-cjs/index.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/constants.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/fromEnvSigningName.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/fromSso.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/fromStatic.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/getNewSsoOidcToken.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/getSsoOidcClient.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/index.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/nodeProvider.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/validateTokenExpiry.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/validateTokenKey.js +0 -0
- /package/node_modules/@aws-sdk/{credential-provider-sso → client-bedrock-runtime}/node_modules/@aws-sdk/token-providers/dist-es/writeSSOTokenToFile.js +0 -0
- /package/node_modules/@earendil-works/pi-ai/dist/{auth/oauth → utils}/oauth-page.js +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// File generated from our OpenAPI spec by
|
|
1
|
+
// File generated from our OpenAPI spec by Castiron. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../../core/resource';
|
|
4
4
|
import * as ChatCompletionsAPI from './completions';
|
|
@@ -15,8 +15,15 @@ import { path } from '../../../internal/utils/path';
|
|
|
15
15
|
import { ChatCompletionRunner } from '../../../lib/ChatCompletionRunner';
|
|
16
16
|
import { ChatCompletionStreamingRunner } from '../../../lib/ChatCompletionStreamingRunner';
|
|
17
17
|
import { RunnerOptions } from '../../../lib/AbstractChatCompletionRunner';
|
|
18
|
-
import {
|
|
19
|
-
|
|
18
|
+
import {
|
|
19
|
+
ChatCompletionToolRunnerParamsWithContext,
|
|
20
|
+
ChatCompletionToolRunnerParamsWithoutContext,
|
|
21
|
+
} from '../../../lib/ChatCompletionRunner';
|
|
22
|
+
import {
|
|
23
|
+
ChatCompletionStreamingToolRunnerParamsWithContext,
|
|
24
|
+
ChatCompletionStreamingToolRunnerParamsWithoutContext,
|
|
25
|
+
} from '../../../lib/ChatCompletionStreamingRunner';
|
|
26
|
+
import { type RunnableToolFunctionWithContext } from '../../../lib/RunnableFunction';
|
|
20
27
|
import { ChatCompletionStream, type ChatCompletionStreamParams } from '../../../lib/ChatCompletionStream';
|
|
21
28
|
import { ExtractParsedContentFromParams, parseChatCompletion, validateInputTools } from '../../../lib/parser';
|
|
22
29
|
|
|
@@ -28,22 +35,22 @@ export class Completions extends APIResource {
|
|
|
28
35
|
|
|
29
36
|
/**
|
|
30
37
|
* **Starting a new project?** We recommend trying
|
|
31
|
-
* [Responses](https://
|
|
32
|
-
* advantage of the latest OpenAI platform features. Compare
|
|
33
|
-
* [Chat Completions with Responses](https://
|
|
38
|
+
* [Responses](https://developers.openai.com/api/reference/resources/responses) to
|
|
39
|
+
* take advantage of the latest OpenAI platform features. Compare
|
|
40
|
+
* [Chat Completions with Responses](https://developers.openai.com/api/docs/guides/migrate-to-responses?api-mode=responses).
|
|
34
41
|
*
|
|
35
42
|
* ---
|
|
36
43
|
*
|
|
37
44
|
* Creates a model response for the given chat conversation. Learn more in the
|
|
38
|
-
* [text generation](https://
|
|
39
|
-
* [vision](https://
|
|
40
|
-
* [audio](https://
|
|
45
|
+
* [text generation](https://developers.openai.com/api/docs/guides/text),
|
|
46
|
+
* [vision](https://developers.openai.com/api/docs/guides/images-vision), and
|
|
47
|
+
* [audio](https://developers.openai.com/api/docs/guides/audio) guides.
|
|
41
48
|
*
|
|
42
49
|
* Parameter support can differ depending on the model used to generate the
|
|
43
50
|
* response, particularly for newer reasoning models. Parameters that are only
|
|
44
51
|
* supported for reasoning models are noted below. For the current state of
|
|
45
52
|
* unsupported parameters in reasoning models,
|
|
46
|
-
* [refer to the reasoning guide](https://
|
|
53
|
+
* [refer to the reasoning guide](https://developers.openai.com/api/docs/guides/reasoning).
|
|
47
54
|
*
|
|
48
55
|
* Returns a chat completion object, or a streamed sequence of chat completion
|
|
49
56
|
* chunk objects if the request is streamed.
|
|
@@ -53,7 +60,7 @@ export class Completions extends APIResource {
|
|
|
53
60
|
* const chatCompletion = await client.chat.completions.create(
|
|
54
61
|
* {
|
|
55
62
|
* messages: [{ content: 'string', role: 'developer' }],
|
|
56
|
-
* model: 'gpt-
|
|
63
|
+
* model: 'gpt-6-astra',
|
|
57
64
|
* },
|
|
58
65
|
* );
|
|
59
66
|
* ```
|
|
@@ -170,10 +177,7 @@ export class Completions extends APIResource {
|
|
|
170
177
|
return this._client.chat.completions
|
|
171
178
|
.create(body, {
|
|
172
179
|
...options,
|
|
173
|
-
|
|
174
|
-
...options?.headers,
|
|
175
|
-
'X-Stainless-Helper-Method': 'chat.completions.parse',
|
|
176
|
-
},
|
|
180
|
+
__metadata: { ...options?.__metadata, helperMethod: 'chat.completions.parse' },
|
|
177
181
|
})
|
|
178
182
|
._thenUnwrap((completion) => parseChatCompletion(completion, body));
|
|
179
183
|
}
|
|
@@ -188,17 +192,55 @@ export class Completions extends APIResource {
|
|
|
188
192
|
* [the docs](https://github.com/openai/openai-node#automated-function-calls)
|
|
189
193
|
*/
|
|
190
194
|
runTools<
|
|
191
|
-
|
|
195
|
+
ToolContext,
|
|
196
|
+
Params extends Omit<
|
|
197
|
+
ChatCompletionToolRunnerParamsWithContext<any, ToolContext>,
|
|
198
|
+
'toolContext' | 'tools'
|
|
199
|
+
> = Omit<ChatCompletionToolRunnerParamsWithContext<any, ToolContext>, 'toolContext' | 'tools'>,
|
|
200
|
+
ParsedT = ExtractParsedContentFromParams<
|
|
201
|
+
Params & ChatCompletionToolRunnerParamsWithContext<any, ToolContext>
|
|
202
|
+
>,
|
|
203
|
+
>(
|
|
204
|
+
body: Params & {
|
|
205
|
+
toolContext: ToolContext;
|
|
206
|
+
tools: readonly RunnableToolFunctionWithContext<ToolContext>[];
|
|
207
|
+
},
|
|
208
|
+
options?: RunnerOptions,
|
|
209
|
+
): ChatCompletionRunner<ParsedT>;
|
|
210
|
+
|
|
211
|
+
runTools<
|
|
212
|
+
ToolContext,
|
|
213
|
+
Params extends Omit<
|
|
214
|
+
ChatCompletionStreamingToolRunnerParamsWithContext<any, ToolContext>,
|
|
215
|
+
'toolContext' | 'tools'
|
|
216
|
+
> = Omit<ChatCompletionStreamingToolRunnerParamsWithContext<any, ToolContext>, 'toolContext' | 'tools'>,
|
|
217
|
+
ParsedT = ExtractParsedContentFromParams<
|
|
218
|
+
Params & ChatCompletionStreamingToolRunnerParamsWithContext<any, ToolContext>
|
|
219
|
+
>,
|
|
220
|
+
>(
|
|
221
|
+
body: Params & {
|
|
222
|
+
toolContext: ToolContext;
|
|
223
|
+
tools: readonly RunnableToolFunctionWithContext<ToolContext>[];
|
|
224
|
+
},
|
|
225
|
+
options?: RunnerOptions,
|
|
226
|
+
): ChatCompletionStreamingRunner<ParsedT>;
|
|
227
|
+
|
|
228
|
+
runTools<
|
|
229
|
+
Params extends ChatCompletionToolRunnerParamsWithoutContext<any>,
|
|
192
230
|
ParsedT = ExtractParsedContentFromParams<Params>,
|
|
193
231
|
>(body: Params, options?: RunnerOptions): ChatCompletionRunner<ParsedT>;
|
|
194
232
|
|
|
195
233
|
runTools<
|
|
196
|
-
Params extends
|
|
234
|
+
Params extends ChatCompletionStreamingToolRunnerParamsWithoutContext<any>,
|
|
197
235
|
ParsedT = ExtractParsedContentFromParams<Params>,
|
|
198
236
|
>(body: Params, options?: RunnerOptions): ChatCompletionStreamingRunner<ParsedT>;
|
|
199
237
|
|
|
200
238
|
runTools<
|
|
201
|
-
Params extends
|
|
239
|
+
Params extends
|
|
240
|
+
| ChatCompletionToolRunnerParamsWithoutContext<any>
|
|
241
|
+
| ChatCompletionToolRunnerParamsWithContext<any, any>
|
|
242
|
+
| ChatCompletionStreamingToolRunnerParamsWithoutContext<any>
|
|
243
|
+
| ChatCompletionStreamingToolRunnerParamsWithContext<any, any>,
|
|
202
244
|
ParsedT = ExtractParsedContentFromParams<Params>,
|
|
203
245
|
>(
|
|
204
246
|
body: Params,
|
|
@@ -207,12 +249,16 @@ export class Completions extends APIResource {
|
|
|
207
249
|
if (body.stream) {
|
|
208
250
|
return ChatCompletionStreamingRunner.runTools(
|
|
209
251
|
this._client,
|
|
210
|
-
body as
|
|
252
|
+
body as ChatCompletionStreamingToolRunnerParamsWithContext<any, any>,
|
|
211
253
|
options,
|
|
212
254
|
);
|
|
213
255
|
}
|
|
214
256
|
|
|
215
|
-
return ChatCompletionRunner.runTools(
|
|
257
|
+
return ChatCompletionRunner.runTools(
|
|
258
|
+
this._client,
|
|
259
|
+
body as ChatCompletionToolRunnerParamsWithContext<any, any>,
|
|
260
|
+
options,
|
|
261
|
+
);
|
|
216
262
|
}
|
|
217
263
|
|
|
218
264
|
/**
|
|
@@ -234,9 +280,19 @@ export interface ParsedFunctionToolCall extends ChatCompletionMessageFunctionToo
|
|
|
234
280
|
function: ParsedFunction;
|
|
235
281
|
}
|
|
236
282
|
|
|
283
|
+
/**
|
|
284
|
+
* A tool call on a parsed chat completion message.
|
|
285
|
+
*
|
|
286
|
+
* Function tool calls are augmented with `function.parsed_arguments`, custom tool
|
|
287
|
+
* calls are returned as-is because they have no arguments schema to parse against.
|
|
288
|
+
*/
|
|
289
|
+
export type ParsedChatCompletionMessageToolCall =
|
|
290
|
+
| ParsedFunctionToolCall
|
|
291
|
+
| ChatCompletionMessageCustomToolCall;
|
|
292
|
+
|
|
237
293
|
export interface ParsedChatCompletionMessage<ParsedT> extends ChatCompletionMessage {
|
|
238
294
|
parsed: ParsedT | null;
|
|
239
|
-
tool_calls?: Array<
|
|
295
|
+
tool_calls?: Array<ParsedChatCompletionMessageToolCall>;
|
|
240
296
|
}
|
|
241
297
|
|
|
242
298
|
export interface ParsedChoice<ParsedT> extends ChatCompletion.Choice {
|
|
@@ -255,8 +311,16 @@ export {
|
|
|
255
311
|
type RunnableFunctionWithoutParse,
|
|
256
312
|
ParsingToolFunction,
|
|
257
313
|
} from '../../../lib/RunnableFunction';
|
|
258
|
-
export {
|
|
259
|
-
|
|
314
|
+
export {
|
|
315
|
+
type ChatCompletionToolRunnerParams,
|
|
316
|
+
type ChatCompletionToolRunnerParamsWithContext,
|
|
317
|
+
type ChatCompletionToolRunnerParamsWithoutContext,
|
|
318
|
+
} from '../../../lib/ChatCompletionRunner';
|
|
319
|
+
export {
|
|
320
|
+
type ChatCompletionStreamingToolRunnerParams,
|
|
321
|
+
type ChatCompletionStreamingToolRunnerParamsWithContext,
|
|
322
|
+
type ChatCompletionStreamingToolRunnerParamsWithoutContext,
|
|
323
|
+
} from '../../../lib/ChatCompletionStreamingRunner';
|
|
260
324
|
export { ChatCompletionStream, type ChatCompletionStreamParams } from '../../../lib/ChatCompletionStream';
|
|
261
325
|
export { ChatCompletionRunner } from '../../../lib/ChatCompletionRunner';
|
|
262
326
|
|
|
@@ -295,6 +359,22 @@ export interface ChatCompletion {
|
|
|
295
359
|
*/
|
|
296
360
|
object: 'chat.completion';
|
|
297
361
|
|
|
362
|
+
/**
|
|
363
|
+
* Set of 16 key-value pairs that can be attached to an object. This can be useful
|
|
364
|
+
* for storing additional information about the object in a structured format, and
|
|
365
|
+
* querying for objects via API or the dashboard.
|
|
366
|
+
*
|
|
367
|
+
* Keys are strings with a maximum length of 64 characters. Values are strings with
|
|
368
|
+
* a maximum length of 512 characters.
|
|
369
|
+
*/
|
|
370
|
+
metadata?: Shared.Metadata | null;
|
|
371
|
+
|
|
372
|
+
/**
|
|
373
|
+
* Moderation results for the request input and generated output, if moderated
|
|
374
|
+
* completions were requested.
|
|
375
|
+
*/
|
|
376
|
+
moderation?: ChatCompletion.Moderation | null;
|
|
377
|
+
|
|
298
378
|
/**
|
|
299
379
|
* Specifies the processing type used for serving the request.
|
|
300
380
|
*
|
|
@@ -303,9 +383,15 @@ export interface ChatCompletion {
|
|
|
303
383
|
* will use 'default'.
|
|
304
384
|
* - If set to 'default', then the request will be processed with the standard
|
|
305
385
|
* pricing and performance for the selected model.
|
|
306
|
-
* - If set to
|
|
307
|
-
* '[
|
|
308
|
-
* will be processed with the
|
|
386
|
+
* - If set to
|
|
387
|
+
* '[flex](https://developers.openai.com/api/docs/guides/flex-processing)', then
|
|
388
|
+
* the request will be processed with the Flex Processing service tier.
|
|
389
|
+
* - To opt-in to
|
|
390
|
+
* [Fast mode](https://developers.openai.com/api/docs/guides/fast-mode) at the
|
|
391
|
+
* request level, include the `service_tier=fast` or `service_tier=priority`
|
|
392
|
+
* parameter for Responses or Chat Completions. The response will show
|
|
393
|
+
* `service_tier=priority` regardless of if you specify `service_tier=fast` or
|
|
394
|
+
* `priority` in your request.
|
|
309
395
|
* - When not set, the default behavior is 'auto'.
|
|
310
396
|
*
|
|
311
397
|
* When the `service_tier` parameter is set, the response body will include the
|
|
@@ -313,7 +399,7 @@ export interface ChatCompletion {
|
|
|
313
399
|
* request. This response value may be different from the value set in the
|
|
314
400
|
* parameter.
|
|
315
401
|
*/
|
|
316
|
-
service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
|
|
402
|
+
service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | 'fast' | null;
|
|
317
403
|
|
|
318
404
|
/**
|
|
319
405
|
* @deprecated This fingerprint represents the backend configuration that the model
|
|
@@ -338,7 +424,8 @@ export namespace ChatCompletion {
|
|
|
338
424
|
* number of tokens specified in the request was reached, `content_filter` if
|
|
339
425
|
* content was omitted due to a flag from our content filters, `tool_calls` if the
|
|
340
426
|
* model called a tool, or `function_call` (deprecated) if the model called a
|
|
341
|
-
* function.
|
|
427
|
+
* function. Read the [Model Spec](https://model-spec.openai.com/2025-12-18.html)
|
|
428
|
+
* for more.
|
|
342
429
|
*/
|
|
343
430
|
finish_reason: 'stop' | 'length' | 'tool_calls' | 'content_filter' | 'function_call';
|
|
344
431
|
|
|
@@ -374,6 +461,182 @@ export namespace ChatCompletion {
|
|
|
374
461
|
refusal: Array<ChatCompletionsAPI.ChatCompletionTokenLogprob> | null;
|
|
375
462
|
}
|
|
376
463
|
}
|
|
464
|
+
|
|
465
|
+
/**
|
|
466
|
+
* Moderation results for the request input and generated output, if moderated
|
|
467
|
+
* completions were requested.
|
|
468
|
+
*/
|
|
469
|
+
export interface Moderation {
|
|
470
|
+
/**
|
|
471
|
+
* Moderation for the request input.
|
|
472
|
+
*/
|
|
473
|
+
input: Moderation.ModerationResults | Moderation.Error;
|
|
474
|
+
|
|
475
|
+
/**
|
|
476
|
+
* Moderation for the generated output.
|
|
477
|
+
*/
|
|
478
|
+
output: Moderation.ModerationResults | Moderation.Error;
|
|
479
|
+
}
|
|
480
|
+
|
|
481
|
+
export namespace Moderation {
|
|
482
|
+
/**
|
|
483
|
+
* Successful moderation results for the request input or generated output.
|
|
484
|
+
*/
|
|
485
|
+
export interface ModerationResults {
|
|
486
|
+
/**
|
|
487
|
+
* The moderation model used to generate the results.
|
|
488
|
+
*/
|
|
489
|
+
model: string;
|
|
490
|
+
|
|
491
|
+
/**
|
|
492
|
+
* A list of moderation results.
|
|
493
|
+
*/
|
|
494
|
+
results: Array<ModerationResults.Result>;
|
|
495
|
+
|
|
496
|
+
/**
|
|
497
|
+
* The object type, which is always `moderation_results`.
|
|
498
|
+
*/
|
|
499
|
+
type: 'moderation_results';
|
|
500
|
+
}
|
|
501
|
+
|
|
502
|
+
export namespace ModerationResults {
|
|
503
|
+
/**
|
|
504
|
+
* A moderation result produced for the response input or output.
|
|
505
|
+
*/
|
|
506
|
+
export interface Result {
|
|
507
|
+
/**
|
|
508
|
+
* A dictionary of moderation categories to booleans, True if the input is flagged
|
|
509
|
+
* under this category.
|
|
510
|
+
*/
|
|
511
|
+
categories: { [key: string]: boolean };
|
|
512
|
+
|
|
513
|
+
/**
|
|
514
|
+
* Which modalities of input are reflected by the score for each category.
|
|
515
|
+
*/
|
|
516
|
+
category_applied_input_types: { [key: string]: Array<'text' | 'image'> };
|
|
517
|
+
|
|
518
|
+
/**
|
|
519
|
+
* A dictionary of moderation categories to scores.
|
|
520
|
+
*/
|
|
521
|
+
category_scores: { [key: string]: number };
|
|
522
|
+
|
|
523
|
+
/**
|
|
524
|
+
* A boolean indicating whether the content was flagged by any category.
|
|
525
|
+
*/
|
|
526
|
+
flagged: boolean;
|
|
527
|
+
|
|
528
|
+
/**
|
|
529
|
+
* The moderation model that produced this result.
|
|
530
|
+
*/
|
|
531
|
+
model: string;
|
|
532
|
+
|
|
533
|
+
/**
|
|
534
|
+
* The object type, which was always `moderation_result` for successful moderation
|
|
535
|
+
* results.
|
|
536
|
+
*/
|
|
537
|
+
type: 'moderation_result';
|
|
538
|
+
}
|
|
539
|
+
}
|
|
540
|
+
|
|
541
|
+
/**
|
|
542
|
+
* An error produced while attempting moderation.
|
|
543
|
+
*/
|
|
544
|
+
export interface Error {
|
|
545
|
+
/**
|
|
546
|
+
* The error code.
|
|
547
|
+
*/
|
|
548
|
+
code: string;
|
|
549
|
+
|
|
550
|
+
/**
|
|
551
|
+
* The error message.
|
|
552
|
+
*/
|
|
553
|
+
message: string;
|
|
554
|
+
|
|
555
|
+
/**
|
|
556
|
+
* The object type, which is always `error`.
|
|
557
|
+
*/
|
|
558
|
+
type: 'error';
|
|
559
|
+
}
|
|
560
|
+
|
|
561
|
+
/**
|
|
562
|
+
* Successful moderation results for the request input or generated output.
|
|
563
|
+
*/
|
|
564
|
+
export interface ModerationResults {
|
|
565
|
+
/**
|
|
566
|
+
* The moderation model used to generate the results.
|
|
567
|
+
*/
|
|
568
|
+
model: string;
|
|
569
|
+
|
|
570
|
+
/**
|
|
571
|
+
* A list of moderation results.
|
|
572
|
+
*/
|
|
573
|
+
results: Array<ModerationResults.Result>;
|
|
574
|
+
|
|
575
|
+
/**
|
|
576
|
+
* The object type, which is always `moderation_results`.
|
|
577
|
+
*/
|
|
578
|
+
type: 'moderation_results';
|
|
579
|
+
}
|
|
580
|
+
|
|
581
|
+
export namespace ModerationResults {
|
|
582
|
+
/**
|
|
583
|
+
* A moderation result produced for the response input or output.
|
|
584
|
+
*/
|
|
585
|
+
export interface Result {
|
|
586
|
+
/**
|
|
587
|
+
* A dictionary of moderation categories to booleans, True if the input is flagged
|
|
588
|
+
* under this category.
|
|
589
|
+
*/
|
|
590
|
+
categories: { [key: string]: boolean };
|
|
591
|
+
|
|
592
|
+
/**
|
|
593
|
+
* Which modalities of input are reflected by the score for each category.
|
|
594
|
+
*/
|
|
595
|
+
category_applied_input_types: { [key: string]: Array<'text' | 'image'> };
|
|
596
|
+
|
|
597
|
+
/**
|
|
598
|
+
* A dictionary of moderation categories to scores.
|
|
599
|
+
*/
|
|
600
|
+
category_scores: { [key: string]: number };
|
|
601
|
+
|
|
602
|
+
/**
|
|
603
|
+
* A boolean indicating whether the content was flagged by any category.
|
|
604
|
+
*/
|
|
605
|
+
flagged: boolean;
|
|
606
|
+
|
|
607
|
+
/**
|
|
608
|
+
* The moderation model that produced this result.
|
|
609
|
+
*/
|
|
610
|
+
model: string;
|
|
611
|
+
|
|
612
|
+
/**
|
|
613
|
+
* The object type, which was always `moderation_result` for successful moderation
|
|
614
|
+
* results.
|
|
615
|
+
*/
|
|
616
|
+
type: 'moderation_result';
|
|
617
|
+
}
|
|
618
|
+
}
|
|
619
|
+
|
|
620
|
+
/**
|
|
621
|
+
* An error produced while attempting moderation.
|
|
622
|
+
*/
|
|
623
|
+
export interface Error {
|
|
624
|
+
/**
|
|
625
|
+
* The error code.
|
|
626
|
+
*/
|
|
627
|
+
code: string;
|
|
628
|
+
|
|
629
|
+
/**
|
|
630
|
+
* The error message.
|
|
631
|
+
*/
|
|
632
|
+
message: string;
|
|
633
|
+
|
|
634
|
+
/**
|
|
635
|
+
* The object type, which is always `error`.
|
|
636
|
+
*/
|
|
637
|
+
type: 'error';
|
|
638
|
+
}
|
|
639
|
+
}
|
|
377
640
|
}
|
|
378
641
|
|
|
379
642
|
/**
|
|
@@ -402,7 +665,7 @@ export interface ChatCompletionAssistantMessageParam {
|
|
|
402
665
|
|
|
403
666
|
/**
|
|
404
667
|
* Data about a previous audio response from the model.
|
|
405
|
-
* [Learn more](https://
|
|
668
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/audio).
|
|
406
669
|
*/
|
|
407
670
|
audio?: ChatCompletionAssistantMessageParam.Audio | null;
|
|
408
671
|
|
|
@@ -438,7 +701,7 @@ export interface ChatCompletionAssistantMessageParam {
|
|
|
438
701
|
export namespace ChatCompletionAssistantMessageParam {
|
|
439
702
|
/**
|
|
440
703
|
* Data about a previous audio response from the model.
|
|
441
|
-
* [Learn more](https://
|
|
704
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/audio).
|
|
442
705
|
*/
|
|
443
706
|
export interface Audio {
|
|
444
707
|
/**
|
|
@@ -470,7 +733,7 @@ export namespace ChatCompletionAssistantMessageParam {
|
|
|
470
733
|
/**
|
|
471
734
|
* If the audio output modality is requested, this object contains data about the
|
|
472
735
|
* audio response from the model.
|
|
473
|
-
* [Learn more](https://
|
|
736
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/audio).
|
|
474
737
|
*/
|
|
475
738
|
export interface ChatCompletionAudio {
|
|
476
739
|
/**
|
|
@@ -499,7 +762,7 @@ export interface ChatCompletionAudio {
|
|
|
499
762
|
/**
|
|
500
763
|
* Parameters for audio output. Required when audio output is requested with
|
|
501
764
|
* `modalities: ["audio"]`.
|
|
502
|
-
* [Learn more](https://
|
|
765
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/audio).
|
|
503
766
|
*/
|
|
504
767
|
export interface ChatCompletionAudioParam {
|
|
505
768
|
/**
|
|
@@ -544,7 +807,7 @@ export namespace ChatCompletionAudioParam {
|
|
|
544
807
|
/**
|
|
545
808
|
* Represents a streamed chunk of a chat completion response returned by the model,
|
|
546
809
|
* based on the provided input.
|
|
547
|
-
* [Learn more](https://
|
|
810
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/streaming-responses).
|
|
548
811
|
*/
|
|
549
812
|
export interface ChatCompletionChunk {
|
|
550
813
|
/**
|
|
@@ -575,6 +838,19 @@ export interface ChatCompletionChunk {
|
|
|
575
838
|
*/
|
|
576
839
|
object: 'chat.completion.chunk';
|
|
577
840
|
|
|
841
|
+
/**
|
|
842
|
+
* Moderation results for the request input and generated output. Present on the
|
|
843
|
+
* moderation chunk when moderated completions are requested.
|
|
844
|
+
*/
|
|
845
|
+
moderation?: ChatCompletionChunk.Moderation | null;
|
|
846
|
+
|
|
847
|
+
/**
|
|
848
|
+
* An obfuscation string added to normalize the size of streamed chunks as a
|
|
849
|
+
* mitigation to certain side-channel attacks. The field is included by default and
|
|
850
|
+
* omitted when `stream_options.include_obfuscation` is `false`.
|
|
851
|
+
*/
|
|
852
|
+
obfuscation?: string;
|
|
853
|
+
|
|
578
854
|
/**
|
|
579
855
|
* Specifies the processing type used for serving the request.
|
|
580
856
|
*
|
|
@@ -583,9 +859,15 @@ export interface ChatCompletionChunk {
|
|
|
583
859
|
* will use 'default'.
|
|
584
860
|
* - If set to 'default', then the request will be processed with the standard
|
|
585
861
|
* pricing and performance for the selected model.
|
|
586
|
-
* - If set to
|
|
587
|
-
* '[
|
|
588
|
-
* will be processed with the
|
|
862
|
+
* - If set to
|
|
863
|
+
* '[flex](https://developers.openai.com/api/docs/guides/flex-processing)', then
|
|
864
|
+
* the request will be processed with the Flex Processing service tier.
|
|
865
|
+
* - To opt-in to
|
|
866
|
+
* [Fast mode](https://developers.openai.com/api/docs/guides/fast-mode) at the
|
|
867
|
+
* request level, include the `service_tier=fast` or `service_tier=priority`
|
|
868
|
+
* parameter for Responses or Chat Completions. The response will show
|
|
869
|
+
* `service_tier=priority` regardless of if you specify `service_tier=fast` or
|
|
870
|
+
* `priority` in your request.
|
|
589
871
|
* - When not set, the default behavior is 'auto'.
|
|
590
872
|
*
|
|
591
873
|
* When the `service_tier` parameter is set, the response body will include the
|
|
@@ -593,7 +875,7 @@ export interface ChatCompletionChunk {
|
|
|
593
875
|
* request. This response value may be different from the value set in the
|
|
594
876
|
* parameter.
|
|
595
877
|
*/
|
|
596
|
-
service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
|
|
878
|
+
service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | 'fast' | null;
|
|
597
879
|
|
|
598
880
|
/**
|
|
599
881
|
* @deprecated This fingerprint represents the backend configuration that the model
|
|
@@ -699,15 +981,29 @@ export namespace ChatCompletionChunk {
|
|
|
699
981
|
*/
|
|
700
982
|
id?: string;
|
|
701
983
|
|
|
984
|
+
custom?: ToolCall.Custom;
|
|
985
|
+
|
|
702
986
|
function?: ToolCall.Function;
|
|
703
987
|
|
|
704
988
|
/**
|
|
705
|
-
* The type of the tool.
|
|
989
|
+
* The type of the tool.
|
|
706
990
|
*/
|
|
707
|
-
type?: 'function';
|
|
991
|
+
type?: 'function' | 'custom';
|
|
708
992
|
}
|
|
709
993
|
|
|
710
994
|
export namespace ToolCall {
|
|
995
|
+
export interface Custom {
|
|
996
|
+
/**
|
|
997
|
+
* The input for the custom tool call generated by the model.
|
|
998
|
+
*/
|
|
999
|
+
input?: string;
|
|
1000
|
+
|
|
1001
|
+
/**
|
|
1002
|
+
* The name of the custom tool to call.
|
|
1003
|
+
*/
|
|
1004
|
+
name?: string;
|
|
1005
|
+
}
|
|
1006
|
+
|
|
711
1007
|
export interface Function {
|
|
712
1008
|
/**
|
|
713
1009
|
* The arguments to call the function with, as generated by the model in JSON
|
|
@@ -740,11 +1036,186 @@ export namespace ChatCompletionChunk {
|
|
|
740
1036
|
refusal: Array<ChatCompletionsAPI.ChatCompletionTokenLogprob> | null;
|
|
741
1037
|
}
|
|
742
1038
|
}
|
|
1039
|
+
|
|
1040
|
+
/**
|
|
1041
|
+
* Moderation results for the request input and generated output. Present on the
|
|
1042
|
+
* moderation chunk when moderated completions are requested.
|
|
1043
|
+
*/
|
|
1044
|
+
export interface Moderation {
|
|
1045
|
+
/**
|
|
1046
|
+
* Moderation for the request input.
|
|
1047
|
+
*/
|
|
1048
|
+
input: Moderation.ModerationResults | Moderation.Error;
|
|
1049
|
+
|
|
1050
|
+
/**
|
|
1051
|
+
* Moderation for the generated output.
|
|
1052
|
+
*/
|
|
1053
|
+
output: Moderation.ModerationResults | Moderation.Error;
|
|
1054
|
+
}
|
|
1055
|
+
|
|
1056
|
+
export namespace Moderation {
|
|
1057
|
+
/**
|
|
1058
|
+
* Successful moderation results for the request input or generated output.
|
|
1059
|
+
*/
|
|
1060
|
+
export interface ModerationResults {
|
|
1061
|
+
/**
|
|
1062
|
+
* The moderation model used to generate the results.
|
|
1063
|
+
*/
|
|
1064
|
+
model: string;
|
|
1065
|
+
|
|
1066
|
+
/**
|
|
1067
|
+
* A list of moderation results.
|
|
1068
|
+
*/
|
|
1069
|
+
results: Array<ModerationResults.Result>;
|
|
1070
|
+
|
|
1071
|
+
/**
|
|
1072
|
+
* The object type, which is always `moderation_results`.
|
|
1073
|
+
*/
|
|
1074
|
+
type: 'moderation_results';
|
|
1075
|
+
}
|
|
1076
|
+
|
|
1077
|
+
export namespace ModerationResults {
|
|
1078
|
+
/**
|
|
1079
|
+
* A moderation result produced for the response input or output.
|
|
1080
|
+
*/
|
|
1081
|
+
export interface Result {
|
|
1082
|
+
/**
|
|
1083
|
+
* A dictionary of moderation categories to booleans, True if the input is flagged
|
|
1084
|
+
* under this category.
|
|
1085
|
+
*/
|
|
1086
|
+
categories: { [key: string]: boolean };
|
|
1087
|
+
|
|
1088
|
+
/**
|
|
1089
|
+
* Which modalities of input are reflected by the score for each category.
|
|
1090
|
+
*/
|
|
1091
|
+
category_applied_input_types: { [key: string]: Array<'text' | 'image'> };
|
|
1092
|
+
|
|
1093
|
+
/**
|
|
1094
|
+
* A dictionary of moderation categories to scores.
|
|
1095
|
+
*/
|
|
1096
|
+
category_scores: { [key: string]: number };
|
|
1097
|
+
|
|
1098
|
+
/**
|
|
1099
|
+
* A boolean indicating whether the content was flagged by any category.
|
|
1100
|
+
*/
|
|
1101
|
+
flagged: boolean;
|
|
1102
|
+
|
|
1103
|
+
/**
|
|
1104
|
+
* The moderation model that produced this result.
|
|
1105
|
+
*/
|
|
1106
|
+
model: string;
|
|
1107
|
+
|
|
1108
|
+
/**
|
|
1109
|
+
* The object type, which was always `moderation_result` for successful moderation
|
|
1110
|
+
* results.
|
|
1111
|
+
*/
|
|
1112
|
+
type: 'moderation_result';
|
|
1113
|
+
}
|
|
1114
|
+
}
|
|
1115
|
+
|
|
1116
|
+
/**
|
|
1117
|
+
* An error produced while attempting moderation.
|
|
1118
|
+
*/
|
|
1119
|
+
export interface Error {
|
|
1120
|
+
/**
|
|
1121
|
+
* The error code.
|
|
1122
|
+
*/
|
|
1123
|
+
code: string;
|
|
1124
|
+
|
|
1125
|
+
/**
|
|
1126
|
+
* The error message.
|
|
1127
|
+
*/
|
|
1128
|
+
message: string;
|
|
1129
|
+
|
|
1130
|
+
/**
|
|
1131
|
+
* The object type, which is always `error`.
|
|
1132
|
+
*/
|
|
1133
|
+
type: 'error';
|
|
1134
|
+
}
|
|
1135
|
+
|
|
1136
|
+
/**
|
|
1137
|
+
* Successful moderation results for the request input or generated output.
|
|
1138
|
+
*/
|
|
1139
|
+
export interface ModerationResults {
|
|
1140
|
+
/**
|
|
1141
|
+
* The moderation model used to generate the results.
|
|
1142
|
+
*/
|
|
1143
|
+
model: string;
|
|
1144
|
+
|
|
1145
|
+
/**
|
|
1146
|
+
* A list of moderation results.
|
|
1147
|
+
*/
|
|
1148
|
+
results: Array<ModerationResults.Result>;
|
|
1149
|
+
|
|
1150
|
+
/**
|
|
1151
|
+
* The object type, which is always `moderation_results`.
|
|
1152
|
+
*/
|
|
1153
|
+
type: 'moderation_results';
|
|
1154
|
+
}
|
|
1155
|
+
|
|
1156
|
+
export namespace ModerationResults {
|
|
1157
|
+
/**
|
|
1158
|
+
* A moderation result produced for the response input or output.
|
|
1159
|
+
*/
|
|
1160
|
+
export interface Result {
|
|
1161
|
+
/**
|
|
1162
|
+
* A dictionary of moderation categories to booleans, True if the input is flagged
|
|
1163
|
+
* under this category.
|
|
1164
|
+
*/
|
|
1165
|
+
categories: { [key: string]: boolean };
|
|
1166
|
+
|
|
1167
|
+
/**
|
|
1168
|
+
* Which modalities of input are reflected by the score for each category.
|
|
1169
|
+
*/
|
|
1170
|
+
category_applied_input_types: { [key: string]: Array<'text' | 'image'> };
|
|
1171
|
+
|
|
1172
|
+
/**
|
|
1173
|
+
* A dictionary of moderation categories to scores.
|
|
1174
|
+
*/
|
|
1175
|
+
category_scores: { [key: string]: number };
|
|
1176
|
+
|
|
1177
|
+
/**
|
|
1178
|
+
* A boolean indicating whether the content was flagged by any category.
|
|
1179
|
+
*/
|
|
1180
|
+
flagged: boolean;
|
|
1181
|
+
|
|
1182
|
+
/**
|
|
1183
|
+
* The moderation model that produced this result.
|
|
1184
|
+
*/
|
|
1185
|
+
model: string;
|
|
1186
|
+
|
|
1187
|
+
/**
|
|
1188
|
+
* The object type, which was always `moderation_result` for successful moderation
|
|
1189
|
+
* results.
|
|
1190
|
+
*/
|
|
1191
|
+
type: 'moderation_result';
|
|
1192
|
+
}
|
|
1193
|
+
}
|
|
1194
|
+
|
|
1195
|
+
/**
|
|
1196
|
+
* An error produced while attempting moderation.
|
|
1197
|
+
*/
|
|
1198
|
+
export interface Error {
|
|
1199
|
+
/**
|
|
1200
|
+
* The error code.
|
|
1201
|
+
*/
|
|
1202
|
+
code: string;
|
|
1203
|
+
|
|
1204
|
+
/**
|
|
1205
|
+
* The error message.
|
|
1206
|
+
*/
|
|
1207
|
+
message: string;
|
|
1208
|
+
|
|
1209
|
+
/**
|
|
1210
|
+
* The object type, which is always `error`.
|
|
1211
|
+
*/
|
|
1212
|
+
type: 'error';
|
|
1213
|
+
}
|
|
1214
|
+
}
|
|
743
1215
|
}
|
|
744
1216
|
|
|
745
1217
|
/**
|
|
746
|
-
* Learn about
|
|
747
|
-
* [text inputs](https://platform.openai.com/docs/guides/text-generation).
|
|
1218
|
+
* Learn about [text inputs](https://developers.openai.com/api/docs/guides/text).
|
|
748
1219
|
*/
|
|
749
1220
|
export type ChatCompletionContentPart =
|
|
750
1221
|
| ChatCompletionContentPartText
|
|
@@ -754,8 +1225,8 @@ export type ChatCompletionContentPart =
|
|
|
754
1225
|
|
|
755
1226
|
export namespace ChatCompletionContentPart {
|
|
756
1227
|
/**
|
|
757
|
-
* Learn about [file inputs](https://
|
|
758
|
-
* generation.
|
|
1228
|
+
* Learn about [file inputs](https://developers.openai.com/api/docs/guides/text)
|
|
1229
|
+
* for text generation.
|
|
759
1230
|
*/
|
|
760
1231
|
export interface File {
|
|
761
1232
|
file: File.File;
|
|
@@ -764,6 +1235,13 @@ export namespace ChatCompletionContentPart {
|
|
|
764
1235
|
* The type of the content part. Always `file`.
|
|
765
1236
|
*/
|
|
766
1237
|
type: 'file';
|
|
1238
|
+
|
|
1239
|
+
/**
|
|
1240
|
+
* Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
1241
|
+
* from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
1242
|
+
* token block.
|
|
1243
|
+
*/
|
|
1244
|
+
prompt_cache_breakpoint?: File.PromptCacheBreakpoint;
|
|
767
1245
|
}
|
|
768
1246
|
|
|
769
1247
|
export namespace File {
|
|
@@ -784,11 +1262,24 @@ export namespace ChatCompletionContentPart {
|
|
|
784
1262
|
*/
|
|
785
1263
|
filename?: string;
|
|
786
1264
|
}
|
|
1265
|
+
|
|
1266
|
+
/**
|
|
1267
|
+
* Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
1268
|
+
* from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
1269
|
+
* token block.
|
|
1270
|
+
*/
|
|
1271
|
+
export interface PromptCacheBreakpoint {
|
|
1272
|
+
/**
|
|
1273
|
+
* The breakpoint mode. Always `explicit`.
|
|
1274
|
+
*/
|
|
1275
|
+
mode: 'explicit';
|
|
1276
|
+
}
|
|
787
1277
|
}
|
|
788
1278
|
}
|
|
789
1279
|
|
|
790
1280
|
/**
|
|
791
|
-
* Learn about
|
|
1281
|
+
* Learn about
|
|
1282
|
+
* [image inputs](https://developers.openai.com/api/docs/guides/images-vision).
|
|
792
1283
|
*/
|
|
793
1284
|
export interface ChatCompletionContentPartImage {
|
|
794
1285
|
image_url: ChatCompletionContentPartImage.ImageURL;
|
|
@@ -797,6 +1288,13 @@ export interface ChatCompletionContentPartImage {
|
|
|
797
1288
|
* The type of the content part.
|
|
798
1289
|
*/
|
|
799
1290
|
type: 'image_url';
|
|
1291
|
+
|
|
1292
|
+
/**
|
|
1293
|
+
* Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
1294
|
+
* from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
1295
|
+
* token block.
|
|
1296
|
+
*/
|
|
1297
|
+
prompt_cache_breakpoint?: ChatCompletionContentPartImage.PromptCacheBreakpoint;
|
|
800
1298
|
}
|
|
801
1299
|
|
|
802
1300
|
export namespace ChatCompletionContentPartImage {
|
|
@@ -808,14 +1306,26 @@ export namespace ChatCompletionContentPartImage {
|
|
|
808
1306
|
|
|
809
1307
|
/**
|
|
810
1308
|
* Specifies the detail level of the image. Learn more in the
|
|
811
|
-
* [Vision guide](https://
|
|
1309
|
+
* [Vision guide](https://developers.openai.com/api/docs/guides/images-vision#choose-an-image-detail-level).
|
|
812
1310
|
*/
|
|
813
1311
|
detail?: 'auto' | 'low' | 'high';
|
|
814
1312
|
}
|
|
1313
|
+
|
|
1314
|
+
/**
|
|
1315
|
+
* Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
1316
|
+
* from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
1317
|
+
* token block.
|
|
1318
|
+
*/
|
|
1319
|
+
export interface PromptCacheBreakpoint {
|
|
1320
|
+
/**
|
|
1321
|
+
* The breakpoint mode. Always `explicit`.
|
|
1322
|
+
*/
|
|
1323
|
+
mode: 'explicit';
|
|
1324
|
+
}
|
|
815
1325
|
}
|
|
816
1326
|
|
|
817
1327
|
/**
|
|
818
|
-
* Learn about [audio inputs](https://
|
|
1328
|
+
* Learn about [audio inputs](https://developers.openai.com/api/docs/guides/audio).
|
|
819
1329
|
*/
|
|
820
1330
|
export interface ChatCompletionContentPartInputAudio {
|
|
821
1331
|
input_audio: ChatCompletionContentPartInputAudio.InputAudio;
|
|
@@ -824,6 +1334,13 @@ export interface ChatCompletionContentPartInputAudio {
|
|
|
824
1334
|
* The type of the content part. Always `input_audio`.
|
|
825
1335
|
*/
|
|
826
1336
|
type: 'input_audio';
|
|
1337
|
+
|
|
1338
|
+
/**
|
|
1339
|
+
* Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
1340
|
+
* from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
1341
|
+
* token block.
|
|
1342
|
+
*/
|
|
1343
|
+
prompt_cache_breakpoint?: ChatCompletionContentPartInputAudio.PromptCacheBreakpoint;
|
|
827
1344
|
}
|
|
828
1345
|
|
|
829
1346
|
export namespace ChatCompletionContentPartInputAudio {
|
|
@@ -838,6 +1355,18 @@ export namespace ChatCompletionContentPartInputAudio {
|
|
|
838
1355
|
*/
|
|
839
1356
|
format: 'wav' | 'mp3';
|
|
840
1357
|
}
|
|
1358
|
+
|
|
1359
|
+
/**
|
|
1360
|
+
* Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
1361
|
+
* from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
1362
|
+
* token block.
|
|
1363
|
+
*/
|
|
1364
|
+
export interface PromptCacheBreakpoint {
|
|
1365
|
+
/**
|
|
1366
|
+
* The breakpoint mode. Always `explicit`.
|
|
1367
|
+
*/
|
|
1368
|
+
mode: 'explicit';
|
|
1369
|
+
}
|
|
841
1370
|
}
|
|
842
1371
|
|
|
843
1372
|
export interface ChatCompletionContentPartRefusal {
|
|
@@ -853,8 +1382,7 @@ export interface ChatCompletionContentPartRefusal {
|
|
|
853
1382
|
}
|
|
854
1383
|
|
|
855
1384
|
/**
|
|
856
|
-
* Learn about
|
|
857
|
-
* [text inputs](https://platform.openai.com/docs/guides/text-generation).
|
|
1385
|
+
* Learn about [text inputs](https://developers.openai.com/api/docs/guides/text).
|
|
858
1386
|
*/
|
|
859
1387
|
export interface ChatCompletionContentPartText {
|
|
860
1388
|
/**
|
|
@@ -866,6 +1394,27 @@ export interface ChatCompletionContentPartText {
|
|
|
866
1394
|
* The type of the content part.
|
|
867
1395
|
*/
|
|
868
1396
|
type: 'text';
|
|
1397
|
+
|
|
1398
|
+
/**
|
|
1399
|
+
* Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
1400
|
+
* from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
1401
|
+
* token block.
|
|
1402
|
+
*/
|
|
1403
|
+
prompt_cache_breakpoint?: ChatCompletionContentPartText.PromptCacheBreakpoint;
|
|
1404
|
+
}
|
|
1405
|
+
|
|
1406
|
+
export namespace ChatCompletionContentPartText {
|
|
1407
|
+
/**
|
|
1408
|
+
* Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
1409
|
+
* from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
1410
|
+
* token block.
|
|
1411
|
+
*/
|
|
1412
|
+
export interface PromptCacheBreakpoint {
|
|
1413
|
+
/**
|
|
1414
|
+
* The breakpoint mode. Always `explicit`.
|
|
1415
|
+
*/
|
|
1416
|
+
mode: 'explicit';
|
|
1417
|
+
}
|
|
869
1418
|
}
|
|
870
1419
|
|
|
871
1420
|
/**
|
|
@@ -1053,14 +1602,14 @@ export interface ChatCompletionMessage {
|
|
|
1053
1602
|
|
|
1054
1603
|
/**
|
|
1055
1604
|
* Annotations for the message, when applicable, as when using the
|
|
1056
|
-
* [web search tool](https://
|
|
1605
|
+
* [web search tool](https://developers.openai.com/api/docs/guides/tools-web-search).
|
|
1057
1606
|
*/
|
|
1058
1607
|
annotations?: Array<ChatCompletionMessage.Annotation>;
|
|
1059
1608
|
|
|
1060
1609
|
/**
|
|
1061
1610
|
* If the audio output modality is requested, this object contains data about the
|
|
1062
1611
|
* audio response from the model.
|
|
1063
|
-
* [Learn more](https://
|
|
1612
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/audio).
|
|
1064
1613
|
*/
|
|
1065
1614
|
audio?: ChatCompletionAudio | null;
|
|
1066
1615
|
|
|
@@ -1524,27 +2073,27 @@ export type ChatCompletionCreateParams =
|
|
|
1524
2073
|
export interface ChatCompletionCreateParamsBase {
|
|
1525
2074
|
/**
|
|
1526
2075
|
* A list of messages comprising the conversation so far. Depending on the
|
|
1527
|
-
* [model](https://
|
|
1528
|
-
* types (modalities) are supported, like
|
|
1529
|
-
* [text](https://
|
|
1530
|
-
* [images](https://
|
|
1531
|
-
* [audio](https://
|
|
2076
|
+
* [model](https://developers.openai.com/api/docs/models) you use, different
|
|
2077
|
+
* message types (modalities) are supported, like
|
|
2078
|
+
* [text](https://developers.openai.com/api/docs/guides/text),
|
|
2079
|
+
* [images](https://developers.openai.com/api/docs/guides/images-vision), and
|
|
2080
|
+
* [audio](https://developers.openai.com/api/docs/guides/audio).
|
|
1532
2081
|
*/
|
|
1533
2082
|
messages: Array<ChatCompletionMessageParam>;
|
|
1534
2083
|
|
|
1535
2084
|
/**
|
|
1536
|
-
* Model ID used to generate the response, like `gpt-
|
|
1537
|
-
* wide range of models with different capabilities, performance
|
|
1538
|
-
* and price points. Refer to the
|
|
1539
|
-
* [model guide](https://
|
|
1540
|
-
* available models.
|
|
2085
|
+
* Model ID used to generate the response, like `gpt-6-astra` or `o3`. OpenAI
|
|
2086
|
+
* offers a wide range of models with different capabilities, performance
|
|
2087
|
+
* characteristics, and price points. Refer to the
|
|
2088
|
+
* [model guide](https://developers.openai.com/api/docs/models) to browse and
|
|
2089
|
+
* compare available models.
|
|
1541
2090
|
*/
|
|
1542
2091
|
model: (string & {}) | Shared.ChatModel;
|
|
1543
2092
|
|
|
1544
2093
|
/**
|
|
1545
2094
|
* Parameters for audio output. Required when audio output is requested with
|
|
1546
2095
|
* `modalities: ["audio"]`.
|
|
1547
|
-
* [Learn more](https://
|
|
2096
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/audio).
|
|
1548
2097
|
*/
|
|
1549
2098
|
audio?: ChatCompletionAudioParam | null;
|
|
1550
2099
|
|
|
@@ -1602,18 +2151,19 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1602
2151
|
/**
|
|
1603
2152
|
* An upper bound for the number of tokens that can be generated for a completion,
|
|
1604
2153
|
* including visible output tokens and
|
|
1605
|
-
* [reasoning tokens](https://
|
|
2154
|
+
* [reasoning tokens](https://developers.openai.com/api/docs/guides/reasoning).
|
|
1606
2155
|
*/
|
|
1607
2156
|
max_completion_tokens?: number | null;
|
|
1608
2157
|
|
|
1609
2158
|
/**
|
|
1610
|
-
* @deprecated The maximum number of
|
|
1611
|
-
*
|
|
2159
|
+
* @deprecated The maximum number of
|
|
2160
|
+
* [tokens](https://platform.openai.com/tokenizer) that can be generated in the
|
|
2161
|
+
* chat completion. This value can be used to control
|
|
1612
2162
|
* [costs](https://openai.com/api/pricing/) for text generated via API.
|
|
1613
2163
|
*
|
|
1614
2164
|
* This value is now deprecated in favor of `max_completion_tokens`, and is not
|
|
1615
2165
|
* compatible with
|
|
1616
|
-
* [o-series models](https://
|
|
2166
|
+
* [o-series models](https://developers.openai.com/api/docs/guides/reasoning).
|
|
1617
2167
|
*/
|
|
1618
2168
|
max_tokens?: number | null;
|
|
1619
2169
|
|
|
@@ -1634,13 +2184,18 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1634
2184
|
* `["text"]`
|
|
1635
2185
|
*
|
|
1636
2186
|
* The `gpt-4o-audio-preview` model can also be used to
|
|
1637
|
-
* [generate audio](https://
|
|
1638
|
-
* this model generate both text and audio responses, you can use:
|
|
2187
|
+
* [generate audio](https://developers.openai.com/api/docs/guides/audio). To
|
|
2188
|
+
* request that this model generate both text and audio responses, you can use:
|
|
1639
2189
|
*
|
|
1640
2190
|
* `["text", "audio"]`
|
|
1641
2191
|
*/
|
|
1642
2192
|
modalities?: Array<'text' | 'audio'> | null;
|
|
1643
2193
|
|
|
2194
|
+
/**
|
|
2195
|
+
* Configuration for running moderation on the request input and generated output.
|
|
2196
|
+
*/
|
|
2197
|
+
moderation?: ChatCompletionCreateParams.Moderation | null;
|
|
2198
|
+
|
|
1644
2199
|
/**
|
|
1645
2200
|
* How many chat completion choices to generate for each input message. Note that
|
|
1646
2201
|
* you will be charged based on the number of generated tokens across all of the
|
|
@@ -1650,7 +2205,7 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1650
2205
|
|
|
1651
2206
|
/**
|
|
1652
2207
|
* Whether to enable
|
|
1653
|
-
* [parallel function calling](https://
|
|
2208
|
+
* [parallel function calling](https://developers.openai.com/api/docs/guides/function-calling#parallel-function-calling)
|
|
1654
2209
|
* during tool use.
|
|
1655
2210
|
*/
|
|
1656
2211
|
parallel_tool_calls?: boolean;
|
|
@@ -1671,16 +2226,34 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1671
2226
|
/**
|
|
1672
2227
|
* Used by OpenAI to cache responses for similar requests to optimize your cache
|
|
1673
2228
|
* hit rates. Replaces the `user` field.
|
|
1674
|
-
* [Learn more](https://
|
|
2229
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/prompt-caching).
|
|
1675
2230
|
*/
|
|
1676
|
-
prompt_cache_key?: string;
|
|
2231
|
+
prompt_cache_key?: string | null;
|
|
1677
2232
|
|
|
1678
2233
|
/**
|
|
2234
|
+
* Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
2235
|
+
* default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
2236
|
+
* explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each
|
|
2237
|
+
* request can write up to four breakpoints. For cache matching, OpenAI considers
|
|
2238
|
+
* up to the latest 80 breakpoints in the conversation, without a content-block
|
|
2239
|
+
* lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
|
|
2240
|
+
* `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
2241
|
+
* [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
|
|
2242
|
+
* for current details.
|
|
2243
|
+
*/
|
|
2244
|
+
prompt_cache_options?: ChatCompletionCreateParams.PromptCacheOptions;
|
|
2245
|
+
|
|
2246
|
+
/**
|
|
2247
|
+
* @deprecated Deprecated. Use `prompt_cache_options.ttl` instead.
|
|
2248
|
+
*
|
|
1679
2249
|
* The retention policy for the prompt cache. Set to `24h` to enable extended
|
|
1680
2250
|
* prompt caching, which keeps cached prefixes active for longer, up to a maximum
|
|
1681
2251
|
* of 24 hours.
|
|
1682
|
-
* [Learn more](https://
|
|
1683
|
-
*
|
|
2252
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/prompt-caching#prompt-cache-retention).
|
|
2253
|
+
* This field expresses a maximum retention policy, while
|
|
2254
|
+
* `prompt_cache_options.ttl` expresses a minimum cache lifetime. The two fields
|
|
2255
|
+
* are independent and do not interact. For `gpt-5.5`, `gpt-5.5-pro`, and future
|
|
2256
|
+
* models, only `24h` is supported.
|
|
1684
2257
|
*
|
|
1685
2258
|
* For older models that support both `in_memory` and `24h`, the default depends on
|
|
1686
2259
|
* your organization's data retention policy:
|
|
@@ -1692,19 +2265,12 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1692
2265
|
prompt_cache_retention?: 'in_memory' | '24h' | null;
|
|
1693
2266
|
|
|
1694
2267
|
/**
|
|
1695
|
-
* Constrains effort on reasoning for
|
|
1696
|
-
*
|
|
1697
|
-
*
|
|
1698
|
-
*
|
|
1699
|
-
*
|
|
1700
|
-
*
|
|
1701
|
-
* - `gpt-5.1` defaults to `none`, which does not perform reasoning. The supported
|
|
1702
|
-
* reasoning values for `gpt-5.1` are `none`, `low`, `medium`, and `high`. Tool
|
|
1703
|
-
* calls are supported for all reasoning values in gpt-5.1.
|
|
1704
|
-
* - All models before `gpt-5.1` default to `medium` reasoning effort, and do not
|
|
1705
|
-
* support `none`.
|
|
1706
|
-
* - The `gpt-5-pro` model defaults to (and only supports) `high` reasoning effort.
|
|
1707
|
-
* - `xhigh` is supported for all models after `gpt-5.1-codex-max`.
|
|
2268
|
+
* Constrains effort on reasoning for reasoning models. Currently supported values
|
|
2269
|
+
* are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`. Reducing
|
|
2270
|
+
* reasoning effort can result in faster responses and fewer tokens used on
|
|
2271
|
+
* reasoning in a response. Not all reasoning models support every value. See the
|
|
2272
|
+
* [reasoning guide](https://developers.openai.com/api/docs/guides/reasoning) for
|
|
2273
|
+
* model-specific support.
|
|
1708
2274
|
*/
|
|
1709
2275
|
reasoning_effort?: Shared.ReasoningEffort | null;
|
|
1710
2276
|
|
|
@@ -1714,7 +2280,7 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1714
2280
|
* Setting to `{ "type": "json_schema", "json_schema": {...} }` enables Structured
|
|
1715
2281
|
* Outputs which ensures the model will match your supplied JSON schema. Learn more
|
|
1716
2282
|
* in the
|
|
1717
|
-
* [Structured Outputs guide](https://
|
|
2283
|
+
* [Structured Outputs guide](https://developers.openai.com/api/docs/guides/structured-outputs).
|
|
1718
2284
|
*
|
|
1719
2285
|
* Setting to `{ "type": "json_object" }` enables the older JSON mode, which
|
|
1720
2286
|
* ensures the message the model generates is valid JSON. Using `json_schema` is
|
|
@@ -1731,9 +2297,9 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1731
2297
|
* identifies each user, with a maximum length of 64 characters. We recommend
|
|
1732
2298
|
* hashing their username or email address, in order to avoid sending us any
|
|
1733
2299
|
* identifying information.
|
|
1734
|
-
* [Learn more](https://
|
|
2300
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
|
|
1735
2301
|
*/
|
|
1736
|
-
safety_identifier?: string;
|
|
2302
|
+
safety_identifier?: string | null;
|
|
1737
2303
|
|
|
1738
2304
|
/**
|
|
1739
2305
|
* @deprecated This feature is in Beta. If specified, our system will make a best
|
|
@@ -1752,9 +2318,15 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1752
2318
|
* will use 'default'.
|
|
1753
2319
|
* - If set to 'default', then the request will be processed with the standard
|
|
1754
2320
|
* pricing and performance for the selected model.
|
|
1755
|
-
* - If set to
|
|
1756
|
-
* '[
|
|
1757
|
-
* will be processed with the
|
|
2321
|
+
* - If set to
|
|
2322
|
+
* '[flex](https://developers.openai.com/api/docs/guides/flex-processing)', then
|
|
2323
|
+
* the request will be processed with the Flex Processing service tier.
|
|
2324
|
+
* - To opt-in to
|
|
2325
|
+
* [Fast mode](https://developers.openai.com/api/docs/guides/fast-mode) at the
|
|
2326
|
+
* request level, include the `service_tier=fast` or `service_tier=priority`
|
|
2327
|
+
* parameter for Responses or Chat Completions. The response will show
|
|
2328
|
+
* `service_tier=priority` regardless of if you specify `service_tier=fast` or
|
|
2329
|
+
* `priority` in your request.
|
|
1758
2330
|
* - When not set, the default behavior is 'auto'.
|
|
1759
2331
|
*
|
|
1760
2332
|
* When the `service_tier` parameter is set, the response body will include the
|
|
@@ -1762,7 +2334,7 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1762
2334
|
* request. This response value may be different from the value set in the
|
|
1763
2335
|
* parameter.
|
|
1764
2336
|
*/
|
|
1765
|
-
service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
|
|
2337
|
+
service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | 'fast' | null;
|
|
1766
2338
|
|
|
1767
2339
|
/**
|
|
1768
2340
|
* Not supported with latest reasoning models `o3` and `o4-mini`.
|
|
@@ -1774,8 +2346,9 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1774
2346
|
|
|
1775
2347
|
/**
|
|
1776
2348
|
* Whether or not to store the output of this chat completion request for use in
|
|
1777
|
-
* our
|
|
1778
|
-
*
|
|
2349
|
+
* our
|
|
2350
|
+
* [model distillation](https://developers.openai.com/api/docs/guides/supervised-fine-tuning#distilling-from-a-larger-model)
|
|
2351
|
+
* or [evals](https://developers.openai.com/api/docs/guides/evals) products.
|
|
1779
2352
|
*
|
|
1780
2353
|
* Supports text and image inputs. Note: image inputs over 8MB will be dropped.
|
|
1781
2354
|
*/
|
|
@@ -1786,9 +2359,9 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1786
2359
|
* generated using
|
|
1787
2360
|
* [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
|
|
1788
2361
|
* See the
|
|
1789
|
-
* [Streaming section below](https://
|
|
2362
|
+
* [Streaming section below](https://developers.openai.com/api/reference/resources/chat/subresources/completions/streaming-events)
|
|
1790
2363
|
* for more information, along with the
|
|
1791
|
-
* [streaming responses](https://
|
|
2364
|
+
* [streaming responses](https://developers.openai.com/api/docs/guides/streaming-responses)
|
|
1792
2365
|
* guide for more information on how to handle the streaming events.
|
|
1793
2366
|
*/
|
|
1794
2367
|
stream?: boolean | null;
|
|
@@ -1821,8 +2394,9 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1821
2394
|
|
|
1822
2395
|
/**
|
|
1823
2396
|
* A list of tools the model may call. You can provide either
|
|
1824
|
-
* [custom tools](https://
|
|
1825
|
-
* or
|
|
2397
|
+
* [custom tools](https://developers.openai.com/api/docs/guides/function-calling#custom-tools)
|
|
2398
|
+
* or
|
|
2399
|
+
* [function tools](https://developers.openai.com/api/docs/guides/function-calling).
|
|
1826
2400
|
*/
|
|
1827
2401
|
tools?: Array<ChatCompletionTool>;
|
|
1828
2402
|
|
|
@@ -1849,21 +2423,22 @@ export interface ChatCompletionCreateParamsBase {
|
|
|
1849
2423
|
* optimizations. A stable identifier for your end-users. Used to boost cache hit
|
|
1850
2424
|
* rates by better bucketing similar requests and to help OpenAI detect and prevent
|
|
1851
2425
|
* abuse.
|
|
1852
|
-
* [Learn more](https://
|
|
2426
|
+
* [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
|
|
1853
2427
|
*/
|
|
1854
2428
|
user?: string;
|
|
1855
2429
|
|
|
1856
2430
|
/**
|
|
1857
2431
|
* Constrains the verbosity of the model's response. Lower values will result in
|
|
1858
2432
|
* more concise responses, while higher values will result in more verbose
|
|
1859
|
-
* responses. Currently supported values are `low`, `medium`, and `high`.
|
|
2433
|
+
* responses. Currently supported values are `low`, `medium`, and `high`. The
|
|
2434
|
+
* default is `medium`.
|
|
1860
2435
|
*/
|
|
1861
2436
|
verbosity?: 'low' | 'medium' | 'high' | null;
|
|
1862
2437
|
|
|
1863
2438
|
/**
|
|
1864
2439
|
* This tool searches the web for relevant results to use in a response. Learn more
|
|
1865
2440
|
* about the
|
|
1866
|
-
* [web search tool](https://
|
|
2441
|
+
* [web search tool](https://developers.openai.com/api/docs/guides/tools-web-search).
|
|
1867
2442
|
*/
|
|
1868
2443
|
web_search_options?: ChatCompletionCreateParams.WebSearchOptions;
|
|
1869
2444
|
}
|
|
@@ -1887,8 +2462,8 @@ export namespace ChatCompletionCreateParams {
|
|
|
1887
2462
|
|
|
1888
2463
|
/**
|
|
1889
2464
|
* The parameters the functions accepts, described as a JSON Schema object. See the
|
|
1890
|
-
* [guide](https://
|
|
1891
|
-
* and the
|
|
2465
|
+
* [guide](https://developers.openai.com/api/docs/guides/function-calling) for
|
|
2466
|
+
* examples, and the
|
|
1892
2467
|
* [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for
|
|
1893
2468
|
* documentation about the format.
|
|
1894
2469
|
*
|
|
@@ -1897,10 +2472,89 @@ export namespace ChatCompletionCreateParams {
|
|
|
1897
2472
|
parameters?: Shared.FunctionParameters;
|
|
1898
2473
|
}
|
|
1899
2474
|
|
|
2475
|
+
/**
|
|
2476
|
+
* Configuration for running moderation on the request input and generated output.
|
|
2477
|
+
*/
|
|
2478
|
+
export interface Moderation {
|
|
2479
|
+
/**
|
|
2480
|
+
* The moderation model to use for moderated completions, e.g.
|
|
2481
|
+
* 'omni-moderation-latest'.
|
|
2482
|
+
*/
|
|
2483
|
+
model: string;
|
|
2484
|
+
|
|
2485
|
+
/**
|
|
2486
|
+
* The policy to apply to moderated response input and output.
|
|
2487
|
+
*/
|
|
2488
|
+
policy?: Moderation.Policy | null;
|
|
2489
|
+
}
|
|
2490
|
+
|
|
2491
|
+
export namespace Moderation {
|
|
2492
|
+
/**
|
|
2493
|
+
* The policy to apply to moderated response input and output.
|
|
2494
|
+
*/
|
|
2495
|
+
export interface Policy {
|
|
2496
|
+
/**
|
|
2497
|
+
* The moderation policy for the response input.
|
|
2498
|
+
*/
|
|
2499
|
+
input?: Policy.Input | null;
|
|
2500
|
+
|
|
2501
|
+
/**
|
|
2502
|
+
* The moderation policy for the response output.
|
|
2503
|
+
*/
|
|
2504
|
+
output?: Policy.Output | null;
|
|
2505
|
+
}
|
|
2506
|
+
|
|
2507
|
+
export namespace Policy {
|
|
2508
|
+
/**
|
|
2509
|
+
* The moderation policy for the response input.
|
|
2510
|
+
*/
|
|
2511
|
+
export interface Input {
|
|
2512
|
+
mode: 'score' | 'block';
|
|
2513
|
+
}
|
|
2514
|
+
|
|
2515
|
+
/**
|
|
2516
|
+
* The moderation policy for the response output.
|
|
2517
|
+
*/
|
|
2518
|
+
export interface Output {
|
|
2519
|
+
mode: 'score' | 'block';
|
|
2520
|
+
}
|
|
2521
|
+
}
|
|
2522
|
+
}
|
|
2523
|
+
|
|
2524
|
+
/**
|
|
2525
|
+
* Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
2526
|
+
* default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
2527
|
+
* explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each
|
|
2528
|
+
* request can write up to four breakpoints. For cache matching, OpenAI considers
|
|
2529
|
+
* up to the latest 80 breakpoints in the conversation, without a content-block
|
|
2530
|
+
* lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
|
|
2531
|
+
* `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
2532
|
+
* [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
|
|
2533
|
+
* for current details.
|
|
2534
|
+
*/
|
|
2535
|
+
export interface PromptCacheOptions {
|
|
2536
|
+
/**
|
|
2537
|
+
* Controls whether OpenAI automatically creates an implicit cache breakpoint.
|
|
2538
|
+
* Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
|
|
2539
|
+
* and writes up to the latest three explicit breakpoints in the request. With
|
|
2540
|
+
* `explicit`, OpenAI does not create an implicit breakpoint and writes up to the
|
|
2541
|
+
* latest four explicit breakpoints. If there are no explicit breakpoints, the
|
|
2542
|
+
* request does not use prompt caching.
|
|
2543
|
+
*/
|
|
2544
|
+
mode?: 'implicit' | 'explicit';
|
|
2545
|
+
|
|
2546
|
+
/**
|
|
2547
|
+
* The minimum lifetime applied to every implicit and explicit cache breakpoint
|
|
2548
|
+
* written by the request. Defaults to `30m`, which is currently the only supported
|
|
2549
|
+
* value. The backend may retain cache entries for longer.
|
|
2550
|
+
*/
|
|
2551
|
+
ttl?: '30m';
|
|
2552
|
+
}
|
|
2553
|
+
|
|
1900
2554
|
/**
|
|
1901
2555
|
* This tool searches the web for relevant results to use in a response. Learn more
|
|
1902
2556
|
* about the
|
|
1903
|
-
* [web search tool](https://
|
|
2557
|
+
* [web search tool](https://developers.openai.com/api/docs/guides/tools-web-search).
|
|
1904
2558
|
*/
|
|
1905
2559
|
export interface WebSearchOptions {
|
|
1906
2560
|
/**
|
|
@@ -1972,9 +2626,9 @@ export interface ChatCompletionCreateParamsNonStreaming extends ChatCompletionCr
|
|
|
1972
2626
|
* generated using
|
|
1973
2627
|
* [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
|
|
1974
2628
|
* See the
|
|
1975
|
-
* [Streaming section below](https://
|
|
2629
|
+
* [Streaming section below](https://developers.openai.com/api/reference/resources/chat/subresources/completions/streaming-events)
|
|
1976
2630
|
* for more information, along with the
|
|
1977
|
-
* [streaming responses](https://
|
|
2631
|
+
* [streaming responses](https://developers.openai.com/api/docs/guides/streaming-responses)
|
|
1978
2632
|
* guide for more information on how to handle the streaming events.
|
|
1979
2633
|
*/
|
|
1980
2634
|
stream?: false | null;
|
|
@@ -1986,9 +2640,9 @@ export interface ChatCompletionCreateParamsStreaming extends ChatCompletionCreat
|
|
|
1986
2640
|
* generated using
|
|
1987
2641
|
* [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
|
|
1988
2642
|
* See the
|
|
1989
|
-
* [Streaming section below](https://
|
|
2643
|
+
* [Streaming section below](https://developers.openai.com/api/reference/resources/chat/subresources/completions/streaming-events)
|
|
1990
2644
|
* for more information, along with the
|
|
1991
|
-
* [streaming responses](https://
|
|
2645
|
+
* [streaming responses](https://developers.openai.com/api/docs/guides/streaming-responses)
|
|
1992
2646
|
* guide for more information on how to handle the streaming events.
|
|
1993
2647
|
*/
|
|
1994
2648
|
stream: true;
|