Optional
params: SyntheticEmbeddingsParamsGenerates a synthetic embedding for a document. The document is converted into chunks, a numerical value is calculated for each chunk, and an array of these values is returned as the embedding.
The document to generate an embedding for.
A promise that resolves with a synthetic embedding for the document.
Generated using TypeDoc
A class that provides synthetic embeddings by overriding the embedDocuments and embedQuery methods to generate embeddings based on the input documents. The embeddings are generated by converting each document into chunks, calculating a numerical value for each chunk, and returning an array of these values as the embedding.