ai 6.0.0-beta.135 → 6.0.0-beta.136

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -813,7 +813,7 @@ import {
813
813
  } from "@ai-sdk/provider-utils";
814
814
 
815
815
  // src/version.ts
816
- var VERSION = true ? "6.0.0-beta.135" : "0.0.0-test";
816
+ var VERSION = true ? "6.0.0-beta.136" : "0.0.0-test";
817
817
 
818
818
  // src/util/download/download.ts
819
819
  var download = async ({ url }) => {
@@ -9905,10 +9905,10 @@ function defaultFormatExample(example) {
9905
9905
  return JSON.stringify(example.input);
9906
9906
  }
9907
9907
  function addToolInputExamplesMiddleware({
9908
- examplesPrefix,
9909
- formatExample = defaultFormatExample,
9910
- removeInputExamples = true
9911
- }) {
9908
+ prefix = "Input Examples:",
9909
+ format = defaultFormatExample,
9910
+ remove = true
9911
+ } = {}) {
9912
9912
  return {
9913
9913
  specificationVersion: "v3",
9914
9914
  transformParams: async ({ params }) => {
@@ -9921,8 +9921,8 @@ function addToolInputExamplesMiddleware({
9921
9921
  if (tool2.type !== "function" || !((_a16 = tool2.inputExamples) == null ? void 0 : _a16.length)) {
9922
9922
  return tool2;
9923
9923
  }
9924
- const formattedExamples = tool2.inputExamples.map((example, index) => formatExample(example, index)).join("\n");
9925
- const examplesSection = `${examplesPrefix}
9924
+ const formattedExamples = tool2.inputExamples.map((example, index) => format(example, index)).join("\n");
9925
+ const examplesSection = `${prefix}
9926
9926
  ${formattedExamples}`;
9927
9927
  const toolDescription = tool2.description ? `${tool2.description}
9928
9928
 
@@ -9930,7 +9930,7 @@ ${examplesSection}` : examplesSection;
9930
9930
  return {
9931
9931
  ...tool2,
9932
9932
  description: toolDescription,
9933
- inputExamples: removeInputExamples ? void 0 : tool2.inputExamples
9933
+ inputExamples: remove ? void 0 : tool2.inputExamples
9934
9934
  };
9935
9935
  });
9936
9936
  return {