kajdun commited on
Commit
b873d66
·
1 Parent(s): d478af0

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +1 -1
handler.py CHANGED
@@ -12,7 +12,7 @@ class EndpointHandler():
12
  self.model = Llama(model_path="/repository/iubaris-13b-v3_ggml_Q4_K_S.bin", n_ctx=4000, n_gpu_layers=50, n_threads=cpu_count, verbose=True)
13
 
14
  def get_input_token_length(self, message: str) -> int:
15
- input_ids = self.model([message.encode('utf-8')]
16
  return len(input_ids)
17
 
18
  def __call__(self, data: Any) -> List[List[Dict[str, float]]]:
 
12
  self.model = Llama(model_path="/repository/iubaris-13b-v3_ggml_Q4_K_S.bin", n_ctx=4000, n_gpu_layers=50, n_threads=cpu_count, verbose=True)
13
 
14
  def get_input_token_length(self, message: str) -> int:
15
+ input_ids = self.model([message.encode('utf-8')])
16
  return len(input_ids)
17
 
18
  def __call__(self, data: Any) -> List[List[Dict[str, float]]]: