在 Solr 中获取片段
我正在运行 Solr + Nutch,需要获取每个结果的片段。我尝试在查询 URL 中将 hl
设置为 true
,但仍然得到相同的 XML 结果(没有片段)。关于如何完成这项工作有什么想法吗?
I'm running Solr + Nutch and need to get a snippet of each result. I tried setting hl
to true
in the query URL but I still get the same XML result (without snippets). Any ideas on how to get this done?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您需要通过将字段名称传递给查询中的
hl.fl
参数来指定要突出显示返回结果的字段。请参阅 Solr Wiki 上的 HighlightingParameters 了解更多详细信息和示例。You need to specify the fields that you want highlight results returned for by passing field names to the
hl.fl
parameter in your query. Please see HighlightingParameters on the Solr Wiki for more details and examples.