Skip to content

Commit

Permalink
Added check to not convert punctuation for convert_non_cjk
Browse files Browse the repository at this point in the history
  • Loading branch information
andreihar committed May 1, 2024
1 parent 6605cc9 commit b2631ca
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion taibun/taibun.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def __convert_tokenised(self, word):
if "/" in word[0]:
dialect_part = word[0].split("/")[1] if self.dialect == 'north' else word[0].split("/")[0]
word = (dialect_part,) + word[1:]
elif not self.convert_non_cjk:
elif not self.convert_non_cjk or word[0] in ".,!?\"#$%&()*+/:;<=>@[\\]^`{|}~\t。.,、!?;:()[]【】「」“”":
return word[0]
word = self.__system_conversion(word).replace('---', '--')
if self.format == 'number' and self.system in ['tailo', 'poj']:
Expand Down

0 comments on commit b2631ca

Please sign in to comment.