Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
efb5545
Merge pull request #23 from PyThaiNLP/dev
bact Nov 25, 2018
238ac8e
Tokenizer class example
bact Mar 17, 2019
79432c2
Add Tokenizer from pythainlp.tokenize.Tokenizer
korakot Apr 1, 2019
23a54cc
๊Use f-String
bact Apr 5, 2019
8855a30
Merge pull request #24 from PyThaiNLP/dev
bact Apr 5, 2019
cf9d002
Get Started Notebook
bact Apr 6, 2019
6f72b4c
Merge pull request #183 from bact/dev
bact Apr 6, 2019
6722b53
Update README.md
bact Apr 6, 2019
e3edd18
Update README.md
bact Apr 6, 2019
8ec724e
smaller notebook
bact Apr 6, 2019
daa27b4
Merge pull request #184 from bact/dev
bact Apr 6, 2019
cab8230
More descriptions
bact Apr 6, 2019
e19ec28
Merge pull request #185 from bact/dev
bact Apr 6, 2019
e8bb270
Merge pull request #25 from PyThaiNLP/dev
bact Apr 7, 2019
7b910da
- Fix misspelled filenames (NER models, etc) in setup.py
bact Apr 7, 2019
651e710
update test cases
bact Apr 7, 2019
e9078bf
simplify countthai()
bact Apr 7, 2019
78f4e06
fix incomplete type hinting
bact Apr 7, 2019
0ccf8a9
update test cases for tcc
bact Apr 7, 2019
86d4b74
update tcc test case
bact Apr 7, 2019
9072664
more test cases
bact Apr 7, 2019
13aafe0
Merge pull request #186 from bact/dev
bact Apr 7, 2019
0cdcb9d
Merge pull request #187 from PyThaiNLP/dev
wannaphong Apr 7, 2019
1928dd2
update tag map
wannaphong Apr 8, 2019
73da5a8
Update README.md
bact Apr 8, 2019
5fe7ad7
Update README-pypi.md
bact Apr 8, 2019
eda0078
Add etcc reference
c4n Apr 10, 2019
dd366c4
fix TCC citation
c4n Apr 10, 2019
9af0ba6
include etcc in subword_tokenize module as advertised on README.md
c4n Apr 10, 2019
b492360
Merge pull request #190 from c4n/master
wannaphong Apr 11, 2019
bfae642
PyThaiNLP 2.0.2
wannaphong Apr 11, 2019
3c2de29
Merge pull request #191 from PyThaiNLP/dev
wannaphong Apr 11, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,11 @@ install:

os:
- linux

# command to run tests, e.g. python setup.py test
script:
coverage run --source=pythainlp setup.py test

after_success:
coveralls

Expand Down
7 changes: 3 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,14 @@ We use the famous [gitflow](http://nvie.com/posts/a-successful-git-branching-mod

## Code Guidelines

- Use [PEP8](http://www.python.org/dev/peps/pep-0008/);
- Follows [PEP8](http://www.python.org/dev/peps/pep-0008/), use [black](https://github.com/ambv/black);
- Write tests for your new features (please see "Tests" topic below);
- Always remember that [commented code is dead
code](http://www.codinghorror.com/blog/2008/07/coding-without-comments.html);
- Name identifiers (variables, classes, functions, module names) with meaningful
and pronounceable names (`x` is always wrong);
- When manipulating strings, use [Python's new-style
formatting](http://docs.python.org/library/string.html#format-string-syntax)
(`'{} = {}'.format(a, b)` instead of `'%s = %s' % (a, b)`);
- When manipulating strings, use [f-String](https://www.python.org/dev/peps/pep-0498/)
(use `"{a} = {b}"`, instead of `"{} = {}".format(a, b)` and `"%s = %s' % (a, b)"`);
- All `#TODO` comments should be turned into issues (use our
[GitHub issue system](https://github.com/PyThaiNLP/pythainlp/));
- Run all tests before pushing (just execute `tox`) so you will know if your
Expand Down
14 changes: 5 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ help:

clean: clean-build clean-pyc clean-test ## remove all build, test, coverage and Python artifacts


clean-build: ## remove build artifacts
rm -fr build/
rm -fr dist/
Expand All @@ -51,19 +50,16 @@ lint: ## check style with flake8
flake8 pythainlp tests

test: ## run tests quickly with the default Python

python setup.py test
python setup.py test

test-all: ## run tests on every Python version with tox
tox

coverage: ## check code coverage quickly with the default Python

coverage run --source pythainlp setup.py test

coverage report -m
coverage html
$(BROWSER) htmlcov/index.html
coverage run --source pythainlp setup.py test
coverage report -m
coverage html
$(BROWSER) htmlcov/index.html

release: clean ## package and upload a release
python setup.py sdist upload
Expand Down
6 changes: 3 additions & 3 deletions README-pypi.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
![PyThaiNLP Logo](https://avatars0.githubusercontent.com/u/32934255?s=200&v=4)

# PyThaiNLP 2.0
# PyThaiNLP 2.0.2

[![Codacy Badge](https://api.codacy.com/project/badge/Grade/cb946260c87a4cc5905ca608704406f7)](https://www.codacy.com/app/pythainlp/pythainlp_2?utm_source=github.com&utm_medium=referral&utm_content=PyThaiNLP/pythainlp&utm_campaign=Badge_Grade)[![pypi](https://img.shields.io/pypi/v/pythainlp.svg)](https://pypi.python.org/pypi/pythainlp)
[![Build Status](https://travis-ci.org/PyThaiNLP/pythainlp.svg?branch=develop)](https://travis-ci.org/PyThaiNLP/pythainlp)
Expand All @@ -12,9 +12,9 @@ PyThaiNLP is a Python library for natural language processing (NLP) of Thai lang

PyThaiNLP includes Thai word tokenizers, transliterators, soundex converters, part-of-speech taggers, and spell checkers.

📖 For details on upgrading from PyThaiNLP 1.7 to PyThaiNLP 2.0, see [From PyThaiNLP 1.7 to PyThaiNLP 2.0](https://thainlp.org/pythainlp/docs/2.0/notes/pythainlp-1_7-2_0.html)
📖 [Upgrading from PyThaiNLP 1.7 to 2.0](https://thainlp.org/pythainlp/docs/2.0/notes/pythainlp-1_7-2_0.html)

📖 For ThaiNER user after upgrading from PyThaiNLP 1.7 to PyThaiNLP 2.0, see [Upgrade ThaiNER from PyThaiNLP 1.7 to PyThaiNLP 2.0](https://github.com/PyThaiNLP/pythainlp/wiki/Upgrade-ThaiNER-from-PyThaiNLP-1.7-to-PyThaiNLP-2.0)
📖 [Upgrade ThaiNER from PyThaiNLP 1.7 to 2.0](https://github.com/PyThaiNLP/pythainlp/wiki/Upgrade-ThaiNER-from-PyThaiNLP-1.7-to-PyThaiNLP-2.0)

📫 follow us on Facebook [Pythainlp](https://www.facebook.com/pythainlp/)

Expand Down
21 changes: 9 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@ Thai Natural Language Processing in Python.
PyThaiNLP is a Python package for text processing and linguistic analysis, similar to `nltk` but with focus on Thai language.

- [Current PyThaiNLP stable release is 2.0](https://github.com/PyThaiNLP/pythainlp/tree/master)
- PyThaiNLP 2.0 will support only Python 3.6+. Some functions may work with older version of Python 3, but it is not well-tested and will not be supported. See [PyThaiNLP 2.0 change log](https://github.com/PyThaiNLP/pythainlp/issues/118).
- Python 2 users can use PyThaiNLP 1.6, our latest released that tested with Python 2.7.
- PyThaiNLP 2.0 supports Python 3.6+. Some functions may work with older version of Python 3, but it is not well-tested and will not be supported. See [PyThaiNLP 2.0 change log](https://github.com/PyThaiNLP/pythainlp/issues/118).
- Python 2.7+ users can use PyThaiNLP 1.6.

**This is a document for development branch (post 1.7.x). Things will break. For a stable branch document, see [master](https://github.com/PyThaiNLP/pythainlp/tree/master).**
**This is a document for development branch (post 2.0). Things will break. For a stable branch document, see [master](https://github.com/PyThaiNLP/pythainlp/tree/master).**

📫 follow us on Facebook [Pythainlp](https://www.facebook.com/pythainlp/)
📫 follow us on Facebook [PyThaiNLP](https://www.facebook.com/pythainlp/)

## Capabilities

Expand All @@ -34,7 +34,7 @@ PyThaiNLP is a Python package for text processing and linguistic analysis, simil
- Thai misspellings detection and spelling correction (```spell```)
- Thai soundex (```lk82```, ```udom83```, ```metasound```)
- Thai WordNet wrapper
- and much more - see [examples](https://github.com/PyThaiNLP/pythainlp/tree/dev/examples).
- and much more - see examples in [PyThaiNLP Get Started notebook](https://github.com/PyThaiNLP/pythainlp/blob/dev/notebooks/pythainlp-get-started.ipynb).

## Installation

Expand Down Expand Up @@ -102,13 +102,10 @@ PyThaiNLP เป็นไลบารีภาษาไพทอนเพื่

> เพราะโลกขับเคลื่อนต่อไปด้วยการแบ่งปัน

รองรับ Python 3.6 ขึ้นไป
- PyThaiNLP 2.0 รองรับ Python 3.6 ขึ้นไป
- ผู้ใช้ Python 2.7+ ยังสามารถใช้ PyThaiNLP 1.6 ได้

- ตั้งแต่รุ่น 1.7 PyThaiNLP จะเลิกสนับสนุน Python 2 (บางฟังก์ชันอาจยังทำงานได้ แต่จะไม่ได้รับการสนับสนุน)
- ตั้งแต่รุ่น 2.0 จะยุติการรองรับ Python 2 ทั้งหมด
- ผู้ใช้ Python 2 ยังสามารถใช้ PyThaiNLP 1.6 ได้

**เอกสารนี้สำหรับรุ่นพัฒนา (หลัง 1.7.x) อาจมีการเปลี่ยนแปลงได้ตลอด สำหรับเอกสารรุ่นเสถียร ดูที่ [master](https://github.com/PyThaiNLP/pythainlp/tree/master).**
**เอกสารนี้สำหรับรุ่นพัฒนา (หลัง 2.0) อาจมีการเปลี่ยนแปลงได้ตลอด สำหรับเอกสารรุ่นเสถียร ดูที่ [master](https://github.com/PyThaiNLP/pythainlp/tree/master).**

📫 ติดตามข่าวสารได้ที่ Facebook [Pythainlp](https://www.facebook.com/pythainlp/)

Expand All @@ -125,7 +122,7 @@ PyThaiNLP เป็นไลบารีภาษาไพทอนเพื่
- ตรวจคำสะกดผิดในภาษาไทย (```spell```)
- soundex ภาษาไทย (```lk82```, ```udom83```, ```metasound```)
- Thai WordNet wrapper
- และอื่น ๆ [ดูตัวอย่าง](https://github.com/PyThaiNLP/pythainlp/tree/dev/examples)
- และอื่น ๆ ดูตัวอย่างได้ใน [PyThaiNLP Get Started notebook](https://github.com/PyThaiNLP/pythainlp/blob/dev/notebooks/pythainlp-get-started.ipynb)

## ติดตั้ง

Expand Down
2 changes: 1 addition & 1 deletion bin/pythainlp
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,4 @@ elif args.soundex!=None:
args.engine="lk82"
print(soundex(args.soundex, engine=args.engine))
else:
print("PyThaiNLP 2.0")
print("PyThaiNLP 2.0.2")
49 changes: 0 additions & 49 deletions conda.recipe/meta-old.yaml

This file was deleted.

2 changes: 1 addition & 1 deletion conda.recipe/meta.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% set version = "1.7.2" %}
{% set version = "2.0.2" %}

package:
name: pythainlp
Expand Down
6 changes: 1 addition & 5 deletions docs/api/spell.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,4 @@ Modules
-------

.. autofunction:: spell
.. autofunction:: pythainlp.spell.pn.spell
.. autofunction:: pythainlp.spell.pn.prob
.. autofunction:: pythainlp.spell.pn.correct
.. autofunction:: pythainlp.spell.pn.known
.. autofunction:: pythainlp.spell.pn.dictionary
.. autofunction:: correct
6 changes: 3 additions & 3 deletions docs/api/util.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ Modules
.. autofunction:: digit_to_text
.. autofunction:: eng_to_thai
.. autofunction:: find_keyword
.. autofunction:: is_thai
.. autofunction:: is_thaichar
.. autofunction:: is_thaiword
.. autofunction:: countthai
.. autofunction:: isthai
.. autofunction:: isthaichar
.. autofunction:: normalize
.. autofunction:: now_reign_year
.. autofunction:: num_to_thaiword
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
12 changes: 0 additions & 12 deletions docs/whatsnew-1.7.md

This file was deleted.

5 changes: 0 additions & 5 deletions examples/collate.py

This file was deleted.

10 changes: 0 additions & 10 deletions examples/date.py

This file was deleted.

5 changes: 0 additions & 5 deletions examples/etcc.py

This file was deleted.

5 changes: 0 additions & 5 deletions examples/ner.py

This file was deleted.

5 changes: 0 additions & 5 deletions examples/normalize.py

This file was deleted.

16 changes: 0 additions & 16 deletions examples/soundex.py

This file was deleted.

27 changes: 0 additions & 27 deletions examples/spell.py

This file was deleted.

10 changes: 0 additions & 10 deletions examples/tcc.py

This file was deleted.

24 changes: 0 additions & 24 deletions examples/tokenize.py

This file was deleted.

6 changes: 0 additions & 6 deletions examples/transliterate.py

This file was deleted.

2 changes: 1 addition & 1 deletion meta.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% set version = "1.7.2" %}
{% set version = "2.0.2" %}

package:
name: pythainlp
Expand Down
Loading