@ax-llm/ax 11.0.19 → 11.0.21

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/index.cjs CHANGED
@@ -2698,10 +2698,10 @@ var axAIGoogleGeminiDefaultConfig = () => structuredClone({
2698
2698
  ...axBaseAIDefaultConfig()
2699
2699
  });
2700
2700
  var AxAIGoogleGeminiImpl = class {
2701
- constructor(config, isVertex, endpoint, apiKey, options) {
2701
+ constructor(config, isVertex, endpointId, apiKey, options) {
2702
2702
  this.config = config;
2703
2703
  this.isVertex = isVertex;
2704
- this.endpoint = endpoint;
2704
+ this.endpointId = endpointId;
2705
2705
  this.apiKey = apiKey;
2706
2706
  this.options = options;
2707
2707
  }
@@ -2727,9 +2727,9 @@ var AxAIGoogleGeminiImpl = class {
2727
2727
  throw new Error("Chat prompt is empty");
2728
2728
  }
2729
2729
  let apiConfig;
2730
- if (this.endpoint) {
2730
+ if (this.endpointId) {
2731
2731
  apiConfig = {
2732
- name: stream ? `/${this.endpoint}:streamGenerateContent?alt=sse` : `/${this.endpoint}:generateContent`
2732
+ name: stream ? `/${this.endpointId}:streamGenerateContent?alt=sse` : `/${this.endpointId}:generateContent`
2733
2733
  };
2734
2734
  } else {
2735
2735
  apiConfig = {
@@ -2888,9 +2888,9 @@ var AxAIGoogleGeminiImpl = class {
2888
2888
  let apiConfig;
2889
2889
  let reqValue;
2890
2890
  if (this.isVertex) {
2891
- if (this.endpoint) {
2891
+ if (this.endpointId) {
2892
2892
  apiConfig = {
2893
- name: `/${this.endpoint}:predict`
2893
+ name: `/${this.endpointId}:predict`
2894
2894
  };
2895
2895
  } else {
2896
2896
  apiConfig = {
@@ -2994,7 +2994,7 @@ var AxAIGoogleGemini = class extends AxBaseAI {
2994
2994
  apiKey,
2995
2995
  projectId,
2996
2996
  region,
2997
- endpoint,
2997
+ endpointId,
2998
2998
  config,
2999
2999
  options,
3000
3000
  models
@@ -3004,7 +3004,7 @@ var AxAIGoogleGemini = class extends AxBaseAI {
3004
3004
  let headers;
3005
3005
  if (isVertex) {
3006
3006
  let path;
3007
- if (endpoint) {
3007
+ if (endpointId) {
3008
3008
  path = "endpoints";
3009
3009
  } else {
3010
3010
  path = "publishers/google";
@@ -3032,7 +3032,7 @@ var AxAIGoogleGemini = class extends AxBaseAI {
3032
3032
  const aiImpl = new AxAIGoogleGeminiImpl(
3033
3033
  _config,
3034
3034
  isVertex,
3035
- endpoint,
3035
+ endpointId,
3036
3036
  apiKey,
3037
3037
  options
3038
3038
  );
@@ -5282,7 +5282,7 @@ var renderOutputFields = (fields) => {
5282
5282
  const rows = fields.map((field) => {
5283
5283
  const name = field.title;
5284
5284
  const type = field.type?.name ? toFieldType(field.type) : "string";
5285
- const requiredMsg = field.isOptional ? `Only include this ${type} field is it's value is available` : `This ${type} field must be included`;
5285
+ const requiredMsg = field.isOptional ? `Only include this ${type} field if its value is available` : `This ${type} field must be included`;
5286
5286
  const description = field.description ? ` ${formatDescription(field.description)}` : "";
5287
5287
  return `${name}: (${requiredMsg})${description}`.trim();
5288
5288
  });