bhlewis commited on
Commit
bff0113
·
verified ·
1 Parent(s): 7935863

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -51,7 +51,7 @@ embeddings, patent_numbers, metadata, texts = load_data()
51
  try:
52
  tokenizer = AutoTokenizer.from_pretrained('anferico/bert-for-patents')
53
  bert_model = AutoModel.from_pretrained('anferico/bert-for-patents')
54
- word_embedding_model = models.Transformer(model_name='anferico/bert-for-patents', tokenizer=tokenizer, model=bert_model)
55
  pooling_model = models.Pooling(word_embedding_model.get_word_embedding_dimension())
56
  model = SentenceTransformer(modules=[word_embedding_model, pooling_model])
57
  except Exception as e:
 
51
  try:
52
  tokenizer = AutoTokenizer.from_pretrained('anferico/bert-for-patents')
53
  bert_model = AutoModel.from_pretrained('anferico/bert-for-patents')
54
+ word_embedding_model = models.Transformer(model_name='anferico/bert-for-patents', tokenizer=tokenizer)
55
  pooling_model = models.Pooling(word_embedding_model.get_word_embedding_dimension())
56
  model = SentenceTransformer(modules=[word_embedding_model, pooling_model])
57
  except Exception as e: