File size: 1,075 Bytes
5a9fc1b 6fceff2 99d627f 3fc01cd 315969f 6d2801b 3775d97 d96c778 3775d97 8042c99 6d2801b 8042c99 1a8668c 8042c99 3775d97 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
---
library_name: generic
tags:
- summarization
license: mit
---
## Model Description
This is the project for the course Multimedia System in Leiden University 2023 fall. The model is part of self-designed software for the final project that summarizes short texts.
The original summarization model is from https://towardsdatascience.com/text-summarization-with-gpt2-and-layer-ai-599625085d8e .
## Training Datasets
- Amazon review dataset
- Twitter crawler dataset
- Emotion analysis dataset
- Kindle review dataset
## TODO
- Improve training data quality
- Model analysis
- Inference development
## Interface
```python
import requests
API_URL = "https://api-inference.huggingface.co/models/Lin0He/text-summary-gpt2-short"
headers = {"Authorization": "Bearer <Your API tokens>"}
def query(payload):
response = requests.post(API_URL, headers=headers, json=payload)
return response.json()
output = query({
"inputs": "Today was a beautiful day. I have down all my homework, and baked some cookies with my friends. What a lovely day."
})
print(output)
``` |