mirror of
https://github.com/ikechan8370/chatgpt-plugin.git
synced 2025-12-17 05:47:11 +00:00
feat: support search for gemini2: #chatgpt开启gemini搜索 #chatgpt开启代码执行 暂时不可并存
This commit is contained in:
parent
8fc2ca5621
commit
5f6c4e5abb
5 changed files with 118 additions and 13 deletions
|
|
@ -13,7 +13,13 @@ export async function getChatHistoryGroup (e, num) {
|
|||
let chats = []
|
||||
while (chats.length < num) {
|
||||
let chatHistory = await e.group.getChatHistory(seq, 20)
|
||||
if (!chatHistory || chatHistory.length === 0) {
|
||||
break
|
||||
}
|
||||
chats.push(...chatHistory)
|
||||
if (seq === chatHistory[0].seq || seq === chatHistory[0].message_id) {
|
||||
break
|
||||
}
|
||||
seq = chatHistory[0].seq || chatHistory[0].message_id
|
||||
}
|
||||
chats = chats.slice(0, num)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue