{
  "aboutHtml": "<p>Gemini Embedding 2 是 Google 用於數值表示文字、圖片、影片、音訊與 PDF 的多模態嵌入模型。它將不同媒體型別映射至共用空間，讓應用程式跨型別比較意義。結果是數值向量，可用於語意搜尋、文件檢索、推薦、分類或分群；不是書面答案或生成的媒體檔案。Google 記載其語意範圍涵蓋超過 100 種語言。</p><p>知識庫可先為來源段落建立向量，將使用者查詢與向量比較，再檢索相關資料。另一個文字模型隨後可使用這些來源撰寫答案。媒體集合可以用文字描述搜尋相關圖片或影片，圖片也能作為查詢。請保留各向量與原始內容的連結，包括頁面或片段參照，讓檢索結果可被檢視，並在原始上下文中呈現。</p><p>整體輸入上限為 8,192 token。穩定版模型指南允許最多六張 PNG 或 JPEG 圖片、最長 180 秒 MP3 或 WAV 音訊，以及最長 120 秒 MP4 或 MOV 影片。文件所載影片編碼格式為 H264、H265、AV1、VP9。影片處理最多使用 32 個影格：32 秒以內片段每秒取樣一格，較長片段則均勻取樣至 32 格。該影片輸入不處理音軌；聲音與檢索相關時，請另外嵌入音訊。</p><p>PDF 輸入接受一個最多六頁的檔案。Google 建議每個 PDF 一頁以獲得最佳品質。請將較大來源拆成有意義的頁面或章節，並保留與原始文件的關係。選擇代表可檢索內容的摘錄，不要只因符合上限就合併無關資料。混合媒體請求仍適用共用 token 邊界。每個 PDF 頁面除擷取文字 token 外，還消耗 258 個視覺 token。Google 文件所載流程中，超過共用 8,192 token 上限的內容會被截斷而不報錯。</p><p>輸出維度可在 128 至 3,072 之間彈性選擇，預設為 3,072，建議大小為 768、1,536、3,072。模型使用 Matryoshka Representation Learning，因此向量前綴在較小維度下仍有用。指南記載，預設及縮短向量都會自動正規化。請為應用程式比較的記錄與查詢選擇一致維度；要求的大小改變數值表示，不改變來源內容本身。</p><p>純文字任務請將用途納入文字，而非使用舊的 task_type 欄位。Google 區分非對稱檢索與對稱比較。搜尋查詢使用 “task: search result | query: {content}”，來源文件使用 “title: {title} | text: {content}”；沒有標題時使用 “title: none”。問答、事實查核及程式碼檢索任務有各自的查詢前綴。分類、分群或句子相似度，請在兩端一致使用相同任務格式。指南通常建議，不要在合併多模態表示的文字部分加入任務前綴。</p><p>輸入結構決定結果表示一個合併物件，或多個獨立項目。一起提供的多個部分會建立聚合嵌入；分開的 Content 物件則為每個項目建立獨立嵌入。文字與圖片貼文可透過合併表示捕捉兩者關係。需獨立搜尋的記錄，請保持分開。這會影響檢索粒度：整篇貼文一個向量，不同於每個段落或圖片各一個向量。</p><p>指南指出，Gemini Embedding 001 與 Gemini Embedding 2 向量位於不相容空間，不能直接比較。從舊模型移轉的集合必須為新空間重新建立嵌入。請讓模型選擇與維度符合正在比較的向量，並將原始文字和媒體與數值索引分開保留。嵌入相似度是檢索訊號，不是文件為何回答使用者問題的事實解釋。</p><p>實際目錄中，若產品照片與核准說明應作為同一物件檢索，請一起嵌入。文件集合請嵌入聚焦段落，與依用途設定格式的查詢比較，再將來源段落和搜尋結果一起呈現。音訊或影片請選擇描述可搜尋事件的區段，並保留原始時間範圍。實用產物是連結來源證據的數值表示，供應用程式下一個搜尋或分析步驟使用。</p>",
  "aboutText": "Gemini Embedding 2 是 Google 用於數值表示文字、圖片、影片、音訊與 PDF 的多模態嵌入模型。它將不同媒體型別映射至共用空間，讓應用程式跨型別比較意義。結果是數值向量，可用於語意搜尋、文件檢索、推薦、分類或分群；不是書面答案或生成的媒體檔案。Google 記載其語意範圍涵蓋超過 100 種語言。\n\n知識庫可先為來源段落建立向量，將使用者查詢與向量比較，再檢索相關資料。另一個文字模型隨後可使用這些來源撰寫答案。媒體集合可以用文字描述搜尋相關圖片或影片，圖片也能作為查詢。請保留各向量與原始內容的連結，包括頁面或片段參照，讓檢索結果可被檢視，並在原始上下文中呈現。\n\n整體輸入上限為 8,192 token。穩定版模型指南允許最多六張 PNG 或 JPEG 圖片、最長 180 秒 MP3 或 WAV 音訊，以及最長 120 秒 MP4 或 MOV 影片。文件所載影片編碼格式為 H264、H265、AV1、VP9。影片處理最多使用 32 個影格：32 秒以內片段每秒取樣一格，較長片段則均勻取樣至 32 格。該影片輸入不處理音軌；聲音與檢索相關時，請另外嵌入音訊。\n\nPDF 輸入接受一個最多六頁的檔案。Google 建議每個 PDF 一頁以獲得最佳品質。請將較大來源拆成有意義的頁面或章節，並保留與原始文件的關係。選擇代表可檢索內容的摘錄，不要只因符合上限就合併無關資料。混合媒體請求仍適用共用 token 邊界。每個 PDF 頁面除擷取文字 token 外，還消耗 258 個視覺 token。Google 文件所載流程中，超過共用 8,192 token 上限的內容會被截斷而不報錯。\n\n輸出維度可在 128 至 3,072 之間彈性選擇，預設為 3,072，建議大小為 768、1,536、3,072。模型使用 Matryoshka Representation Learning，因此向量前綴在較小維度下仍有用。指南記載，預設及縮短向量都會自動正規化。請為應用程式比較的記錄與查詢選擇一致維度；要求的大小改變數值表示，不改變來源內容本身。\n\n純文字任務請將用途納入文字，而非使用舊的 task_type 欄位。Google 區分非對稱檢索與對稱比較。搜尋查詢使用 “task: search result | query: {content}”，來源文件使用 “title: {title} | text: {content}”；沒有標題時使用 “title: none”。問答、事實查核及程式碼檢索任務有各自的查詢前綴。分類、分群或句子相似度，請在兩端一致使用相同任務格式。指南通常建議，不要在合併多模態表示的文字部分加入任務前綴。\n\n輸入結構決定結果表示一個合併物件，或多個獨立項目。一起提供的多個部分會建立聚合嵌入；分開的 Content 物件則為每個項目建立獨立嵌入。文字與圖片貼文可透過合併表示捕捉兩者關係。需獨立搜尋的記錄，請保持分開。這會影響檢索粒度：整篇貼文一個向量，不同於每個段落或圖片各一個向量。\n\n指南指出，Gemini Embedding 001 與 Gemini Embedding 2 向量位於不相容空間，不能直接比較。從舊模型移轉的集合必須為新空間重新建立嵌入。請讓模型選擇與維度符合正在比較的向量，並將原始文字和媒體與數值索引分開保留。嵌入相似度是檢索訊號，不是文件為何回答使用者問題的事實解釋。\n\n實際目錄中，若產品照片與核准說明應作為同一物件檢索，請一起嵌入。文件集合請嵌入聚焦段落，與依用途設定格式的查詢比較，再將來源段落和搜尋結果一起呈現。音訊或影片請選擇描述可搜尋事件的區段，並保留原始時間範圍。實用產物是連結來源證據的數值表示，供應用程式下一個搜尋或分析步驟使用。",
  "editorialOverlay": {
    "copy_fields": null,
    "copy_sha256": null,
    "copy_source": null,
    "html_sha256": "6dc3f00cc300312084ee83298b19f3461c871dd574b473164e0996e4ab1a192c",
    "module_sha256": "ee9dc1c50b1e6a8fb7fa062030fcb4646b9aaaeb08be513b723a5a92a7290f06",
    "raw_model_unchanged": true,
    "schema": "ailoot-native-model-editorial-v1"
  },
  "locale": "zh-hant-tw",
  "methods": [
    {
      "html": "<div class=\"sheet-head\"><span class=\"mav\" aria-hidden=\"true\">G</span><h2 id=\"sheet-title\">Google: Gemini Embedding 2</h2><button class=\"icon-btn\" type=\"button\" data-close-sheet aria-label=\"關閉\">×</button></div><div class=\"idline\"><span>Google /</span><code>google/gemini-embedding-2</code><button type=\"button\" id=\"copy-id\">複製 ID</button></div><nav class=\"card-jump-nav\" aria-label=\"模型卡片區段\"><button type=\"button\" data-card-jump=\"overview\">入門</button><button type=\"button\" data-card-jump=\"methods\">輸入與方法</button><button type=\"button\" data-card-jump=\"pricing\">方案</button><button type=\"button\" data-card-jump=\"examples\">範例</button><button type=\"button\" data-card-jump=\"results\">結果</button><button type=\"button\" data-card-jump=\"aliases\">別名</button></nav><div class=\"card-method-tabs\" role=\"tablist\" aria-label=\"API 方法\"><button type=\"button\" role=\"tab\" tabindex=\"0\" aria-controls=\"card-method-content\" aria-selected=\"true\" id=\"card-method-tab-0\" data-card-method=\"Ultra|embeddings|/v1/embeddings|google%2Fgemini-embedding-2\">嵌入向量</button></div><div id=\"card-method-content\" role=\"tabpanel\" aria-labelledby=\"card-method-tab-0\"><section class=\"card-section\" data-card-section=\"overview\"><h3 tabindex=\"-1\">入門</h3><p class=\"mdesc-full\">Gemini Embedding 2 將文字、圖片、音訊、影片與 PDF 映射至共用數值空間。其向量支援跨模態搜尋、檢索、分類與分群，並提供彈性維度及 8,192 token 輸入上限。</p><dl class=\"card-io\" data-card-io><div><dt>接受的輸入</dt><dd>文字 · token_ids</dd></div><div><dt>結果</dt><dd>embedding</dd></div></dl><details class=\"card-about\"><summary>關於模型</summary><p class=\"note-s\" data-model-method-boundary>此說明介紹模型的能力。Ailoot 可用的輸入、輸出與選項，依所選方法列於下方。</p><div class=\"mabout\" id=\"m-about\"><p>Gemini Embedding 2 是 Google 用於數值表示文字、圖片、影片、音訊與 PDF 的多模態嵌入模型。它將不同媒體型別映射至共用空間，讓應用程式跨型別比較意義。結果是數值向量，可用於語意搜尋、文件檢索、推薦、分類或分群；不是書面答案或生成的媒體檔案。Google 記載其語意範圍涵蓋超過 100 種語言。</p><p>知識庫可先為來源段落建立向量，將使用者查詢與向量比較，再檢索相關資料。另一個文字模型隨後可使用這些來源撰寫答案。媒體集合可以用文字描述搜尋相關圖片或影片，圖片也能作為查詢。請保留各向量與原始內容的連結，包括頁面或片段參照，讓檢索結果可被檢視，並在原始上下文中呈現。</p><p>整體輸入上限為 8,192 token。穩定版模型指南允許最多六張 PNG 或 JPEG 圖片、最長 180 秒 MP3 或 WAV 音訊，以及最長 120 秒 MP4 或 MOV 影片。文件所載影片編碼格式為 H264、H265、AV1、VP9。影片處理最多使用 32 個影格：32 秒以內片段每秒取樣一格，較長片段則均勻取樣至 32 格。該影片輸入不處理音軌；聲音與檢索相關時，請另外嵌入音訊。</p><p>PDF 輸入接受一個最多六頁的檔案。Google 建議每個 PDF 一頁以獲得最佳品質。請將較大來源拆成有意義的頁面或章節，並保留與原始文件的關係。選擇代表可檢索內容的摘錄，不要只因符合上限就合併無關資料。混合媒體請求仍適用共用 token 邊界。每個 PDF 頁面除擷取文字 token 外，還消耗 258 個視覺 token。Google 文件所載流程中，超過共用 8,192 token 上限的內容會被截斷而不報錯。</p><p>輸出維度可在 128 至 3,072 之間彈性選擇，預設為 3,072，建議大小為 768、1,536、3,072。模型使用 Matryoshka Representation Learning，因此向量前綴在較小維度下仍有用。指南記載，預設及縮短向量都會自動正規化。請為應用程式比較的記錄與查詢選擇一致維度；要求的大小改變數值表示，不改變來源內容本身。</p><p>純文字任務請將用途納入文字，而非使用舊的 task_type 欄位。Google 區分非對稱檢索與對稱比較。搜尋查詢使用 “task: search result | query: {content}”，來源文件使用 “title: {title} | text: {content}”；沒有標題時使用 “title: none”。問答、事實查核及程式碼檢索任務有各自的查詢前綴。分類、分群或句子相似度，請在兩端一致使用相同任務格式。指南通常建議，不要在合併多模態表示的文字部分加入任務前綴。</p><p>輸入結構決定結果表示一個合併物件，或多個獨立項目。一起提供的多個部分會建立聚合嵌入；分開的 Content 物件則為每個項目建立獨立嵌入。文字與圖片貼文可透過合併表示捕捉兩者關係。需獨立搜尋的記錄，請保持分開。這會影響檢索粒度：整篇貼文一個向量，不同於每個段落或圖片各一個向量。</p><p>指南指出，Gemini Embedding 001 與 Gemini Embedding 2 向量位於不相容空間，不能直接比較。從舊模型移轉的集合必須為新空間重新建立嵌入。請讓模型選擇與維度符合正在比較的向量，並將原始文字和媒體與數值索引分開保留。嵌入相似度是檢索訊號，不是文件為何回答使用者問題的事實解釋。</p><p>實際目錄中，若產品照片與核准說明應作為同一物件檢索，請一起嵌入。文件集合請嵌入聚焦段落，與依用途設定格式的查詢比較，再將來源段落和搜尋結果一起呈現。音訊或影片請選擇描述可搜尋事件的區段，並保留原始時間範圍。實用產物是連結來源證據的數值表示，供應用程式下一個搜尋或分析步驟使用。</p></div></details></section><section class=\"card-section\" data-card-section=\"methods\"><h3 tabindex=\"-1\">Ailoot 可用 · 輸入與方法</h3><details class=\"card-method\" open><summary><b>Ailoot Ultra · 嵌入向量</b> <code>POST /v1/embeddings</code></summary><dl class=\"method-capabilities\"><div><dt>輸入</dt><dd><code>text</code>, <code>token_ids</code></dd></div><div><dt>輸出</dt><dd><code>embedding</code></dd></div><div><dt>上下文</dt><dd>8,192 tokens</dd></div><div><dt>輸出格式</dt><dd>json</dd></div></dl><div class=\"tw\" data-card-parameters data-typed-parameters><table><thead><tr><th>欄位</th><th>類型</th><th>要求</th><th>值與限制</th><th>預設值</th></tr></thead><tbody><tr data-parameter-availability=\"source_interface\"><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">model</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span><code>string</code></td><td data-cell-label=\"要求\"><span class=\"card-cell-label\">要求</span>必填</td><td data-cell-label=\"值與限制\"><span class=\"card-cell-label\">值與限制</span><div>google/gemini-embedding-2</div></td><td data-cell-label=\"預設值\" data-default=\"unspecified\"><span class=\"card-cell-label\">預設值</span>—</td></tr><tr data-parameter-availability=\"source_interface\"><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">input</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span><code>string|string[]|integer[]|integer[][]</code></td><td data-cell-label=\"要求\"><span class=\"card-cell-label\">要求</span>必填</td><td data-cell-label=\"值與限制\"><span class=\"card-cell-label\">值與限制</span><div>項目數下限: 1</div><div>條件: 批次不得為空，且各項目類型須一致。Token ID 須為非負整數。</div><div>輸入額度： 最大值: 8,192 · 文字單位: UTF8 位元組 · Token 單位: token 陣列元素</div></td><td data-cell-label=\"預設值\" data-default=\"unspecified\"><span class=\"card-cell-label\">預設值</span>—</td></tr><tr data-parameter-availability=\"source_interface\"><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">encoding_format</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span><code>string</code></td><td data-cell-label=\"要求\"><span class=\"card-cell-label\">要求</span>選填</td><td data-cell-label=\"值與限制\"><span class=\"card-cell-label\">值與限制</span><div>float</div></td><td data-cell-label=\"預設值\" data-default=\"known\"><span class=\"card-cell-label\">預設值</span>float</td></tr><tr data-parameter-availability=\"unsupported\"><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">dimensions</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span><code>integer</code></td><td data-cell-label=\"要求\"><span class=\"card-cell-label\">要求</span>不支援</td><td data-cell-label=\"值與限制\"><span class=\"card-cell-label\">值與限制</span><div>最小值: 1</div></td><td data-cell-label=\"預設值\" data-default=\"unspecified\"><span class=\"card-cell-label\">預設值</span>—</td></tr><tr data-parameter-availability=\"pass_through_metadata\"><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">user</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span><code>json_value</code></td><td data-cell-label=\"要求\"><span class=\"card-cell-label\">要求</span>選填</td><td data-cell-label=\"值與限制\"><span class=\"card-cell-label\">值與限制</span><div>條件: 來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。</div></td><td data-cell-label=\"預設值\" data-default=\"unspecified\"><span class=\"card-cell-label\">預設值</span>—</td></tr><tr data-parameter-availability=\"pass_through_metadata\"><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">session_id</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span><code>json_value</code></td><td data-cell-label=\"要求\"><span class=\"card-cell-label\">要求</span>選填</td><td data-cell-label=\"值與限制\"><span class=\"card-cell-label\">值與限制</span><div>條件: 來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。</div></td><td data-cell-label=\"預設值\" data-default=\"unspecified\"><span class=\"card-cell-label\">預設值</span>—</td></tr><tr data-parameter-availability=\"pass_through_metadata\"><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">trace</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span><code>json_value</code></td><td data-cell-label=\"要求\"><span class=\"card-cell-label\">要求</span>選填</td><td data-cell-label=\"值與限制\"><span class=\"card-cell-label\">值與限制</span><div>條件: 來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。</div></td><td data-cell-label=\"預設值\" data-default=\"unspecified\"><span class=\"card-cell-label\">預設值</span>—</td></tr><tr data-parameter-availability=\"source_interface\"><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">provider</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span><code>object</code></td><td data-cell-label=\"要求\"><span class=\"card-cell-label\">要求</span>選填</td><td data-cell-label=\"值與限制\"><span class=\"card-cell-label\">值與限制</span><div>條件: provider.options 遭拒絕</div></td><td data-cell-label=\"預設值\" data-default=\"unspecified\"><span class=\"card-cell-label\">預設值</span>—</td></tr></tbody></table></div><details class=\"card-about\" data-material-combinations><summary>輸入素材組合</summary><p class=\"note-s\"><b>text_to_embedding</b></p></details><details class=\"note-s\" data-method-contract><summary>方法參數與生命週期</summary><div class=\"tw\" data-card-table=\"contract\"><table><thead><tr><th>參數</th><th>規格</th></tr></thead><tbody><tr><th data-cell-label=\"參數\" scope=\"row\"><span class=\"card-cell-label\">參數</span><code>content_type</code></th><td data-cell-label=\"規格\"><span class=\"card-cell-label\">規格</span>application/json</td></tr><tr><th data-cell-label=\"參數\" scope=\"row\"><span class=\"card-cell-label\">參數</span><code>required</code></th><td data-cell-label=\"規格\"><span class=\"card-cell-label\">規格</span>model, input</td></tr><tr><th data-cell-label=\"參數\" scope=\"row\"><span class=\"card-cell-label\">參數</span><code>input_shapes</code></th><td data-cell-label=\"規格\"><span class=\"card-cell-label\">規格</span>string, string[], nonnegative_integer_token_array, nonnegative_integer_token_array[]</td></tr><tr><th data-cell-label=\"參數\" scope=\"row\"><span class=\"card-cell-label\">參數</span><code>encoding_format</code></th><td data-cell-label=\"規格\"><span class=\"card-cell-label\">規格</span>float</td></tr><tr><th data-cell-label=\"參數\" scope=\"row\"><span class=\"card-cell-label\">參數</span><code>dimensions_override</code></th><td data-cell-label=\"規格\"><span class=\"card-cell-label\">規格</span>false</td></tr><tr><th data-cell-label=\"參數\" scope=\"row\"><span class=\"card-cell-label\">參數</span><code>max_input_budget_units</code></th><td data-cell-label=\"規格\"><span class=\"card-cell-label\">規格</span>8192</td></tr><tr><th data-cell-label=\"參數\" scope=\"row\"><span class=\"card-cell-label\">參數</span><code>multimodal_objects</code></th><td data-cell-label=\"規格\"><span class=\"card-cell-label\">規格</span>false</td></tr><tr><th data-cell-label=\"參數\" scope=\"row\"><span class=\"card-cell-label\">參數</span><code>material_types</code></th><td data-cell-label=\"規格\"><span class=\"card-cell-label\">規格</span>text, token_ids</td></tr></tbody></table></div><p>生命週期： <code>synchronous_json</code></p><p class=\"note-s\">保留每個向量的索引與維度。</p><p class=\"note-s\">即使模型名稱標示為多模態，此指定路徑也不接受圖片物件。</p></details></details></section><section class=\"card-section\" data-card-section=\"pricing\"><h3 tabindex=\"-1\">方案</h3><div data-native-semantic-method=\"v1\" data-tariff-reference-only><p class=\"note-s\" data-rate-support-note>費率資訊不會增加請求選項。支援的參數列於所選方法中。</p><dl data-price-conditions><dt>快速模式</dt><dd>標準費率 <span class=\"note-s\">選取快速模式時</span></dd><dt>flex 模式</dt><dd>標準費率 <span class=\"note-s\">選取 flex 模式時</span></dd><dt>最高推理強度</dt><dd>標準費率 <span class=\"note-s\">最高推理強度採用 default 調整值時</span></dd></dl></div><div data-declared-tariff-pricing><h4>Ailoot 費率</h4><h4>各設定的價格</h4><div class=\"tw\" data-pricing-profiles><table><thead><tr><th>設定</th><th>費率表</th><th>費用</th></tr></thead><tbody><tr><th data-cell-label=\"設定\" scope=\"row\"><span class=\"card-cell-label\">設定</span>詞元基本費率</th><td data-cell-label=\"費率表\"><span class=\"card-cell-label\">費率表</span>基本費率</td><td data-cell-label=\"費用\"><span class=\"card-cell-label\">費用</span><div><span>輸入 · 輸入 Token</span> <b>$0.0004</b> <span class=\"price-unit\">/ 1K Token</span></div><div><span>輸出 · 輸出 Token</span> <b>$0</b> <span class=\"price-unit\">/ 1K Token</span></div><div><span>輸入 · 讀取快取</span> <b>—</b> <span class=\"price-unit\">/ 1K Token</span></div><div><span>輸入 · 寫入快取</span> <b>—</b> <span class=\"price-unit\">/ 1K Token</span></div><div><span>輸入 · 寫入快取，1 小時</span> <b>—</b> <span class=\"price-unit\">/ 1K Token</span></div></td></tr></tbody></table></div></div><p class=\"note-s\">Ailoot 會在請求前預留估算金額。取得結果後，依實測用量結算最終費用。串流結算採用最終用量紀錄。<a href=\"/docs/zh-hant-tw/billing/reserve/\">預留金額與結算的運作方式 →</a></p></section><section class=\"card-section\" data-card-section=\"examples\"><h3 tabindex=\"-1\">請求範例</h3><h4>Ailoot Ultra · 嵌入向量</h4><div class=\"code-group\"><div class=\"cg-bar\"><div class=\"cg-tabs\" role=\"tablist\" aria-label=\"程式碼版本\"><button class=\"cg-tab\" id=\"model-code-1487-tab-0\" role=\"tab\" type=\"button\" aria-controls=\"model-code-1487-panel-0\" aria-selected=\"true\" tabindex=\"0\">curl</button><button class=\"cg-tab\" id=\"model-code-1487-tab-1\" role=\"tab\" type=\"button\" aria-controls=\"model-code-1487-panel-1\" aria-selected=\"false\" tabindex=\"-1\">Python SDK</button></div><div class=\"cg-tools\"><button class=\"cg-btn cg-copy\" type=\"button\" aria-label=\"複製程式碼\"><svg class=\"cp\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.4\"><rect x=\"5.25\" y=\"5.25\" width=\"8.5\" height=\"8.5\" rx=\"1.75\"/><path d=\"M10.75 5.25V3.5a1.25 1.25 0 0 0-1.25-1.25H3.5A1.25 1.25 0 0 0 2.25 3.5v6a1.25 1.25 0 0 0 1.25 1.25h1.75\"/></svg><svg class=\"ok\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.4\"><path d=\"m3 8.5 3.25 3.25L13 5\"/></svg></button></div></div><div class=\"cg-body\"><div class=\"cg-pane\" id=\"model-code-1487-panel-0\" role=\"tabpanel\" aria-labelledby=\"model-code-1487-tab-0\"><pre data-lang=\"bash\"><code>set -eu\n: &quot;${AILOOT_API_KEY:?Set your Ailoot API key}&quot;\npython3 - &lt;&lt;&#39;PY_REQUEST&#39;\nimport json,os\nfrom pathlib import Path\np=json.loads(&#39;{&quot;model&quot;: &quot;google/gemini-embedding-2&quot;, &quot;input&quot;: [&quot;First document&quot;, &quot;Second document&quot;]}&#39;)\n\nPath(&quot;request.json&quot;).write_text(json.dumps(p,ensure_ascii=False))\nPY_REQUEST\ncurl --fail-with-body --silent --show-error https://api.ailoot.ai/v1/embeddings \\\n  -H &quot;Authorization: Bearer $AILOOT_API_KEY&quot; -H &#39;Content-Type: application/json&#39; \\\n  --data-binary @request.json -D response-headers.txt -o result.json\npython3 - &lt;&lt;&#39;PY_RESULT&#39;\nimport json\nfrom pathlib import Path\nr=json.loads(Path(&quot;result.json&quot;).read_text())\nfor x in r.get(&quot;data&quot;,[]): print(json.dumps({&quot;index&quot;:x.get(&quot;index&quot;),&quot;embedding&quot;:x.get(&quot;embedding&quot;)}))\nPY_RESULT\n</code></pre></div><div class=\"cg-pane\" id=\"model-code-1487-panel-1\" role=\"tabpanel\" aria-labelledby=\"model-code-1487-tab-1\" hidden><pre data-lang=\"python\"><code>from openai import OpenAI\nimport os\n\nclient=OpenAI(base_url=&quot;https://api.ailoot.ai/v1&quot;,api_key=os.environ[&quot;AILOOT_API_KEY&quot;],max_retries=0)\nresult=client.embeddings.create(model=&#39;google/gemini-embedding-2&#39;,input=[&quot;First document&quot;,&quot;Second document&quot;])\nprint(result)\nfor item in result.data:print(item.index,item.embedding)\n</code></pre></div></div></div></section><section class=\"card-section\" data-card-section=\"results\"><h3 tabindex=\"-1\">接收並儲存結果</h3><h4>Ailoot Ultra · 嵌入向量</h4><p class=\"note-s\">json</p><div class=\"card-result-process\" data-all-results><h5>保留所有已完成的結果</h5><p class=\"note-s\">請保留所有完整傳回的回應、檔案與內容區塊。</p><p class=\"note-s\">保留每個向量及其索引。向量數量必須與輸入數量相同，且維度必須一致。</p></div><div class=\"card-result-process\" data-unknown-recovery><h5>需要檢查原始回應時</h5><p class=\"note-s\">此流程未引入嵌入向量任務端點。</p></div><details class=\"card-about\" data-output-fields><summary>回應欄位</summary><div class=\"tw\" data-card-table=\"output\"><table><thead><tr><th>欄位</th><th>類型</th></tr></thead><tbody><tr><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">object</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span>string</td></tr><tr><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">model</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span>string</td></tr><tr><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">data[].index</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span>integer</td></tr><tr><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">data[].embedding</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span>finite float[]</td></tr><tr><th data-cell-label=\"欄位\" scope=\"row\"><span class=\"card-cell-label\">欄位</span><code class=\"card-field-name\">usage</code></th><td data-cell-label=\"類型\" data-field-type><span class=\"card-cell-label\">類型</span>object</td></tr></tbody></table></div></details><details class=\"card-about\" data-method-errors><summary>錯誤與後續步驟</summary><div class=\"tw\" data-card-table=\"errors\"><table><thead><tr><th>回應</th><th>條件</th><th>下一步</th></tr></thead><tbody><tr><th data-cell-label=\"回應\" scope=\"row\"><span class=\"card-cell-label\">回應</span>400 · <code>invalid_request_error</code></th><td data-cell-label=\"條件\"><span class=\"card-cell-label\">條件</span>必要欄位、素材表示方式或參數值無效</td><td data-cell-label=\"下一步\"><span class=\"card-cell-label\">下一步</span>提出新的建立請求前，先修正指定欄位。</td></tr></tbody></table></div></details></section><section class=\"card-section\" data-card-section=\"aliases\"><h3 tabindex=\"-1\">別名</h3><h4>模型別名</h4><p class=\"note-s\"><span data-model-alias-route=\"Ultra\"><b>Ailoot Ultra</b> <a href=\"#m=google%2Fgemini-embedding-2&amp;route=Ultra&amp;caller=google%2Fgemini-embedding-2&amp;fmt=embeddings\"><code>google/gemini-embedding-2</code></a></span></p><h4>方法路徑別名</h4><p class=\"note-s\">請使用上方列出的 API 方法路徑。</p><h4>相關呼叫用 ID</h4><p class=\"note-s\"><a href=\"#m=google%2Fgemini-embedding-2&amp;route=Ultra&amp;caller=google%2Fgemini-embedding-2&amp;fmt=embeddings\"><code>google/gemini-embedding-2</code></a></p></section></div>",
      "method_identity": {
        "effective_request_model_id": "google/gemini-embedding-2",
        "fmt": "embeddings",
        "http": "POST",
        "path": "/v1/embeddings",
        "request_model_id": "google/gemini-embedding-2",
        "route_label": "Ultra"
      },
      "method_key": "Ultra|embeddings|/v1/embeddings|google%2Fgemini-embedding-2",
      "ordinal": 0,
      "rawMethod": {
        "available": null,
        "cache_read": null,
        "cache_write": null,
        "cache_write_1h": null,
        "contract": {
          "data": {
            "all_results": "Keep every vector with its index. Vector count must equal input count; dimensions must be consistent.",
            "errors": [
              {
                "code": null,
                "condition": "必要欄位、素材表示方式或參數值無效",
                "http_status": 400,
                "recovery": "提出新的建立請求前，先修正指定欄位。",
                "type": "invalid_request_error"
              }
            ],
            "hints": [],
            "ignored_fields": [],
            "lifecycle": {
              "create": {
                "http": "POST",
                "path": "/v1/embeddings"
              },
              "job_read": null,
              "mode": "synchronous_json",
              "unknown": "此流程未引入嵌入向量任務端點。"
            },
            "material_combinations": [
              {
                "alternatives": [
                  "string",
                  "string[]",
                  "nonnegative_integer_token_array",
                  "nonnegative_integer_token_array[]"
                ],
                "mode": "text_to_embedding"
              }
            ],
            "operation_modes": [
              "single_embedding",
              "batched_embeddings"
            ],
            "outputs": {
              "all_results": "保留每個向量及其索引。向量數量必須與輸入數量相同，且維度必須一致。",
              "default_dimensions": null,
              "family": "embedding",
              "fields": [
                {
                  "description": null,
                  "name": "object",
                  "type": "string"
                },
                {
                  "description": null,
                  "name": "model",
                  "type": "string"
                },
                {
                  "description": null,
                  "name": "data[].index",
                  "type": "integer"
                },
                {
                  "description": null,
                  "name": "data[].embedding",
                  "type": "finite float[]"
                },
                {
                  "description": null,
                  "name": "usage",
                  "type": "object"
                }
              ],
              "format": "json"
            },
            "parameters": [
              {
                "availability": "source_interface",
                "default": null,
                "default_known": false,
                "enum": [
                  "google/gemini-embedding-2"
                ],
                "enum_known": true,
                "name": "model",
                "required": true,
                "type": "string"
              },
              {
                "availability": "source_interface",
                "budget": {
                  "maximum": 8192,
                  "text_unit": "UTF8 位元組",
                  "token_unit": "token 陣列元素"
                },
                "conditions": "批次不得為空，且各項目類型須一致。Token ID 須為非負整數。",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "min_items": 1,
                "name": "input",
                "required": true,
                "type": "string|string[]|integer[]|integer[][]"
              },
              {
                "availability": "source_interface",
                "default": "float",
                "default_known": true,
                "enum": [
                  "float"
                ],
                "enum_known": true,
                "name": "encoding_format",
                "required": false,
                "type": "string"
              },
              {
                "availability": "unsupported",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "minimum": 1,
                "name": "dimensions",
                "required": false,
                "type": "integer"
              },
              {
                "availability": "pass_through_metadata",
                "conditions": "來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "name": "user",
                "required": false,
                "type": "json_value"
              },
              {
                "availability": "pass_through_metadata",
                "conditions": "來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "name": "session_id",
                "required": false,
                "type": "json_value"
              },
              {
                "availability": "pass_through_metadata",
                "conditions": "來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "name": "trace",
                "required": false,
                "type": "json_value"
              },
              {
                "availability": "source_interface",
                "conditions": "provider.options 遭拒絕",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "name": "provider",
                "required": false,
                "type": "object"
              }
            ],
            "profile_binding": "Exact existing Ailoot model and method; interface constraints below do not assert provider qualification.",
            "unsupported": [
              "mixed input kinds",
              "empty input",
              "image/audio/file objects",
              "encoding_format=base64",
              "dimensions override"
            ]
          },
          "hints": [
            "保留每個向量的索引與維度。",
            "即使模型名稱標示為多模態，此指定路徑也不接受圖片物件。"
          ],
          "input": {
            "content_type": "application/json",
            "dimensions_override": false,
            "encoding_format": [
              "float"
            ],
            "input_shapes": [
              "string",
              "string[]",
              "nonnegative_integer_token_array",
              "nonnegative_integer_token_array[]"
            ],
            "material_types": [
              "text",
              "token_ids"
            ],
            "max_input_budget_units": 8192,
            "multimodal_objects": false,
            "required": [
              "model",
              "input"
            ]
          },
          "lifecycle": {
            "mode": "synchronous_json",
            "unknown": "no embedding job endpoint inferred"
          },
          "manufacturer_capability": null,
          "method": {
            "http": "POST",
            "path": "/v1/embeddings"
          },
          "method_aliases": [],
          "operation_modes": [
            "text_to_embedding"
          ],
          "output": {
            "default_dimensions": null,
            "family": "embedding",
            "format": "json",
            "http_success": 200,
            "vectors": "one dense float vector per input; indices/model/usage validated"
          }
        },
        "ctx": 8192,
        "declared_pricing_profiles": [
          {
            "dimensions": {
              "regime": "base"
            },
            "label": "詞元基本費率",
            "units": [
              {
                "amount": "0.0004000",
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "input_price",
                "label": "Input tokens",
                "native_amount_usd_per_unit": "0.0000004",
                "native_quantity": 1,
                "native_unit": "input_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "input_token"
              },
              {
                "amount": "0",
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "output_price",
                "label": "Output tokens",
                "native_amount_usd_per_unit": "0",
                "native_quantity": 1,
                "native_unit": "output_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "out",
                "unit": "output_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_read_price",
                "label": "Cache read",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "cached_input_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "cached_input_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_write_price",
                "label": "Cache write",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "generic_cache_creation_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "generic_cache_creation_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_write_1h_price",
                "label": "Cache write, 1 hour",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "one_hour_cache_creation_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "one_hour_cache_creation_token"
              }
            ]
          }
        ],
        "examples": [
          {
            "code": "set -eu\n: \"${AILOOT_API_KEY:?Set your Ailoot API key}\"\npython3 - <<'PY_REQUEST'\nimport json,os\nfrom pathlib import Path\np=json.loads('{\"model\": \"google/gemini-embedding-2\", \"input\": [\"First document\", \"Second document\"]}')\n\nPath(\"request.json\").write_text(json.dumps(p,ensure_ascii=False))\nPY_REQUEST\ncurl --fail-with-body --silent --show-error https://api.ailoot.ai/v1/embeddings \\\n  -H \"Authorization: Bearer $AILOOT_API_KEY\" -H 'Content-Type: application/json' \\\n  --data-binary @request.json -D response-headers.txt -o result.json\npython3 - <<'PY_RESULT'\nimport json\nfrom pathlib import Path\nr=json.loads(Path(\"result.json\").read_text())\nfor x in r.get(\"data\",[]): print(json.dumps({\"index\":x.get(\"index\"),\"embedding\":x.get(\"embedding\")}))\nPY_RESULT\n",
            "label": "curl · retained exact creation",
            "language": "bash"
          },
          {
            "code": "from openai import OpenAI\nimport os\n\nclient=OpenAI(base_url=\"https://api.ailoot.ai/v1\",api_key=os.environ[\"AILOOT_API_KEY\"],max_retries=0)\nresult=client.embeddings.create(model='google/gemini-embedding-2',input=[\"First document\",\"Second document\"])\nprint(result)\nfor item in result.data:print(item.index,item.embedding)\n",
            "label": "Python SDK · all vectors",
            "language": "python"
          }
        ],
        "family": "openai",
        "fast_multiplier": 1,
        "flex_multiplier": 1,
        "fmt": "embeddings",
        "hints": [
          "Keep every vector index and dimension.",
          "Multimodal model name does not admit image objects on this exact path."
        ],
        "http": "POST",
        "in": 0.4,
        "input": [
          "text",
          "token_ids"
        ],
        "label": "Эмбеддинги",
        "max_out": null,
        "max_reasoning_effort_multiplier": 1,
        "method_aliases": [],
        "out": 0,
        "output": [
          "embedding"
        ],
        "path": "/v1/embeddings",
        "price_conditions": [
          {
            "label": "快速模式",
            "value": "標準費率",
            "when": "選取快速模式時"
          },
          {
            "label": "flex 模式",
            "value": "標準費率",
            "when": "選取 flex 模式時"
          },
          {
            "label": "最高推理強度",
            "value": "標準費率",
            "when": "最高推理強度採用 default 調整值時"
          }
        ],
        "pricing": {
          "billing_mode": "token",
          "image_input_price": null,
          "image_output_price": null,
          "per_request_price": null
        },
        "pricing_profiles": [
          {
            "dimensions": {
              "regime": "base"
            },
            "label": "Base token rates",
            "units": [
              {
                "amount": "0.0004000",
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "input_price",
                "label": "Input tokens",
                "native_amount_usd_per_unit": "0.0000004",
                "native_quantity": 1,
                "native_unit": "input_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "input_token"
              },
              {
                "amount": "0",
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "output_price",
                "label": "Output tokens",
                "native_amount_usd_per_unit": "0",
                "native_quantity": 1,
                "native_unit": "output_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "out",
                "unit": "output_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_read_price",
                "label": "Cache read",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "cached_input_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "cached_input_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_write_price",
                "label": "Cache write",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "generic_cache_creation_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "generic_cache_creation_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_write_1h_price",
                "label": "Cache write, 1 hour",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "one_hour_cache_creation_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "one_hour_cache_creation_token"
              }
            ]
          }
        ],
        "request_model_id": "google/gemini-embedding-2",
        "route_label": "Ultra",
        "status_reads": [],
        "tiers": [],
        "units": [
          {
            "amount": "0.0004000",
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "input_price",
            "label": "Input tokens",
            "native_amount_usd_per_unit": "0.0000004",
            "native_quantity": 1,
            "native_unit": "input_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "input_token"
          },
          {
            "amount": "0",
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "output_price",
            "label": "Output tokens",
            "native_amount_usd_per_unit": "0",
            "native_quantity": 1,
            "native_unit": "output_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "out",
            "unit": "output_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_read_price",
            "label": "Cache read",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "cached_input_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "cached_input_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_write_price",
            "label": "Cache write",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "generic_cache_creation_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "generic_cache_creation_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_write_1h_price",
            "label": "Cache write, 1 hour",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "one_hour_cache_creation_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "one_hour_cache_creation_token"
          }
        ]
      }
    }
  ],
  "model_id": "google/gemini-embedding-2",
  "nativeProvenance": {
    "input_facts_canonical_sha256": "2354a94a31dc89ddcda0b8fa6cfda865798f06ecc46541397bcf6bd90c86a0ea",
    "input_html_sha256": "232c73b0962400a6f205fe5802b8fa6643f158498a02bdbf35be50a55390bf8d",
    "private_audit_sha256": "7a32d14d5dcc44980d1bb7ce457519ed277173a811d45dee104e153fd2374475",
    "role": "historical-normalized-input-audit-hashes",
    "schema": "ailoot-native-model-provenance-v2"
  },
  "page": {
    "canonical": "https://ailoot.ai/models/zh-hant-tw/google-gemini-embedding-2/",
    "description": "Gemini Embedding 2 將文字、圖片、音訊、影片與 PDF 映射至共用數值空間。其向量支援跨模態搜尋、檢索、分類與分群，並提供彈性維度及 8,192 token 輸入上限。",
    "locale": "zh-hant-tw",
    "md_url": "https://ailoot.ai/models/zh-hant-tw/google-gemini-embedding-2/index.md",
    "title": "Google: Gemini Embedding 2 — Ailoot",
    "url": "https://ailoot.ai/models/zh-hant-tw/google-gemini-embedding-2/"
  },
  "rawModel": {
    "about": "Gemini Embedding 2 是 Google 用於數值表示文字、圖片、影片、音訊與 PDF 的多模態嵌入模型。它將不同媒體型別映射至共用空間，讓應用程式跨型別比較意義。結果是數值向量，可用於語意搜尋、文件檢索、推薦、分類或分群；不是書面答案或生成的媒體檔案。Google 記載其語意範圍涵蓋超過 100 種語言。\n\n知識庫可先為來源段落建立向量，將使用者查詢與向量比較，再檢索相關資料。另一個文字模型隨後可使用這些來源撰寫答案。媒體集合可以用文字描述搜尋相關圖片或影片，圖片也能作為查詢。請保留各向量與原始內容的連結，包括頁面或片段參照，讓檢索結果可被檢視，並在原始上下文中呈現。\n\n整體輸入上限為 8,192 token。穩定版模型指南允許最多六張 PNG 或 JPEG 圖片、最長 180 秒 MP3 或 WAV 音訊，以及最長 120 秒 MP4 或 MOV 影片。文件所載影片編碼格式為 H264、H265、AV1、VP9。影片處理最多使用 32 個影格：32 秒以內片段每秒取樣一格，較長片段則均勻取樣至 32 格。該影片輸入不處理音軌；聲音與檢索相關時，請另外嵌入音訊。\n\nPDF 輸入接受一個最多六頁的檔案。Google 建議每個 PDF 一頁以獲得最佳品質。請將較大來源拆成有意義的頁面或章節，並保留與原始文件的關係。選擇代表可檢索內容的摘錄，不要只因符合上限就合併無關資料。混合媒體請求仍適用共用 token 邊界。每個 PDF 頁面除擷取文字 token 外，還消耗 258 個視覺 token。Google 文件所載流程中，超過共用 8,192 token 上限的內容會被截斷而不報錯。\n\n輸出維度可在 128 至 3,072 之間彈性選擇，預設為 3,072，建議大小為 768、1,536、3,072。模型使用 Matryoshka Representation Learning，因此向量前綴在較小維度下仍有用。指南記載，預設及縮短向量都會自動正規化。請為應用程式比較的記錄與查詢選擇一致維度；要求的大小改變數值表示，不改變來源內容本身。\n\n純文字任務請將用途納入文字，而非使用舊的 task_type 欄位。Google 區分非對稱檢索與對稱比較。搜尋查詢使用 “task: search result | query: {content}”，來源文件使用 “title: {title} | text: {content}”；沒有標題時使用 “title: none”。問答、事實查核及程式碼檢索任務有各自的查詢前綴。分類、分群或句子相似度，請在兩端一致使用相同任務格式。指南通常建議，不要在合併多模態表示的文字部分加入任務前綴。\n\n輸入結構決定結果表示一個合併物件，或多個獨立項目。一起提供的多個部分會建立聚合嵌入；分開的 Content 物件則為每個項目建立獨立嵌入。文字與圖片貼文可透過合併表示捕捉兩者關係。需獨立搜尋的記錄，請保持分開。這會影響檢索粒度：整篇貼文一個向量，不同於每個段落或圖片各一個向量。\n\n指南指出，Gemini Embedding 001 與 Gemini Embedding 2 向量位於不相容空間，不能直接比較。從舊模型移轉的集合必須為新空間重新建立嵌入。請讓模型選擇與維度符合正在比較的向量，並將原始文字和媒體與數值索引分開保留。嵌入相似度是檢索訊號，不是文件為何回答使用者問題的事實解釋。\n\n實際目錄中，若產品照片與核准說明應作為同一物件檢索，請一起嵌入。文件集合請嵌入聚焦段落，與依用途設定格式的查詢比較，再將來源段落和搜尋結果一起呈現。音訊或影片請選擇描述可搜尋事件的區段，並保留原始時間範圍。實用產物是連結來源證據的數值表示，供應用程式下一個搜尋或分析步驟使用。",
    "alias_of": null,
    "aliases": [],
    "author": "Google",
    "available": null,
    "canonical_model": "google/gemini-embedding-2",
    "capabilities": {
      "context_length": 8192,
      "manufacturer_input": [
        "text",
        "image",
        "file",
        "audio",
        "video"
      ],
      "manufacturer_output": [
        "embeddings"
      ]
    },
    "card_routes": [
      {
        "label": "Ultra",
        "rates": [
          {
            "amount": "0.0004000",
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "input_price",
            "label": "Input tokens",
            "native_amount_usd_per_unit": "0.0000004",
            "native_quantity": 1,
            "native_unit": "input_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "input_token"
          },
          {
            "amount": "0",
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "output_price",
            "label": "Output tokens",
            "native_amount_usd_per_unit": "0",
            "native_quantity": 1,
            "native_unit": "output_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "out",
            "unit": "output_token"
          }
        ],
        "summary": "完整的設定價格資訊請見詳細資料。"
      }
    ],
    "ctx": 8192,
    "entity_type": "model",
    "formats": [
      "embeddings"
    ],
    "id": "google/gemini-embedding-2",
    "input": [
      "text",
      "token_ids"
    ],
    "kind": "embedding",
    "max_out": null,
    "methods": [
      {
        "available": null,
        "cache_read": null,
        "cache_write": null,
        "cache_write_1h": null,
        "contract": {
          "data": {
            "all_results": "Keep every vector with its index. Vector count must equal input count; dimensions must be consistent.",
            "errors": [
              {
                "code": null,
                "condition": "必要欄位、素材表示方式或參數值無效",
                "http_status": 400,
                "recovery": "提出新的建立請求前，先修正指定欄位。",
                "type": "invalid_request_error"
              }
            ],
            "hints": [],
            "ignored_fields": [],
            "lifecycle": {
              "create": {
                "http": "POST",
                "path": "/v1/embeddings"
              },
              "job_read": null,
              "mode": "synchronous_json",
              "unknown": "此流程未引入嵌入向量任務端點。"
            },
            "material_combinations": [
              {
                "alternatives": [
                  "string",
                  "string[]",
                  "nonnegative_integer_token_array",
                  "nonnegative_integer_token_array[]"
                ],
                "mode": "text_to_embedding"
              }
            ],
            "operation_modes": [
              "single_embedding",
              "batched_embeddings"
            ],
            "outputs": {
              "all_results": "保留每個向量及其索引。向量數量必須與輸入數量相同，且維度必須一致。",
              "default_dimensions": null,
              "family": "embedding",
              "fields": [
                {
                  "description": null,
                  "name": "object",
                  "type": "string"
                },
                {
                  "description": null,
                  "name": "model",
                  "type": "string"
                },
                {
                  "description": null,
                  "name": "data[].index",
                  "type": "integer"
                },
                {
                  "description": null,
                  "name": "data[].embedding",
                  "type": "finite float[]"
                },
                {
                  "description": null,
                  "name": "usage",
                  "type": "object"
                }
              ],
              "format": "json"
            },
            "parameters": [
              {
                "availability": "source_interface",
                "default": null,
                "default_known": false,
                "enum": [
                  "google/gemini-embedding-2"
                ],
                "enum_known": true,
                "name": "model",
                "required": true,
                "type": "string"
              },
              {
                "availability": "source_interface",
                "budget": {
                  "maximum": 8192,
                  "text_unit": "UTF8 位元組",
                  "token_unit": "token 陣列元素"
                },
                "conditions": "批次不得為空，且各項目類型須一致。Token ID 須為非負整數。",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "min_items": 1,
                "name": "input",
                "required": true,
                "type": "string|string[]|integer[]|integer[][]"
              },
              {
                "availability": "source_interface",
                "default": "float",
                "default_known": true,
                "enum": [
                  "float"
                ],
                "enum_known": true,
                "name": "encoding_format",
                "required": false,
                "type": "string"
              },
              {
                "availability": "unsupported",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "minimum": 1,
                "name": "dimensions",
                "required": false,
                "type": "integer"
              },
              {
                "availability": "pass_through_metadata",
                "conditions": "來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "name": "user",
                "required": false,
                "type": "json_value"
              },
              {
                "availability": "pass_through_metadata",
                "conditions": "來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "name": "session_id",
                "required": false,
                "type": "json_value"
              },
              {
                "availability": "pass_through_metadata",
                "conditions": "來源允許此 JSON 中繼資料欄位；確切的上游語意依模型而異。",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "name": "trace",
                "required": false,
                "type": "json_value"
              },
              {
                "availability": "source_interface",
                "conditions": "provider.options 遭拒絕",
                "default": null,
                "default_known": false,
                "enum": null,
                "enum_known": false,
                "name": "provider",
                "required": false,
                "type": "object"
              }
            ],
            "profile_binding": "Exact existing Ailoot model and method; interface constraints below do not assert provider qualification.",
            "unsupported": [
              "mixed input kinds",
              "empty input",
              "image/audio/file objects",
              "encoding_format=base64",
              "dimensions override"
            ]
          },
          "hints": [
            "保留每個向量的索引與維度。",
            "即使模型名稱標示為多模態，此指定路徑也不接受圖片物件。"
          ],
          "input": {
            "content_type": "application/json",
            "dimensions_override": false,
            "encoding_format": [
              "float"
            ],
            "input_shapes": [
              "string",
              "string[]",
              "nonnegative_integer_token_array",
              "nonnegative_integer_token_array[]"
            ],
            "material_types": [
              "text",
              "token_ids"
            ],
            "max_input_budget_units": 8192,
            "multimodal_objects": false,
            "required": [
              "model",
              "input"
            ]
          },
          "lifecycle": {
            "mode": "synchronous_json",
            "unknown": "no embedding job endpoint inferred"
          },
          "manufacturer_capability": null,
          "method": {
            "http": "POST",
            "path": "/v1/embeddings"
          },
          "method_aliases": [],
          "operation_modes": [
            "text_to_embedding"
          ],
          "output": {
            "default_dimensions": null,
            "family": "embedding",
            "format": "json",
            "http_success": 200,
            "vectors": "one dense float vector per input; indices/model/usage validated"
          }
        },
        "ctx": 8192,
        "declared_pricing_profiles": [
          {
            "dimensions": {
              "regime": "base"
            },
            "label": "詞元基本費率",
            "units": [
              {
                "amount": "0.0004000",
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "input_price",
                "label": "Input tokens",
                "native_amount_usd_per_unit": "0.0000004",
                "native_quantity": 1,
                "native_unit": "input_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "input_token"
              },
              {
                "amount": "0",
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "output_price",
                "label": "Output tokens",
                "native_amount_usd_per_unit": "0",
                "native_quantity": 1,
                "native_unit": "output_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "out",
                "unit": "output_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_read_price",
                "label": "Cache read",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "cached_input_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "cached_input_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_write_price",
                "label": "Cache write",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "generic_cache_creation_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "generic_cache_creation_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_write_1h_price",
                "label": "Cache write, 1 hour",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "one_hour_cache_creation_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "one_hour_cache_creation_token"
              }
            ]
          }
        ],
        "examples": [
          {
            "code": "set -eu\n: \"${AILOOT_API_KEY:?Set your Ailoot API key}\"\npython3 - <<'PY_REQUEST'\nimport json,os\nfrom pathlib import Path\np=json.loads('{\"model\": \"google/gemini-embedding-2\", \"input\": [\"First document\", \"Second document\"]}')\n\nPath(\"request.json\").write_text(json.dumps(p,ensure_ascii=False))\nPY_REQUEST\ncurl --fail-with-body --silent --show-error https://api.ailoot.ai/v1/embeddings \\\n  -H \"Authorization: Bearer $AILOOT_API_KEY\" -H 'Content-Type: application/json' \\\n  --data-binary @request.json -D response-headers.txt -o result.json\npython3 - <<'PY_RESULT'\nimport json\nfrom pathlib import Path\nr=json.loads(Path(\"result.json\").read_text())\nfor x in r.get(\"data\",[]): print(json.dumps({\"index\":x.get(\"index\"),\"embedding\":x.get(\"embedding\")}))\nPY_RESULT\n",
            "label": "curl · retained exact creation",
            "language": "bash"
          },
          {
            "code": "from openai import OpenAI\nimport os\n\nclient=OpenAI(base_url=\"https://api.ailoot.ai/v1\",api_key=os.environ[\"AILOOT_API_KEY\"],max_retries=0)\nresult=client.embeddings.create(model='google/gemini-embedding-2',input=[\"First document\",\"Second document\"])\nprint(result)\nfor item in result.data:print(item.index,item.embedding)\n",
            "label": "Python SDK · all vectors",
            "language": "python"
          }
        ],
        "family": "openai",
        "fast_multiplier": 1,
        "flex_multiplier": 1,
        "fmt": "embeddings",
        "hints": [
          "Keep every vector index and dimension.",
          "Multimodal model name does not admit image objects on this exact path."
        ],
        "http": "POST",
        "in": 0.4,
        "input": [
          "text",
          "token_ids"
        ],
        "label": "Эмбеддинги",
        "max_out": null,
        "max_reasoning_effort_multiplier": 1,
        "method_aliases": [],
        "out": 0,
        "output": [
          "embedding"
        ],
        "path": "/v1/embeddings",
        "price_conditions": [
          {
            "label": "快速模式",
            "value": "標準費率",
            "when": "選取快速模式時"
          },
          {
            "label": "flex 模式",
            "value": "標準費率",
            "when": "選取 flex 模式時"
          },
          {
            "label": "最高推理強度",
            "value": "標準費率",
            "when": "最高推理強度採用 default 調整值時"
          }
        ],
        "pricing": {
          "billing_mode": "token",
          "image_input_price": null,
          "image_output_price": null,
          "per_request_price": null
        },
        "pricing_profiles": [
          {
            "dimensions": {
              "regime": "base"
            },
            "label": "Base token rates",
            "units": [
              {
                "amount": "0.0004000",
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "input_price",
                "label": "Input tokens",
                "native_amount_usd_per_unit": "0.0000004",
                "native_quantity": 1,
                "native_unit": "input_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "input_token"
              },
              {
                "amount": "0",
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "output_price",
                "label": "Output tokens",
                "native_amount_usd_per_unit": "0",
                "native_quantity": 1,
                "native_unit": "output_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "out",
                "unit": "output_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_read_price",
                "label": "Cache read",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "cached_input_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "cached_input_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_write_price",
                "label": "Cache write",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "generic_cache_creation_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "generic_cache_creation_token"
              },
              {
                "amount": null,
                "amount_unit": "usd_per_thousand_tokens",
                "billing_input": true,
                "estimate_only": false,
                "key": "cache_write_1h_price",
                "label": "Cache write, 1 hour",
                "native_amount_usd_per_unit": null,
                "native_quantity": 1,
                "native_unit": "one_hour_cache_creation_token",
                "public_unit_label": "/ 1K tokens",
                "quantity": 1000,
                "quantity_is_estimate": false,
                "rate_role": "typed_native_retail_rate",
                "side": "in",
                "unit": "one_hour_cache_creation_token"
              }
            ]
          }
        ],
        "request_model_id": "google/gemini-embedding-2",
        "route_label": "Ultra",
        "status_reads": [],
        "tiers": [],
        "units": [
          {
            "amount": "0.0004000",
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "input_price",
            "label": "Input tokens",
            "native_amount_usd_per_unit": "0.0000004",
            "native_quantity": 1,
            "native_unit": "input_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "input_token"
          },
          {
            "amount": "0",
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "output_price",
            "label": "Output tokens",
            "native_amount_usd_per_unit": "0",
            "native_quantity": 1,
            "native_unit": "output_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "out",
            "unit": "output_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_read_price",
            "label": "Cache read",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "cached_input_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "cached_input_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_write_price",
            "label": "Cache write",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "generic_cache_creation_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "generic_cache_creation_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_write_1h_price",
            "label": "Cache write, 1 hour",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "one_hour_cache_creation_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "one_hour_cache_creation_token"
          }
        ]
      }
    ],
    "model_aliases": [
      {
        "canonical_model_id": "google/gemini-embedding-2",
        "request_model_id": "google/gemini-embedding-2",
        "route_label": "Ultra"
      }
    ],
    "name": "Google: Gemini Embedding 2",
    "price": {
      "in": 0.4,
      "in_label": null,
      "out": 0,
      "out_label": null,
      "scope_label": "Token rates",
      "sort_in": 0.4,
      "sort_out": 0,
      "varies": false
    },
    "pricing_profiles": [
      {
        "dimensions": {
          "regime": "base"
        },
        "label": "Эмбеддинги · Base token rates",
        "units": [
          {
            "amount": "0.0004000",
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "input_price",
            "label": "Input tokens",
            "native_amount_usd_per_unit": "0.0000004",
            "native_quantity": 1,
            "native_unit": "input_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "input_token"
          },
          {
            "amount": "0",
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "output_price",
            "label": "Output tokens",
            "native_amount_usd_per_unit": "0",
            "native_quantity": 1,
            "native_unit": "output_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "out",
            "unit": "output_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_read_price",
            "label": "Cache read",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "cached_input_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "cached_input_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_write_price",
            "label": "Cache write",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "generic_cache_creation_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "generic_cache_creation_token"
          },
          {
            "amount": null,
            "amount_unit": "usd_per_thousand_tokens",
            "billing_input": true,
            "estimate_only": false,
            "key": "cache_write_1h_price",
            "label": "Cache write, 1 hour",
            "native_amount_usd_per_unit": null,
            "native_quantity": 1,
            "native_unit": "one_hour_cache_creation_token",
            "public_unit_label": "/ 1K tokens",
            "quantity": 1000,
            "quantity_is_estimate": false,
            "rate_role": "typed_native_retail_rate",
            "side": "in",
            "unit": "one_hour_cache_creation_token"
          }
        ]
      }
    ],
    "public_id": "google/gemini-embedding-2",
    "short": "Gemini Embedding 2 將文字、圖片、音訊、影片與 PDF 映射至共用數值空間。其向量支援跨模態搜尋、檢索、分類與分群，並提供彈性維度及 8,192 token 輸入上限。"
  },
  "renderer_schema": {
    "method_order": "Original DTO methods order; every exact route/format/path/caller survives.",
    "prices": "Original public DTO fields and original native display HTML; no flattened or normalized offers."
  },
  "representation": "exact-public-dto-and-native-renderer-html",
  "representationNotes": {
    "current_reference": {
      "about_json_pointer": "/aboutHtml",
      "methods": [
        {
          "contract_json_pointer": "/methods/0/rawMethod/contract",
          "html_json_pointer": "/methods/0/html",
          "method_ordinal": 0
        }
      ],
      "role": "current-semantic-reference"
    },
    "raw_input": {
      "examples_role": "historical-input-not-current-ready-examples",
      "json_pointers": [
        "/rawModel",
        "/methods/0/rawMethod"
      ],
      "role": "historical-owner-input"
    },
    "schema": "ailoot-native-model-representations-v1"
  },
  "schema": "ailoot-static-model-facts-v1",
  "schema_version": 1,
  "shortText": "Gemini Embedding 2 將文字、圖片、音訊、影片與 PDF 映射至共用數值空間。其向量支援跨模態搜尋、檢索、分類與分群，並提供彈性維度及 8,192 token 輸入上限。",
  "source": {
    "audit_sha256": "2e00086bcbfc28e64d0cebe97aa47c17d8d5618963027f8ffb9dc6123d7d25b1",
    "bridge_map_sha256": "1125275768b9636fc8461bc7da5061239a81ddfe508e2557843ca42c58ab0036",
    "raw_model_json_sha256": "f1d143d1b3e87189e081edcd543f596e4af07cc3fa338dc5451aa5123d91a1f4",
    "renderer_sha256": "13a3fc1b22d07359278e2249d630bfc9bb9e6416c71ba53def933fb5a903660b"
  },
  "sourceRevision": "31429d109abf030f3fc6791c98dcd83dfff1cadc33fd48567d13807aa06e5bac"
}
