sahilnishad commited on
Commit
d78c05e
·
verified ·
1 Parent(s): c6431d9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -19,9 +19,12 @@ from constants import CHROMA_SETTINGS
19
  st.set_page_config(layout="centered")
20
 
21
  checkpoint = "meta-llama/Llama-2-7b-chat-hf"
22
- tokenizer = AutoTokenizer.from_pretrained(checkpoint)
 
 
23
  model = AutoModelForCausalLM.from_pretrained(
24
- checkpoint,
 
25
  device_map="auto",
26
  torch_dtype=torch.float32
27
  )
 
19
  st.set_page_config(layout="centered")
20
 
21
  checkpoint = "meta-llama/Llama-2-7b-chat-hf"
22
+ token = os.getenv("HF_TOKEN")
23
+
24
+ tokenizer = AutoTokenizer.from_pretrained(checkpoint, use_auth_token=token)
25
  model = AutoModelForCausalLM.from_pretrained(
26
+ checkpoint,
27
+ use_auth_token=token,
28
  device_map="auto",
29
  torch_dtype=torch.float32
30
  )