sdeepanraj commited on
Commit
0201d9b
·
verified ·
1 Parent(s): a51f393

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -8
app.py CHANGED
@@ -29,17 +29,11 @@ class BasicAgent:
29
  if token is None:
30
  print("Hugging Face API token not found in environment variables.")
31
 
32
- model_name = "pankajmathur/orca_mini_3b" # or "gpt2-medium", "gpt2-large"
33
 
34
  # Load tokenizer and inject a minimal chat_template
35
  tokenizer = AutoTokenizer.from_pretrained(model_name)
36
- if not getattr(tokenizer, "chat_template", None):
37
- tokenizer.chat_template = (
38
- "### System:\n{system}\n\n"
39
- "### User:\n{instruction}\n\n"
40
- "### Input:\n{input}\n\n"
41
- "### Response:\n"
42
- )
43
  quant_config = BitsAndBytesConfig(
44
  load_in_4bit=True,
45
  bnb_4bit_quant_type="nf4",
 
29
  if token is None:
30
  print("Hugging Face API token not found in environment variables.")
31
 
32
+ model_name = "HuggingFaceTB/SmolLM-1.7B-Instruct"
33
 
34
  # Load tokenizer and inject a minimal chat_template
35
  tokenizer = AutoTokenizer.from_pretrained(model_name)
36
+
 
 
 
 
 
 
37
  quant_config = BitsAndBytesConfig(
38
  load_in_4bit=True,
39
  bnb_4bit_quant_type="nf4",