Araeynn commited on
Commit
d99e3cf
·
verified ·
1 Parent(s): 4d7eb22

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -8
app.py CHANGED
@@ -174,14 +174,7 @@ async def on_message(message: discord.Message):
174
  if message.author == client.user:
175
  return
176
  ats = []
177
- if len(message.attachments) > 0:
178
- for i in message.attachments:
179
- print(i)
180
- print(await i.read())
181
- Image.open(io.BytesIO(await i.read())).save("image.png")
182
- ats.append(f"ImageInput:{caption('image.png')}")
183
- print(caption("image.png"))
184
- s = f"GPT4 Correct {message.author}: {message.content} Attachments: {' '.join(ats)}<|end_of_turn|>"
185
  try:
186
  with open(os.path.join(guild_name, f"{msgchannel_name}.txt"), "a") as f:
187
  f.write(s)
 
174
  if message.author == client.user:
175
  return
176
  ats = []
177
+ s = f"GPT4 Correct {message.author}: {message.content}<|end_of_turn|>"
 
 
 
 
 
 
 
178
  try:
179
  with open(os.path.join(guild_name, f"{msgchannel_name}.txt"), "a") as f:
180
  f.write(s)