Skip to content

Sujay0076/mini-search-engine-java

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

2 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ” Mini Search Engine (Java - Console Based)

๐Ÿš€ About the Project

This is a console-based mini search engine built using Java.
It demonstrates how search systems work internally using an inverted index and keyword-based lookup.

The system allows users to add documents and search for keywords efficiently with ranked results.


๐Ÿ”ฅ Features

  • Add documents with title and content
  • Keyword-based search
  • Inverted index using HashMap
  • Ranking system based on word frequency
  • Multi-document search results
  • Console-based user interaction

๐Ÿง  What I Implemented

  • Used HashMap to build an inverted index
  • Stored data as:
    word โ†’ (document โ†’ frequency)
  • Implemented keyword search with fast lookup
  • Added ranking logic based on frequency count
  • Handled multiple documents and dynamic input

โš™๏ธ Tech Stack

  • Java
  • Collections Framework (HashMap, List)
  • OOP Concepts

๐Ÿ“ธ Sample Output

==== MINI SEARCH ENGINE ====

  1. Add Document
  2. Search Document
  3. Exit 1 Title: Java Guide Enter Content: Java is easy Document Added!..

==== MINI SEARCH ENGINE ====

  1. Add Document
  2. Search Document
  3. Exit 1 Title: Spring Enter Content: Java is powerful Document Added!..

==== MINI SEARCH ENGINE ====

  1. Add Document
  2. Search Document
  3. Exit 2 Search Keyword: java Search Results (By Ranked): Java Guide (score: 2) Spring (score: 1)

==== MINI SEARCH ENGINE ====

  1. Add Document
  2. Search Document
  3. Exit 2 Search Keyword: spring Search Results (By Ranked): Spring (score: 1)

==== MINI SEARCH ENGINE ====

  1. Add Document
  2. Search Document
  3. Exit 3 Exiting...

About

Console-based mini search engine built in Java using HashMap inverted index with keyword-based search and ranking system

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages