-
-
Notifications
You must be signed in to change notification settings - Fork 13.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Blackbox stream #2623
Comments
It seems to me that a different approach is needed here than just catching the tag. Yes, for simple code where the response comes to the console, you can remove it, but for different bots, sites, etc., it is better to design a similar block. I suppose it is better to make it a function. Personally, in my bot, I implemented it like this:
Yes, I catch the tag myself because at the moment g4f does not process this tag. But still, this approach seems better to me. If you have any ideas on how this can be implemented for g4f in general, then it is better to write here before the topic is closed. |
Hey @phoen1x-dev, @TheFirstNoob, we should do it in the Reasoning Response Type so the UI can read it. We can still print those tags in the /chat/completions API. HuggingChat's reasoning is better, plus it shows steps. |
I chose this option of code for the Telegram bot with data streaming:
|
I ask to return the data stream for the provider Blackbox. I changed part of your code below, I don't know how correct it turned out...
<think>
— this is for the deepseek-r1 model.The text was updated successfully, but these errors were encountered: