Feat: quickstart video-analysis sample feature - #1083
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces a new video analysis feature using the Gemini API, allowing users to upload videos and receive analysis results via standard or streaming responses. The reviewer feedback points out critical issues with invalid model names (gemini-3.5-flash and gemini-3.7-flash) that would cause runtime failures, recommending valid alternatives like gemini-1.5-flash. Additionally, an improvement is suggested to use onload instead of onloadend in the FileReader logic to avoid redundant promise rejections.
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
…start-js into feat/video-anaylsis-final
hsubox76
left a comment
There was a problem hiding this comment.
It looks like this still needs to be plugged into the app - imported into index.tsx and App.tsx and inserted into the navigation, added to the isolatedFeature switch, etc., and added to the README. (Also I think automatic function calling needs to be added to the README).
I added it to isolatedFeature and tested it so it works and the code looks good, but it just needs to be plugged in.
| resolve({ | ||
| inlineData: { | ||
| data: base64Data, | ||
| mimeType: file.type || 'video/mp4', |
There was a problem hiding this comment.
Why is the fallback video/mp4? If there's no file.type isn't something wrong? Or do mp4s sometimes not have a file type?
| npm run dev:function # Function Calling | ||
| npm run dev:auto-function # Automatic Function Calling | ||
| npm run dev:image # Image Generation | ||
| npm run dev:video # Video Analysis |
There was a problem hiding this comment.
I think package.json needs to be updated to include this script?
Feature sample for analyzing videos: https://firebase.google.com/docs/ai-logic/analyze-video?api=dev