@xuda.io/ai_module 1.1.4284 → 1.1.4286
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 +4 -4
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -6699,15 +6699,15 @@ export const is_spam_email = async function (uid, email, subject, account_profil
|
|
|
6699
6699
|
};
|
|
6700
6700
|
|
|
6701
6701
|
export const is_business_contact = async function (uid, email, subject, body, account_profile_info) {
|
|
6702
|
-
const
|
|
6702
|
+
const is_business = await submit_chat_gpt_prompt({
|
|
6703
6703
|
uid,
|
|
6704
|
-
prompt: `
|
|
6704
|
+
prompt: `Determine if the contact with email "${email}", subject "${subject}", and body "${body}" belongs to a business account. Return true if it is a business contact, false otherwise.`,
|
|
6705
6705
|
model: 'gpt-5-nano',
|
|
6706
6706
|
response_format: z.object({
|
|
6707
|
-
is_spam: z.boolean().describe('if business account
|
|
6707
|
+
is_spam: z.boolean().describe('true if this is a business account/contact, false otherwise'),
|
|
6708
6708
|
}),
|
|
6709
6709
|
metadata: { func: 'is_business_contact' },
|
|
6710
6710
|
account_profile_info,
|
|
6711
6711
|
});
|
|
6712
|
-
return
|
|
6712
|
+
return is_business;
|
|
6713
6713
|
};
|