Interface IEmailAttachmentImageDescriber
- Namespace
- MailFathom.Application.Emails.Extraction.Images
- Assembly
- MailFathom.Application.dll
Turns one image attachment into text, or says why it stayed a picture.
public interface IEmailAttachmentImageDescriber
Remarks
An image has no text to extract, so it reaches search only if something first writes down what it shows. That is what this does, and it is the whole of what it does: it composes no chunk, embeds nothing, stores nothing, and decides nothing about where a described message ranks. What it produces is a string, which from that point is attachment-derived text like any other, described by ADR 0030.
**It runs in the background and never on a read path.** Describing costs a call to a chat provider, so a caller that reached it while answering an MCP tool or a client request would have put a remote party's latency, rate limit, and outage between a person and their own mail. What calls this is the work that runs after a message is stored.
**Every call sends the attachment's octets to a third party.** That is a disclosure of mail content at least as large as sending message text for embedding — a photograph of a document discloses the document — and it is the one egress on this path that no content scan covers, because SensitiveContentEgressGuard detects regions in a string and an image is not one. What governs it is the deployment's own activation and nothing else, which is why an instance that has not turned image description on refuses every call with NotActivated rather than describing anything.
The octets arrive as a stream the caller owns, and are read once. Nothing here seeks, so a forward-only stream over a stored part is what this expects; an attachment larger than one request may send is refused after the ceiling is reached rather than after the whole of it is in memory.
Methods
- DescribeAsync(string, Stream, CancellationToken)
Describes what one image attachment shows.