org.llm4s.rag.embed.EmbeddingBatching
See theEmbeddingBatching companion object
@Experimental
How many texts, and how many characters, one embedding request may carry (#3001). Providers cap a request's inputs (Cohere 96, Voyage 128, OpenAI 2,048) and its tokens (OpenAI 300,000), and reject a larger one outright, so a document of a few thousand chunks failed to ingest as a whole. The pipeline splits the texts into requests within both bounds; the defaults are below every provider llm4s ships.
Value parameters
- maxChars
-
the most characters in one request, summed over its texts: a token budget, at roughly four characters a token. A single text longer than this goes alone in its request
- maxInputs
-
the most texts in one request; at least 1
Attributes
- Companion
- object
- Source
- EmbeddingBatching.scala
- Graph
-
- Supertypes
Members list
In this article
