
Lucene
文章平均质量分 77
fxjtoday
这个作者很懒,什么都没留下…
展开
-
Lucene in action 笔记 search篇
一. 用lucene怎么完成search1. 创建IndexSearcherIndexSearcher searcher = new IndexSearcher(directory);2. 生成需要搜索的词Term t = new Term("subject", "ant");3. 创建查询Query query = new TermQuery(t);4. search原创 2009-12-04 11:06:00 · 1076 阅读 · 0 评论 -
Lucene in action 笔记 index篇
一. Index之前要做什么1. 将要index的内容转化为文本你要处理的文件可能是PDF, word, html, OK通通转化成文本, lucene只能处理文本2.分析文本在index之前, 必须对文本做一系列的分析, 对文本的token化, 就是分词. 然后滤掉一些没有区分度的词, 如stop word这个地方涉及语言相关性. 不同语言的处理会不同. 英文还要处理大小写,原创 2009-12-02 15:47:00 · 3084 阅读 · 0 评论 -
Lucene in action 笔记 analysis篇
Analysis, in Lucene, is the process of converting field text into its most fundamental indexed representation, terms. 这个分析的步骤不一定的, 一般会包含如下:extracting words, discarding punctuation, removing accent原创 2009-12-07 17:21:00 · 1976 阅读 · 0 评论 -
Lucene in action 笔记 case study
一. Nutch作为用lucene实现的开源search engine怎么使用lucene的了.Nutch用了许多个的lucene indexes放在不同的server上, 因为是面对Web-scale的, document数目在1-10billion量级, 非常的多, 必须用许多机器同时去进行index和search操作. 而且在query的时候需要快速反应, 不能因为某个server原创 2009-12-24 11:03:00 · 1034 阅读 · 0 评论 -
Lucene in action 笔记 term vector
Leveraging term vectors所谓term vector, 就是对于documents的某一field,如title,body这种文本类型的, 建立词频的多维向量空间.每一个词就是一维, 这维的值就是这个词在这个field中的频率. 如果你要使用term vectors, 就要在indexing的时候对该field打开term vectors的选项:Field op原创 2010-01-06 14:25:00 · 10669 阅读 · 5 评论