GithubHelp home page GithubHelp logo

blvming / sphinx-jieba Goto Github PK

View Code? Open in Web Editor NEW

This project forked from frankee/sphinx-jieba

0.0 1.0 0.0 5.18 MB

sphinx search engine with jieba tokenizer

License: GNU General Public License v2.0

CMake 0.41% Makefile 3.15% M4 0.71% Java 1.05% Batchfile 0.14% Shell 4.81% C 12.22% Ruby 1.29% PHP 4.09% Smarty 0.01% Python 0.75% Perl 0.07% C++ 70.05% Yacc 1.05% Lex 0.19% C# 0.01%

sphinx-jieba's Introduction

sphinx-jieba

Sphinx for Chinese with cppJieba

仿照Sphinx for Chinese,基于sphinx 2.2.9版本,结合cppJieba分词系统,让sphinx支持中文。

安装

解压

$ git clone https://github.com/eric1688/sphinx
$ cd sphinx

编译(假设安装到/usr/local/sphinx目录,下文同)

$ ./configure --prefix=/usr/local/sphinx
--prefix 指定安装路径
--with-mysql 编译mysql支持
--with-pgsql 编译pgsql支持
$ make
$ make install

配置中文支持

修改sphinx.conf索引配置文件

在索引配置项中添加以下两项:

charset_type = utf-8
chinese_dictionary = /usr/local/sphinx/etc/xdict

注意在source部分一定加上如下字段,否则中文分词无法起作用。

sql_query_pre = SET NAMES utf8

TODOs:

  1. 在index时,添加同义词功能 a. 本身在Sphinx GetToken时可以返回多个同义Token b. 增加同义词典
  2. 字典支持二进制形式
  3. cmake make sure the expat and int64_t varible set.

sphinx-jieba's People

Contributors

frankee avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.