From 7f5fb4124ad10d55961dd30a9a39330ea977dd32 Mon Sep 17 00:00:00 2001 From: kudo-sync-bot Date: Sun, 26 Jan 2025 06:55:40 -0800 Subject: [PATCH] =?UTF-8?q?Added=20Dev=20Mode=20log=20of=20final=20`reqDat?= =?UTF-8?q?a`=20to=20`api.createReqData()`=20=E2=86=9E=20[auto-sync=20from?= =?UTF-8?q?=20https://github.com/adamlui/ai-web-extensions/tree/main/amazo?= =?UTF-8?q?ngpt]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- chatgpt/amazongpt/amazongpt.user.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/chatgpt/amazongpt/amazongpt.user.js b/chatgpt/amazongpt/amazongpt.user.js index 274be030c..c2a9971a8 100644 --- a/chatgpt/amazongpt/amazongpt.user.js +++ b/chatgpt/amazongpt/amazongpt.user.js @@ -3,7 +3,7 @@ // @description Adds the magic of AI to Amazon shopping // @author KudoAI // @namespace https://kudoai.com -// @version 2025.1.26.6 +// @version 2025.1.26.7 // @license MIT // @icon https://amazongpt.kudoai.com/assets/images/icons/amazongpt/black-gold-teal/icon48.png?v=0fddfc7 // @icon64 https://amazongpt.kudoai.com/assets/images/icons/amazongpt/black-gold-teal/icon64.png?v=0fddfc7 @@ -2505,6 +2505,7 @@ }, async createReqData(api, msgs) { // returns payload for POST / query string for GET + log.caller = `api.createReqData('${api}', msgs)` msgs = structuredClone(msgs) // avoid mutating global msgChain const time = Date.now(), lastUserMsg = msgs[msgs.length - 1] lastUserMsg.content = prompts.augment(lastUserMsg.content, { api: api }) @@ -2527,7 +2528,7 @@ : apis[api].method == 'GET' ? encodeURIComponent(lastUserMsg.content) : null if (api == 'GPTforLove' && apis.GPTforLove.parentID) // include parentID for contextual replies reqData.options = { parentMessageId: apis.GPTforLove.parentID } - return reqData + log.dev(reqData) ; return reqData }, pick(caller) {