@xuda.io/ai_module 1.1.5155 → 1.1.5157

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.
Files changed (2) hide show
  1. package/index.mjs +5 -3
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -4173,7 +4173,7 @@ const ai_chat_conversation = async function (req, job_id, headers) {
4173
4173
  // const reference_type = conversation_doc.reference_type;
4174
4174
  // const reference_id = conversation_doc.reference_id;
4175
4175
 
4176
- const suggestionsPromise = activate_prompt_suggestions ? get_chat_suggestions(uid, ai_agents, out_conversation_item_save_ret.data.id) : Promise.resolve(null);
4176
+ const suggestionsPromise = activate_prompt_suggestions ? get_chat_suggestions({ uid, ai_agents, conversation_item_id: out_conversation_item_save_ret.data.id }) : Promise.resolve(null);
4177
4177
 
4178
4178
  conversation_doc.stat = 2;
4179
4179
  conversation_doc.ts = Date.now();
@@ -4837,7 +4837,7 @@ setTimeout(async () => {
4837
4837
 
4838
4838
  // await init_studio_units();
4839
4839
  let ret;
4840
- ret = await get_chat_suggestions(uid, [], 'coi_7b65b783af38b91c8ec4c499d3694bab');
4840
+ ret = await get_chat_suggestions({ uid, ai_agents: [], conversation_item_id: 'coi_7b65b783af38b91c8ec4c499d3694bab' });
4841
4841
  // ret = await get_active_account_profile_info(uid);
4842
4842
  // ret = await is_spam_email(uid, 'dsgr8-2994400420@gigs.craigslist.org', 'To: You, From: Us - 70% Off Stickers & Labels Today Only');
4843
4843
  // ret = await is_spam_email(uid, 'noreply@tm.openai.com', 'Please update your Plus payment method', account_profile_info);
@@ -10887,7 +10887,9 @@ export const open_ai_alive_check = async function () {};
10887
10887
  // return account_profile_info;
10888
10888
  // };
10889
10889
 
10890
- export const get_chat_suggestions = async function (uid, ai_agents, conversation_item_id, no_of_suggestions = 3, ai_model = _conf.default_ai_model) {
10890
+ export const get_chat_suggestions = async function (req) {
10891
+ const { uid, ai_agents, conversation_item_id, no_of_suggestions = 3, ai_model = _conf.default_ai_model } = req;
10892
+
10891
10893
  try {
10892
10894
  debugger;
10893
10895
  const account_profile_info = await get_active_account_profile_info(uid);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/ai_module",
3
- "version": "1.1.5155",
3
+ "version": "1.1.5157",
4
4
  "description": "Xuda AI Module",
5
5
  "main": "index.mjs",
6
6
  "type": "module",