Table of Contents

Constructor StoredEmailEmbeddingGenerator

Namespace
MailFathom.Application.Emails.Embeddings.Generation
Assembly
MailFathom.Application.dll

StoredEmailEmbeddingGenerator(IEmailEmbeddingStore, ITextEmbeddingGenerator, OptimisticConcurrencyRetryPolicy, EmbeddingSpendGate, EmbeddingRequestPacer)

Initializes a new generator of one message's embeddings.

public StoredEmailEmbeddingGenerator(IEmailEmbeddingStore embeddingStore, ITextEmbeddingGenerator textEmbeddingGenerator, OptimisticConcurrencyRetryPolicy concurrencyRetryPolicy, EmbeddingSpendGate spendGate, EmbeddingRequestPacer requestPacer)

Parameters

embeddingStore IEmailEmbeddingStore

Reads which passages lack a vector, and writes the vectors that answer.

textEmbeddingGenerator ITextEmbeddingGenerator

Turns passages into points of that space.

concurrencyRetryPolicy OptimisticConcurrencyRetryPolicy

Commits one call's vectors, retrying a conflict with a competing writer.

spendGate EmbeddingSpendGate

Says whether the period still admits a request, and is charged for the ones it does.

requestPacer EmbeddingRequestPacer

Holds a call back until this deployment is allowed to send its next one.

Exceptions

ArgumentNullException

Thrown when any argument is null.