Method Create
- Namespace
- MailFathom.Application.Emails.Embeddings
- Assembly
- MailFathom.Application.dll
Create(int, string?, bool)
Builds a preparation, refusing one that could not produce a passage to send.
public static EmbeddingInputPreparation Create(int inputCharacterLimit, string? passageInstruction, bool normalizesVector)
Parameters
inputCharacterLimitintThe width a passage is cut to before it is sent.
passageInstructionstringThe instruction a model requires of a passage, or null.
normalizesVectorboolWhether the vector is normalized to unit length.
Returns
- EmbeddingInputPreparation
The input preparation.
Exceptions
- ArgumentOutOfRangeException
Thrown when the character limit is not positive.
- ArgumentException
Thrown when the instruction is blank, or longer than MaximumPassageInstructionLength.