Skip to content
Permalink
Browse files

fix(preprocessor): fix preprocessor service handler function name error

  • Loading branch information...
numb3r3 committed Jul 17, 2019
1 parent 1229f5c commit 3836020aca4dbf9d3a650ca8c75907c2803db477
Showing with 3 additions and 3 deletions.
  1. +3 −3 gnes/service/preprocessor.py
@@ -27,15 +27,15 @@ def post_init(self):
self._model = self.load_model(BasePreprocessor)

@handler.register(gnes_pb2.Request.TrainRequest)
def _handler_train_index(self, msg: 'gnes_pb2.Message'):
def _handler_train(self, msg: 'gnes_pb2.Message'):
for d in msg.request.train.docs:
self._model.apply(d)

@handler.register(gnes_pb2.Request.IndexRequest)
def _handler_train_index(self, msg: 'gnes_pb2.Message'):
def _handler_index(self, msg: 'gnes_pb2.Message'):
for d in msg.request.index.docs:
self._model.apply(d)

@handler.register(gnes_pb2.Request.QueryRequest)
def _handler_train_index(self, msg: 'gnes_pb2.Message'):
def _handler_query(self, msg: 'gnes_pb2.Message'):
self._model.apply(msg.request.search.query)

0 comments on commit 3836020

Please sign in to comment.
You can’t perform that action at this time.