monarchwadia / ragged

33 stars 4 forks source link

Remove rxjs and openai as peer dependencies, in order to turn Ragged into a 0-dependency library #9

Closed monarchwadia closed 3 months ago

monarchwadia commented 4 months ago

Currently, the Subject class from rxjs is being imported and extended inside the RaggedSubject class. It's being used in a few different places to handle streaming event subscriptions.

We need to remove the rxjs dependency without breaking the current interface. This will eliminate rxjs as a dependency. rxjs currently adds about 10kb to the build.

openai also needs to be removed, and we can just do straight API calls... although this is admittedly a bit trickier. openai adds about 40-50kb to the build.

Doing this will make Ragged a 0-dependency library, which is very good for many reasons.

monarchwadia commented 3 months ago

This is done.