From c4d89b2067be362e6ad0085e7d3a1b54d36a257b Mon Sep 17 00:00:00 2001 From: Nikolas Brown Date: Sun, 1 Jun 2025 08:04:16 -0400 Subject: [PATCH] Gemini inline video (#4078) * Add inline video attachment support for Gemini 2.5 Pro * file formatting * removed redundant function for saving video to message * removed other redundant function for saving video to message * Seperate inlining check for video * Edit video token cost to be a conservative estimate of 10000 tokens * fixed missing semicolon * Adds seperate ui toggle for video inlining. * Move mes_video out of img_container * Remove title from video element for now * Better visibilty of video with controls --------- Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com> --- public/index.html | 14 +++++++ public/script.js | 25 ++++++++++++ public/scripts/chats.js | 8 +++- public/scripts/openai.js | 82 +++++++++++++++++++++++++++++++++++++++- public/style.css | 18 +++++++++ src/endpoints/images.js | 2 +- src/prompt-converters.js | 13 +++++++ 7 files changed, 159 insertions(+), 3 deletions(-) diff --git a/public/index.html b/public/index.html index 40d96cf0c..6d04ef466 100644 --- a/public/index.html +++ b/public/index.html @@ -2019,6 +2019,20 @@ +
+ +
+ Sends videos in prompts if the model supports it. Use the + + action on any message or the + + menu to attach a video file to the chat. + Videos must be less than 20 MB and under 1 minute long +
+