# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
import grpc

from harix.rdk.proto.nlu import nlu_pb2 as rdk_dot_proto_dot_nlu_dot_nlu__pb2


class NLUStub(object):
  # missing associated documentation comment in .proto file
  pass

  def __init__(self, channel):
    """Constructor.

    Args:
      channel: A grpc.Channel.
    """
    self.Detect = channel.unary_unary(
        '/skill.nlu.NLU/Detect',
        request_serializer=rdk_dot_proto_dot_nlu_dot_nlu__pb2.TextRequest.SerializeToString,
        response_deserializer=rdk_dot_proto_dot_nlu_dot_nlu__pb2.TextResponse.FromString,
        )


class NLUServicer(object):
  # missing associated documentation comment in .proto file
  pass

  def Detect(self, request, context):
    """本公司调用接口
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')


def add_NLUServicer_to_server(servicer, server):
  rpc_method_handlers = {
      'Detect': grpc.unary_unary_rpc_method_handler(
          servicer.Detect,
          request_deserializer=rdk_dot_proto_dot_nlu_dot_nlu__pb2.TextRequest.FromString,
          response_serializer=rdk_dot_proto_dot_nlu_dot_nlu__pb2.TextResponse.SerializeToString,
      ),
  }
  generic_handler = grpc.method_handlers_generic_handler(
      'skill.nlu.NLU', rpc_method_handlers)
  server.add_generic_rpc_handlers((generic_handler,))
