2021-04-09 10:17:38 +02:00
|
|
|
syntax = "proto3";
|
|
|
|
package nexus.meta_api.proto;
|
|
|
|
|
|
|
|
import "nexus/models/proto/typed_document.proto";
|
|
|
|
|
|
|
|
message ScoredDocument {
|
|
|
|
nexus.models.proto.TypedDocument typed_document = 1;
|
2021-04-13 16:23:31 +02:00
|
|
|
float score = 2;
|
|
|
|
uint32 position = 3;
|
2021-04-09 10:17:38 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
message SearchResponse {
|
|
|
|
repeated ScoredDocument scored_documents = 1;
|
|
|
|
bool has_next = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message SearchRequest {
|
|
|
|
repeated string schemas = 1;
|
|
|
|
string query = 2;
|
|
|
|
uint32 page = 3;
|
|
|
|
uint32 page_size = 4;
|
|
|
|
string language = 5;
|
|
|
|
int64 user_id = 6;
|
|
|
|
string session_id = 7;
|
|
|
|
}
|
|
|
|
|
2021-04-15 16:14:54 +02:00
|
|
|
service Search {
|
2021-04-09 10:17:38 +02:00
|
|
|
rpc search (SearchRequest) returns (SearchResponse) {}
|
|
|
|
}
|