Azure / azure-functions-openai-extension

An extension that adds support for Azure OpenAI/ OpenAI bindings in Azure Functions for LLM (GPT-3.5-Turbo, GPT-4, etc)
MIT License
73 stars 26 forks source link

Add support and samples for URL based input types for Embeddings Binding #22

Closed paulyuk closed 4 months ago

paulyuk commented 7 months ago

I noticed in the recent Nuget samples we have the user write their own record for embeddings requests, and it only handles this one input type:

public record EmbeddingsRequest(string FilePath);

In prior samples we handled 2 of the 3 cases ; - )

public record EmbeddingsRequest(string RawText, string FilePath);

My opinion is we should probably give the user a standard type for embedding request and handle all 3 of the cases: RawText, FilePath, and Url (cool new one!). But at least have sample code that is aware of each case like i have above pls.