with t3 what do you use to stream open ai chat gpt responses?
Since tRPC currently does not support it.
Thanks
2 Replies
Custom express endpoint?
Web socket with custom Chanel per request?
Thanks
since tRPC dones't support it you could create a custom route for it using a
route.ts
file and can follow these docs on how to do it https://nextjs.org/docs/app/building-your-application/routing/route-handlers#streamingRouting: Route Handlers
Create custom request handlers for a given route using the Web's Request and Response APIs.