Visecy / Karuha

A simple Tinode chatbot framework.
Apache License 2.0
27 stars 2 forks source link

Add more examples, please #23

Open shax-xxx opened 4 days ago

shax-xxx commented 4 days ago

Hi. It would be great if you could add an example of extracting data from incoming audio messages. This may be useful for further translation of them into text and sending them to GPT similar services. Also could you add very simple examples of extracting data from messages without interaction (something like @on_message decorator).

Ovizro commented 4 days ago

Hello,

At present, karuha's audio processing and attachment parts are indeed not perfect enough. The audio upload part mainly involves the preview generation of audio files, which may be supported in the next version. As for the download of audio and other attachments, the 0.2.2 version added the corresponding underlying interface, but it has not yet provided support at the session level. You can consider using bot.download as a temporary solution.

As for the problem of non-command message processing, you can use the on_rule decorator, see the examples of tino and aigc.