broke out redis to redis subdirectory
Some checks failed
Builds / Discord-Node-Build (push) Has been cancelled
Builds / Discord-Ollama-Container-Build (push) Has been cancelled
Coverage / Discord-Node-Coverage (push) Has been cancelled

This commit is contained in:
2025-05-19 22:08:24 -04:00
parent bc7c3b55d8
commit 26a1f4d554
5 changed files with 90 additions and 28 deletions

View File

@@ -36,10 +36,10 @@ export default event(Events.MessageCreate, async ({ log, msgHist, ollama, client
// Do not respond if bot talks in the chat
if (message.author.id === clientId) return
// Check if message mentions the bot or passes random chance (10%)
// Check if message mentions the bot or passes random chance (30%)
const isMentioned = message.mentions.has(clientId)
const isCommand = message.content.startsWith('/')
const randomChance = Math.random() < 0.1 // 10% chance
const randomChance = Math.random() < 0.30 // 30% chance
if (!isMentioned && (isCommand || !randomChance)) return
// Log response trigger