Asankhaya Sharma commited on
Commit
c4709fb
·
1 Parent(s): af7e3ad
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -6,7 +6,7 @@ from transformers import AutoModelForCausalLM, AutoTokenizer
6
  checkpoint = "gpt2-large"
7
 
8
  tokenizer = AutoTokenizer.from_pretrained(checkpoint)
9
- @st.cache_resource
10
  def load_model(model_name):
11
  model = AutoModelForCausalLM.from_pretrained(model_name)
12
  return model
 
6
  checkpoint = "gpt2-large"
7
 
8
  tokenizer = AutoTokenizer.from_pretrained(checkpoint)
9
+ @st.cache
10
  def load_model(model_name):
11
  model = AutoModelForCausalLM.from_pretrained(model_name)
12
  return model