Skip to content

Commit

Permalink
Merge pull request #5 from adhaamehab/develop
Browse files Browse the repository at this point in the history
Add usage in readme
  • Loading branch information
adhaamehab committed May 5, 2019
2 parents f23bb8a + 08724c7 commit e7e32fa
Showing 1 changed file with 35 additions and 1 deletion.
36 changes: 35 additions & 1 deletion README.md
Expand Up @@ -4,6 +4,39 @@ Arabic NLP is a python package that provides an implementation for natural langu
This projetc is an active project that aims to build a standard tool for more advanced nlp tasks.


### Installation

```shell
pip install arabicnlp
```

### Usage

```python
from arabicnlp import tags, tokens, stem

tags("العربية هي شبكة لنقل الاخبار و المعلومات و مقاطع الفيديو إلى عالم عبر عدة وسائط ، تشمل الانترنت و مواقع التواصل الاجتماعي")
'''
{'العربية': 'PART', 'هي': 'ADP', 'شبكة': 'PART', 'لنقل': 'NUM', 'الاخبار': 'SYM', 'و': 'ADP', 'المعلومات': 'SYM', 'مقاطع': 'NUM', 'الفيديو': 'SYM', 'إلى': 'NUM', 'عالم': 'NUM', 'عبر': 'ADP', 'عدة': 'ADP', 'وسائط': 'NUM', '،': 'SYM', 'تشمل': 'SYM', 'الانترنت': 'INTJ', 'مواقع': 'PART', 'التواصل': 'SYM', 'الاجتماعي': 'ADP'}
'''

tokens("العربية هي شبكة لنقل الاخبار و المعلومات و مقاطع الفيديو إلى عالم عبر عدة وسائط ، تشمل الانترنت و مواقع التواصل الاجتماعي")

'''
['العربية', 'هي', 'شبكة', 'لنقل', 'الاخبار', 'و', 'المعلومات', 'و', 'مقاطع', 'الفيديو', 'إلى', 'عالم', 'عبر', 'عدة', 'وسائط', '،', 'تشمل', 'الانترنت', 'و', 'مواقع', 'التواصل', 'الاجتماعي']
'''

stem("العربية هي شبكة لنقل الاخبار و المعلومات و مقاطع الفيديو إلى عالم عبر عدة وسائط ، تشمل الانترنت و مواقع التواصل الاجتماعي")

'''
['عرب', 'هي', 'شبك', 'لنقل', 'اخبار', 'و', 'معلوم', 'و', 'مقاطع', 'فيديو', 'الى', 'عالم', 'عبر', 'عد', 'سايط', '', 'تشمل', 'انتر', 'و', 'مواقع', 'تواصل', 'اجتماع']
'''


```



### arabicnlp

- Arabicnlp is a natural language processing package for python developer
Expand All @@ -14,6 +47,7 @@ This projetc is an active project that aims to build a standard tool for more ad
* Part-of-speech tagger



### Known issue

- [tagger] Randomly some words that exists in word2index get msilabeled as `-PAD-`
Expand All @@ -29,4 +63,4 @@ This projetc is an active project that aims to build a standard tool for more ad

## LICENSE

MIT License
MIT License

0 comments on commit e7e32fa

Please sign in to comment.