AI/ML Embeddings
AI/ML Embeddings turns text into a numeric fingerprint of its meaning using the models of AI/ML API. With that fingerprint, NappAI can find the documents that say something similar to what you are looking for, even when they use different words, for example in a knowledge base.
You connect the component to a vector database, which uses it both to store your documents and to search them. Use it if your company already has an AI/ML API account, which gives access to models from several providers with a single account.
When to use it
- Give an agent the knowledge in your manuals, contracts or FAQs by storing them in a vector database.
- Build an internal search that finds documents by their meaning, not only by exact words.
- You already have an AI/ML API account and prefer not to open one with each provider.
- You need a multilingual model for documents in several languages.
Configuration
| Field | What it does |
|---|---|
| Credential (required) | The credential of the service AI/ML API. Pick one with Choose an option or create one with Add new credential. See Credentials. |
| Model Name (required) | The model that calculates the fingerprints. Pick one from the list: text-embedding-3-large, text-embedding-3-small, text-embedding-ada-002, text-multilingual-embedding-002, textembedding-gecko-multilingual@001, textembedding-gecko@001 or textembedding-gecko@003. |
Output
- Embeddings: the model that calculates the fingerprints, ready to use. Connect it to the Embedding input of a vector database: Astra DB, Cassandra, Chroma DB, Couchbase, Elasticsearch, FAISS, Milvus, MongoDB Vector Store, PGVector, Pinecone, Qdrant, Redis, Supabase Vector Store, Upstash, Vectara, Weaviate Cloud (v4). Other components with an input of this type accept it too, such as Semantic Text Splitter or Text Embedder.
Example
An office supplies distributor, Suministros Ebro, wants its assistant to answer using its product catalogue and its terms of sale.
- In a loading flow, split the documents into chunks with Recursive Character Text Splitter and pass them to Chroma DB with Operation set to
Add. - Add AI/ML Embeddings and connect its Embeddings output to the Embedding input of Chroma DB.
- In the assistant flow, use the same Chroma DB collection with the same AI/ML Embeddings component to find the chunks that answer each question.