-
Notifications
You must be signed in to change notification settings - Fork 635
Add support for token-based usage metrics #6658
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Token measurement is broken down by modaliy, with separate counters for image, audio, etc. Tests are in version 6.*, so this change also includes bumping update_responses.sh
Javadoc Changes:--- /home/runner/diff/original/firebase-kotlindoc/android/client/firebase-vertexai/_toc.yaml 2025-02-08 03:34:27.321393953 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/android/client/firebase-vertexai/_toc.yaml 2025-02-08 03:32:21.411957472 +0000
@@ -54,6 +54,8 @@
path: "/docs/reference/android/com/google/firebase/vertexai/type/Content.Builder.html"
- title: "ContentKt"
path: "/docs/reference/android/com/google/firebase/vertexai/type/ContentKt.html"
+ - title: "ContentModality"
+ path: "/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html"
- title: "CountTokensResponse"
path: "/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html"
- title: "FileDataPart"
@@ -90,6 +92,8 @@
path: "/docs/reference/android/com/google/firebase/vertexai/type/ImagePart.html"
- title: "InlineDataPart"
path: "/docs/reference/android/com/google/firebase/vertexai/type/InlineDataPart.html"
+ - title: "ModalityTokenCount"
+ path: "/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html"
- title: "PartKt"
path: "/docs/reference/android/com/google/firebase/vertexai/type/PartKt.html"
- title: "PromptFeedback" --- /home/runner/diff/original/firebase-kotlindoc/android/com/google/firebase/vertexai/type/ContentModality.Companion.html 1970-01-01 00:00:00.000000000 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/android/com/google/firebase/vertexai/type/ContentModality.Companion.html 2025-02-08 03:32:21.417957496 +0000
@@ -0,0 +1,16 @@
+<html devsite="true">
+ <head>
+ <title>ContentModality.Companion</title>
+{% setvar book_path %}/_book.yaml{% endsetvar %}
+{% include "docs/reference/android/_reference-head-tags.html" %}
+ </head>
+ <body>
+ <div id="metadata-info-block"></div>
+ <h1>ContentModality.Companion</h1>
+ <p>
+ <pre>public static class <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html">ContentModality.Companion</a></pre>
+ </p>
+ <hr>
+ </body>
+</html>
+ --- /home/runner/diff/original/firebase-kotlindoc/android/com/google/firebase/vertexai/type/ContentModality.html 1970-01-01 00:00:00.000000000 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/android/com/google/firebase/vertexai/type/ContentModality.html 2025-02-08 03:32:21.417957496 +0000
@@ -0,0 +1,138 @@
+<html devsite="true">
+ <head>
+ <title>ContentModality</title>
+{% setvar book_path %}/_book.yaml{% endsetvar %}
+{% include "docs/reference/android/_reference-head-tags.html" %}
+ </head>
+ <body>
+ <div id="metadata-info-block"></div>
+ <h1>ContentModality</h1>
+ <p>
+ <pre>public final class <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ </p>
+ <hr>
+ <p>Content part modality.</p>
+ <h2>Summary</h2>
+ <div class="devsite-table-wrapper">
+ <table class="responsive">
+ <colgroup>
+ <col width="40%">
+ <col>
+ </colgroup>
+ <thead>
+ <tr>
+ <th colspan="100%"><h3>Nested types</h3></th>
+ </tr>
+ </thead>
+ <tbody class="list">
+ <tr>
+ <td>
+ <div><code>public static class <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html">ContentModality.Companion</a></code></div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ <div class="devsite-table-wrapper">
+ <table class="responsive">
+ <colgroup>
+ <col width="40%">
+ <col>
+ </colgroup>
+ <thead>
+ <tr>
+ <th colspan="100%"><h3>Public fields</h3></th>
+ </tr>
+ </thead>
+ <tbody class="list">
+ <tr>
+ <td><code>static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#AUDIO()">AUDIO</a></code></div>
+ <p>Audio.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code>static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#DOCUMENT()">DOCUMENT</a></code></div>
+ <p>Document, e.g.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code>static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#IMAGE()">IMAGE</a></code></div>
+ <p>Image.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code>static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#TEXT()">TEXT</a></code></div>
+ <p>Plain text.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code>static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#UNSPECIFIED()">UNSPECIFIED</a></code></div>
+ <p>Unspecified modality.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code>static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#VIDEO()">VIDEO</a></code></div>
+ <p>Video.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code>final int</code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html#ordinal()">ordinal</a></code></div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ <div class="list">
+ <h2>Public fields</h2>
+ <div class="api-item"><a name="getAUDIO()"></a><a name="setAUDIO()"></a><a name="getAUDIO--"></a><a name="setAUDIO--"></a>
+ <h3 class="api-name" id="AUDIO()">AUDIO</h3>
+ <pre class="api-signature no-pretty-print">public static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#AUDIO()">AUDIO</a></pre>
+ <p>Audio.</p>
+ </div>
+ <div class="api-item"><a name="getDOCUMENT()"></a><a name="setDOCUMENT()"></a><a name="getDOCUMENT--"></a><a name="setDOCUMENT--"></a>
+ <h3 class="api-name" id="DOCUMENT()">DOCUMENT</h3>
+ <pre class="api-signature no-pretty-print">public static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#DOCUMENT()">DOCUMENT</a></pre>
+ <p>Document, e.g. PDF.</p>
+ </div>
+ <div class="api-item"><a name="getIMAGE()"></a><a name="setIMAGE()"></a><a name="getIMAGE--"></a><a name="setIMAGE--"></a>
+ <h3 class="api-name" id="IMAGE()">IMAGE</h3>
+ <pre class="api-signature no-pretty-print">public static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#IMAGE()">IMAGE</a></pre>
+ <p>Image.</p>
+ </div>
+ <div class="api-item"><a name="getTEXT()"></a><a name="setTEXT()"></a><a name="getTEXT--"></a><a name="setTEXT--"></a>
+ <h3 class="api-name" id="TEXT()">TEXT</h3>
+ <pre class="api-signature no-pretty-print">public static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#TEXT()">TEXT</a></pre>
+ <p>Plain text.</p>
+ </div>
+ <div class="api-item"><a name="getUNSPECIFIED()"></a><a name="setUNSPECIFIED()"></a><a name="getUNSPECIFIED--"></a><a name="setUNSPECIFIED--"></a>
+ <h3 class="api-name" id="UNSPECIFIED()">UNSPECIFIED</h3>
+ <pre class="api-signature no-pretty-print">public static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#UNSPECIFIED()">UNSPECIFIED</a></pre>
+ <p>Unspecified modality.</p>
+ </div>
+ <div class="api-item"><a name="getVIDEO()"></a><a name="setVIDEO()"></a><a name="getVIDEO--"></a><a name="setVIDEO--"></a>
+ <h3 class="api-name" id="VIDEO()">VIDEO</h3>
+ <pre class="api-signature no-pretty-print">public static final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.Companion.html#VIDEO()">VIDEO</a></pre>
+ <p>Video.</p>
+ </div>
+ <div class="api-item"><a name="getOrdinal()"></a><a name="setOrdinal()"></a><a name="getOrdinal--"></a><a name="setOrdinal--"></a>
+ <h3 class="api-name" id="ordinal()">ordinal</h3>
+ <pre class="api-signature no-pretty-print">public final int <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html#ordinal()">ordinal</a></pre>
+ </div>
+ </div>
+ </body>
+</html>
+ --- /home/runner/diff/original/firebase-kotlindoc/android/com/google/firebase/vertexai/type/CountTokensResponse.html 2025-02-08 03:34:27.323393960 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/android/com/google/firebase/vertexai/type/CountTokensResponse.html 2025-02-08 03:32:21.414957484 +0000
@@ -27,6 +27,13 @@
</thead>
<tbody class="list">
<tr>
+ <td><code>final <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#promptTokensDetails()">promptTokensDetails</a></code></div>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </td>
+ </tr>
+ <tr>
<td><code>final <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a></code></td>
<td>
<div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#totalBillableCharacters()">totalBillableCharacters</a></code></div>
@@ -57,7 +64,7 @@
<tbody class="list">
<tr>
<td>
- <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#CountTokensResponse(kotlin.Int,kotlin.Int)">CountTokensResponse</a>(int totalTokens, <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> totalBillableCharacters)</code></div>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#CountTokensResponse(kotlin.Int,kotlin.Int,kotlin.collections.List)">CountTokensResponse</a>(<br> int totalTokens,<br> <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> totalBillableCharacters,<br> <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> promptTokensDetails<br>)</code></div>
</td>
</tr>
</tbody>
@@ -87,11 +94,22 @@
<div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#component2()">component2</a>()</code></div>
</td>
</tr>
+ <tr>
+ <td><code>final <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#component3()">component3</a>()</code></div>
+ </td>
+ </tr>
</tbody>
</table>
</div>
<div class="list">
<h2>Public fields</h2>
+ <div class="api-item"><a name="getPromptTokensDetails()"></a><a name="setPromptTokensDetails()"></a><a name="getPromptTokensDetails--"></a><a name="setPromptTokensDetails--"></a>
+ <h3 class="api-name" id="promptTokensDetails()">promptTokensDetails</h3>
+ <pre class="api-signature no-pretty-print">public final <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#promptTokensDetails()">promptTokensDetails</a></pre>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </div>
<div class="api-item"><a name="getTotalBillableCharacters()"></a><a name="setTotalBillableCharacters()"></a><a name="getTotalBillableCharacters--"></a><a name="setTotalBillableCharacters--"></a>
<h3 class="api-name" id="totalBillableCharacters()">totalBillableCharacters</h3>
<pre class="api-signature no-pretty-print">public final <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#totalBillableCharacters()">totalBillableCharacters</a></pre>
@@ -105,9 +123,9 @@
</div>
<div class="list">
<h2>Public constructors</h2>
- <div class="api-item"><a name="CountTokensResponse(kotlin.Int, kotlin.Int)"></a><a name="CountTokensResponse-kotlin.Int-kotlin.Int-"></a><a name="counttokensresponse"></a>
- <h3 class="api-name" id="CountTokensResponse(kotlin.Int,kotlin.Int)">CountTokensResponse</h3>
- <pre class="api-signature no-pretty-print">public <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#CountTokensResponse(kotlin.Int,kotlin.Int)">CountTokensResponse</a>(int totalTokens, <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> totalBillableCharacters)</pre>
+ <div class="api-item"><a name="CountTokensResponse(kotlin.Int, kotlin.Int, kotlin.collections.List)"></a><a name="CountTokensResponse-kotlin.Int-kotlin.Int-kotlin.collections.List-"></a><a name="counttokensresponse"></a>
+ <h3 class="api-name" id="CountTokensResponse(kotlin.Int,kotlin.Int,kotlin.collections.List)">CountTokensResponse</h3>
+ <pre class="api-signature no-pretty-print">public <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#CountTokensResponse(kotlin.Int,kotlin.Int,kotlin.collections.List)">CountTokensResponse</a>(<br> int totalTokens,<br> <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> totalBillableCharacters,<br> <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> promptTokensDetails<br>)</pre>
</div>
</div>
<div class="list">
@@ -120,6 +138,10 @@
<h3 class="api-name" id="component2()">component2</h3>
<pre class="api-signature no-pretty-print">public final <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#component2()">component2</a>()</pre>
</div>
+ <div class="api-item"><a name="component3--"></a><a name="component3"></a>
+ <h3 class="api-name" id="component3()">component3</h3>
+ <pre class="api-signature no-pretty-print">public final <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html#component3()">component3</a>()</pre>
+ </div>
</div>
</body>
</html> --- /home/runner/diff/original/firebase-kotlindoc/android/com/google/firebase/vertexai/type/ModalityTokenCount.html 1970-01-01 00:00:00.000000000 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/android/com/google/firebase/vertexai/type/ModalityTokenCount.html 2025-02-08 03:32:21.412957476 +0000
@@ -0,0 +1,98 @@
+<html devsite="true">
+ <head>
+ <title>ModalityTokenCount</title>
+{% setvar book_path %}/_book.yaml{% endsetvar %}
+{% include "docs/reference/android/_reference-head-tags.html" %}
+ </head>
+ <body>
+ <div id="metadata-info-block"></div>
+ <h1>ModalityTokenCount</h1>
+ <p>
+ <pre>public final class <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a></pre>
+ </p>
+ <hr>
+ <p>Represents token counting info for a single modality.</p>
+ <h2>Summary</h2>
+ <div class="devsite-table-wrapper">
+ <table class="responsive">
+ <colgroup>
+ <col width="40%">
+ <col>
+ </colgroup>
+ <thead>
+ <tr>
+ <th colspan="100%"><h3>Public fields</h3></th>
+ </tr>
+ </thead>
+ <tbody class="list">
+ <tr>
+ <td><code>final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html#modality()">modality</a></code></div>
+ <p>The modality associated with this token count.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code>final int</code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html#tokenCount()">tokenCount</a></code></div>
+ <p>The number of tokens counted.</p>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ <div class="devsite-table-wrapper">
+ <table class="responsive">
+ <colgroup>
+ <col width="40%">
+ <col>
+ </colgroup>
+ <thead>
+ <tr>
+ <th colspan="100%"><h3>Public methods</h3></th>
+ </tr>
+ </thead>
+ <tbody class="list">
+ <tr>
+ <td><code>final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html#component1()">component1</a>()</code></div>
+ </td>
+ </tr>
+ <tr>
+ <td><code>final int</code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html#component2()">component2</a>()</code></div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ <div class="list">
+ <h2>Public fields</h2>
+ <div class="api-item"><a name="getModality()"></a><a name="setModality()"></a><a name="getModality--"></a><a name="setModality--"></a>
+ <h3 class="api-name" id="modality()">modality</h3>
+ <pre class="api-signature no-pretty-print">public final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html#modality()">modality</a></pre>
+ <p>The modality associated with this token count.</p>
+ </div>
+ <div class="api-item"><a name="getTokenCount()"></a><a name="setTokenCount()"></a><a name="getTokenCount--"></a><a name="setTokenCount--"></a>
+ <h3 class="api-name" id="tokenCount()">tokenCount</h3>
+ <pre class="api-signature no-pretty-print">public final int <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html#tokenCount()">tokenCount</a></pre>
+ <p>The number of tokens counted.</p>
+ </div>
+ </div>
+ <div class="list">
+ <h2>Public methods</h2>
+ <div class="api-item"><a name="component1--"></a><a name="component1"></a>
+ <h3 class="api-name" id="component1()">component1</h3>
+ <pre class="api-signature no-pretty-print">public final @<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html#component1()">component1</a>()</pre>
+ </div>
+ <div class="api-item"><a name="component2--"></a><a name="component2"></a>
+ <h3 class="api-name" id="component2()">component2</h3>
+ <pre class="api-signature no-pretty-print">public final int <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html#component2()">component2</a>()</pre>
+ </div>
+ </div>
+ </body>
+</html>
+ --- /home/runner/diff/original/firebase-kotlindoc/android/com/google/firebase/vertexai/type/UsageMetadata.html 2025-02-08 03:34:27.323393960 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/android/com/google/firebase/vertexai/type/UsageMetadata.html 2025-02-08 03:32:21.414957484 +0000
@@ -33,6 +33,13 @@
</td>
</tr>
<tr>
+ <td><code>final <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#candidatesTokensDetails()">candidatesTokensDetails</a></code></div>
+ <p>The breakdown, by modality, of how many tokens are consumed by the candidates.</p>
+ </td>
+ </tr>
+ <tr>
<td><code>final int</code></td>
<td>
<div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#promptTokenCount()">promptTokenCount</a></code></div>
@@ -40,6 +47,13 @@
</td>
</tr>
<tr>
+ <td><code>final <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#promptTokensDetails()">promptTokensDetails</a></code></div>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </td>
+ </tr>
+ <tr>
<td><code>final int</code></td>
<td>
<div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#totalTokenCount()">totalTokenCount</a></code></div>
@@ -63,7 +77,7 @@
<tbody class="list">
<tr>
<td>
- <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int)">UsageMetadata</a>(<br> int promptTokenCount,<br> <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> candidatesTokenCount,<br> int totalTokenCount<br>)</code></div>
+ <div><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.collections.List,kotlin.collections.List)">UsageMetadata</a>(<br> int promptTokenCount,<br> <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> candidatesTokenCount,<br> int totalTokenCount,<br> <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> promptTokensDetails,<br> <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> candidatesTokensDetails<br>)</code></div>
</td>
</tr>
</tbody>
@@ -76,11 +90,21 @@
<pre class="api-signature no-pretty-print">public final <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#candidatesTokenCount()">candidatesTokenCount</a></pre>
<p>Number of tokens in the response(s).</p>
</div>
+ <div class="api-item"><a name="getCandidatesTokensDetails()"></a><a name="setCandidatesTokensDetails()"></a><a name="getCandidatesTokensDetails--"></a><a name="setCandidatesTokensDetails--"></a>
+ <h3 class="api-name" id="candidatesTokensDetails()">candidatesTokensDetails</h3>
+ <pre class="api-signature no-pretty-print">public final <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#candidatesTokensDetails()">candidatesTokensDetails</a></pre>
+ <p>The breakdown, by modality, of how many tokens are consumed by the candidates.</p>
+ </div>
<div class="api-item"><a name="getPromptTokenCount()"></a><a name="setPromptTokenCount()"></a><a name="getPromptTokenCount--"></a><a name="setPromptTokenCount--"></a>
<h3 class="api-name" id="promptTokenCount()">promptTokenCount</h3>
<pre class="api-signature no-pretty-print">public final int <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#promptTokenCount()">promptTokenCount</a></pre>
<p>Number of tokens in the request.</p>
</div>
+ <div class="api-item"><a name="getPromptTokensDetails()"></a><a name="setPromptTokensDetails()"></a><a name="getPromptTokensDetails--"></a><a name="setPromptTokensDetails--"></a>
+ <h3 class="api-name" id="promptTokensDetails()">promptTokensDetails</h3>
+ <pre class="api-signature no-pretty-print">public final <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#promptTokensDetails()">promptTokensDetails</a></pre>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </div>
<div class="api-item"><a name="getTotalTokenCount()"></a><a name="setTotalTokenCount()"></a><a name="getTotalTokenCount--"></a><a name="setTotalTokenCount--"></a>
<h3 class="api-name" id="totalTokenCount()">totalTokenCount</h3>
<pre class="api-signature no-pretty-print">public final int <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#totalTokenCount()">totalTokenCount</a></pre>
@@ -89,9 +113,9 @@
</div>
<div class="list">
<h2>Public constructors</h2>
- <div class="api-item"><a name="UsageMetadata(kotlin.Int, kotlin.Int, kotlin.Int)"></a><a name="UsageMetadata-kotlin.Int-kotlin.Int-kotlin.Int-"></a><a name="usagemetadata"></a>
- <h3 class="api-name" id="UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int)">UsageMetadata</h3>
- <pre class="api-signature no-pretty-print">public <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int)">UsageMetadata</a>(<br> int promptTokenCount,<br> <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> candidatesTokenCount,<br> int totalTokenCount<br>)</pre>
+ <div class="api-item"><a name="UsageMetadata(kotlin.Int, kotlin.Int, kotlin.Int, kotlin.collections.List, kotlin.collections.List)"></a><a name="UsageMetadata-kotlin.Int-kotlin.Int-kotlin.Int-kotlin.collections.List-kotlin.collections.List-"></a><a name="usagemetadata"></a>
+ <h3 class="api-name" id="UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.collections.List,kotlin.collections.List)">UsageMetadata</h3>
+ <pre class="api-signature no-pretty-print">public <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/UsageMetadata.html#UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.collections.List,kotlin.collections.List)">UsageMetadata</a>(<br> int promptTokenCount,<br> <a href="https://developer.android.com/reference/kotlin/java/lang/Integer.html">Integer</a> candidatesTokenCount,<br> int totalTokenCount,<br> <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> promptTokensDetails,<br> <a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> candidatesTokensDetails<br>)</pre>
<div class="devsite-table-wrapper">
<table class="responsive">
<colgroup>
@@ -122,6 +146,18 @@
<p>Total number of tokens.</p>
</td>
</tr>
+ <tr>
+ <td><code><a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> promptTokensDetails</code></td>
+ <td>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code><a href="https://developer.android.com/reference/kotlin/java/util/List.html">List</a><@<a href="https://developer.android.com/reference/kotlin/androidx/annotation/NonNull.html">NonNull</a> <a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>> candidatesTokensDetails</code></td>
+ <td>
+ <p>The breakdown, by modality, of how many tokens are consumed by the candidates.</p>
+ </td>
+ </tr>
</tbody>
</table>
</div> --- /home/runner/diff/original/firebase-kotlindoc/android/com/google/firebase/vertexai/type/package-summary.html 2025-02-08 03:34:27.322393957 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/android/com/google/firebase/vertexai/type/package-summary.html 2025-02-08 03:32:21.413957480 +0000
@@ -72,6 +72,12 @@
<td></td>
</tr>
<tr>
+ <td><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <p>Content part modality.</p>
+ </td>
+ </tr>
+ <tr>
<td><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/CountTokensResponse.html">CountTokensResponse</a></code></td>
<td>
<p>The model's response to a count tokens request.</p>
@@ -178,6 +184,12 @@
</td>
</tr>
<tr>
+ <td><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a></code></td>
+ <td>
+ <p>Represents token counting info for a single modality.</p>
+ </td>
+ </tr>
+ <tr>
<td><code><a href="/https/github.com/docs/reference/android/com/google/firebase/vertexai/type/PartKt.html">PartKt</a></code></td>
<td></td>
</tr> --- /home/runner/diff/original/firebase-kotlindoc/kotlin/client/firebase-vertexai/_toc.yaml 2025-02-08 03:34:27.328393976 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/kotlin/client/firebase-vertexai/_toc.yaml 2025-02-08 03:32:21.419957504 +0000
@@ -50,6 +50,8 @@
path: "/docs/reference/kotlin/com/google/firebase/vertexai/type/Content.html"
- title: "Content.Builder"
path: "/docs/reference/kotlin/com/google/firebase/vertexai/type/Content.Builder.html"
+ - title: "ContentModality"
+ path: "/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html"
- title: "CountTokensResponse"
path: "/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html"
- title: "FileDataPart"
@@ -84,6 +86,8 @@
path: "/docs/reference/kotlin/com/google/firebase/vertexai/type/ImagePart.html"
- title: "InlineDataPart"
path: "/docs/reference/kotlin/com/google/firebase/vertexai/type/InlineDataPart.html"
+ - title: "ModalityTokenCount"
+ path: "/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html"
- title: "PromptFeedback"
path: "/docs/reference/kotlin/com/google/firebase/vertexai/type/PromptFeedback.html"
- title: "RequestOptions" --- /home/runner/diff/original/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/ContentModality.html 1970-01-01 00:00:00.000000000 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/ContentModality.html 2025-02-08 03:32:21.424957524 +0000
@@ -0,0 +1,136 @@
+<html devsite="true">
+ <head>
+ <title>ContentModality</title>
+{% setvar book_path %}/_book.yaml{% endsetvar %}
+{% include "docs/reference/kotlin/_reference-head-tags.html" %}
+ </head>
+ <body>
+ <div id="metadata-info-block"></div>
+ <h1>ContentModality</h1>
+ <p>
+ <pre>class <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ </p>
+ <hr>
+ <p>Content part modality.</p>
+ <h2>Summary</h2>
+ <div class="devsite-table-wrapper">
+ <table class="responsive">
+ <colgroup>
+ <col width="40%">
+ <col>
+ </colgroup>
+ <thead>
+ <tr>
+ <th colspan="100%"><h3>Public companion properties</h3></th>
+ </tr>
+ </thead>
+ <tbody class="list">
+ <tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#AUDIO()">AUDIO</a></code></div>
+ <p>Audio.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#DOCUMENT()">DOCUMENT</a></code></div>
+ <p>Document, e.g.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#IMAGE()">IMAGE</a></code></div>
+ <p>Image.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#TEXT()">TEXT</a></code></div>
+ <p>Plain text.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#UNSPECIFIED()">UNSPECIFIED</a></code></div>
+ <p>Unspecified modality.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#VIDEO()">VIDEO</a></code></div>
+ <p>Video.</p>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ <div class="devsite-table-wrapper">
+ <table class="responsive">
+ <colgroup>
+ <col width="40%">
+ <col>
+ </colgroup>
+ <thead>
+ <tr>
+ <th colspan="100%"><h3>Public properties</h3></th>
+ </tr>
+ </thead>
+ <tbody class="list">
+ <tr>
+ <td><code><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html#ordinal()">ordinal</a></code></div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ <div class="list">
+ <h2>Public companion properties</h2>
+ <div class="api-item"><a name="getAUDIO()"></a><a name="setAUDIO()"></a><a name="getAUDIO--"></a><a name="setAUDIO--"></a>
+ <h3 class="api-name" id="AUDIO()">AUDIO</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#AUDIO()">AUDIO</a>: <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ <p>Audio.</p>
+ </div>
+ <div class="api-item"><a name="getDOCUMENT()"></a><a name="setDOCUMENT()"></a><a name="getDOCUMENT--"></a><a name="setDOCUMENT--"></a>
+ <h3 class="api-name" id="DOCUMENT()">DOCUMENT</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#DOCUMENT()">DOCUMENT</a>: <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ <p>Document, e.g. PDF.</p>
+ </div>
+ <div class="api-item"><a name="getIMAGE()"></a><a name="setIMAGE()"></a><a name="getIMAGE--"></a><a name="setIMAGE--"></a>
+ <h3 class="api-name" id="IMAGE()">IMAGE</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#IMAGE()">IMAGE</a>: <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ <p>Image.</p>
+ </div>
+ <div class="api-item"><a name="getTEXT()"></a><a name="setTEXT()"></a><a name="getTEXT--"></a><a name="setTEXT--"></a>
+ <h3 class="api-name" id="TEXT()">TEXT</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#TEXT()">TEXT</a>: <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ <p>Plain text.</p>
+ </div>
+ <div class="api-item"><a name="getUNSPECIFIED()"></a><a name="setUNSPECIFIED()"></a><a name="getUNSPECIFIED--"></a><a name="setUNSPECIFIED--"></a>
+ <h3 class="api-name" id="UNSPECIFIED()">UNSPECIFIED</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#UNSPECIFIED()">UNSPECIFIED</a>: <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ <p>Unspecified modality.</p>
+ </div>
+ <div class="api-item"><a name="getVIDEO()"></a><a name="setVIDEO()"></a><a name="getVIDEO--"></a><a name="setVIDEO--"></a>
+ <h3 class="api-name" id="VIDEO()">VIDEO</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.Companion.html#VIDEO()">VIDEO</a>: <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ <p>Video.</p>
+ </div>
+ </div>
+ <div class="list">
+ <h2>Public properties</h2>
+ <div class="api-item"><a name="getOrdinal()"></a><a name="setOrdinal()"></a><a name="getOrdinal--"></a><a name="setOrdinal--"></a>
+ <h3 class="api-name" id="ordinal()">ordinal</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html#ordinal()">ordinal</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></pre>
+ </div>
+ </div>
+ </body>
+</html>
+ --- /home/runner/diff/original/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html 2025-02-08 03:34:27.330393982 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html 2025-02-08 03:32:21.421957512 +0000
@@ -28,7 +28,7 @@
<tbody class="list">
<tr>
<td>
- <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#CountTokensResponse(kotlin.Int,kotlin.Int)">CountTokensResponse</a>(totalTokens: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>, totalBillableCharacters: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?)</code></div>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#CountTokensResponse(kotlin.Int,kotlin.Int,kotlin.collections.List)">CountTokensResponse</a>(<br> totalTokens: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>,<br> totalBillableCharacters: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?,<br> promptTokensDetails: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?<br>)</code></div>
</td>
</tr>
</tbody>
@@ -58,6 +58,12 @@
<div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#component2()">component2</a>()</code></div>
</td>
</tr>
+ <tr>
+ <td><code>operator <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#component3()">component3</a>()</code></div>
+ </td>
+ </tr>
</tbody>
</table>
</div>
@@ -74,6 +80,13 @@
</thead>
<tbody class="list">
<tr>
+ <td><code><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#promptTokensDetails()">promptTokensDetails</a></code></div>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </td>
+ </tr>
+ <tr>
<td><code><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?</code></td>
<td>
<div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#totalBillableCharacters()">totalBillableCharacters</a></code></div>
@@ -92,9 +105,9 @@
</div>
<div class="list">
<h2>Public constructors</h2>
- <div class="api-item"><a name="CountTokensResponse(kotlin.Int, kotlin.Int)"></a><a name="CountTokensResponse-kotlin.Int-kotlin.Int-"></a><a name="counttokensresponse"></a>
- <h3 class="api-name" id="CountTokensResponse(kotlin.Int,kotlin.Int)">CountTokensResponse</h3>
- <pre class="api-signature no-pretty-print"><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#CountTokensResponse(kotlin.Int,kotlin.Int)">CountTokensResponse</a>(totalTokens: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>, totalBillableCharacters: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>? = null)</pre>
+ <div class="api-item"><a name="CountTokensResponse(kotlin.Int, kotlin.Int, kotlin.collections.List)"></a><a name="CountTokensResponse-kotlin.Int-kotlin.Int-kotlin.collections.List-"></a><a name="counttokensresponse"></a>
+ <h3 class="api-name" id="CountTokensResponse(kotlin.Int,kotlin.Int,kotlin.collections.List)">CountTokensResponse</h3>
+ <pre class="api-signature no-pretty-print"><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#CountTokensResponse(kotlin.Int,kotlin.Int,kotlin.collections.List)">CountTokensResponse</a>(<br> totalTokens: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>,<br> totalBillableCharacters: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>? = null,<br> promptTokensDetails: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>? = null<br>)</pre>
</div>
</div>
<div class="list">
@@ -107,9 +120,18 @@
<h3 class="api-name" id="component2()">component2</h3>
<pre class="api-signature no-pretty-print">operator fun <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#component2()">component2</a>(): <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?</pre>
</div>
+ <div class="api-item"><a name="component3--"></a><a name="component3"></a>
+ <h3 class="api-name" id="component3()">component3</h3>
+ <pre class="api-signature no-pretty-print">operator fun <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#component3()">component3</a>(): <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</pre>
+ </div>
</div>
<div class="list">
<h2>Public properties</h2>
+ <div class="api-item"><a name="getPromptTokensDetails()"></a><a name="setPromptTokensDetails()"></a><a name="getPromptTokensDetails--"></a><a name="setPromptTokensDetails--"></a>
+ <h3 class="api-name" id="promptTokensDetails()">promptTokensDetails</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#promptTokensDetails()">promptTokensDetails</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</pre>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </div>
<div class="api-item"><a name="getTotalBillableCharacters()"></a><a name="setTotalBillableCharacters()"></a><a name="getTotalBillableCharacters--"></a><a name="setTotalBillableCharacters--"></a>
<h3 class="api-name" id="totalBillableCharacters()">totalBillableCharacters</h3>
<pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html#totalBillableCharacters()">totalBillableCharacters</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?</pre> --- /home/runner/diff/original/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html 1970-01-01 00:00:00.000000000 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html 2025-02-08 03:32:21.420957508 +0000
@@ -0,0 +1,98 @@
+<html devsite="true">
+ <head>
+ <title>ModalityTokenCount</title>
+{% setvar book_path %}/_book.yaml{% endsetvar %}
+{% include "docs/reference/kotlin/_reference-head-tags.html" %}
+ </head>
+ <body>
+ <div id="metadata-info-block"></div>
+ <h1>ModalityTokenCount</h1>
+ <p>
+ <pre>class <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a></pre>
+ </p>
+ <hr>
+ <p>Represents token counting info for a single modality.</p>
+ <h2>Summary</h2>
+ <div class="devsite-table-wrapper">
+ <table class="responsive">
+ <colgroup>
+ <col width="40%">
+ <col>
+ </colgroup>
+ <thead>
+ <tr>
+ <th colspan="100%"><h3>Public functions</h3></th>
+ </tr>
+ </thead>
+ <tbody class="list">
+ <tr>
+ <td><code>operator <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html#component1()">component1</a>()</code></div>
+ </td>
+ </tr>
+ <tr>
+ <td><code>operator <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html#component2()">component2</a>()</code></div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ <div class="devsite-table-wrapper">
+ <table class="responsive">
+ <colgroup>
+ <col width="40%">
+ <col>
+ </colgroup>
+ <thead>
+ <tr>
+ <th colspan="100%"><h3>Public properties</h3></th>
+ </tr>
+ </thead>
+ <tbody class="list">
+ <tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html#modality()">modality</a></code></div>
+ <p>The modality associated with this token count.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html#tokenCount()">tokenCount</a></code></div>
+ <p>The number of tokens counted.</p>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ <div class="list">
+ <h2>Public functions</h2>
+ <div class="api-item"><a name="component1--"></a><a name="component1"></a>
+ <h3 class="api-name" id="component1()">component1</h3>
+ <pre class="api-signature no-pretty-print">operator fun <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html#component1()">component1</a>(): <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ </div>
+ <div class="api-item"><a name="component2--"></a><a name="component2"></a>
+ <h3 class="api-name" id="component2()">component2</h3>
+ <pre class="api-signature no-pretty-print">operator fun <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html#component2()">component2</a>(): <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></pre>
+ </div>
+ </div>
+ <div class="list">
+ <h2>Public properties</h2>
+ <div class="api-item"><a name="getModality()"></a><a name="setModality()"></a><a name="getModality--"></a><a name="setModality--"></a>
+ <h3 class="api-name" id="modality()">modality</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html#modality()">modality</a>: <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></pre>
+ <p>The modality associated with this token count.</p>
+ </div>
+ <div class="api-item"><a name="getTokenCount()"></a><a name="setTokenCount()"></a><a name="getTokenCount--"></a><a name="setTokenCount--"></a>
+ <h3 class="api-name" id="tokenCount()">tokenCount</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html#tokenCount()">tokenCount</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></pre>
+ <p>The number of tokens counted.</p>
+ </div>
+ </div>
+ </body>
+</html>
+ --- /home/runner/diff/original/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html 2025-02-08 03:34:27.330393982 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html 2025-02-08 03:32:21.421957512 +0000
@@ -27,7 +27,7 @@
<tbody class="list">
<tr>
<td>
- <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int)">UsageMetadata</a>(<br> promptTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>,<br> candidatesTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?,<br> totalTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a><br>)</code></div>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.collections.List,kotlin.collections.List)">UsageMetadata</a>(<br> promptTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>,<br> candidatesTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?,<br> totalTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>,<br> promptTokensDetails: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?,<br> candidatesTokensDetails: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?<br>)</code></div>
</td>
</tr>
</tbody>
@@ -53,6 +53,13 @@
</td>
</tr>
<tr>
+ <td><code><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#candidatesTokensDetails()">candidatesTokensDetails</a></code></div>
+ <p>The breakdown, by modality, of how many tokens are consumed by the candidates.</p>
+ </td>
+ </tr>
+ <tr>
<td><code><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></code></td>
<td>
<div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#promptTokenCount()">promptTokenCount</a></code></div>
@@ -60,6 +67,13 @@
</td>
</tr>
<tr>
+ <td><code><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</code></td>
+ <td>
+ <div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#promptTokensDetails()">promptTokensDetails</a></code></div>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </td>
+ </tr>
+ <tr>
<td><code><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></code></td>
<td>
<div><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#totalTokenCount()">totalTokenCount</a></code></div>
@@ -71,9 +85,9 @@
</div>
<div class="list">
<h2>Public constructors</h2>
- <div class="api-item"><a name="UsageMetadata(kotlin.Int, kotlin.Int, kotlin.Int)"></a><a name="UsageMetadata-kotlin.Int-kotlin.Int-kotlin.Int-"></a><a name="usagemetadata"></a>
- <h3 class="api-name" id="UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int)">UsageMetadata</h3>
- <pre class="api-signature no-pretty-print"><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int)">UsageMetadata</a>(<br> promptTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>,<br> candidatesTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?,<br> totalTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a><br>)</pre>
+ <div class="api-item"><a name="UsageMetadata(kotlin.Int, kotlin.Int, kotlin.Int, kotlin.collections.List, kotlin.collections.List)"></a><a name="UsageMetadata-kotlin.Int-kotlin.Int-kotlin.Int-kotlin.collections.List-kotlin.collections.List-"></a><a name="usagemetadata"></a>
+ <h3 class="api-name" id="UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.collections.List,kotlin.collections.List)">UsageMetadata</h3>
+ <pre class="api-signature no-pretty-print"><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#UsageMetadata(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.collections.List,kotlin.collections.List)">UsageMetadata</a>(<br> promptTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>,<br> candidatesTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?,<br> totalTokenCount: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>,<br> promptTokensDetails: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?,<br> candidatesTokensDetails: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?<br>)</pre>
<div class="devsite-table-wrapper">
<table class="responsive">
<colgroup>
@@ -104,6 +118,18 @@
<p>Total number of tokens.</p>
</td>
</tr>
+ <tr>
+ <td><code>promptTokensDetails: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</code></td>
+ <td>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </td>
+ </tr>
+ <tr>
+ <td><code>candidatesTokensDetails: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</code></td>
+ <td>
+ <p>The breakdown, by modality, of how many tokens are consumed by the candidates.</p>
+ </td>
+ </tr>
</tbody>
</table>
</div>
@@ -116,11 +142,21 @@
<pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#candidatesTokenCount()">candidatesTokenCount</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a>?</pre>
<p>Number of tokens in the response(s).</p>
</div>
+ <div class="api-item"><a name="getCandidatesTokensDetails()"></a><a name="setCandidatesTokensDetails()"></a><a name="getCandidatesTokensDetails--"></a><a name="setCandidatesTokensDetails--"></a>
+ <h3 class="api-name" id="candidatesTokensDetails()">candidatesTokensDetails</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#candidatesTokensDetails()">candidatesTokensDetails</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</pre>
+ <p>The breakdown, by modality, of how many tokens are consumed by the candidates.</p>
+ </div>
<div class="api-item"><a name="getPromptTokenCount()"></a><a name="setPromptTokenCount()"></a><a name="getPromptTokenCount--"></a><a name="setPromptTokenCount--"></a>
<h3 class="api-name" id="promptTokenCount()">promptTokenCount</h3>
<pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#promptTokenCount()">promptTokenCount</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></pre>
<p>Number of tokens in the request.</p>
</div>
+ <div class="api-item"><a name="getPromptTokensDetails()"></a><a name="setPromptTokensDetails()"></a><a name="getPromptTokensDetails--"></a><a name="setPromptTokensDetails--"></a>
+ <h3 class="api-name" id="promptTokensDetails()">promptTokensDetails</h3>
+ <pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#promptTokensDetails()">promptTokensDetails</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html">List</a><<a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a>>?</pre>
+ <p>The breakdown, by modality, of how many tokens are consumed by the prompt.</p>
+ </div>
<div class="api-item"><a name="getTotalTokenCount()"></a><a name="setTotalTokenCount()"></a><a name="getTotalTokenCount--"></a><a name="setTotalTokenCount--"></a>
<h3 class="api-name" id="totalTokenCount()">totalTokenCount</h3>
<pre class="api-signature no-pretty-print">val <a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/UsageMetadata.html#totalTokenCount()">totalTokenCount</a>: <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html">Int</a></pre> --- /home/runner/diff/original/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/package-summary.html 2025-02-08 03:34:27.329393979 +0000
+++ /home/runner/diff/modified/firebase-kotlindoc/kotlin/com/google/firebase/vertexai/type/package-summary.html 2025-02-08 03:32:21.421957512 +0000
@@ -68,6 +68,12 @@
</td>
</tr>
<tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ContentModality.html">ContentModality</a></code></td>
+ <td>
+ <p>Content part modality.</p>
+ </td>
+ </tr>
+ <tr>
<td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/CountTokensResponse.html">CountTokensResponse</a></code></td>
<td>
<p>The model's response to a count tokens request.</p>
@@ -170,6 +176,12 @@
</td>
</tr>
<tr>
+ <td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/ModalityTokenCount.html">ModalityTokenCount</a></code></td>
+ <td>
+ <p>Represents token counting info for a single modality.</p>
+ </td>
+ </tr>
+ <tr>
<td><code><a href="/https/github.com/docs/reference/kotlin/com/google/firebase/vertexai/type/PromptFeedback.html">PromptFeedback</a></code></td>
<td>
<p>Feedback on the prompt provided in the request.</p> |
Coverage Report 1Affected ProductsNo changes between base commit (336cf32) and merge commit (52c9564).Test Logs |
Test Results 20 files - 1 014 20 suites - 1 014 12s ⏱️ - 34m 8s Results for commit 1d21728. ± Comparison against base commit 336cf32. This pull request removes 5776 and adds 2 tests. Note that renamed tests count towards both.
♻️ This comment has been updated with latest results. |
Size Report 1Affected Products
Test Logs |
There are other possible classes that will use the same Modality name
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, but left some comments that might wanna be addressed before merging.
Oh, and don't forget to add a release note!!
firebase-vertexai/src/main/kotlin/com/google/firebase/vertexai/type/ContentModality.kt
Show resolved
Hide resolved
firebase-vertexai/src/main/kotlin/com/google/firebase/vertexai/type/UsageMetadata.kt
Outdated
Show resolved
Hide resolved
firebase-vertexai/src/main/kotlin/com/google/firebase/vertexai/type/ContentModality.kt
Show resolved
Hide resolved
The public api surface has changed for the subproject firebase-vertexai: Please update the api.txt files for the subprojects being affected by this change by running ./gradlew ${subproject}:generateApiTxtFile. Also perform a major/minor bump accordingly. |
1 similar comment
The public api surface has changed for the subproject firebase-vertexai: Please update the api.txt files for the subprojects being affected by this change by running ./gradlew ${subproject}:generateApiTxtFile. Also perform a major/minor bump accordingly. |
- update api.txt - bump version - Add missing kdoc A note about api.txt and version. While this change is technically removing two methods, those are constructors of classes returned by the server, which shouldn't be instantiated by clients. In an upcoming breaking release we should moved them to be hidden using the `internal` visibility.
Token measurement is broken down by modaliy, with separate counters for image, audio, etc.
Tests are in version 6.*, so this change also includes bumping update_responses.sh