Update README.md
Browse files
README.md
CHANGED
|
@@ -9,12 +9,16 @@ As a part of a project assignment in EPFL's CS-401 class, we need a simple model
|
|
| 9 |
|
| 10 |
# Model info
|
| 11 |
- Input prompt format
|
|
|
|
| 12 |
f"Predict the percentage of a movie's plot that a character takes up.\nCharacter: {character_name} \nPlot: {plot}"
|
|
|
|
| 13 |
- Output
|
|
|
|
| 14 |
13.4
|
| 15 |
|
| 16 |
We used max_token = 2048 for training.
|
| 17 |
-
|
|
|
|
| 18 |
```python
|
| 19 |
tokenizer = T5Tokenizer.from_pretrained("Hyeongdon/t5-large-character_plot_portion") # same as default t5 tokenizer
|
| 20 |
model = T5ForConditionalGeneration.from_pretrained("Hyeongdon/t5-large-character_plot_portion")
|
|
|
|
| 9 |
|
| 10 |
# Model info
|
| 11 |
- Input prompt format
|
| 12 |
+
|
| 13 |
f"Predict the percentage of a movie's plot that a character takes up.\nCharacter: {character_name} \nPlot: {plot}"
|
| 14 |
+
|
| 15 |
- Output
|
| 16 |
+
|
| 17 |
13.4
|
| 18 |
|
| 19 |
We used max_token = 2048 for training.
|
| 20 |
+
|
| 21 |
+
| Sample code
|
| 22 |
```python
|
| 23 |
tokenizer = T5Tokenizer.from_pretrained("Hyeongdon/t5-large-character_plot_portion") # same as default t5 tokenizer
|
| 24 |
model = T5ForConditionalGeneration.from_pretrained("Hyeongdon/t5-large-character_plot_portion")
|