Book Image

Neural Search - From Prototype to Production with Jina

By : Jina AI, Bo Wang, Cristian Mitroi, Feng Wang, Shubham Saboo, Susana Guzmán
Book Image

Neural Search - From Prototype to Production with Jina

By: Jina AI, Bo Wang, Cristian Mitroi, Feng Wang, Shubham Saboo, Susana Guzmán

Overview of this book

Search is a big and ever-growing part of the tech ecosystem. Traditional search, however, has limitations that are hard to overcome because of the way it is designed. Neural search is a novel approach that uses the power of machine learning to retrieve information using vector embeddings as first-class citizens, opening up new possibilities of improving the results obtained through traditional search. Although neural search is a powerful tool, it is new and finetuning it can be tedious as it requires you to understand the several components on which it relies. Jina fills this gap by providing an infrastructure that reduces the time and complexity involved in creating deep learning–powered search engines. This book will enable you to learn the fundamentals of neural networks for neural search, its strengths and weaknesses, as well as how to use Jina to build a search engine. With the help of step-by-step explanations, practical examples, and self-assessment questions, you'll become well-versed with the basics of neural search and core Jina concepts, and learn to apply this knowledge to build your own search engine. By the end of this deep learning book, you'll be able to make the most of Jina's neural search design patterns to build an end-to-end search solution for any modality.
Table of Contents (13 chapters)
1
Part 1: Introduction to Neural Search Fundamentals
5
Part 2: Introduction to Jina Fundamentals
8
Part 3: How to Use Jina for Neural Search

Getting started with the Q/A chatbot

The Q/A chatbot is a pre-built example that comes with the Jina installation. To experience the power of Jina firsthand and quickly get started, you can run the Q/A chatbot example directly from the command line without even getting into the code. The Q/A chatbot uses the public Covid Q/A dataset (https://www.kaggle.com/datasets/xhlulu/covidqa) from Kaggle, which contains 418 Q/A pairs (https://www.kaggle.com/xhlulu/covidqa).

Follow these instructions to set up the development environment and run the Q/A chatbot example:

  1. The first step is to install the Jina library from the Python Package Index (PyPI) along with the required dependencies:
    pip install "jina[demo]"
  2. After that, simply type the following command to launch your app:
    jina hello chatbot

After typing this command, you will see the following text on your command-line interface (CLI):

Figure 6.1 – Q/A chatbot command line

If...