mirror of
https://gitee.com/milvus-io/milvus.git
synced 2024-12-02 11:59:00 +08:00
a8b78f11c3
Signed-off-by: cai.zhang <cai.zhang@zilliz.com>
203 lines
4.0 KiB
Protocol Buffer
203 lines
4.0 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package milvus.proto.service;
|
|
option go_package="github.com/zilliztech/milvus-distributed/internal/proto/servicepb";
|
|
|
|
import "common.proto";
|
|
import "schema.proto";
|
|
|
|
/**
|
|
* @brief Collection name
|
|
*/
|
|
message CollectionName {
|
|
string collection_name = 1;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Partition name
|
|
*/
|
|
message PartitionName {
|
|
string collection_name = 1;
|
|
string tag = 2;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Row batch for Insert call
|
|
*/
|
|
message RowBatch {
|
|
string collection_name = 1;
|
|
string partition_tag = 2;
|
|
repeated common.Blob row_data = 3;
|
|
repeated uint32 hash_keys = 4;
|
|
}
|
|
|
|
/**
|
|
* @brief Placeholder value types
|
|
*/
|
|
enum PlaceholderType {
|
|
NONE = 0;
|
|
VECTOR_BINARY = 100;
|
|
VECTOR_FLOAT = 101;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Placeholder value in DSL
|
|
*/
|
|
message PlaceholderValue {
|
|
string tag = 1;
|
|
PlaceholderType type = 2;
|
|
// values is a 2d-array, every array contains a vector
|
|
repeated bytes values = 3;
|
|
|
|
}
|
|
|
|
message PlaceholderGroup {
|
|
repeated PlaceholderValue placeholders = 1;
|
|
}
|
|
|
|
/**
|
|
* @brief Query for Search call
|
|
*/
|
|
message Query {
|
|
string collection_name = 1;
|
|
repeated string partition_tags = 2;
|
|
string dsl = 3;
|
|
// placeholder_group contains the serialized PlaceholderGroup
|
|
bytes placeholder_group = 4;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief String response
|
|
*/
|
|
message StringResponse {
|
|
common.Status status = 1;
|
|
string value = 2;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Bool response
|
|
*/
|
|
message BoolResponse {
|
|
common.Status status = 1;
|
|
bool value = 2;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief String list response
|
|
*/
|
|
message StringListResponse {
|
|
common.Status status = 1;
|
|
repeated string values = 2;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Integer list response
|
|
*/
|
|
message IntegerListResponse {
|
|
common.Status status = 1;
|
|
repeated int64 values = 2;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Range response, [begin, end)
|
|
*/
|
|
message IntegerRangeResponse {
|
|
common.Status status = 1;
|
|
int64 begin = 2;
|
|
int64 end = 3;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Response of DescribeCollection
|
|
*/
|
|
message CollectionDescription {
|
|
common.Status status = 1;
|
|
schema.CollectionSchema schema = 2;
|
|
repeated common.KeyValuePair statistics = 3;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Response of DescribePartition
|
|
*/
|
|
message PartitionDescription {
|
|
common.Status status = 1;
|
|
PartitionName name = 2;
|
|
repeated common.KeyValuePair statistics = 3;
|
|
}
|
|
|
|
/**
|
|
* @brief Response of GetSysConfig
|
|
*/
|
|
message SysConfigResponse {
|
|
common.Status status = 1;
|
|
repeated string keys = 2;
|
|
repeated string values = 3;
|
|
}
|
|
|
|
/**
|
|
* @brief Entities hit by query
|
|
*/
|
|
message Hits {
|
|
repeated int64 IDs = 1;
|
|
repeated bytes row_data = 2;
|
|
repeated float scores = 3;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Query result
|
|
*/
|
|
message QueryResult {
|
|
common.Status status = 1;
|
|
repeated bytes hits = 2;
|
|
}
|
|
|
|
|
|
/**
|
|
* @brief Index params
|
|
* @collection_name: target collection
|
|
* @field_name: target field
|
|
* @index_name: a name for index provided by user, unique within this field
|
|
* @extra_params: index parameters in json format
|
|
* for vector field:
|
|
* extra_params["index_type"] = one of the values: FLAT, IVF_LAT, IVF_SQ8, NSGMIX, IVFSQ8H,
|
|
* PQ, HNSW, HNSW_SQ8NM, ANNOY
|
|
* extra_params["metric_type"] = one of the values: L2, IP, HAMMING, JACCARD, TANIMOTO
|
|
* SUBSTRUCTURE, SUPERSTRUCTURE
|
|
* extra_params["params"] = extra parameters for index, for example ivflat: {nlist: 2048}
|
|
* for structured field:
|
|
* extra_params["index_type"] = one of the values: SORTED
|
|
*/
|
|
message IndexParam {
|
|
string collection_name = 1;
|
|
string field_name = 2;
|
|
repeated common.KeyValuePair extra_params = 3;
|
|
}
|
|
|
|
message DescribeIndexRequest {
|
|
string collection_name = 1;
|
|
string field_name = 2;
|
|
}
|
|
|
|
message DescribeIndexProgressRequest {
|
|
string collection_name = 1;
|
|
string field_name = 2;
|
|
}
|
|
|
|
message DescribeIndexResponse {
|
|
common.Status status = 1;
|
|
string collection_name = 2;
|
|
string field_name = 3;
|
|
repeated common.KeyValuePair extra_params = 4;
|
|
}
|