REST Resource: projects.locations.corpora.indexes

资源:索引

索引是语料库中的资源。它包含资产和注释的编入索引的版本。部署到端点后,用户便可搜索该索引。

JSON 表示法
{
  "name": string,
  "displayName": string,
  "description": string,
  "state": enum (State),
  "createTime": string,
  "updateTime": string,
  "deployedIndexes": [
    {
      object (DeployedIndexReference)
    }
  ],

  // Union field asset_filter can be only one of the following:
  "entireCorpus": boolean
  // End of list of possible types for union field asset_filter.
}
字段
name

string

仅限输出。索引资源的资源名称。格式:projects/{project_number}/locations/{locationId}/corpora/{corpus_id}/indexes/{indexId}

displayName

string

可选。索引的可选用户指定显示名称。

description

string

可选。索引的说明(可选)。

state

enum (State)

仅限输出。索引的状态。

createTime

string (Timestamp format)

仅限输出。创建时间戳。

时间戳采用 RFC3339 世界协调时间(UTC,即“祖鲁时”)格式,精确到纳秒,最多九个小数位。示例:"2014-10-02T15:01:23Z""2014-10-02T15:01:23.045123456Z"

updateTime

string (Timestamp format)

仅限输出。更新时间戳。

时间戳采用 RFC3339 世界协调时间(UTC,即“祖鲁时”)格式,精确到纳秒,最多九个小数位。示例:"2014-10-02T15:01:23Z""2014-10-02T15:01:23.045123456Z"

deployedIndexes[]

object (DeployedIndexReference)

仅限输出。对已部署的索引实例的引用。VIDEO_ON_DEMAND 语料库的索引最多只能有一个已部署的索引。IMAGE 语料库的索引可以有多个已部署的索引。

联合字段 asset_filter。指定如何为此索引选择素材资源。如果未指定,则默认为 entire_corpus。UpdateIndex 中的行为:如果 update_mask 包含 asset_filter 字段路径之一,则系统将使用最新的素材资源(包括其分析数据和注释)重新构建索引。asset_filter 只能是下列其中一项:
entireCorpus

boolean

包含该语料库下的所有资产。

表示索引在其生命周期内可能会循环的不同状态的枚举。

枚举
STATE_UNSPECIFIED 默认值。不应使用。
CREATING 状态为“正在创建”。
CREATED 状态为“已创建”。
UPDATING 状态为“UPDATING”。

DeployedIndexReference

指向 DeployedIndex。

JSON 表示法
{
  "indexEndpoint": string
}
字段
indexEndpoint

string

不可变。IndexEndpoint 的资源名称。

方法

create

在语料库下创建索引。

delete

删除单个索引。

get

获取语料库下单个索引的详细信息。

list

列出给定语料库中的所有索引。

patch

更新语料库下的索引。

viewAssets

列出索引中的资产。