sse code should be in the librechat-data-provider package ? #8527
Replies: 3 comments 2 replies
-
I would leave as is, this is done to utilize the SSE package directly. |
Beta Was this translation helpful? Give feedback.
-
Since the SSE package is only consumed within this one file, could I move the SSE consumption into the librechat-data-provider package ? What are your thoughts on the other 2 locations ? My purpose is to be able to mock all network calls from the front end by mocking the librechat-data-provider package because I want to make an adapter to use a different kind of server and database implementation. These three locations stand out as deviations from an otherwise consistent pattern. |
Beta Was this translation helpful? Give feedback.
-
I would also just like to add that this is an extremely clean codebase. The more I poke around, the more it feels really nice to go thru - thank you. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
In this section:
LibreChat/client/src/hooks/SSE/useSSE.ts
Lines 105 to 108 in 4b12ea3
a rare call is made to the server directly, without going thru the librechat-data-provider package.
All other server calls very neatly go thru the librechat-data-provider bar 2:
/api/files/speech/tts
in StreamAudio.tsx${EndpointURLs[endpoint ?? '']}/abort
in useEventHandlers.tsWould you like a pull request to move this code to the librechat-data-provider package ?
Is there some reason these calls were left out of that package ?
Beta Was this translation helpful? Give feedback.
All reactions