This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import argparse | |
| import sys | |
| from stream2sentence import generate_sentences | |
| def file_or_pipe_input(file_path=None): | |
| if file_path: | |
| with open(file_path, "r", encoding="utf-8") as file: | |
| yield file.read() | |
| else: |
OlderNewer