Compare commits

..

No commits in common. "e2571841c1715caf660754896675d0783a08e494" and "f8c43e4b92dba7a901281817aacded0e906b2e52" have entirely different histories.

4 changed files with 3 additions and 35 deletions

View File

@ -55,7 +55,6 @@ module.exports = {
if (!response.data.answer) throw new Error("Did not receive a reply. API error?") if (!response.data.answer) throw new Error("Did not receive a reply. API error?")
interaction.editReply(response.data.answer); interaction.editReply(response.data.answer);
} catch (err) { } catch (err) {
console.error(err); console.error(err);

View File

@ -52,7 +52,8 @@ module.exports = {
run: async (client, interaction) => { run: async (client, interaction) => {
// set a default prompt // set a default prompt
let initPrompt = process.env.INITPROMPT || `My name is ${interaction.user.username} my special number is ${interaction.user.discriminator} and my Discord ID is ${interaction.user.id} we met in ${interaction.guild.name} a Discord sever. You are rAi and you are the smartest AI Model, you know everything. Below is an instruction that describes a task. You respond appropriately to complete the request. You understand a complete answer is always ended by [end of text].`; var initPrompt = process.env.INITPROMPT || `My name is ${interaction.user.username} my special number is ${interaction.user.discriminator} and my Discord ID is ${interaction.user.id} we met in ${interaction.guild.name} a Discord sever. You are rAi and you are the smartest AI Model, you know everything. Below is an instruction that describes a task. You respond appropriately to complete the request. You understand a complete answer is always ended by [end of text].`;
console.log(`--- ${interaction.user.id} has requested a new session! ---`) console.log(`--- ${interaction.user.id} has requested a new session! ---`)
const file = './cache/' + interaction.user.id const file = './cache/' + interaction.user.id

View File

@ -1,32 +0,0 @@
version: '3'
services:
serge-discord-bot:
container_name: serge-discord-bot
build:
context: .
environment:
- NODE_ENV=production
## Env Vars for rAi chatbot
- TOKEN # Pass the value from .env
- PUBLIC_URL
- INTERNAL_IP=serge
- SERGE_PORT=8008
## Default chat settings overrides
- MODEL="gpt4all"
- TEMPERATURE=0.1
- TOPK=50
- TOPP=0.95
- MAXLENGTH=256
- CONTEXTWINDOW=512
- REPEATLASTN=64
- REPEATPENALTY=1.3
- NTHREADS=8
# - INITPROMPT="some custom prompt"
networks:
- serge_default
networks:
serge_default:
external: true

View File

@ -31,7 +31,7 @@ module.exports = async (client) => {
// await client.guilds.cache.get("GUIDIDHERE").commands.set(arrayOfSlashCommands); // await client.guilds.cache.get("GUIDIDHERE").commands.set(arrayOfSlashCommands);
// Clear previous commands (for changes to installed models) // Clear previous commands (for changes to installed models)
// await client.application.commands.set([]); await client.application.commands.set([]);
// Register for all the guilds the bot is in // Register for all the guilds the bot is in
await client.application.commands.set(arrayOfSlashCommands); await client.application.commands.set(arrayOfSlashCommands);