Skip to content

Latest commit

 

History

History
31 lines (19 loc) · 604 Bytes

README.md

File metadata and controls

31 lines (19 loc) · 604 Bytes

xs4go

xunsearch golang sdk

文档

建立索引: 参考Xunsearch 索引部分。

搜索: 参考Xunsearch 搜索部分。

配置文件

参考test/demox.tomlXunsearch官方。

分词器

请自己实现如下接口:

type Tokenizer interface {
    GetTokens(text string) []string
}

然后将其设置为分词器:

index, err := xs.NewIndexer("./demox.toml")

index.SetTokenizer(yourTokenizer)