mirror of
https://github.com/fxsjy/jieba.git
synced 2025-07-10 00:01:33 +08:00
fix English part of README
This commit is contained in:
parent
31b7d11809
commit
9d2818b440
@ -400,6 +400,7 @@ Main Functions
|
|||||||
|
|
||||||
**Code example: segmentation**
|
**Code example: segmentation**
|
||||||
|
|
||||||
|
```python
|
||||||
#encoding=utf-8
|
#encoding=utf-8
|
||||||
import jieba
|
import jieba
|
||||||
|
|
||||||
@ -414,6 +415,7 @@ Main Functions
|
|||||||
|
|
||||||
seg_list = jieba.cut_for_search("小明硕士毕业于中国科学院计算所,后在日本京都大学深造") # 搜索引擎模式
|
seg_list = jieba.cut_for_search("小明硕士毕业于中国科学院计算所,后在日本京都大学深造") # 搜索引擎模式
|
||||||
print ", ".join(seg_list)
|
print ", ".join(seg_list)
|
||||||
|
```
|
||||||
|
|
||||||
Output:
|
Output:
|
||||||
|
|
||||||
@ -474,6 +476,7 @@ Use: `jieba.analyse.textrank(raw_text)`.
|
|||||||
* Tags the POS of each word after segmentation, using labels compatible with ictclas.
|
* Tags the POS of each word after segmentation, using labels compatible with ictclas.
|
||||||
* Example:
|
* Example:
|
||||||
|
|
||||||
|
```pycon
|
||||||
>>> import jieba.posseg as pseg
|
>>> import jieba.posseg as pseg
|
||||||
>>> words = pseg.cut("我爱北京天安门")
|
>>> words = pseg.cut("我爱北京天安门")
|
||||||
>>> for w in words:
|
>>> for w in words:
|
||||||
@ -483,6 +486,7 @@ Use: `jieba.analyse.textrank(raw_text)`.
|
|||||||
爱 v
|
爱 v
|
||||||
北京 ns
|
北京 ns
|
||||||
天安门 ns
|
天安门 ns
|
||||||
|
```
|
||||||
|
|
||||||
5) : Parallel Processing
|
5) : Parallel Processing
|
||||||
-----------
|
-----------
|
||||||
|
Loading…
x
Reference in New Issue
Block a user