// Force strict mode and setup for ESM
"use strict";
import {
  init_esbuild_shims
} from "./chunk-5O2XNYP6.js";
import {
  __name
} from "./chunk-J2S4EL5Y.js";

// packages/core/src/core/openaiContentGenerator/constants.ts
init_esbuild_shims();
var DEFAULT_TIMEOUT = 12e4;
var DISABLED_REQUEST_TIMEOUT_MS = 2147483647;
function resolveRequestTimeout(timeout) {
  if (timeout === void 0 || timeout === null) {
    return DEFAULT_TIMEOUT;
  }
  return timeout <= 0 ? DISABLED_REQUEST_TIMEOUT_MS : timeout;
}
__name(resolveRequestTimeout, "resolveRequestTimeout");
var DEFAULT_STREAM_IDLE_TIMEOUT_MS = 24e4;
var QWEN_STREAM_IDLE_TIMEOUT_MS_ENV = "QWEN_STREAM_IDLE_TIMEOUT_MS";
var MAX_STREAM_IDLE_TIMEOUT_MS = 2147483647;
var DEFAULT_MAX_RETRIES = 3;
var DEFAULT_OPENAI_BASE_URL = "https://api.openai.com/v1";
var DEFAULT_DASHSCOPE_BASE_URL = "https://dashscope.aliyuncs.com/compatible-mode/v1";
var DASHSCOPE_PROXY_BASE_URL = process.env["DASHSCOPE_PROXY_BASE_URL"];

export {
  resolveRequestTimeout,
  DEFAULT_STREAM_IDLE_TIMEOUT_MS,
  QWEN_STREAM_IDLE_TIMEOUT_MS_ENV,
  MAX_STREAM_IDLE_TIMEOUT_MS,
  DEFAULT_MAX_RETRIES,
  DEFAULT_OPENAI_BASE_URL,
  DEFAULT_DASHSCOPE_BASE_URL,
  DASHSCOPE_PROXY_BASE_URL
};
