ai 4.1.53 → 4.1.54

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/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # ai
2
2
 
3
+ ## 4.1.54
4
+
5
+ ### Patch Changes
6
+
7
+ - ee1c787: fix (ai/core): correct spread apply order to fix extract reasoning middleware with generateText
8
+
3
9
  ## 4.1.53
4
10
 
5
11
  ### Patch Changes
package/dist/index.js CHANGED
@@ -6061,7 +6061,7 @@ function extractReasoningMiddleware({
6061
6061
  );
6062
6062
  textWithoutReasoning = beforeMatch + (beforeMatch.length > 0 && afterMatch.length > 0 ? separator : "") + afterMatch;
6063
6063
  }
6064
- return { text: textWithoutReasoning, reasoning, ...rest };
6064
+ return { ...rest, text: textWithoutReasoning, reasoning };
6065
6065
  },
6066
6066
  wrapStream: async ({ doStream }) => {
6067
6067
  const { stream, ...rest } = await doStream();