日本熟妇hd丰满老熟妇,中文字幕一区二区三区在线不卡 ,亚洲成片在线观看,免费女同在线一区二区

圖搜場景快速入門

購買實例

購買實例可參考購買OpenSearch向量檢索版實例

配置實例

新購買的實例,在其詳情頁中,實例狀態為“待配置”,并且會自動部署一個與購買的查詢節點和數據節點的個數及規格一致的空實例,之后需要為該實例配置表信息>數據同步>字段配置>索引結構,之后等待索引重建完成即可正常搜索。

image.png

1. 表基礎信息

表管理點擊“表添加",輸入表名稱,設置數據分片數數據更新資源數,場景模板選擇:向量(圖片搜索),數據處理選擇:已有向量數據,點擊下一步,

image.png

配置說明

  • 表名稱:可自定義。

  • 數據分片數:分片數設置時,請填寫不超過256的正整數, 用于提升全量構建速度、單次查詢性能。(部分存量實例,仍需各索引表分片數保持一致;或至少一個索引表分片數為1,其余索引表分片數一致)

  • 數據更新資源數:數據更新所用資源數,每個索引默認免費提供2個4核8G的更新資源,超出免費額度的資源將產生費用,詳情可參考向量檢索版計費概述

  • 場景模板:向量檢索版內置了3種模板可供用戶選擇:通用、向量-圖片搜索、向量-文本語義模板。

說明

如果需要將原始數據轉為向量數據可參考端到端圖搜解決方案

2. 數據同步

配置數據源(目前支持的數據源有MaxCompute數據源和API推送數據源),這里以MaxCompute數據源為例,數據源類型選擇MaxCompute,設置Project、AccesskeyID、AccesskeySecret、Table、分組鍵partition、時間戳,可按需選擇是否開啟“自動索引重建”選擇完成之后可選擇校驗,通過后可點擊下一步:

image.png

3. 字段配置

OpenSearch會根據您選擇的場景模板,預置相關字段,并會將全量數據來源中的字段(如有),自動導入字段列表中:

image

設置字段:‘向量圖片搜索’模板必須至少包含4個預置字段,id(主鍵)、vector(向量字段)、cate_id(類目字段)、vector_source_image(存儲圖片向量的字段),平臺默認會生成:

image

字段配置說明:

  • 必選字段:主鍵字段和向量字段,主鍵字段為int或string類型并且需要勾選主鍵按鈕,向量字段為float類型并且需要勾選向量字段按鈕;

  • 向量字段默認為多值的float類型,多值分隔符默認使用ha3分割符^] 進行切分(其對應utf編碼為\x1D),也可以輸入自定義多值分隔符

  • 若無需系統生成向量可刪除vector_source_image字段或取消勾選“需embedding字段”

  • 使用向量檢索,在定義字段時有位置要求,需要按照主鍵字段、命名空間字段(非必要)、向量字段的順序創建。(如上圖所示)

  • 當數據中缺少字段或字段為空時,系統將自動補充默認值,數字類型默認補0,STRING類型默認補空字符串,支持自定義默認值

4. 索引結構

4.1. 向量索引

OpenSearch會對主鍵與向量字段自動構建索引,索引名與字段名相同,只需要在控制臺配置向量索引:

image.png

高級配置,向量索引需要單獨配置參數,詳情可參考向量索引通用配置

說明
  • 主鍵字段、向量字段必須填寫,命名空間字段非必填,可以為空。

  • 僅支持選擇固定的三個字段,不支持新增。

  • 系統自動填充向量索引的配置參數,如無特殊需求,可直接點擊「確定」快速完成配置。

  • 命名空間字段:實例引擎版本為vetcor service 1.0.2及以下版本,namespace標簽字段不支持string格式類型;實例引擎版本為vetcor service 1.0.2及以上版本,無此限制。

5. 確認創建

索引配置完成后,點擊確認創建

image.png

6. 變更歷史

實例管理-變更歷史-數據源變更,可以看到創建表及新增索引及索引重建的所有FSM,全部完成之后引擎搭建完成,可以開始查詢測試:

image.png

7. 查詢測試

查詢示例

{
  "vector": [0.0019676427,0.005902928,0.021644069,0.21644068,0.12199384,0.043288138,0.007870571,0.0,0.08460863,0.041320495,0.043288138,0.035417568,0.011805856,0.055093993,0.12592913,0.017708784,0.021644069,0.0019676427,0.0,0.0,0.0019676427,0.078705706,0.1987319,0.041320495,0.039352853,0.0039352854,0.007870571,0.0039352854,0.0039352854,0.017708784,0.035417568,0.06886749,0.0019676427,0.0019676427,0.013773498,0.049191065,0.2125054,0.22824654,0.123961486,0.0039352854,0.0,0.0,0.021644069,0.14560555,0.078705706,0.1987319,0.22824654,0.005902928,0.064932205,0.0019676427,0.0019676427,0.021644069,0.027546996,0.035417568,0.22824654,0.22824654,0.1337997,0.023611711,0.009838213,0.007870571,0.0039352854,0.0039352854,0.017708784,0.20069954,0.033449925,0.005902928,0.019676426,0.035417568,0.015741142,0.029514639,0.13183205,0.123961486,0.029514639,0.0,0.027546996,0.22824654,0.15741141,0.0,0.0039352854,0.043288138,0.18889369,0.072802775,0.055093993,0.17315255,0.08460863,0.0019676427,0.007870571,0.035417568,0.22824654,0.10034977,0.009838213,0.021644069,0.062964566,0.027546996,0.015741142,0.04525578,0.086576276,0.033449925,0.023611711,0.017708784,0.0,0.0,0.03738521,0.072802775,0.16724962,0.035417568,0.031482283,0.20463483,0.043288138,0.011805856,0.0039352854,0.051158708,0.023611711,0.11412327,0.13183205,0.16134669,0.049191065,0.023611711,0.0039352854,0.0039352854,0.049191065,0.035417568,0.015741142,0.0039352854,0.03738521,0.08264099,0.094446845,0.021644069],
  "topK": 10,
  "includeVector": true
}
  • vector:具體要查詢的向量

  • topK:取top K個結果

  • 是否返回文檔中的向量信息

結果演示

image.png

詳細的查詢語法可參考下文的語法說明。

語法說明

SDK中使用向量檢索