From bca83f2278a022646730acf617a9c0e2fbdfca98 Mon Sep 17 00:00:00 2001 From: David Motsonashvili Date: Tue, 19 Dec 2023 11:07:17 -0800 Subject: [PATCH] typo --- .../java/com/google/ai/client/generativeai/Chat.kt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/generativeai/src/main/java/com/google/ai/client/generativeai/Chat.kt b/generativeai/src/main/java/com/google/ai/client/generativeai/Chat.kt index 805c6e6c..004fba94 100644 --- a/generativeai/src/main/java/com/google/ai/client/generativeai/Chat.kt +++ b/generativeai/src/main/java/com/google/ai/client/generativeai/Chat.kt @@ -48,7 +48,7 @@ class Chat(private val model: GenerativeModel, val history: MutableList * * @param prompt A [Content] to send to the model. * @throws InvalidStateException if the prompt is not coming from the 'user' role - * @throws InvalidStateException if the [Chat] instance has a active, outgoing request + * @throws InvalidStateException if the [Chat] instance has an active request. */ suspend fun sendMessage(prompt: Content): GenerateContentResponse { prompt.assertComesFromUser() @@ -67,7 +67,7 @@ class Chat(private val model: GenerativeModel, val history: MutableList * Generates a response from the backend with the provided text represented [Content]. * * @param prompt The text to be converted into a single piece of [Content] to send to the model. - * @throws InvalidStateException if the [Chat] instance has a active, outgoing request + * @throws InvalidStateException if the [Chat] instance has an active request. */ suspend fun sendMessage(prompt: String): GenerateContentResponse { val content = content("user") { text(prompt) } @@ -78,7 +78,7 @@ class Chat(private val model: GenerativeModel, val history: MutableList * Generates a response from the backend with the provided image represented [Content]. * * @param prompt The image to be converted into a single piece of [Content] to send to the model. - * @throws InvalidStateException if the [Chat] instance has a active, outgoing request + * @throws InvalidStateException if the [Chat] instance has an active request. */ suspend fun sendMessage(prompt: Bitmap): GenerateContentResponse { val content = content("user") { image(prompt) } @@ -91,7 +91,7 @@ class Chat(private val model: GenerativeModel, val history: MutableList * @param prompt A [Content] to send to the model. * @return A [Flow] which will emit responses as they are returned from the model. * @throws InvalidStateException if the prompt is not coming from the 'user' role - * @throws InvalidStateException if the [Chat] instance has a active, outgoing request + * @throws InvalidStateException if the [Chat] instance has an active request. */ fun sendMessageStream(prompt: Content): Flow { prompt.assertComesFromUser() @@ -144,7 +144,7 @@ class Chat(private val model: GenerativeModel, val history: MutableList * * @param prompt A [Content] to send to the model. * @return A [Flow] which will emit responses as they are returned from the model. - * @throws InvalidStateException if the [Chat] instance has a active, outgoing request + * @throws InvalidStateException if the [Chat] instance has an active request. */ fun sendMessageStream(prompt: String): Flow { val content = content("user") { text(prompt) } @@ -156,7 +156,7 @@ class Chat(private val model: GenerativeModel, val history: MutableList * * @param prompt A [Content] to send to the model. * @return A [Flow] which will emit responses as they are returned from the model. - * @throws InvalidStateException if the [Chat] instance has a active, outgoing request + * @throws InvalidStateException if the [Chat] instance has an active request. */ fun sendMessageStream(prompt: Bitmap): Flow { val content = content("user") { image(prompt) }