mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-09-22 06:00:56 +02:00
feat: remove customGpts
This commit is contained in:
parent
5aa6b516ed
commit
8c2d577e60
16 changed files with 58 additions and 281 deletions
|
@ -1,82 +0,0 @@
|
||||||
const mongoose = require('mongoose');
|
|
||||||
|
|
||||||
const customGptSchema = mongoose.Schema({
|
|
||||||
chatGptLabel: {
|
|
||||||
type: String,
|
|
||||||
required: true
|
|
||||||
},
|
|
||||||
promptPrefix: {
|
|
||||||
type: String
|
|
||||||
},
|
|
||||||
value: {
|
|
||||||
type: String,
|
|
||||||
required: true
|
|
||||||
},
|
|
||||||
user: {
|
|
||||||
type: String
|
|
||||||
},
|
|
||||||
}, { timestamps: true });
|
|
||||||
|
|
||||||
const CustomGpt = mongoose.models.CustomGpt || mongoose.model('CustomGpt', customGptSchema);
|
|
||||||
|
|
||||||
const createCustomGpt = async ({ chatGptLabel, promptPrefix, value, user }) => {
|
|
||||||
try {
|
|
||||||
await CustomGpt.create({
|
|
||||||
chatGptLabel,
|
|
||||||
promptPrefix,
|
|
||||||
value,
|
|
||||||
user
|
|
||||||
});
|
|
||||||
return { chatGptLabel, promptPrefix, value };
|
|
||||||
} catch (error) {
|
|
||||||
console.error(error);
|
|
||||||
return { customGpt: 'Error saving customGpt' };
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
module.exports = {
|
|
||||||
getCustomGpts: async (user, filter) => {
|
|
||||||
try {
|
|
||||||
return await CustomGpt.find({ ...filter, user }).exec();
|
|
||||||
} catch (error) {
|
|
||||||
console.error(error);
|
|
||||||
return { customGpt: 'Error getting customGpts' };
|
|
||||||
}
|
|
||||||
},
|
|
||||||
updateCustomGpt: async (user, { value, ...update }) => {
|
|
||||||
try {
|
|
||||||
const customGpt = await CustomGpt.findOne({ value, user }).exec();
|
|
||||||
|
|
||||||
if (!customGpt) {
|
|
||||||
return await createCustomGpt({ value, ...update, user });
|
|
||||||
} else {
|
|
||||||
return await CustomGpt.findOneAndUpdate({ value, user }, update, {
|
|
||||||
new: true,
|
|
||||||
upsert: true
|
|
||||||
}).exec();
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
console.log(error);
|
|
||||||
return { message: 'Error updating customGpt' };
|
|
||||||
}
|
|
||||||
},
|
|
||||||
updateByLabel: async (user, { prevLabel, ...update }) => {
|
|
||||||
try {
|
|
||||||
return await CustomGpt.findOneAndUpdate({ chatGptLabel: prevLabel, user }, update, {
|
|
||||||
new: true,
|
|
||||||
upsert: true
|
|
||||||
}).exec();
|
|
||||||
} catch (error) {
|
|
||||||
console.log(error);
|
|
||||||
return { message: 'Error updating customGpt' };
|
|
||||||
}
|
|
||||||
},
|
|
||||||
deleteCustomGpts: async (user, filter) => {
|
|
||||||
try {
|
|
||||||
return await CustomGpt.deleteMany({ ...filter, user }).exec();
|
|
||||||
} catch (error) {
|
|
||||||
console.error(error);
|
|
||||||
return { customGpt: 'Error deleting customGpts' };
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
|
@ -1,5 +1,4 @@
|
||||||
const { getMessages, saveMessage, deleteMessagesSince, deleteMessages } = require('./Message');
|
const { getMessages, saveMessage, deleteMessagesSince, deleteMessages } = require('./Message');
|
||||||
const { getCustomGpts, updateCustomGpt, updateByLabel, deleteCustomGpts } = require('./CustomGpt');
|
|
||||||
const { getConvoTitle, getConvo, saveConvo, updateConvo } = require('./Conversation');
|
const { getConvoTitle, getConvo, saveConvo, updateConvo } = require('./Conversation');
|
||||||
const { getPreset, getPresets, savePreset, deletePresets } = require('./Preset');
|
const { getPreset, getPresets, savePreset, deletePresets } = require('./Preset');
|
||||||
|
|
||||||
|
@ -14,11 +13,6 @@ module.exports = {
|
||||||
saveConvo,
|
saveConvo,
|
||||||
updateConvo,
|
updateConvo,
|
||||||
|
|
||||||
getCustomGpts,
|
|
||||||
updateCustomGpt,
|
|
||||||
updateByLabel,
|
|
||||||
deleteCustomGpts,
|
|
||||||
|
|
||||||
getPreset,
|
getPreset,
|
||||||
getPresets,
|
getPresets,
|
||||||
savePreset,
|
savePreset,
|
||||||
|
|
|
@ -10,7 +10,6 @@ const errorController = require('./controllers/errorController');
|
||||||
|
|
||||||
const port = process.env.PORT || 3080;
|
const port = process.env.PORT || 3080;
|
||||||
const host = process.env.HOST || 'localhost';
|
const host = process.env.HOST || 'localhost';
|
||||||
const userSystemEnabled = process.env.ENABLE_USER_SYSTEM || false;
|
|
||||||
const projectPath = path.join(__dirname, '..', '..', 'client');
|
const projectPath = path.join(__dirname, '..', '..', 'client');
|
||||||
|
|
||||||
(async () => {
|
(async () => {
|
||||||
|
@ -34,6 +33,8 @@ const projectPath = path.join(__dirname, '..', '..', 'client');
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
|
// ROUTES
|
||||||
|
|
||||||
/* chore: potential redirect error here, can only comment out this block;
|
/* chore: potential redirect error here, can only comment out this block;
|
||||||
comment back in if using auth routes i guess */
|
comment back in if using auth routes i guess */
|
||||||
// app.get('/', routes.authenticatedOrRedirect, function (req, res) {
|
// app.get('/', routes.authenticatedOrRedirect, function (req, res) {
|
||||||
|
@ -41,40 +42,21 @@ const projectPath = path.join(__dirname, '..', '..', 'client');
|
||||||
// res.sendFile(path.join(projectPath, 'public', 'index.html'));
|
// res.sendFile(path.join(projectPath, 'public', 'index.html'));
|
||||||
// });
|
// });
|
||||||
|
|
||||||
app.get('/api/me', function (req, res) {
|
// api endpoint
|
||||||
if (userSystemEnabled) {
|
|
||||||
const user = req?.session?.user;
|
|
||||||
|
|
||||||
if (user) res.send(JSON.stringify({ username: user?.username, display: user?.display }));
|
|
||||||
else res.send(JSON.stringify(null));
|
|
||||||
} else {
|
|
||||||
res.send(JSON.stringify({ username: 'anonymous_user', display: 'Anonymous User' }));
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
app.use('/api/search', routes.authenticatedOr401, routes.search);
|
app.use('/api/search', routes.authenticatedOr401, routes.search);
|
||||||
app.use('/api/ask', routes.authenticatedOr401, routes.ask);
|
app.use('/api/ask', routes.authenticatedOr401, routes.ask);
|
||||||
app.use('/api/messages', routes.authenticatedOr401, routes.messages);
|
app.use('/api/messages', routes.authenticatedOr401, routes.messages);
|
||||||
app.use('/api/convos', routes.authenticatedOr401, routes.convos);
|
app.use('/api/convos', routes.authenticatedOr401, routes.convos);
|
||||||
app.use('/api/customGpts', routes.authenticatedOr401, routes.customGpts);
|
|
||||||
app.use('/api/presets', routes.authenticatedOr401, routes.presets);
|
app.use('/api/presets', routes.authenticatedOr401, routes.presets);
|
||||||
app.use('/api/prompts', routes.authenticatedOr401, routes.prompts);
|
app.use('/api/prompts', routes.authenticatedOr401, routes.prompts);
|
||||||
app.use('/api/tokenizer', routes.authenticatedOr401, routes.tokenizer);
|
app.use('/api/tokenizer', routes.authenticatedOr401, routes.tokenizer);
|
||||||
|
app.use('/api/endpoints', routes.authenticatedOr401, routes.endpoints);
|
||||||
|
|
||||||
|
// user system
|
||||||
app.use('/auth', routes.auth);
|
app.use('/auth', routes.auth);
|
||||||
|
app.use('/api/me', routes.me);
|
||||||
|
|
||||||
app.get('/api/endpoints', function (req, res) {
|
// static files
|
||||||
const azureOpenAI = !!process.env.AZURE_OPENAI_KEY;
|
|
||||||
const openAI = process.env.OPENAI_KEY
|
|
||||||
? { availableModels: ['gpt-4', 'text-davinci-003', 'gpt-3.5-turbo', 'gpt-3.5-turbo-0301'] }
|
|
||||||
: false;
|
|
||||||
const bingAI = !!process.env.BING_TOKEN;
|
|
||||||
const chatGPTBrowser = process.env.OPENAI_KEY
|
|
||||||
? { availableModels: ['Default (GPT-3.5)', 'Legacy (GPT-3.5)', 'GPT-4'] }
|
|
||||||
: false;
|
|
||||||
|
|
||||||
res.send(JSON.stringify({ azureOpenAI, openAI, bingAI, chatGPTBrowser }));
|
|
||||||
});
|
|
||||||
|
|
||||||
app.get('/*', routes.authenticatedOrRedirect, function (req, res) {
|
app.get('/*', routes.authenticatedOrRedirect, function (req, res) {
|
||||||
res.sendFile(path.join(projectPath, 'dist', 'index.html'));
|
res.sendFile(path.join(projectPath, 'dist', 'index.html'));
|
||||||
});
|
});
|
||||||
|
@ -89,7 +71,7 @@ const projectPath = path.join(__dirname, '..', '..', 'client');
|
||||||
})();
|
})();
|
||||||
|
|
||||||
let messageCount = 0;
|
let messageCount = 0;
|
||||||
process.on('uncaughtException', (err) => {
|
process.on('uncaughtException', err => {
|
||||||
if (!err.message.includes('fetch failed')) {
|
if (!err.message.includes('fetch failed')) {
|
||||||
console.error('There was an uncaught error:', err.message);
|
console.error('There was an uncaught error:', err.message);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
const express = require('express');
|
const express = require('express');
|
||||||
const crypto = require('crypto');
|
const crypto = require('crypto');
|
||||||
const router = express.Router();
|
const router = express.Router();
|
||||||
const { titleConvo, askBing } = require('../../app');
|
const { titleConvo, askBing } = require('../../../app');
|
||||||
const { saveMessage, getConvoTitle, saveConvo, getConvo } = require('../../models');
|
const { saveMessage, getConvoTitle, saveConvo, getConvo } = require('../../../models');
|
||||||
const { handleError, sendMessage, createOnProgress, handleText } = require('./handlers');
|
const { handleError, sendMessage, createOnProgress, handleText } = require('./handlers');
|
||||||
|
|
||||||
router.post('/', async (req, res) => {
|
router.post('/', async (req, res) => {
|
|
@ -1,8 +1,8 @@
|
||||||
const express = require('express');
|
const express = require('express');
|
||||||
const crypto = require('crypto');
|
const crypto = require('crypto');
|
||||||
const router = express.Router();
|
const router = express.Router();
|
||||||
const { titleConvo, browserClient } = require('../../app/');
|
const { titleConvo, browserClient } = require('../../../app/');
|
||||||
const { saveMessage, getConvoTitle, saveConvo, updateConvo, getConvo } = require('../../models');
|
const { saveMessage, getConvoTitle, saveConvo, updateConvo, getConvo } = require('../../../models');
|
||||||
const { handleError, sendMessage, createOnProgress, handleText } = require('./handlers');
|
const { handleError, sendMessage, createOnProgress, handleText } = require('./handlers');
|
||||||
|
|
||||||
router.post('/', async (req, res) => {
|
router.post('/', async (req, res) => {
|
|
@ -1,8 +1,8 @@
|
||||||
const express = require('express');
|
const express = require('express');
|
||||||
const crypto = require('crypto');
|
const crypto = require('crypto');
|
||||||
const router = express.Router();
|
const router = express.Router();
|
||||||
const { titleConvo, askClient } = require('../../app/');
|
const { titleConvo, askClient } = require('../../../app/');
|
||||||
const { saveMessage, getConvoTitle, saveConvo, updateConvo, getConvo } = require('../../models');
|
const { saveMessage, getConvoTitle, saveConvo, updateConvo, getConvo } = require('../../../models');
|
||||||
const { handleError, sendMessage, createOnProgress, handleText } = require('./handlers');
|
const { handleError, sendMessage, createOnProgress, handleText } = require('./handlers');
|
||||||
|
|
||||||
router.post('/', async (req, res) => {
|
router.post('/', async (req, res) => {
|
|
@ -3,7 +3,7 @@ const citationRegex = /\[\^\d+?\^]/g;
|
||||||
const backtick = /(?<!`)[`](?!`)/g;
|
const backtick = /(?<!`)[`](?!`)/g;
|
||||||
// const singleBacktick = /(?<!`)[`](?!`)/;
|
// const singleBacktick = /(?<!`)[`](?!`)/;
|
||||||
const cursorDefault = '<span className="result-streaming">█</span>';
|
const cursorDefault = '<span className="result-streaming">█</span>';
|
||||||
const { getCitations, citeText } = require('../../app/');
|
const { getCitations, citeText } = require('../../../app');
|
||||||
|
|
||||||
const handleError = (res, message) => {
|
const handleError = (res, message) => {
|
||||||
res.write(`event: error\ndata: ${JSON.stringify(message)}\n\n`);
|
res.write(`event: error\ndata: ${JSON.stringify(message)}\n\n`);
|
|
@ -1,67 +0,0 @@
|
||||||
const express = require('express');
|
|
||||||
const router = express.Router();
|
|
||||||
const {
|
|
||||||
getCustomGpts,
|
|
||||||
updateCustomGpt,
|
|
||||||
updateByLabel,
|
|
||||||
deleteCustomGpts
|
|
||||||
} = require('../../models');
|
|
||||||
|
|
||||||
router.get('/', async (req, res) => {
|
|
||||||
const models = (await getCustomGpts(req?.session?.user?.username)).map((model) => {
|
|
||||||
model = model.toObject();
|
|
||||||
model._id = model._id.toString();
|
|
||||||
return model;
|
|
||||||
});
|
|
||||||
res.status(200).send(models);
|
|
||||||
});
|
|
||||||
|
|
||||||
router.post('/delete', async (req, res) => {
|
|
||||||
const { arg } = req.body;
|
|
||||||
|
|
||||||
try {
|
|
||||||
await deleteCustomGpts(req?.session?.user?.username, arg);
|
|
||||||
const models = (await getCustomGpts(req?.session?.user?.username)).map((model) => {
|
|
||||||
model = model.toObject();
|
|
||||||
model._id = model._id.toString();
|
|
||||||
return model;
|
|
||||||
});
|
|
||||||
res.status(201).send(models);
|
|
||||||
// res.status(201).send(dbResponse);
|
|
||||||
} catch (error) {
|
|
||||||
console.error(error);
|
|
||||||
res.status(500).send(error);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
// router.post('/create', async (req, res) => {
|
|
||||||
// const payload = req.body.arg;
|
|
||||||
|
|
||||||
// try {
|
|
||||||
// const dbResponse = await createCustomGpt(payload);
|
|
||||||
// res.status(201).send(dbResponse);
|
|
||||||
// } catch (error) {
|
|
||||||
// console.error(error);
|
|
||||||
// res.status(500).send(error);
|
|
||||||
// }
|
|
||||||
// });
|
|
||||||
|
|
||||||
router.post('/', async (req, res) => {
|
|
||||||
const update = req.body.arg;
|
|
||||||
|
|
||||||
let setter = updateCustomGpt;
|
|
||||||
|
|
||||||
if (update.prevLabel) {
|
|
||||||
setter = updateByLabel;
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
|
||||||
const dbResponse = await setter(req?.session?.user?.username, update);
|
|
||||||
res.status(201).send(dbResponse);
|
|
||||||
} catch (error) {
|
|
||||||
console.error(error);
|
|
||||||
res.status(500).send(error);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
module.exports = router;
|
|
17
api/server/routes/endpoints.js
Normal file
17
api/server/routes/endpoints.js
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
const express = require('express');
|
||||||
|
const router = express.Router();
|
||||||
|
|
||||||
|
router.get('/', function (req, res) {
|
||||||
|
const azureOpenAI = !!process.env.AZURE_OPENAI_KEY;
|
||||||
|
const openAI = process.env.OPENAI_KEY
|
||||||
|
? { availableModels: ['gpt-4', 'text-davinci-003', 'gpt-3.5-turbo', 'gpt-3.5-turbo-0301'] }
|
||||||
|
: false;
|
||||||
|
const bingAI = !!process.env.BING_TOKEN;
|
||||||
|
const chatGPTBrowser = process.env.OPENAI_KEY
|
||||||
|
? { availableModels: ['Default (GPT-3.5)', 'Legacy (GPT-3.5)', 'GPT-4'] }
|
||||||
|
: false;
|
||||||
|
|
||||||
|
res.send(JSON.stringify({ azureOpenAI, openAI, bingAI, chatGPTBrowser }));
|
||||||
|
});
|
||||||
|
|
||||||
|
module.exports = router;
|
|
@ -2,10 +2,11 @@ const ask = require('./ask');
|
||||||
const messages = require('./messages');
|
const messages = require('./messages');
|
||||||
const convos = require('./convos');
|
const convos = require('./convos');
|
||||||
const presets = require('./presets');
|
const presets = require('./presets');
|
||||||
const customGpts = require('./customGpts');
|
|
||||||
const prompts = require('./prompts');
|
const prompts = require('./prompts');
|
||||||
const search = require('./search');
|
const search = require('./search');
|
||||||
const tokenizer = require('./tokenizer');
|
const tokenizer = require('./tokenizer');
|
||||||
|
const me = require('./me');
|
||||||
|
const endpoints = require('./endpoints');
|
||||||
const { router: auth, authenticatedOr401, authenticatedOrRedirect } = require('./auth');
|
const { router: auth, authenticatedOr401, authenticatedOrRedirect } = require('./auth');
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
|
@ -14,10 +15,11 @@ module.exports = {
|
||||||
messages,
|
messages,
|
||||||
convos,
|
convos,
|
||||||
presets,
|
presets,
|
||||||
customGpts,
|
|
||||||
prompts,
|
prompts,
|
||||||
auth,
|
auth,
|
||||||
tokenizer,
|
tokenizer,
|
||||||
|
me,
|
||||||
|
endpoints,
|
||||||
authenticatedOr401,
|
authenticatedOr401,
|
||||||
authenticatedOrRedirect
|
authenticatedOrRedirect
|
||||||
};
|
};
|
||||||
|
|
16
api/server/routes/me.js
Normal file
16
api/server/routes/me.js
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
const express = require('express');
|
||||||
|
const router = express.Router();
|
||||||
|
const userSystemEnabled = !!process.env.ENABLE_USER_SYSTEM || false;
|
||||||
|
|
||||||
|
router.get('/', function (req, res) {
|
||||||
|
if (userSystemEnabled) {
|
||||||
|
const user = req?.session?.user;
|
||||||
|
|
||||||
|
if (user) res.send(JSON.stringify({ username: user?.username, display: user?.display }));
|
||||||
|
else res.send(JSON.stringify(null));
|
||||||
|
} else {
|
||||||
|
res.send(JSON.stringify({ username: 'anonymous_user', display: 'Anonymous User' }));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
module.exports = router;
|
|
@ -1,6 +1,5 @@
|
||||||
import conversation from './conversation';
|
import conversation from './conversation';
|
||||||
import conversations from './conversations';
|
import conversations from './conversations';
|
||||||
import models from './models';
|
|
||||||
import endpoints from './endpoints';
|
import endpoints from './endpoints';
|
||||||
import user from './user';
|
import user from './user';
|
||||||
import text from './text';
|
import text from './text';
|
||||||
|
@ -11,10 +10,9 @@ import preset from './preset';
|
||||||
export default {
|
export default {
|
||||||
...conversation,
|
...conversation,
|
||||||
...conversations,
|
...conversations,
|
||||||
...models,
|
|
||||||
...endpoints,
|
...endpoints,
|
||||||
...user,
|
...user,
|
||||||
text,
|
...text,
|
||||||
...submission,
|
...submission,
|
||||||
...search,
|
...search,
|
||||||
...preset
|
...preset
|
||||||
|
|
|
@ -1,80 +0,0 @@
|
||||||
import React from "react";
|
|
||||||
import {
|
|
||||||
RecoilRoot,
|
|
||||||
atom,
|
|
||||||
selector,
|
|
||||||
useRecoilState,
|
|
||||||
useRecoilValue,
|
|
||||||
} from "recoil";
|
|
||||||
|
|
||||||
const customGPTModels = atom({
|
|
||||||
key: "customGPTModels",
|
|
||||||
default: [],
|
|
||||||
});
|
|
||||||
|
|
||||||
const models = selector({
|
|
||||||
key: "models",
|
|
||||||
get: ({ get }) => {
|
|
||||||
return [
|
|
||||||
{
|
|
||||||
_id: "0",
|
|
||||||
name: "ChatGPT",
|
|
||||||
value: "chatgpt",
|
|
||||||
model: "chatgpt",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
_id: "1",
|
|
||||||
name: "CustomGPT",
|
|
||||||
value: "chatgptCustom",
|
|
||||||
model: "chatgptCustom",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
_id: "2",
|
|
||||||
name: "BingAI",
|
|
||||||
value: "bingai",
|
|
||||||
model: "bingai",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
_id: "3",
|
|
||||||
name: "Sydney",
|
|
||||||
value: "sydney",
|
|
||||||
model: "sydney",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
_id: "4",
|
|
||||||
name: "ChatGPT",
|
|
||||||
value: "chatgptBrowser",
|
|
||||||
model: "chatgptBrowser",
|
|
||||||
},
|
|
||||||
...get(customGPTModels),
|
|
||||||
];
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
const modelsFilter = atom({
|
|
||||||
key: "modelsFilter",
|
|
||||||
default: {
|
|
||||||
chatgpt: false,
|
|
||||||
chatgptCustom: false,
|
|
||||||
bingai: false,
|
|
||||||
sydney: false,
|
|
||||||
chatgptBrowser: false,
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
const availableModels = selector({
|
|
||||||
key: "availableModels",
|
|
||||||
get: ({ get }) => {
|
|
||||||
const m = get(models);
|
|
||||||
const f = get(modelsFilter);
|
|
||||||
return m.filter(({ model }) => f[model]);
|
|
||||||
},
|
|
||||||
});
|
|
||||||
// const modelAvailable
|
|
||||||
|
|
||||||
export default {
|
|
||||||
customGPTModels,
|
|
||||||
models,
|
|
||||||
modelsFilter,
|
|
||||||
availableModels,
|
|
||||||
};
|
|
|
@ -1,5 +1,4 @@
|
||||||
import endpoints from './endpoints';
|
import { atom } from 'recoil';
|
||||||
import { atom, selector, useSetRecoilState, useResetRecoilState, useRecoilCallback } from 'recoil';
|
|
||||||
|
|
||||||
// preset structure is as same defination as conversation
|
// preset structure is as same defination as conversation
|
||||||
// sample structure
|
// sample structure
|
||||||
|
@ -20,11 +19,9 @@ import { atom, selector, useSetRecoilState, useResetRecoilState, useRecoilCallba
|
||||||
// frequency_penalty: 0,
|
// frequency_penalty: 0,
|
||||||
// // for bingAI only
|
// // for bingAI only
|
||||||
// jailbreak: false,
|
// jailbreak: false,
|
||||||
// jailbreakConversationId: null,
|
|
||||||
// conversationSignature: null,
|
|
||||||
// clientId: null,
|
|
||||||
// invocationId: 1,
|
|
||||||
// toneStyle: null,
|
// toneStyle: null,
|
||||||
|
// context: null,
|
||||||
|
// systemMessage: null,
|
||||||
// };
|
// };
|
||||||
|
|
||||||
// an array of saved presets.
|
// an array of saved presets.
|
||||||
|
|
|
@ -5,4 +5,4 @@ const text = atom({
|
||||||
default: ''
|
default: ''
|
||||||
});
|
});
|
||||||
|
|
||||||
export default text;
|
export default { text };
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue