Skip to main content
Semantic searching, which involves understanding the intent and contextual meaning behind search queries, is yet another popular use-case of RAG. It has several popular use cases across various domains:
  • Information Retrieval: Enhances search accuracy in databases and websites
  • E-commerce: Improves product discovery in online shopping
  • Customer Support: Powers smarter chatbots for effective responses
  • Content Discovery: Aids in finding relevant media content
  • Knowledge Management: Streamlines document and data retrieval in enterprises
  • Healthcare: Facilitates medical research and literature search
  • Legal Research: Assists in legal document and case law search
  • Academic Research: Aids in academic paper discovery
  • Language Processing: Enables multilingual search capabilities
EmbedJs offers a simple yet customizable search() API that you can use for semantic search. See the example in the next section to know more.

Example: Semantic Search over Next.JS Website + Forum

Step 1: Set Up Your RAG Pipeline

First, let’s create your RAG pipeline. Open your NodeJs application and add the following code:
Create pipeline
This initializes your application.

Step 2: Populate Your Pipeline with Data

Now, let’s add data to your pipeline. We’ll include the Next.JS website and its documentation:
Ingest data sources
This step incorporates over 15K pages from the Next.JS website and forum into your pipeline. For more data source options, check the EmbedJs data sources overview.

Step 3: Local Testing of Your Pipeline

Test the pipeline on your local machine:
Search App
The source key contains the url of the document that yielded that document chunk. If you are interested in configuring the search further, refer to our API documentation.
This guide will help you swiftly set up a semantic search pipeline with EmbedJs, making it easier to access and analyze specific information from large data sources.

Need help?

In case you run into issues, feel free to contact us via any of the following methods:

Slack

Join our slack community