@xuda.io/ai_module 1.1.4919 → 1.1.4921
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.mjs +10 -18
- package/index_ms.mjs +6 -2
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -3945,23 +3945,15 @@ const ai_chat_conversation = async function (req, job_id, headers) {
|
|
|
3945
3945
|
// const { account_profile_info } = conversation_doc;
|
|
3946
3946
|
const emitToDashboard = (type, content) => {
|
|
3947
3947
|
// console.log(type, content);
|
|
3948
|
-
|
|
3949
|
-
|
|
3950
|
-
|
|
3951
|
-
|
|
3952
|
-
|
|
3953
|
-
|
|
3954
|
-
|
|
3955
|
-
|
|
3956
|
-
|
|
3957
|
-
conversation_id,
|
|
3958
|
-
job_id,
|
|
3959
|
-
delta: content,
|
|
3960
|
-
},
|
|
3961
|
-
},
|
|
3962
|
-
}),
|
|
3963
|
-
),
|
|
3964
|
-
);
|
|
3948
|
+
ws_dashboard_ms.emit_message_to_dashboard({
|
|
3949
|
+
service: type,
|
|
3950
|
+
to: uid,
|
|
3951
|
+
data: {
|
|
3952
|
+
conversation_id,
|
|
3953
|
+
job_id,
|
|
3954
|
+
delta: content,
|
|
3955
|
+
},
|
|
3956
|
+
});
|
|
3965
3957
|
};
|
|
3966
3958
|
|
|
3967
3959
|
const generate_XU_markdown = async function (type, data) {
|
|
@@ -4012,7 +4004,7 @@ const ai_chat_conversation = async function (req, job_id, headers) {
|
|
|
4012
4004
|
job_id,
|
|
4013
4005
|
current_step_name: current_step_name,
|
|
4014
4006
|
},
|
|
4015
|
-
global[`_ai_module_ch`],
|
|
4007
|
+
// global[`_ai_module_ch`],
|
|
4016
4008
|
);
|
|
4017
4009
|
};
|
|
4018
4010
|
|
package/index_ms.mjs
CHANGED
|
@@ -61,7 +61,8 @@ const send_to_queue =async function(ms_method, ...args) {
|
|
|
61
61
|
delete queue[queue_id];
|
|
62
62
|
reject(error);
|
|
63
63
|
};
|
|
64
|
-
|
|
64
|
+
|
|
65
|
+
try{
|
|
65
66
|
global[`_${global.module_in}_ch`].sendToQueue(
|
|
66
67
|
'ai_module',
|
|
67
68
|
Buffer.from(
|
|
@@ -73,7 +74,10 @@ const send_to_queue =async function(ms_method, ...args) {
|
|
|
73
74
|
})
|
|
74
75
|
)
|
|
75
76
|
);
|
|
76
|
-
|
|
77
|
+
|
|
78
|
+
}catch(err){
|
|
79
|
+
debugger
|
|
80
|
+
}
|
|
77
81
|
})
|
|
78
82
|
|
|
79
83
|
};
|