@xuda.io/account_module 1.2.1773 → 1.2.1774

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 -2
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -2126,8 +2126,11 @@ export const add_contact = async function (req, job_id, headers) {
2126
2126
  is_spam = await ai_module.is_spam_email(uid, email, metadata.subject, account_profile_info);
2127
2127
  }
2128
2128
  if (!is_spam) {
2129
- account_type_info = await ai_module.analyze_email_account_type(uid, name, email, account_profile_info, metadata?.summarized_body);
2130
- account_type = account_type_info.account_type;
2129
+ // account_type_info = await ai_module.analyze_email_account_type(uid, name, email, account_profile_info, metadata?.summarized_body);
2130
+ // account_type = account_type_info.account_type;
2131
+
2132
+ const is_business = await ai_module.is_business_contact(uid, email, name, metadata.subject, metadata.summarized_body, account_profile_info);
2133
+ account_type = is_business ? 'business' : 'personal';
2131
2134
 
2132
2135
  if (_.isEmpty(cached_contact) && account_type === 'business' && !account_type_info.is_real_person) {
2133
2136
  const domain = email.includes('@') ? email.split('@')[1] : '';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/account_module",
3
- "version": "1.2.1773",
3
+ "version": "1.2.1774",
4
4
  "description": "Xuda Account Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {