Skip to content

Commit

Permalink
[tn] support punct
Browse files Browse the repository at this point in the history
  • Loading branch information
xingchensong committed Jun 4, 2024
1 parent d3eabff commit 368ac63
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions tn/english/rules/date.py
Original file line number Diff line number Diff line change
Expand Up @@ -282,12 +282,6 @@ def build_tagger(self):

final_graph |= graph_fy

prefix = pynutil.delete(pynini.union("{", "(", "<", "\"",
"'")).ques + self.DELETE_SPACE
suffix = self.DELETE_SPACE + pynutil.delete(
pynini.union("}", ")", ">", "\"", "'")).ques
final_graph = pynutil.add_weight(
prefix, -0.1) + final_graph + pynutil.add_weight(suffix, -0.1)
self.tagger = self.add_tokens(final_graph)

def build_verbalizer(self):
Expand Down

0 comments on commit 368ac63

Please sign in to comment.