Java中的搜索引擎算法?

发布于 2024-12-11 13:47:21 字数 421 浏览 0 评论 0原文

好吧,我对这个网站真的很陌生,我想这才 2 个小时,所以我需要一段时间才能习惯这个网站并提出不违反指南的问题。

我想做的就是实现一个小型搜索引擎,这不是我仅仅通过学习就能获得报酬的家庭作业或工作。

搜索引擎将有一个简单的用户界面,供用户提出问题并显示结果。

显然需要组织该结果,需要显示找到的结果数量,并且最相关的结果将显示在顶部 它还会有指向它找到的材料的链接。 我有一些java经验,因此我需要一个算法来实现这个。

有一百万种不同的搜索引擎,有些是 Java 的,有些是 php 和其他语言的,但是它们已经实现了,我需要从头开始实现这个算法。

我专门为此目的买了一本书,名为“算法导论”,但这并没有我想象的那么有帮助。 我需要一些java指南,一个以代码形式列出我需要做的事情的菜单。

如果有人可以提供帮助,我将非常感激。 谢谢

Ok i am really new to this site, i think it has just been 2 hours so it would take a while for me to get used to the site and ask questions that do not go against the guidelines.

All i am trying to do is implement a small search engine, its not homework or work that i am going to get paid for just learning.

The serch engine would have a simple user interface for the user to ask questions and for results to be displayed.

This results would obviously need to be organised it would need to display the number of results it found and the most relevant results would be displayed on top
It would also have links to the material it found.
I have some expereince in java and therefore i need an algorithm to implement this.

There is a million different search engines some in java some in php and other languages however they have already been implemented and i need to start from scratch implementing this algorithm.

I bought a book just for this purpose its called "Introduction to Algorithms" but that does not help as much as i thougth it would.
I need some guides in java, a menu of what i need to do in the form of code.

If anyone could help, i would be very grateful.
Thanks

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

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

发布评论

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

评论(1

撩起发的微风 2024-12-18 13:47:21

您可以使用库Apache Lucene,它是一个成熟的基于java的信息检索系统。

您必须创建一个 IndexWriter,并使用它来索引您的文档集合。

然后,您应该使用 索引搜索器。请阅读文档,因为可能您需要的一切都已构建。

如果您想从头开始实现它,我建议首先阅读信息检索。一个很好的起点是信息检索简介

You can use the library Apache Lucene, which is a mature java based information retrieval system.

You will have to create an IndexWriter, and use it to index your collection of documents.

Then, you should search for a document, using an IndexSearcher. Please read the documentation, since probably all you need is already built.

If you want to implement it from scratch, I'd suggest first reading about Information Retrieval. A good source to start with will be Introduction to Information Retrieval

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