Skip to content

Commit 3ecd762

Browse files
committed
[AI] Adjust sendVideoRealtime kdoc
The doc must accurately describe that the expected data is a video *frame* rather than actual video data. Description is aligned to the iOS description from firebase/firebase-ios-sdk#15432
1 parent 089f0a1 commit 3ecd762

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

firebase-ai/src/main/kotlin/com/google/firebase/ai/type/LiveSession.kt

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -305,10 +305,16 @@ internal constructor(
305305
}
306306

307307
/**
308-
* Sends a video input stream to the model, using the realtime API.
308+
* Sends a video frame to the model, using the realtime API.
309309
*
310-
* @param video Encoded video data, used to update the model on the client's conversation. The
311-
* MIME type can be a video format (e.g., `video/webm`) or an image format (e.g., `image/jpeg`).
310+
* Instead of raw video data, the model expects individual frames of the video, sent as images.
311+
*
312+
* For better performance, frames can also be sent at a lower rate than the video; even as low as
313+
* 1 frame per second.
314+
*
315+
* @param inlineData Encoded image data extracted from a frame of the video, used to update the
316+
* model on the client's conversation, with the corresponding IANA standard MIME type of the video
317+
* frame data (e.g., `image/png`, `image/jpeg`, etc.).
312318
*/
313319
public suspend fun sendVideoRealtime(video: InlineData) {
314320
FirebaseAIException.catchAsync {

0 commit comments

Comments
 (0)