adjust command further

This commit is contained in:
derpystuff 2023-12-13 22:23:09 +01:00
parent 7d8ad07009
commit 30f00fdbfa

View file

@ -15,8 +15,8 @@ module.exports = {
label: 'text', label: 'text',
aliases: ['gv'], aliases: ['gv'],
metadata: { metadata: {
description: 'Gemini Vision.', description: 'Run Gemini Vision on an Image with a custom prompt.',
description_short: 'Pride overlay', description_short: 'Run Gemini Vision ',
examples: ['gv Which show is this image from?'], examples: ['gv Which show is this image from?'],
category: 'limited', category: 'limited',
usage: 'gemini-vision <attachment> <prompt>' usage: 'gemini-vision <attachment> <prompt>'
@ -27,7 +27,8 @@ module.exports = {
if(!canUseLimitedTestCommands(context)) return; if(!canUseLimitedTestCommands(context)) return;
context.triggerTyping(); context.triggerTyping();
let image = await getRecentImage(context, 2) // for the sake of privacy, make the context window one message
let image = await getRecentImage(context, 1)
if (!image) return editOrReply(context, createEmbed("warning", context, "No images found. Reply if you want a specific image.")) if (!image) return editOrReply(context, createEmbed("warning", context, "No images found. Reply if you want a specific image."))
if(!args.text) return editOrReply(context, createEmbed("warning", context, `Missing Parameter (text).`)) if(!args.text) return editOrReply(context, createEmbed("warning", context, `Missing Parameter (text).`))