Skip to content

Commit

Permalink
delete unnecessary information in README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
taishi-i committed Jun 26, 2018
1 parent d24f255 commit 07d2bac
Showing 1 changed file with 3 additions and 60 deletions.
63 changes: 3 additions & 60 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,20 @@ This tool has the following features.
- The POS-tagging model uses tag dictionary information [[Inoue+]](http://www.aclweb.org/anthology/K17-1042).

For more details refer to the following links.
- The Slide in Japanese is available [here](https://drive.google.com/open?id=1AzR5wh5502u_OI_Jxwsq24t-er_rnJBP).
- The Documentation is available [here](https://nagisa.readthedocs.io/en/latest/?badge=latest).
- The slide in Japanese is available [here](https://drive.google.com/open?id=1AzR5wh5502u_OI_Jxwsq24t-er_rnJBP).
- The documentation is available [here](https://nagisa.readthedocs.io/en/latest/?badge=latest).

Installation
=============

Nagisa is compatible with: Python 2.7-3.6.
This tool uses [DyNet](https://github.com/clab/dynet) (the Dynamic Neural Network Toolkit) to calcucate neural networks.

- Using pip
- You can install nagisa by using the following command.
```bash
pip install nagisa
```

- From github
```bash
git clone https://github.com/taishi-i/nagisa
cd nagisa
python setup.py install
```

Usage
======

Expand All @@ -62,53 +55,3 @@ print(words)
#=> ['Python', 'で', '簡単', 'に', '使える', 'ツール', 'です']
```

Functions
=========

- Output words can be controlled by POS-tags.
```python
# Extarcting all nouns from a text
words = nagisa.extract(text, extract_postags=['名詞'])
print(words)
#=> Python/名詞 ツール/名詞

# Filtering specific POS-tags from a text
words = nagisa.filter(text, filter_postags=['助詞', '助動詞'])
print(words)
#=> Python/名詞 簡単/形状詞 使える/動詞 ツール/名詞

# A list of available POS-tags
print(nagisa.tagger.postags)
#=> ['補助記号', '名詞', ... , 'URL']

```

- A word can be recognized as a single word forcibly.
```python
text = 'ニューラルネットワークを使ってます。'
print(nagisa.tagging(text))
#=> ニューラル/名詞 ネットワーク/名詞 を/助詞 使っ/動詞 て/助動詞 ます/助動詞 。/補助記号

# If a word is included in the single_word_list, it is recognized as a single word.
tagger_nn = nagisa.Tagger(single_word_list=['ニューラルネットワーク'])
print(tagger_nn.tagging(text))
#=> ニューラルネットワーク/名詞 を/助詞 使っ/動詞 て/助動詞 ます/助動詞 。/補助記号
```

- Nagisa is good at capturing URLs and emoticons from an input text.
```python
text = '(人•ᴗ•♡)こんばんは♪'
words = nagisa.tagging(text)
print(words)
#=> (人•ᴗ•♡)/補助記号 こんばんは/感動詞 ♪/補助記号

url = 'https://github.com/taishi-i/nagisaでコードを公開中(๑¯ω¯๑)'
words = nagisa.tagging(url)
print(words)
#=> https://github.com/taishi-i/nagisa/URL で/助詞 コード/名詞 を/助詞 公開/名詞 中/接尾辞 (๑ ̄ω ̄๑)/補助記号

words = nagisa.filter(url, filter_postags=['URL', '補助記号', '助詞'])
print(words)
#=> コード/名詞 公開/名詞 中/接尾辞
```

0 comments on commit 07d2bac

Please sign in to comment.