Merlintxu commited on
Commit
9531935
1 Parent(s): 2ec5dec

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -2,11 +2,11 @@ import gradio as gr
2
  from gradio import Interface, inputs, outputs
3
 
4
  import spacy
5
- from transformers import GPT2LMHeadModel, GPT2Tokenizer
6
 
7
  nlp = spacy.load('es_core_news_sm')
8
- tokenizer = GPT2Tokenizer.from_pretrained("gpt2")
9
- model = GPT2LMHeadModel.from_pretrained("gpt2")
10
 
11
  pos_map = {
12
  'sustantivo': 'NOUN',
 
2
  from gradio import Interface, inputs, outputs
3
 
4
  import spacy
5
+ from transformers import AutoModelForCausalLM, AutoTokenizer
6
 
7
  nlp = spacy.load('es_core_news_sm')
8
+ tokenizer = AutoTokenizer.from_pretrained("vicuna_tokenizer")
9
+ model = AutoModelForCausalLM.from_pretrained("vicuna_model")
10
 
11
  pos_map = {
12
  'sustantivo': 'NOUN',