本文介紹OSS向量檢索模式支援檢索的欄位和操作符。
支援檢索的欄位
使用
OSSUserMeta.*
欄位搜尋檔案時,請替換星號(*)為使用者自訂中繼資料的Key,系統會按照使用者自訂中繼資料的Key-Value來搜尋檔案。使用者自訂中繼資料的Key不區分大小寫,Value區分大小寫。例如要搜尋包含
x-oss-meta-location=hangzhou
使用者自訂中繼資料的檔案,您需要設定查詢條件為{"Field": "OSSUserMeta.x-oss-meta-location", "Value": "hangzhou", "Operation": "eq"}
。使用
OSSTagging.*
欄位搜尋檔案時,請替換星號(*)為對象標籤的Key,系統會按照對象標籤的Key-Value來搜尋檔案。對象標籤的Key和Value均區分大小寫。例如要搜尋包含
owner=John
標籤的檔案,您需要設定查詢條件為{"Field": "OSSTagging.owner", "Value": "John", "Operation": "eq"}
。
分類 | Field(欄位) | 欄位說明 | 是否允許檢索該欄位 | 檢索結果可能包含的欄位 | ||
語義內容檢索(不區分檔案數量) | 中繼資料檢索(檔案數量<1億) | 中繼資料檢索(1億<檔案數量<100億) | ||||
基本資料 | URI | 物件路徑 | ✓ | ✓ | ✓ | ✓ |
FileModifiedTime | 檔案修改時間* | ✓ | ✓ | ✓ | ✓ | |
Filename | 檔案名稱* | ✓ | ✓ | ✓ | ✓ | |
Size | 檔案大小* | ✓ | ✓ | ✓ | ✓ | |
MediaType | 媒體類型* | ✓ | ✓ | × | × | |
ContentType | MIME類型* | ✓ | ✓ | × | × | |
ProduceTime | 創作時間 | ✓ | ✓ | × | × | |
LatLong | 經緯度 | ✓ | ✓ | × | × | |
Title | 標題 | ✓ | ✓ | × | × | |
OSS對象資訊 | ObjectACL | 對象讀寫權限 | ✓ | ✓ | ✓ | ✓ |
ETag | ETag | ✓ | ✓ | ✓ | ✓ | |
OSSCRC64 | CRC64 | ✓ | ✓ | ✓ | ✓ | |
OSSObjectType | 物件類型 | ✓ | ✓ | ✓ | ✓ | |
OSSStorageClass | 儲存類型 | ✓ | ✓ | ✓ | ✓ | |
OSSTagging.* | 對象標籤 | ✓ | ✓ | ✓ | ✓ | |
OSSTaggingCount | 標籤數量 | ✓ | ✓ | ✓ | ✓ | |
OSSUserMeta.* | 自訂資訊 | ✓ | ✓ | ✓ | × | |
OSSExpiration | 到期時間 | ✓ | ✓ | ✓ | × | |
AccessControlAllowOrigin | 允許的跨域請求來源 | ✓ | ✓ | ✓ | × | |
AccessControlRequestMethod | 允許的跨域要求方法 | ✓ | ✓ | ✓ | × | |
ServerSideDataEncryption | Object的密碼編譯演算法 | ✓ | ✓ | ✓ | × | |
ServerSideEncryption | Object的加密方式 | ✓ | ✓ | ✓ | × | |
ServerSideEncryptionCustomerAlgorithm | 客戶自訂服務端密碼編譯演算法 | ✓ | ✓ | ✓ | × | |
ServerSideEncryptionKeyId | 服務端加密金鑰 | ✓ | ✓ | ✓ | × | |
CacheControl | HTTP可緩衝性 | ✓ | ✓ | ✓ | × | |
ContentDisposition | HTTP響應處理方式 | ✓ | ✓ | ✓ | × | |
ContentEncoding | HTTP響應編碼方式 | ✓ | ✓ | ✓ | × | |
ContentLanguage | HTTP響應語言 | ✓ | ✓ | ✓ | × | |
圖片資訊 | ImageHeight | 圖片高度 | ✓ | ✓ | × | × |
ImageWidth | 圖片寬度 | ✓ | ✓ | × | × | |
視頻資訊 | VideoHeight | 視頻高度 | ✓ | ✓ | × | × |
VideoWidth | 視頻寬度 | ✓ | ✓ | × | × | |
VideoStreams.CodecName | 編碼器名稱 | ✓ | ✓ | × | × | |
VideoStreams.Language | 語言 | ✓ | ✓ | × | × | |
VideoStreams.Bitrate | 碼率 | × | ✓ | × | × | |
VideoStreams.FrameRate | 幀率 | × | ✓ | × | × | |
VideoStreams.StartTime | 起始時間 | × | ✓ | × | × | |
VideoStreams.Duration | 時間長度 | × | ✓ | × | × | |
VideoStreams.FrameCount | 幀數 | × | ✓ | × | × | |
VideoStreams.BitDepth | 像素位寬 | × | ✓ | × | × | |
VideoStreams.PixelFormat | 像素格式 | × | ✓ | × | × | |
VideoStreams.ColorSpace | 色彩空間 | × | ✓ | × | × | |
VideoStreams.Height | 視頻解析度高度 | × | ✓ | × | × | |
VideoStreams.Width | 視頻解析度寬度 | × | ✓ | × | × | |
音頻資訊 | AudioStreams.CodecName | 編碼器名稱 | ✓ | ✓ | × | × |
AudioStreams.Bitrate | 碼率 | × | ✓ | × | × | |
AudioStreams.SampleRate | 採樣率 | × | ✓ | × | × | |
AudioStreams.StartTime | 起始時間 | × | ✓ | × | × | |
AudioStreams.Duration | 時間長度 | × | ✓ | × | × | |
AudioStreams.Channels | 聲道數 | × | ✓ | × | × | |
AudioStreams.Language | 語言 | ✓ | ✓ | × | × | |
字幕資訊 | Subtitles.CodecName | 編碼器名稱 | ✓ | ✓ | × | × |
Subtitles.Language | 字幕語言 | ✓ | ✓ | × | × | |
Subtitles.StartTime | 起始時間 | × | ✓ | × | × | |
Subtitles.Duration | 時間長度 | × | ✓ | × | × | |
媒體資訊 | Bitrate | 碼率 | ✓ | ✓ | × | × |
Artist | 藝術家 | ✓ | ✓ | × | × | |
AlbumArtist | 專輯藝術家 | ✓ | ✓ | × | × | |
Composer | 作曲家 | ✓ | ✓ | × | × | |
Performer | 演奏家 | ✓ | ✓ | × | × | |
Album | 專輯 | ✓ | ✓ | × | × | |
Duration | 媒體時間長度 | ✓ | ✓ | × | × | |
地理資訊 | Addresses.AddressLine | 詳細地址 | ✓ | ✓ | × | × |
Addresses.City | 城市 | ✓ | ✓ | × | × | |
Addresses.Country | 國家 | ✓ | ✓ | × | × | |
Addresses.District | 行政地區 | ✓ | ✓ | × | × | |
Addresses.Language | 地址語言 | ✓ | ✓ | × | × | |
Addresses.Province | 省份 | ✓ | ✓ | × | × | |
Addresses.Township | 鄉鎮 | ✓ | ✓ | × | × |
欄位支援的操作符
欄位支援的查詢操作符包含eq(等於)、gt(大於)、gte(大於等於)、lt(小於)、lte(小於等於)、match-phrase(字串匹配查詢)和prefix(首碼查詢),nested(欄位為數組時,其中同一對象內邏輯條件查詢。)、exist(存在性查詢)。
欄位支援的彙總操作符包含min(最小值)、max(最大值)、average(平均數)、sum(求和)、count(計數)、distinct(去重統計)和group(分組計數)。
分類 | Field(欄位) | 欄位說明 | 查詢操作符 | 彙總操作符 | 排序(Sort) | |||||||
eq、gt、 gte、lt、lte | match-phrase | prefix | nested | exist | min、max、 sum、average | count | distinct | group | ||||
基本資料 | URI | 物件路徑 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ |
FileModifiedTime | 檔案修改時間* | ✓ | × | × | × | × | × | ✓ | ✓ | ✓ | ✓ | |
Filename | 檔案名稱* | ✓ | ✓ | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
Size | 檔案大小* | ✓ | × | × | × | × | ✓ | ✓ | ✓ | ✓ | ✓ | |
MediaType | 媒體類型* | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ContentType | MIME類型* | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ProduceTime | 創作時間 | ✓ | × | × | × | × | × | ✓ | ✓ | ✓ | ✓ | |
LatLong | 經緯度 | ✓ | × | × | × | × | × | ✓ | ✓ | × | × | |
Title | 標題 | ✓ | ✓ | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
OSS對象資訊 | ObjectACL | 對象讀寫權限 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ |
ETag | ETag | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
OSSCRC64 | CRC64 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
OSSObjectType | 物件類型 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
OSSStorageClass | 儲存類型 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
OSSTagging.* | 對象標籤 | ✓ | × | ✓ | × | ✓ | × | × | × | × | × | |
OSSTaggingCount | 標籤數量 | ✓ | × | × | × | × | ✓ | ✓ | ✓ | ✓ | ✓ | |
OSSUserMeta.* | 自訂資訊 | ✓ | × | ✓ | × | ✓ | × | × | × | × | × | |
OSSExpiration | 到期時間 | ✓ | × | × | × | × | × | ✓ | ✓ | ✓ | ✓ | |
AccessControlAllowOrigin | 允許的跨域請求來源 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
AccessControlRequestMethod | 允許的跨域要求方法 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ServerSideDataEncryption | 服務端資料加密 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ServerSideEncryption | 服務端加密 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ServerSideEncryptionCustomerAlgorithm | 客戶自訂服務端密碼編譯演算法 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ServerSideEncryptionKeyId | 服務端加密金鑰 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
CacheControl | HTTP可緩衝性 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ContentDisposition | HTTP響應處理方式 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ContentEncoding | HTTP響應編碼方式 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
ContentLanguage | HTTP響應語言 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
圖片資訊 | ImageHeight | 圖片高度 | ✓ | × | × | × | × | ✓ | ✓ | ✓ | ✓ | ✓ |
ImageWidth | 圖片寬度 | ✓ | × | × | × | × | ✓ | ✓ | ✓ | ✓ | ✓ | |
視頻資訊 | VideoHeight | 視頻高度 | ✓ | × | × | × | × | ✓ | ✓ | ✓ | ✓ | ✓ |
VideoWidth | 視頻寬度 | ✓ | × | × | × | × | ✓ | ✓ | ✓ | ✓ | ✓ | |
VideoStreams.CodecName | 編碼器名稱 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
VideoStreams.Language | 語言 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
VideoStreams.Bitrate | 碼率 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.FrameRate | 幀率 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.StartTime | 起始時間 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.Duration | 時間長度 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.FrameCount | 幀數 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.BitDepth | 像素位寬 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.PixelFormat | 像素格式 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.ColorSpace | 色彩空間 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.Height | 視頻解析度高度 | × | × | × | × | × | × | × | × | × | × | |
VideoStreams.Width | 視頻解析度寬度 | × | × | × | × | × | × | × | × | × | × | |
音頻資訊 | AudioStreams.CodecName | 編碼器名稱 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | ||
AudioStreams.Bitrate | 碼率 | × | × | × | × | × | × | × | × | × | × | |
AudioStreams.SampleRate | 採樣率 | × | × | × | × | × | × | × | × | × | × | |
AudioStreams.StartTime | 起始時間 | × | × | × | × | × | × | × | × | × | × | |
AudioStreams.Duration | 時間長度 | × | × | × | × | × | × | × | × | × | × | |
AudioStreams.Channels | 聲道數 | × | × | × | × | × | × | × | × | × | × | |
AudioStreams.Language | 語言 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
字幕資訊 | Subtitles.CodecName | 編碼器名稱 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × |
Subtitles.Language | 字幕語言 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
Subtitles.StartTime | 起始時間 | × | × | × | × | × | × | × | × | × | × | |
Subtitles.Duration | 時間長度 | × | × | × | × | × | × | × | × | × | × | |
媒體資訊 | Bitrate | 碼率 | ✓ | × | × | × | × | ✓ | ✓ | ✓ | ✓ | ✓ |
Artist | 藝術家 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
AlbumArtist | 專輯藝術家 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
Composer | 作曲家 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
Performer | 演奏家 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
Album | 專輯 | ✓ | × | ✓ | × | × | × | ✓ | ✓ | ✓ | ✓ | |
Duration | 媒體時間長度 | ✓ | × | × | × | × | ✓ | ✓ | ✓ | ✓ | ✓ | |
地理資訊 | Addresses.AddressLine | 詳細地址 | × | ✓ | × | ✓ | ✓ | × | × | × | × | × |
Addresses.City | 城市 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
Addresses.Country | 國家 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
Addresses.District | 行政地區 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
Addresses.Language | 地址語言 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
Addresses.Province | 省份 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × | |
Addresses.Township | 鄉鎮 | ✓ | × | ✓ | ✓ | ✓ | × | × | × | × | × |