@myun/gimi-chat 0.9.60 → 0.9.61
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.
|
@@ -564,6 +564,7 @@ var useCommonChatAPI = function useCommonChatAPI(props) {
|
|
|
564
564
|
// if (isSystemAuto) return;
|
|
565
565
|
setIgnoreOnMessage(true);
|
|
566
566
|
currentMessageList = messageListRef.current;
|
|
567
|
+
console.log('currentMessageList-----', currentMessageList);
|
|
567
568
|
lastToolList = _toConsumableArray(currentMessageList[currentMessageList.length - 1].toolList || []);
|
|
568
569
|
newMessageList = [];
|
|
569
570
|
if (type === 'user_confirm') {
|
|
@@ -613,13 +614,13 @@ var useCommonChatAPI = function useCommonChatAPI(props) {
|
|
|
613
614
|
// 获取最新的agent详情,防止redux异步更新
|
|
614
615
|
agentDetail = agentInfo || agentObjRef.current; // 获取推荐追问
|
|
615
616
|
if (!((agentDetail === null || agentDetail === void 0 ? void 0 : agentDetail.isEnableRelated) === 1 && (type === 'end' || type === 'COMPLETED'))) {
|
|
616
|
-
_context5.next =
|
|
617
|
+
_context5.next = 14;
|
|
617
618
|
break;
|
|
618
619
|
}
|
|
619
620
|
setMsgLoading(true);
|
|
620
|
-
_context5.next =
|
|
621
|
+
_context5.next = 14;
|
|
621
622
|
return getRecommendList(newMessageList, lastId, statusRef.current);
|
|
622
|
-
case
|
|
623
|
+
case 14:
|
|
623
624
|
// 获取相关课程
|
|
624
625
|
userInput = newMessageList[newMessageList.length - 2].content;
|
|
625
626
|
getRelatedCourses(userInput || '');
|
|
@@ -630,7 +631,7 @@ var useCommonChatAPI = function useCommonChatAPI(props) {
|
|
|
630
631
|
}
|
|
631
632
|
setMsgLoading(false);
|
|
632
633
|
onSendEnd === null || onSendEnd === void 0 || onSendEnd(newMessageList[newMessageList.length - 1]);
|
|
633
|
-
case
|
|
634
|
+
case 19:
|
|
634
635
|
case "end":
|
|
635
636
|
return _context5.stop();
|
|
636
637
|
}
|