Content pfp
Content
@
0 reply
0 recast
0 reaction

 stringtheory pfp
stringtheory
@stringtheory69
I'm building a React Native app that streams text using ChatGPT and SSE. I have one big problem though - when i move the app to the background the stream will often disconnect. Any solutions? I know it's possible because in chatgpt app it works fine. Thanks.
1 reply
0 recast
4 reactions

dylan pfp
dylan
@dylsteck.eth
haven't used this(only saw demo videos) but maybe it helps and has better stream connection https://github.com/dabit3/react-native-ai
1 reply
0 recast
0 reaction

Thiago Brezinski pfp
Thiago Brezinski
@thiagobrez
Yeah react-native-ai uses react-native-sse (which even has a section dedicated to ChatGPT) https://github.com/binaryminds/react-native-sse?tab=readme-ov-file#-usage-with-chatgpt You probably need to pair this with background tasks Maybe https://docs.expo.dev/versions/latest/sdk/background-fetch/ if you're using Expo
1 reply
0 recast
0 reaction

dylan pfp
dylan
@dylsteck.eth
Nice finds!!
0 reply
0 recast
1 reaction