rishisim commited on
Commit
5011a98
1 Parent(s): 907b68f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -8,12 +8,15 @@ from langchain.prompts import PromptTemplate
8
  from langchain.chains import RetrievalQA
9
  import warnings
10
  from huggingface_hub import login
 
11
 
12
 
13
  # from transformers import AutoModelForCausalLM, AutoTokenizer
14
  from transformers import pipeline
15
 
16
- login(token="your_huggingface_api_token")
 
 
17
 
18
 
19
  llm = pipeline("text-generation", model = "meta-llama/Meta-Llama-3-70B-Instruct")
 
8
  from langchain.chains import RetrievalQA
9
  import warnings
10
  from huggingface_hub import login
11
+ import os
12
 
13
 
14
  # from transformers import AutoModelForCausalLM, AutoTokenizer
15
  from transformers import pipeline
16
 
17
+ hf_token = os.environ['llama_token']
18
+
19
+ login(token=hf_token)
20
 
21
 
22
  llm = pipeline("text-generation", model = "meta-llama/Meta-Llama-3-70B-Instruct")