Reizendretail commited on
Commit
c94c5f0
1 Parent(s): 155a8d7

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +2 -1
handler.py CHANGED
@@ -1,5 +1,5 @@
1
  from typing import Dict, List, Any
2
-
3
  from transformers import AutoModelForCausalLM, AutoTokenizer
4
 
5
 
@@ -23,6 +23,7 @@ class EndpointHandler():
23
  conversation = []
24
  conversation.append({"role": "system", "content": system_prompt})
25
  conversation.append({"role": "user", "content": message})
 
26
  input_ids = self.tokenizer.apply_chat_template(conversation, return_tensors="pt")
27
  input_ids = input_ids.to(self.model.device)
28
 
 
1
  from typing import Dict, List, Any
2
+ import logging
3
  from transformers import AutoModelForCausalLM, AutoTokenizer
4
 
5
 
 
23
  conversation = []
24
  conversation.append({"role": "system", "content": system_prompt})
25
  conversation.append({"role": "user", "content": message})
26
+ logging.info(str(conversation))
27
  input_ids = self.tokenizer.apply_chat_template(conversation, return_tensors="pt")
28
  input_ids = input_ids.to(self.model.device)
29