Zum Inhalt springen
Agentic Workflowdocs
v0.8.2Kostenlos installieren

knoten / builtin / ai / aidependencies / embeddings

Hugging Face Embeddings

Leverage Hugging Face Inference to create embeddings.

KI ErweiterungWeb-App

Dieser Inhalt ist noch nicht in deiner Sprache verfügbar.

Turn text into vectors with an embedding model hosted on Hugging Face, so a knowledge base can find passages by meaning.

Hugging Face Embeddings plugs into the Embeddings slot of a Local Knowledge node. It does not run on its own and has no output. When the knowledge base is filled or searched, the text is sent to Hugging Face’s hosted inference service with your token, and comes back as vectors (lists of numbers that capture meaning).

A knowledge base remembers the embedding model it was built with and always uses it. So this node decides the model when a new, empty knowledge base is first filled. After that, connect the same node to search it.

Your passages and questions are sent to Hugging Face. To run a similar model on your own device instead, use Local Embeddings.

  • You want a specific open embedding model from the Hugging Face Hub.
  • You have a Hugging Face account and want to use its inference service.
EinstellungTypWas es bewirkt
Model (erforderlich)TextThe embeddings model to use.
Authentication (erforderlich)CredentialUse your Hugging Face API key.

Model is the model’s name on the Hugging Face Hub, in the form owner/model, for example sentence-transformers/all-MiniLM-L6-v2. Don’t change it on a knowledge base that already has content.

This node has no output port. It plugs into a slot on another node instead of passing items along.

The vectors go to the knowledge base, not to the next node.

In Authentication, save a Hugging Face access token. Create one in your Hugging Face settings, under Access Tokens (huggingface.co/settings/tokens), with permission to call inference. See Create a credential.

  1. A Context Menu trigger on the page.
  2. Get All Text with Output field name pageText.
  3. Indexer with Input {{ $input.pageText }}, a Recursive Character Text Splitter in its Text Splitter slot, and a Local Knowledge pointing to a new knowledge base in its Knowledge slot.
  4. Hugging Face Embeddings in the Local Knowledge’s Embeddings slot, Model sentence-transformers/all-MiniLM-L6-v2.
  • “Model parameter is required and cannot be empty”. Fill in Model.
  • “… was built with … embeddings. Connect that embeddings node to use it.” The knowledge base was built with this model. Connect Hugging Face Embeddings with the same Model to its Local Knowledge.
  • A “Model mismatch” warning in the run log. The knowledge base was built with another model, so this node was ignored. Disconnect it, or re-embed the knowledge base from its settings.
  • A 401 or 403 error. The token is wrong or lacks inference permission. Create a new one and update the credential.
Seite bearbeiten

Zuletzt aktualisiert:

Was this page useful?
Aria zu Hugging Face Embeddings fragen