我有什么办法可以根据 Lucene 中的学期位置更改评分吗?

发布于 2025-01-01 13:33:47 字数 193 浏览 3 评论 0原文

例如,如果我正在搜索包含“harry”一词的书名索引,则“Dirty Harry”的得分与“Harry Potter”相同,并且当两个项目得分相同时,顺序是随机的。我想提高以我的搜索词(哈利·波特)开头的词的权重。

我宁愿不使用 TermPostionVector,因为这似乎是我只能在搜索和评分完成后才能阅读的内容。

感谢您的时间/考虑。

for example, if I am searching an index of book titles with the term "harry", "Dirty Harry" is scored equally to "Harry Potter", and when two items are equally scored, the order is random. I'd like to weight the one that begins with my search term (Harry Potter) higher.

I would rather not use TermPostionVector as it seems that this is something I can read only after the search and scoring has been completed.

thanks for your time/consideration.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文