This is a demo for a semantic search engine.
This GitHub project demonstrates how to use txtai to perform semantic search on a document. Sentence transformer is used to create embeddings for each sentence in the document and then txtai is used to find the most relevant sentences for a given query.
To use this project, you need to install the following packages:
- txtai
- sentence-transformers
- gradio
-
Clone this repository:
git clone https://github.com/yash2002vardhan/semantic-search.git
-
Access the app on your web browser after running the code.
-
Upload a text file by clicking on the "Upload a Text File" button and select a file from your local machine.
-
Enter a query in the "How can we help" textbox and click on the "Search" button.
-
The top matching result will be displayed in the "Top Matching Result" textbox.
This project was created using the following open-source tools:
- txtai
- sentence-transformers
- gradio
Youtube Link for the explanation of the code