Jina NOW - get your neural search case up and running in minutes.
Project description
One command to host them all. Bring your search case into the cloud in minutes.
Tell us what you think: Survey
NOW gives the world access to neural image search in just one command execution. Main features
- ⛅ Cloud: We take care of the deployment and maintenance
- 🐥 Easy: Minimal effort required to set up your search case
- 🐎 Fast: Set up your search case within minutes
- 🌈 Quality: If you provide labels to your documents, Jina NOW fine-tunes a model for you
- ✨ Nocode: Deployment can be done by non-technical people
Installation
pip install jina-now
In case you need sudo for running Docker, install and use jina-now using sudo as well.
Mac M1
For the Mac M1 it is generally recommended using a conda environment as outlined in the Jina documentation.
In a new conda environment first execute conda install grpcio tokenizers protobuf
. Then run pip install jina-now
.
Usage
You can use the following command to start Jina NOW.
jina now start
First, you will get asked what search case you would like to deploy.
Quick Start
jina now start
First, you will be prompted to choose an app. As for now, we support images or text searches. But in the future, we will add many more options here.
In the next step, you get asked to select the dataset for your search app. You could either choose one of our existing datasets or select custom
to index your own data.
When choosing custom
, you can decide in what format you provide your data. The recommended way, is to push a document array described here.
Alternatively, you can specify a URL where a document array can be downloaded from.
Also, it is possible to provide a local folder where the Images are located. In case of text search it would be a local text file.
If you chose docarray.pull
, you will be asked to insert your docarray id.
Likewise, if you chose docarray URL, you will be prompted to enter the URL.
In case you selected local path, jina-now
will ask you to enter the local path of the data folder as shown bellow.
The search app can be deployed in different qualities. Have in mind that a better quality leads to a larger ai model being deployed and therefore inference will be a bit slower.
Currently, we provide two deployment options. We recommend using the cloud deployment. This will run your search app on our servers. Alternatively, you can select the local deployment option.
In case of local deployment, you will be asked where you want to deploy it. Jina NOW reads your local .kube/config and lists all kubernetes clusters you have access to. If you don't want to use an existing cluster, you can create a new one locally.
After the program execution is finished, two links will be shown to you. The first one brings you to a playground where you can run example queries and experiment with the search case. The second URL leads you to the swagger UI which is useful for Frontend integration.
Example of the playground.
Example of the swagger ui.
Use CLI Parameters
Instead of answering the questions manually, you can also provide command-line arguments when starting Jina NOW like shown here.
jina now start --quality medium --data /local/img/folder
Use API
You can now send requests to the API using the jina client. This case shows a local deployment.
from jina import Client
client = Client(
host='localhost',
port=31080,
)
response = client.search(
Document(text=search_text), # or in case you send an image: Document(url=image_path),
parameters={"limit": 9, "filter": {}},
)
Cleanup
jina now stop
Requirements
Linux
orMac
Python 3.7
,3.8
,3.9
or3.10
Local execution
Docker
installation- 10 GB assigned to docker
- User must be permitted to run docker containers
Supported apps (more will be added)
- Text to Image search 📝 ▶ 🏞
- Image to Text search 🏞 ▶ 📝
- Image to Image search 🏞 ▶ 🏞
- Text to Text search 📝 ▶ 📝
- Music to Music search 🥁 ▶ 🥁
- Text to Video search 📝 ▶ 🎥 (only gif at the moment)
- Text to 3D Mesh search 📝 ▶ 🧊
- ...
Examples
👕 Fashion
☢️ Chest X-Ray
💰 NFT - bored apes
🖼 Art
🚗 Cars
🏞 Street view
🦆 Birds
Now use your custom data :)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.