Lucene 3.5中分组和构面之间有什么区别 [英] what's the difference between grouping and facet in lucene 3.5

查看:60
本文介绍了Lucene 3.5中分组和构面之间有什么区别的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在lucene 3.5 contrib文件夹中找到了两个插件:一个是分组,另一个是构面.在我的选择中,它们都用于将我的文档分为不同的类别.为什么lucene现在有两个插件?

I found in lucene 3.5 contrib folder two plugins: one is grouping, the other is facet. In my option, both of them were used to split my documents into different categories. Why lucene has now two plugins for this?

推荐答案

它们是两种不同的Lucene功能:

They are two different lucene features:

  • 分组最早是与Lucene 3.2一起发布的,其相关的jira问题是 LUCENE-1421 :它允许按指定字段对搜索结果进行分组.例如,如果按作者"字段分组,那么作者"字段中具有相同值的所有文档将归为一个组.您将有一种树作为输出.如果您想更深入地使用此Lucene功能,请此博客帖子应该有用.
  • Faceting最初与Lucene 3.4一起发布,其相关的jira问题是 LUCENE-3079 :此功能不对文档进行分组,它只是告诉您有多少文档属于某个构面的特定值.例如,如果您具有基于作者"字段的构面,则将收到所有作者的列表,并且对于每个作者,您将知道该特定作者属于多少个文档.之后,如果要查看这些文档,则必须再查询一次以添加特定的过滤器(作者=任意).分面搜索实际上是基于浏览文档,其中应用了多个过滤器来逐步访问您要访问的文档真的很感兴趣.
  • Grouping was first released with Lucene 3.2, its related jira issue is LUCENE-1421: it allows to group search results by specified field. For example, if you group by the author field, then all documents with the same value in the author field fall into a single group. You will have a kind of tree as output. If you want to go deeper into using this lucene feature, this blog post should be useful.
  • Faceting was first released with Lucene 3.4, its related jira issue is LUCENE-3079: this feature doesn't group documents, it just tells you how many documents fall in a specific value of a facet. For example, if you have a facet based on the author field, you will receive a list of all your authors, and for each author you will know how many documents belong to that specific author. After, if you want to see those documents, you have to query one more time adding a specific filter (author=whatever). The faceted search is in fact based on browsing documents applying multiple filters to progressively reach the documents you're really interested in.

这篇关于Lucene 3.5中分组和构面之间有什么区别的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆