-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from himkt/add-option-ignoring-word
Add option ignoring word
- Loading branch information
Showing
6 changed files
with
86 additions
and
20 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,12 +4,29 @@ | |
from setuptools import find_packages | ||
from setuptools import setup | ||
|
||
from os import getenv | ||
|
||
setup(name='tiny_tokenizer', | ||
version='1.3.0', | ||
description='Tiny Word/Sentence Tokenizer', | ||
author='himkt', | ||
author_email='[email protected]', | ||
install_requires=['natto-py', 'kytea', 'sentencepiece'], | ||
url='https://github.com/himkt/tiny_tokenizer', | ||
packages=find_packages()) | ||
|
||
try: | ||
BUILD_WORD_TOKENIZER = int(getenv('BUILD_WORD_TOKENIZER', 1)) | ||
except: | ||
raise ValueError('BUILD_WORD_TOKENIZER should be integer') | ||
|
||
|
||
install_requires = [] | ||
if BUILD_WORD_TOKENIZER == 1: | ||
install_requires.extend(['natto-py', 'kytea', 'sentencepiece']) | ||
else: | ||
print('Install sentence tokenizer only') | ||
|
||
|
||
setup( | ||
name='tiny_tokenizer', | ||
version='1.3.1', | ||
description='Tiny Word/Sentence Tokenizer', | ||
author='himkt', | ||
author_email='[email protected]', | ||
install_requires=install_requires, | ||
url='https://github.com/himkt/tiny_tokenizer', | ||
packages=find_packages() | ||
) |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
from .sentence_tokenizer import SentenceTokenizer | ||
from .word_tokenizer import WordTokenizer | ||
|
||
__version__ = '1.3.0' | ||
__version__ = "1.3.1" |
This file contains 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