@xuda.io/ai_module 1.1.4368 → 1.1.4370
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
|
@@ -6828,7 +6828,7 @@ export const get_profile_picture = async function (uid, account_type = 'business
|
|
|
6828
6828
|
// debugger;
|
|
6829
6829
|
try {
|
|
6830
6830
|
// first attempt
|
|
6831
|
-
|
|
6831
|
+
|
|
6832
6832
|
let url = await get_url();
|
|
6833
6833
|
|
|
6834
6834
|
if (url.substr(0, 8) !== 'https://') {
|
|
@@ -6849,7 +6849,7 @@ export const get_profile_picture = async function (uid, account_type = 'business
|
|
|
6849
6849
|
console.error(err);
|
|
6850
6850
|
return '';
|
|
6851
6851
|
}
|
|
6852
|
-
|
|
6852
|
+
profile_picture_source = 'factual';
|
|
6853
6853
|
factual_image_mode = true;
|
|
6854
6854
|
}
|
|
6855
6855
|
}
|
|
@@ -6883,8 +6883,8 @@ export const get_profile_picture = async function (uid, account_type = 'business
|
|
|
6883
6883
|
mimetype: `image/png`,
|
|
6884
6884
|
};
|
|
6885
6885
|
|
|
6886
|
-
|
|
6887
|
-
|
|
6886
|
+
let drive_ret = await drive_module.upload_drive_file_user({ uid, path: '/Profile Images' }, job_id, headers, file_obj);
|
|
6887
|
+
drive_ret.profile_picture_source = profile_picture_source;
|
|
6888
6888
|
record_chat_usage(uid, image_response.usage.input_tokens, image_response.usage.output_tokens, 'profile image', prompt, model, { url }, account_profile_info);
|
|
6889
6889
|
|
|
6890
6890
|
return drive_ret;
|