File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -73,8 +73,9 @@ def build_tagger(self):
7373 | rang
7474 | punct
7575 ).optimize () + (punct .plus | self .DELETE_SPACE )
76- # delete the last space
77- self .tagger = tagger .star @ self .build_rule (delete (' ' ), r = '[EOS]' )
76+ # delete the first and last space
77+ self .tagger = (delete (' ' ).star + tagger .star ) @ self .build_rule (
78+ delete (' ' ), r = '[EOS]' )
7879
7980 def build_verbalizer (self ):
8081 cardinal = Cardinal ().verbalizer
Original file line number Diff line number Diff line change @@ -5,3 +5,4 @@ The museum is open Mon.-Sun. children of 3-4 years 123 The plan will help you lo
55Try searching for 'Toyota' or 'Investment' => Try searching for 'Toyota' or 'Investment'
66"" => ""
77The HTML tag <p> defines a paragraph. => The HTML tag <p> defines a paragraph.
8+ hello world => hello world
You can’t perform that action at this time.
0 commit comments