microsoft / azure-openai-service-proxy

The Azure AI proxy service facilitates easy access to Azure AI resources for workshops and hackathons. It offers a Playground-like interface and supports Azure AI SDKs. Access is granted through a time-limited API key and endpoint.
https://microsoft.github.io/azure-openai-service-proxy/
MIT License
58 stars 34 forks source link

Forward response streams from ProxyService #312

Open aaronpowell opened 2 months ago

aaronpowell commented 2 months ago

The ProxyService will read the HTTP response from the backend Azure resource as a string, and then turns that into a new response stream from our route handler.

To save memory, the stream should probably just be forwarded, as this would mean that we save memory overhead of unpacking and repacking streams, which would be particularly important for services that provide large response payloads.