从Lucene索引获取最高频率项 [英] Get highest frequency terms from Lucene index
问题描述
我需要从多个lucene索引中提取具有最高频率的词语,以便将它们用于某些语义分析。
因此,我想得到可能是前30个最重要的术语(仍然没有决定门槛,我将分析结果)和他们的每个索引计数。我知道我可能因为潜在的重复删除而失去一些精确度,但现在,让我说我没问题。
因此,对于所提出的解决方案,(不用说也许)速度并不重要,因为我会进行静态分析,所以我会强调因为我对Lucene不太熟练,也不能将我的思想包含在它的一些概念中。
我找不到任何类似的代码示例,所以所有的具体建议(代码,伪代码,代码示例的链接...)欣赏所有建议!
谢谢!
看看这个:
http://sujitpal.blogspot.com/2009/02/summarization-with-lucene.html
课程在此页面中有 computeTopTermQuery
方法,您应该可以轻松地翻新以查看多个索引。
i need to extract terms with highest frequencies from several lucene indexes, to use them for some semantic analysis.
So, I want to get maybe top 30 most occuring terms(still did not decide on threshold, i will analyze results) and their per-index counts. I am aware that I might lose some precision because of potentionally dropped duplicates, but for now, lets say i am ok with that.
So for the proposed solutions, (needless to say maybe) speed is not important, since I would do static analysis, I would put accent on simplicity of implementation because im not so skilled with Lucene and cant wrap my mind around some concepts of it..
I can not find any code samples from something similar, so all concrete advices (code, pseudocode, links to code samples...) Appreciate all the advices!
Thank you!
Have a look at this: http://sujitpal.blogspot.com/2009/02/summarization-with-lucene.html
The class in this page hascomputeTopTermQuery
method which you should be easily able to retrofit for going over multiple indexes.
这篇关于从Lucene索引获取最高频率项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!