rubenwol commited on
Commit
f35e572
1 Parent(s): 17585fe

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +6 -9
README.md CHANGED
@@ -1,14 +1,11 @@
1
  # SuperPAL model
2
 
3
- ```python
4
- import requests
5
-
6
- API_URL = "https://api-inference.huggingface.co/models/biu-nlp/superpal"
7
- headers = {"Authorization": "Bearer api_MaOZZEVvkCVoMqyvDwZdMqRKAQJlBrzWqM"}
8
 
9
- def query(payload):
10
- response = requests.post(API_URL, headers=headers, json=payload)
11
- return response.json()
 
12
 
13
- output = query({"inputs": "Prime Minister Hun Sen insisted that talks take place in Cambodia. </s><s> Cambodian leader Hun Sen rejected opposition parties' demands for talks outside the country."})
14
  ```
 
1
  # SuperPAL model
2
 
3
+ use in Transformers
 
 
 
 
4
 
5
+ ```python
6
+ from transformers import AutoTokenizer, AutoModelForSequenceClassification
7
+
8
+ tokenizer = AutoTokenizer.from_pretrained("biu-nlp/superpal")
9
 
10
+ model = AutoModelForSequenceClassification.from_pretrained("biu-nlp/superpal")
11
  ```