slauw87 commited on
Commit
f7375dd
1 Parent(s): 4ac1b34

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +89 -0
README.md ADDED
@@ -0,0 +1,89 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ ---
3
+ language: en
4
+ tags:
5
+ - sagemaker
6
+ - bart
7
+ - summarization
8
+ license: apache-2.0
9
+ datasets:
10
+ - samsum
11
+ model-index:
12
+ - name: bart-large-cnn-samsum
13
+ results:
14
+ - task:
15
+ name: Abstractive Text Summarization
16
+ type: abstractive-text-summarization
17
+ dataset:
18
+ name: "SAMSum Corpus: A Human-annotated Dialogue Dataset for Abstractive Summarization"
19
+ type: samsum
20
+ metrics:
21
+ - name: Validation ROGUE-1
22
+ type: rogue-1
23
+ value: 43.2111
24
+ - name: Validation ROGUE-2
25
+ type: rogue-2
26
+ value: 22.3519
27
+ - name: Validation ROGUE-L
28
+ type: rogue-l
29
+ value: 33.315
30
+ - name: Test ROGUE-1
31
+ type: rogue-1
32
+ value: 41.8283
33
+ - name: Test ROGUE-2
34
+ type: rogue-2
35
+ value: 20.9857
36
+ - name: Test ROGUE-L
37
+ type: rogue-l
38
+ value: 32.3602
39
+ widget:
40
+ - text: |
41
+ Sugi: I am tired of everything in my life.
42
+ Tommy: What? How happy you life is! I do envy you.
43
+ Sugi: You don't know that I have been over-protected by my mother these years. I am really about to leave the family and spread my wings.
44
+ Tommy: Maybe you are right.
45
+ ---
46
+ ## `bart-large-cnn-samsum`
47
+ This model was trained using Amazon SageMaker and the new Hugging Face Deep Learning container.
48
+ For more information look at:
49
+ - [🤗 Transformers Documentation: Amazon SageMaker](https://huggingface.co/transformers/sagemaker.html)
50
+ - [Example Notebooks](https://github.com/huggingface/notebooks/tree/master/sagemaker)
51
+ - [Amazon SageMaker documentation for Hugging Face](https://docs.aws.amazon.com/sagemaker/latest/dg/hugging-face.html)
52
+ - [Python SDK SageMaker documentation for Hugging Face](https://sagemaker.readthedocs.io/en/stable/frameworks/huggingface/index.html)
53
+ - [Deep Learning Container](https://github.com/aws/deep-learning-containers/blob/master/available_images.md#huggingface-training-containers)
54
+ ## Hyperparameters
55
+ {
56
+ "dataset_name": "samsum",
57
+ "do_eval": true,
58
+ "do_predict": true,
59
+ "do_train": true,
60
+ "fp16": true,
61
+ "learning_rate": 5e-05,
62
+ "model_name_or_path": "facebook/bart-large-cnn",
63
+ "num_train_epochs": 3,
64
+ "output_dir": "/opt/ml/model",
65
+ "per_device_eval_batch_size": 4,
66
+ "per_device_train_batch_size": 4,
67
+ "predict_with_generate": true,
68
+ "seed": 7
69
+ }
70
+ ## Usage
71
+ from transformers import pipeline
72
+ summarizer = pipeline("summarization", model="slauw87/bart-large-cnn-samsum")
73
+ conversation = '''Sugi: I am tired of everything in my life.
74
+ Tommy: What? How happy you life is! I do envy you.
75
+ Sugi: You don't know that I have been over-protected by my mother these years. I am really about to leave the family and spread my wings.
76
+ Tommy: Maybe you are right.
77
+ '''
78
+ nlp(conversation)
79
+ ## Results
80
+ | key | value |
81
+ | --- | ----- |
82
+ | eval_rouge1 | 43.2111 |
83
+ | eval_rouge2 | 22.3519 |
84
+ | eval_rougeL | 33.3153 |
85
+ | eval_rougeLsum | 40.0527 |
86
+ | predict_rouge1 | 41.8283 |
87
+ | predict_rouge2 | 20.9857 |
88
+ | predict_rougeL | 32.3602 |
89
+ | predict_rougeLsum | 38.7316 |