Need advice/support implementing streaming FastAPI application with OpenAI API
Budget: $30 – $250 USD
I have a FastAPI application running on a serverless architecture (Modal) that has a post-endpoint. This endpoint calls the ChatGPT API with streaming. I'm trying to stream the response back to the user using StreamingResponse.
Unfortunately, this isn't working and the entire response is sent once it is completed. I would like someone to help me troubleshoot this who is experienced with FastAPI and perhaps the OpenAI APIs.
I've included the FastAPI app code and a test code file I'm using to test the endpoint.
Unfortunately, this isn't working and the entire response is sent once it is completed. I would like someone to help me troubleshoot this who is experienced with FastAPI and perhaps the OpenAI APIs.
I've included the FastAPI app code and a test code file I'm using to test the endpoint.