syntax = "proto3";

option java_multiple_files = true;
option java_package = "com.dmetasoul.metaspore.demo.multimodal.service";
option java_outer_classname = "HfPreprocessorServiceProto";
option objc_class_prefix = "SPORE";
option cc_enable_arenas = true;

package multimodal.service;

service HfPreprocessor {
  rpc HfTokenizer (HfTokenizerRequest) returns (HfTokenizerResponse) {}
  rpc HfTokenizerPush (HfTokenizerPushRequest) returns (HfTokenizerPushResponse) {}
}

message HfTokenizerRequest {
  string model_name = 1;
  map<string, string>   parameters = 3;
  map<string, bytes>    payload    = 5;
}

message HfTokenizerResponse {
  map<string, bytes>    payload    = 1;
  map<string, string>   extras     = 3;
}

message HfTokenizerPushRequest {
  string model_name = 1;
  string model_url = 2;
}

message HfTokenizerPushResponse {
  int32 status = 1;
  string msg = 2;
}
