From 29e936c53b954e0cde472ef1d670800117b9c52b Mon Sep 17 00:00:00 2001 From: Archeb Date: Sat, 3 Aug 2024 21:33:01 +0800 Subject: [PATCH] fix custom mode creation --- provider.mjs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/provider.mjs b/provider.mjs index 893b4c0..f3d0960 100644 --- a/provider.mjs +++ b/provider.mjs @@ -265,14 +265,19 @@ class YouProvider { // 创建新的user chat mode let userChatMode = await page.evaluate( async (proxyModel, proxyModelName) => { - return fetch("https://you.com/api/user_chat_modes", { + return fetch("https://you.com/api/custom_assistants/assistants", { method: "POST", body: JSON.stringify({ aiModel: proxyModel, - chatModeName: proxyModelName, hasLiveWebAccess: false, hasPersonalization: false, + hideInstructions: true, + includeFollowUps: false, instructions: "Please review the attached prompt", + instructionsSummary:"", + isUserOwned: true, + name: proxyModelName, + visibility: "private", }), headers: { "Content-Type": "application/json",