update readme
This commit is contained in:
parent
7190d18513
commit
fa7f4a0b52
@ -4,15 +4,15 @@ IK Analysis for ElasticSearch
|
|||||||
The IK Analysis plugin integrates Lucene IK analyzer into elasticsearch, support customized dictionary.
|
The IK Analysis plugin integrates Lucene IK analyzer into elasticsearch, support customized dictionary.
|
||||||
|
|
||||||
|
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
| IK Analysis Plugin | ElasticSearch |
|
| IK Analysis Plugin | ElasticSearch |
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
| master | 0.19.4 -> master |
|
| master | 0.19.4 -> master |
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
| 1.1.0 | 0.19.4 -> master |
|
| 1.1.0 | 0.19.4 -> master |
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
| 1.0.0 | 0.16.2 -> 0.19.0 |
|
| 1.0.0 | 0.16.2 -> 0.19.0 |
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
Install
|
Install
|
||||||
@ -85,7 +85,7 @@ curl -XPUT http://localhost:9200/index
|
|||||||
|
|
||||||
2.create a mapping
|
2.create a mapping
|
||||||
|
|
||||||
```bash
|
<pre>
|
||||||
|
|
||||||
curl -XPOST http://localhost:9200/index/fulltext/_mapping -d'
|
curl -XPOST http://localhost:9200/index/fulltext/_mapping -d'
|
||||||
{
|
{
|
||||||
@ -108,13 +108,12 @@ curl -XPOST http://localhost:9200/index/fulltext/_mapping -d'
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}'
|
||||||
'
|
</pre>
|
||||||
```
|
|
||||||
|
|
||||||
3.indexing some docs
|
3.indexing some docs
|
||||||
|
|
||||||
```bash
|
<pre>
|
||||||
|
|
||||||
curl -XPOST http://localhost:9200/index/fulltext/1 -d'
|
curl -XPOST http://localhost:9200/index/fulltext/1 -d'
|
||||||
{content:"美国留给伊拉克的是个烂摊子吗"}
|
{content:"美国留给伊拉克的是个烂摊子吗"}
|
||||||
@ -131,12 +130,11 @@ curl -XPOST http://localhost:9200/index/fulltext/3 -d'
|
|||||||
curl -XPOST http://localhost:9200/index/fulltext/4 -d'
|
curl -XPOST http://localhost:9200/index/fulltext/4 -d'
|
||||||
{content:"中国驻洛杉矶领事馆遭亚裔男子枪击 嫌犯已自首"}
|
{content:"中国驻洛杉矶领事馆遭亚裔男子枪击 嫌犯已自首"}
|
||||||
'
|
'
|
||||||
|
</pre>
|
||||||
```
|
|
||||||
|
|
||||||
4.query with highlighting
|
4.query with highlighting
|
||||||
|
|
||||||
```bash
|
<pre>
|
||||||
|
|
||||||
curl -XPOST http://localhost:9200/index/fulltext/_search -d'
|
curl -XPOST http://localhost:9200/index/fulltext/_search -d'
|
||||||
{
|
{
|
||||||
@ -150,11 +148,11 @@ curl -XPOST http://localhost:9200/index/fulltext/_search -d'
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
'
|
'
|
||||||
```
|
</pre>
|
||||||
|
|
||||||
here is the query result
|
here is the query result
|
||||||
|
|
||||||
```bash
|
<pre>
|
||||||
|
|
||||||
{
|
{
|
||||||
"took": 14,
|
"took": 14,
|
||||||
@ -200,7 +198,7 @@ here is the query result
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
```
|
</pre>
|
||||||
|
|
||||||
|
|
||||||
have fun.
|
have fun.
|
Loading…
x
Reference in New Issue
Block a user