Посмотреть вложение 46377
This add-on provides helper functions for working with ChatGPT.
It allows you to set an API key for add-ons that work with ChatGPT and avoid loading duplicate dependencies.
Developer usage guide
Get the OpenAI API key
Get OpenAI APIPHP:$apiKey = \XF::options()->bsChatGptApiKey;
Get reply from ChatGPTPHP:/** \Orhanerday\OpenAi\OpenAi $api */ $api = \XF::app()->container('chatGPT');
PHP:use...
The group of settings has been renamed in accordance with the name of the add-on
New method removeMessageDuplicates in message repo
New method fetchMessagesFromConversation in message repo
Now \BS\ChatGPTBots\Response::getReplyWithLogErrors accept $throwExceptions argument to throw exceptions on error instead of returning default reply
Now the prepareContent method in message also converts mentions into hits
Stream replies support (Will be updated in dev guide later)
Message repo: Ability to fetch comments from profile post
- When streaming the bot's response, characters such as "0" could be missed.
Support for function calling
Fix: Backward compatibility