SJ-Ray commited on
Commit
77f423a
·
1 Parent(s): f35ae0a

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +33 -34
README.md CHANGED
@@ -1,34 +1,33 @@
1
- ---
2
- license: apache-2.0
3
- ---
4
- <h2>Re-Punctuate:</h2>
5
-
6
- Re-Punctuate is a T5 model that attempts to correct Capitalization and Punctuations in the sentences.
7
-
8
- <h3>DataSet:</h3>
9
-
10
- DialogSum dataset (115056 Records) was used to fine-tune the model for Punctuation and Capitalization correction.
11
-
12
- <h3>Usage:</h3>
13
-
14
- <pre>
15
-
16
- from transformers import T5Tokenizer, TFT5ForConditionalGeneration
17
-
18
- tokenizer = T5Tokenizer.from_pretrained('SJ-Ray/Re-Punctuate')
19
- model = TFT5ForConditionalGeneration.from_pretrained('SJ-Ray/Re-Punctuate')
20
-
21
- input_text = 'the story of this brave brilliant athlete whose very being was questioned so publicly is one that still captures the imagination'
22
- inputs = tokenizer.encode("punctuate: " + input_text, return_tensors="tf")
23
- result = model.generate(inputs)
24
-
25
- decoded_output = tokenizer.decode(result[0], skip_special_tokens=True)
26
- print(decoded_output)
27
-
28
- </pre>
29
- <h4> Example: </h4>
30
- <b>Input:</b> the story of this brave brilliant athlete whose very being was questioned so publicly is one that still captures the imagination <br>
31
- <b>Output:</b> The story of this brave, brilliant athlete, whose very being was questioned so publicly, is one that still captures the imagination.
32
-
33
- <h4> Connect on: </h4>
34
- LinkedIn : www.linkedin.com/in/suraj-kumar-710382a7
 
1
+ ---
2
+ license: apache-2.0
3
+ ---
4
+ <h2>Re-Punctuate:</h2>
5
+
6
+ Re-Punctuate is a T5 model that attempts to correct Capitalization and Punctuations in the sentences.
7
+
8
+ <h3>DataSet:</h3>
9
+
10
+ DialogSum dataset (115056 Records) was used to fine-tune the model for Punctuation and Capitalization correction.
11
+
12
+ <h3>Usage:</h3>
13
+
14
+ <pre>
15
+
16
+ from transformers import T5Tokenizer, TFT5ForConditionalGeneration
17
+
18
+ tokenizer = T5Tokenizer.from_pretrained('SJ-Ray/Re-Punctuate')
19
+ model = TFT5ForConditionalGeneration.from_pretrained('SJ-Ray/Re-Punctuate')
20
+
21
+ input_text = 'the story of this brave brilliant athlete whose very being was questioned so publicly is one that still captures the imagination'
22
+ inputs = tokenizer.encode("punctuate: " + input_text, return_tensors="tf")
23
+ result = model.generate(inputs)
24
+
25
+ decoded_output = tokenizer.decode(result[0], skip_special_tokens=True)
26
+ print(decoded_output)
27
+
28
+ </pre>
29
+ <h4> Example: </h4>
30
+ <b>Input:</b> the story of this brave brilliant athlete whose very being was questioned so publicly is one that still captures the imagination <br>
31
+ <b>Output:</b> The story of this brave, brilliant athlete, whose very being was questioned so publicly, is one that still captures the imagination.
32
+
33
+ <h4> Connect on: <a href="www.linkedin.com/in/suraj-kumar-710382a7">LinkedIn</a></h4>