Machlovi commited on
Commit
bda485d
·
verified ·
1 Parent(s): 6533739

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +3 -1
handler.py CHANGED
@@ -71,7 +71,9 @@ class EndpointHandler:
71
  template_tokenizer = self.tokenizer
72
  if hasattr(template_tokenizer, "chat_template") and template_tokenizer.chat_template:
73
  self.tokenizer.chat_template = template_tokenizer.chat_template
74
- print(f"Successfully imported chat template from {self.chat_template_id}")\
 
 
75
 
76
 
77
  def _get_policy_prompt(self):
 
71
  template_tokenizer = self.tokenizer
72
  if hasattr(template_tokenizer, "chat_template") and template_tokenizer.chat_template:
73
  self.tokenizer.chat_template = template_tokenizer.chat_template
74
+ print(f"Successfully imported chat template from {self.chat_template_id}")
75
+ except Exception as e:
76
+ print(f"Failed to import chat template: {e}")
77
 
78
 
79
  def _get_policy_prompt(self):