Skip to content

Commit 7864007

Browse files
authored
Merge branch 'dev' into move-dill2pickle
2 parents 36532dd + a4bbac9 commit 7864007

File tree

5 files changed

+24
-16
lines changed

5 files changed

+24
-16
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
[![Downloads](https://pepy.tech/badge/pythainlp/month)](https://pepy.tech/project/pythainlp)
88
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
99
[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2FPyThaiNLP%2Fpythainlp.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2FPyThaiNLP%2Fpythainlp?ref=badge_shield)
10-
[![Build Status](https://travis-ci.org/PyThaiNLP/pythainlp.svg?branch=develop)](https://travis-ci.org/PyThaiNLP/pythainlp)
1110
[![Build status](https://ci.appveyor.com/api/projects/status/9g3mfcwchi8em40x?svg=true)](https://ci.appveyor.com/project/wannaphongcom/pythainlp-9y1ch)
1211
[![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)
1312
[![Coverage Status](https://coveralls.io/repos/github/PyThaiNLP/pythainlp/badge.svg?branch=dev)](https://coveralls.io/github/PyThaiNLP/pythainlp?branch=dev) [![Google Colab Badge](https://badgen.net/badge/Launch%20Quick%20Start%20Guide/on%20Google%20Colab/blue?icon=terminal)](https://colab.research.google.com/github/PyThaiNLP/tutorials/blob/master/source/notebooks/pythainlp_get_started.ipynb)
@@ -87,6 +86,7 @@ where `extras` can be
8786
- `ner` (for named-entity recognizer)
8887
- `thai2fit` (for Thai word vector)
8988
- `thai2rom` (for machine-learnt romanization)
89+
- `wordnet` (for Thai WordNet API)
9090
- `full` (install everything)
9191

9292
For dependency details, look at `extras` variable in [`setup.py`](https://github.com/PyThaiNLP/pythainlp/blob/dev/setup.py).
@@ -208,6 +208,7 @@ pip install pythainlp[extra1,extra2,...]
208208
- `ner` (สำหรับการติดป้ายชื่อเฉพาะ (named-entity))
209209
- `thai2fit` (สำหรับ word vector)
210210
- `thai2rom` (สำหรับการถอดตัวสะกดเป็นอักษรละติน)
211+
- `wordnet` (สำหรับ API WordNet ภาษาไทย)
211212
- `full` (ติดตั้งทุกอย่าง)
212213

213214
รายละเอียดของแพคเกจเสริมดูได้ในตัวแปรชื่อ `extras` ใน [`setup.py`](https://github.com/PyThaiNLP/pythainlp/blob/dev/setup.py)

docs/api/corpus.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
pythainlp.corpus
44
====================================
5-
The :class:`pythainlp.corpus` is corpus for pythainlp.
5+
The :class:`pythainlp.corpus` provides access to corpus that comes with PyThaiNLP.
66

77
Modules
88
-------
@@ -32,6 +32,9 @@ TTC
3232
Wordnet
3333
-------
3434

35+
PyThaiNLP API is an exact copy of NLTK WordNet API.
36+
See: https://www.nltk.org/howto/wordnet.html
37+
3538
.. autofunction:: pythainlp.corpus.wordnet.synsets
3639
.. autofunction:: pythainlp.corpus.wordnet.synset
3740
.. autofunction:: pythainlp.corpus.wordnet.all_lemma_names

pythainlp/corpus/wordnet.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,11 @@
22
"""
33
NLTK WordNet wrapper
44
5-
API here is exactly the same as NLTK API,
5+
API here is exactly the same as NLTK WordNet API,
66
except that lang (language) argument will be "tha" (Thai) by default.
7+
8+
For more on usage, see NLTK Howto:
9+
https://www.nltk.org/howto/wordnet.html
710
"""
811
import nltk
912

requirements.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
nltk==3.4.*
21
python-crfsuite==0.9.*
3-
requests==2.22.*
4-
tinydb==3.14.*
5-
tqdm==4.36.*
2+
requests==2.23.*
3+
tinydb==4.1.*
4+
tqdm==4.46.*

setup.py

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@
3939
"""
4040

4141
requirements = [
42-
"nltk>=3.3",
4342
"python-crfsuite>=0.9.6",
4443
"requests>=2.22.0",
4544
"tinydb>=3.0",
@@ -48,20 +47,22 @@
4847

4948
extras = {
5049
"attacut": ["attacut>=1.0.6"],
51-
"benchmarks": ["numpy>=1.16", "pandas>=0.24"],
50+
"benchmarks": ["numpy>=1.16.1", "pandas>=0.24"],
5251
"icu": ["pyicu>=2.3"],
5352
"ipa": ["epitran>=1.1"],
54-
"ml": ["numpy>=1.16", "torch>=1.0.0"],
53+
"ml": ["numpy>=1.16.1", "torch>=1.0.0"],
5554
"ner": ["sklearn-crfsuite>=0.3.6"],
5655
"ssg": ["ssg>=0.0.6"],
57-
"thai2fit": ["emoji>=0.5.1", "gensim>=3.2.0", "numpy>=1.16"],
58-
"thai2rom": ["torch>=1.0.0", "numpy>=1.16"],
56+
"thai2fit": ["emoji>=0.5.1", "gensim>=3.2.0", "numpy>=1.16.1"],
57+
"thai2rom": ["torch>=1.0.0", "numpy>=1.16.1"],
58+
"wordnet": ["nltk>=3.3.*"],
5959
"full": [
6060
"attacut>=1.0.4",
6161
"emoji>=0.5.1",
6262
"epitran>=1.1",
6363
"gensim>=3.2.0",
64-
"numpy>=1.16",
64+
"nltk>=3.3.*",
65+
"numpy>=1.16.1",
6566
"pandas>=0.24",
6667
"pyicu>=2.3",
6768
"sklearn-crfsuite>=0.3.6",
@@ -141,9 +142,10 @@
141142
],
142143
},
143144
project_urls={
144-
"Documentation": "https://www.thainlp.org/pythainlp/docs/dev/",
145-
"Source": "https://github.com/PyThaiNLP/pythainlp",
146-
"Bug Reports": "https://github.com/PyThaiNLP/pythainlp/issues",
145+
"Documentation": "https://www.thainlp.org/pythainlp/docs/2.1/",
146+
"Tutorials": "https://www.thainlp.org/pythainlp/tutorials/",
147+
"Source Code": "https://github.com/PyThaiNLP/pythainlp",
148+
"Bug Tracker": "https://github.com/PyThaiNLP/pythainlp/issues",
147149
},
148150
)
149151

0 commit comments

Comments
 (0)