whispercpp icon indicating copy to clipboard operation
whispercpp copied to clipboard

feat: async streaming APIs

Open aarnphm opened this issue 2 years ago • 4 comments
trafficstars

Feature request

Currently, stream_transcribe is blocking, which should be async instead.

Motivation

No response

Other

No response

aarnphm avatar Mar 07 '23 00:03 aarnphm

Would it be possible to implement this so realtime data can be sent from any source (e.g. websockets, reading large file, etc...)

eschmidbauer avatar Mar 11 '23 17:03 eschmidbauer

yeah ran into this as well -

from what i'm able to tell this PR introduced streaming: https://github.com/aarnphm/whispercpp/pull/22

seems like this PR changed self._transcript from a generator to a list / iterator: https://github.com/aarnphm/whispercpp/pull/66... i haven't tried but perhaps reverting the commit back to a generator would get us back into a working state?

definitely eagerly awaiting this change! would love to stream asynchronously straight into an LLM or something. thanks for what seems like an awesome library!

Stonelinks avatar Apr 13 '23 05:04 Stonelinks

I haven't had the bandwidth yet. #22 is pretty experimental. What I want to support eventually is SSE (or eventually websocket)

aarnphm avatar Apr 13 '23 05:04 aarnphm

Would it be possible to implement this so realtime data can be sent from any source (e.g. websockets, reading large file, etc...)

glad to see to support from websockets source

libratiger avatar May 31 '23 08:05 libratiger