Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -32,9 +32,9 @@ def send_message_with_file(
|
|
32 |
filename=filename,
|
33 |
)
|
34 |
if response.get("ok"):
|
35 |
-
print("Message with
|
36 |
else:
|
37 |
-
print("Failed to send message with
|
38 |
|
39 |
except SlackApiError as e:
|
40 |
# Handle Slack-specific errors
|
@@ -191,8 +191,8 @@ def process_clip(prompt, frames, chatbot, id):
|
|
191 |
chatbot.append(((video_clip_path,), None))
|
192 |
chatbot.append((f"ID: {id}. Time: {start_time}\nDetails: {response_details}", None))
|
193 |
|
194 |
-
message_title = "An event for your query has been recorded!"
|
195 |
-
send_message_with_file(
|
196 |
|
197 |
frame_paths = []
|
198 |
for i, base64_frame in enumerate(base64Frames):
|
|
|
32 |
filename=filename,
|
33 |
)
|
34 |
if response.get("ok"):
|
35 |
+
print("Message with file sent successfully!")
|
36 |
else:
|
37 |
+
print("Failed to send message with file:", response)
|
38 |
|
39 |
except SlackApiError as e:
|
40 |
# Handle Slack-specific errors
|
|
|
191 |
chatbot.append(((video_clip_path,), None))
|
192 |
chatbot.append((f"ID: {id}. Time: {start_time}\nDetails: {response_details}", None))
|
193 |
|
194 |
+
message_title = f":warning: An event for your query has been recorded! \nQuery: '{prompt}' \nEvent: '{response_details}'"
|
195 |
+
send_message_with_file("Event video file", "conntour_event.mp4", response_details, video_clip_path)
|
196 |
|
197 |
frame_paths = []
|
198 |
for i, base64_frame in enumerate(base64Frames):
|