@langgraph-js/sdk 1.5.3 → 1.5.4

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.
@@ -444,7 +444,7 @@ export class LangGraphClient extends Client {
444
444
  }
445
445
  runFETool() {
446
446
  var _a;
447
- const data = this.graphMessages;
447
+ const data = this.streamingMessage; // 需要保证不被清理
448
448
  const lastMessage = data[data.length - 1];
449
449
  // 如果最后一条消息是前端工具消息,则调用工具
450
450
  if (lastMessage.type === "ai" && ((_a = lastMessage.tool_calls) === null || _a === void 0 ? void 0 : _a.length)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@langgraph-js/sdk",
3
- "version": "1.5.3",
3
+ "version": "1.5.4",
4
4
  "description": "The UI SDK for LangGraph - seamlessly integrate your AI agents with frontend interfaces",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",
@@ -528,7 +528,7 @@ export class LangGraphClient extends Client {
528
528
  }
529
529
 
530
530
  private runFETool() {
531
- const data = this.graphMessages;
531
+ const data = this.streamingMessage; // 需要保证不被清理
532
532
  const lastMessage = data[data.length - 1];
533
533
  // 如果最后一条消息是前端工具消息,则调用工具
534
534
  if (lastMessage.type === "ai" && lastMessage.tool_calls?.length) {