chore(api): update chatgpt-api dependency to version 1.34.0

feat(api): use gen_title response for askChatGPTBrowser.js (official title)
This commit is contained in:
Daniel Avila 2023-04-05 21:34:39 -04:00
parent 385eb2f398
commit 017447b064
3 changed files with 10 additions and 9 deletions

14
api/package-lock.json generated
View file

@ -11,7 +11,7 @@
"dependencies": {
"@dqbd/tiktoken": "^1.0.2",
"@keyv/mongo": "^2.1.8",
"@waylaidwanderer/chatgpt-api": "^1.33.2",
"@waylaidwanderer/chatgpt-api": "^1.34.0",
"axios": "^1.3.4",
"cors": "^2.8.5",
"crypto": "^1.0.1",
@ -1619,9 +1619,9 @@
}
},
"node_modules/@waylaidwanderer/chatgpt-api": {
"version": "1.33.2",
"resolved": "https://registry.npmjs.org/@waylaidwanderer/chatgpt-api/-/chatgpt-api-1.33.2.tgz",
"integrity": "sha512-8CJLln0yaxLGWs21C31OADdAUnSGEDrIqnuPmzRF30/NQGjOWPeHdh00slVqqSNWSGWx5zhCwc9Gt7TSQJYB5Q==",
"version": "1.34.0",
"resolved": "https://registry.npmjs.org/@waylaidwanderer/chatgpt-api/-/chatgpt-api-1.34.0.tgz",
"integrity": "sha512-DPquhkZucw31xpv7LQC18koG/C6OtSPi0+tBsdeqE4sbt4CcKKauAWk2COWaVRR1VyX8m8Y5K+2/Bkgk2xr2HQ==",
"dependencies": {
"@dqbd/tiktoken": "^1.0.2",
"@fastify/cors": "^8.2.0",
@ -7046,9 +7046,9 @@
}
},
"@waylaidwanderer/chatgpt-api": {
"version": "1.33.2",
"resolved": "https://registry.npmjs.org/@waylaidwanderer/chatgpt-api/-/chatgpt-api-1.33.2.tgz",
"integrity": "sha512-8CJLln0yaxLGWs21C31OADdAUnSGEDrIqnuPmzRF30/NQGjOWPeHdh00slVqqSNWSGWx5zhCwc9Gt7TSQJYB5Q==",
"version": "1.34.0",
"resolved": "https://registry.npmjs.org/@waylaidwanderer/chatgpt-api/-/chatgpt-api-1.34.0.tgz",
"integrity": "sha512-DPquhkZucw31xpv7LQC18koG/C6OtSPi0+tBsdeqE4sbt4CcKKauAWk2COWaVRR1VyX8m8Y5K+2/Bkgk2xr2HQ==",
"requires": {
"@dqbd/tiktoken": "^1.0.2",
"@fastify/cors": "^8.2.0",

View file

@ -21,7 +21,7 @@
"dependencies": {
"@dqbd/tiktoken": "^1.0.2",
"@keyv/mongo": "^2.1.8",
"@waylaidwanderer/chatgpt-api": "^1.33.2",
"@waylaidwanderer/chatgpt-api": "^1.34.0",
"axios": "^1.3.4",
"cors": "^2.8.5",
"crypto": "^1.0.1",

View file

@ -154,7 +154,8 @@ const ask = async ({
res.end();
if (userParentMessageId == '00000000-0000-0000-0000-000000000000') {
const title = await titleConvo({ endpoint: endpointOption?.endpoint, text, response: responseMessage });
// const title = await titleConvo({ endpoint: endpointOption?.endpoint, text, response: responseMessage });
const title = await response.details.title;
await updateConvo(req?.session?.user?.username, {
conversationId: conversationId,
title