MichielvanBeers / Flow.Launcher.Plugin.ChatGPT

MIT License
45 stars 7 forks source link

[FEATURE REQUEST]: Integrate BingChat, using Sydney.py #27

Closed emkay5771 closed 2 months ago

emkay5771 commented 1 year ago

Found this python library, and was wondering if it would be possible to integrate it. Would be happy to take a crack at it if the dev is okay with me forking the project.

Python library: https://github.com/vsakkas/sydney.py

MichielvanBeers commented 1 year ago

Hi @emkay5771! That looks very interesting, I've put it on my list for this weekend to take a look 👀! Thanks for sharing.

I would suggest creating a separate plugin for this if and when it will be incorporated though. This plugin focuses mainly on ChatGPT and the use of your own API keys, allowing for more privacy. I'm also planning to add support for the ChatGPT plugins when I get access to them.

However, if the library you have shared works well and I have some time on my calendar, I would definitely be up for creating a Plugin like that or supporting you in creating one?

emkay5771 commented 1 year ago

Re: the privacy aspect, the Sydney API, based on my cursory glancing, appears to use your personal cookie (retrieved by the user from Developer Settings) to access the chatbot, which should be able to be set in Flow Settings.

Let me know when you get the chance to take a look into it, and if you'd like, I can either try to do it, or more than happy to assist you where needed.

MichielvanBeers commented 1 year ago

So I've looked at the code of Sydney.py. It seems to use a WebSocket connection with BingChat to run the conversation. If we would want to make use of this I think the best way to go would be to set up a single connection, send and receive the prompts and then close it again. Basically like a regular API call.

I'm interested in seeing the possibilities but also have limited availability in the upcoming period. So if you are eager to get started, it might be best to give it a shot yourself. Of course, I can share some of the learnings I have with creating this plugin to help you get started. Otherwise, I can pick it up later. Let me know what you prefer!

MichielvanBeers commented 2 months ago

Closing this issue since I currently unfortunately don't have time to pick this up. Feel free to create a PR to add the functionality. Thank you for your suggestion!