mindoc/search/search.go

18 lines
374 B
Go
Raw Normal View History

2017-04-21 18:20:35 +08:00
package search
import (
"github.com/huichen/wukong/engine"
"github.com/huichen/wukong/types"
)
var searcher engine.Engine
func init() {
searcher.Init(types.EngineInitOptions{
SegmenterDictionaries: "data/dictionary.txt",
StopTokenFile: "data/stop_tokens.txt",
IndexerInitOptions: &types.IndexerInitOptions{
IndexType: types.LocationsIndex,
},
})
}