AndraxDev / speak-gpt

Your personal voice assistant based on OpenAI ChatGPT.
https://play.google.com/store/apps/details?id=org.teslasoft.assistant
Apache License 2.0
290 stars 59 forks source link

Feature Request: share button to send as text #122

Closed thiswillbeyourgithub closed 5 months ago

thiswillbeyourgithub commented 6 months ago

Hi,

I think it would be nice to have a way to share a chat as text, or send copy multiple message.

An idea could be to add the universal "android share icon" button at the top of the chat, and clicking on it would allow to either export the chat (which is currently implemented) but also "copy" the chat in text format.

By that I mean output something like this into the clipboard:

System: [my system prompt]
User: [My prompt]
Assistant: [Answer]
etc

Currently it is not possible to easily send a friend more than 1 chat message at a time from speakgpt : to send 1 we can currently click on "copy" of that message but we can't do that for more than 1.

Alternatively, the UI could be altered like the following :

  1. use only the universal "three dot" icon in the top right corner of a message instead of "copy" and "edit"
  2. the three dots would open the pop up "Edit message" that already exists but with two additional buttons : "copy text" and "select"
  3. Clicking on "copy text" would copy the message's text to clipboard, as clicking on the current "copy" button. Images would be replaced by ![](image) or something.
  4. clicking on "select" would go back to the individual chat window with a bulk selector to select multiple messages of the chat, a bit like in regular messaging apps, or like the "bulk" management of chats in the first window of SpeakGPT. After selecting, clicking on a "copy texts" button at the top of the UI would save the message in the format suggested above.

I think the second suggestion is better because some user would not be interested in copying the system prompt.

AndraxDev commented 5 months ago

An idea could be to add the universal "android share icon" button at the top of the chat, and clicking on it would allow to either export the chat (which is currently implemented) but also "copy" the chat in text format.

Share button will be enough. Android share screen already allows user to copy shared text.

Alternatively, the UI could be altered like the following :

  1. use only the universal "three dot" icon in the top right corner of a message instead of "copy" and "edit"
  2. the three dots would open the pop up "Edit message" that already exists but with two additional buttons : "copy text" and "select"

This will not be added:

Clicking on "copy text" would copy the message's text to clipboard, as clicking on the current "copy" button. Images would be replaced by or something.

Based on the SpeakGPT logic it is impossible (make no sense) todo that because other apps can not access images inside SpeakGPT. It will be possible to copy image into clipboard, but only one image with no text.

About sending multiple messages: It's only your ideas but not actual user needs. If you really need this, please go to the official OpenAI Playground. I will not implement this feature as it is unnecessary because you can use long prompt instead. So why you need to send multiple messages? Is this a feature of regular chatting apps? (I don't see this in Telegram/Discord/Whatsapp/etc)

Currently it is not possible to easily send a friend more than 1 chat message at a time from speakgpt : to send 1 we can currently click on "copy" of that message but we can't do that for more than 1.

I will implement this feature but nor I nor my friends shares multiple messages. Usually we share only one message - output of the assistant, but you want SpeakGPT be a spaceship with tonns of features. But I want to limit you and emphasize that SpeakGPT is already better that tonns of paid shit on the Google Play. At least SpeakGPT is customizable, open-source and production.

thiswillbeyourgithub commented 5 months ago

Hi!

You are not a person who decides how UI will look

I certainly didn't mean that I was!! Merely contributing thoughts. My apologies if that didn't come across.

Android dialog supports only 3 buttons: positive, negative and neutral. For better accessibility button actions should be the same: negative - cancel, positive - confirm and neutral - action.

Oh I see. Thanks a lot for the explanation!

About sending multiple messages: It's only your ideas but not actual user needs. If you really need this, please go to the official OpenAI Playground. I will not implement this feature as it is unnecessary because you can use long prompt instead.

I use LLMs a lot so I cannot affford to lose time (and tokens!) reading the very long and repetitive rambling of GPT-4o when the information I want is a yes/no question, or a single sentence would suffice, etc. That's why I set my system prompt to be very concise, and genuinely find it surprising that not more people get tired of the very long answers from LLM. Moreover, if the messages are short it's easier for the LLM, otherwise the large context size make it struggle to keep track of what's going on.

So why you need to send multiple messages? I will implement this feature but nor I nor my friends shares multiple messages. Usually we share only one message - output of the assistant,

I find this surprising. I very often suffer from this lack of "multi select" so here are a few situations to illustrate:

  1. I gain a lot of knowledge from LLMs, but as there is no full text search (#64) I can't reliably find an information from old chats. So I usually store the most important bits in either Logseq or anki. But given the prevalence of hallucinations I find of utmost importance to keep a record of the chat. Ideally, I would simply copy and paste the message and that's it. But right now what I end up doing is exporting to json, then sending to my computer, then parsing with python to get just the messages, then copy and paste. It's almost quicker than just copying and pasting 10 messages from SpeakGPT. But I can do it for multiple chats in parallel.
  2. When I learn the answer to something and I know a friend would benefit from it, I can't send just the last message : the friend would not know the question. And if you think that I should just use a less concise system prompt then I disagree, I am dealing with complex knowledge and 5 concise technical messages are readable, but I can't send 5 300 words essays from the LLM to my friends, it would be unbearably verbose for technical stuff.
  3. When I created a chat, talked a bit with the LLM, then would like to branch out the chat. This happens very regularly when studying : I arrive at some knowledge where I could either go deeper on one subject or another. I filtered out the idea to create an issue for implementing that kind of branching, but if I could just select and copy multiple message I could very simply manually branch out. This way I could go deeper on both subjects. And that's not something that I can avoid by rephrasing, my chats are dense as f**** and having to recreate the chat with all the technical knowledge of the previous messages is really not acceptable. Contnuing the chat until I'm done with the two branch in a single chat is not feasible too because even GPT4o struggles with long technical chats.

but you want SpeakGPT be a spaceship with tonns of features. But I want to limit you and emphasize that SpeakGPT is already better that tonns of paid shit on the Google Play. At least SpeakGPT is customizable, open-source and production.

I agree with you that SpeakGPT is great for those reasons, and I know I like spaceships software, and I am filtering my ideas before opening suggestion but I really think this is genuinely useful, and can imagine other people finding it useful too!

In any case I am fully aware of how vastly superior SpeakGPT is compared to most alternatives :smile:

Have a nice day and thanks again for this!

AndraxDev commented 5 months ago

Some of your features has been released in SpeakGPT 4.10

![WARNING]

Please note that I had changed about half of the code of the app (completely rewritten chat and assistant window), changed thousands lines of code to make SpeakGPT support functionality requested. And I expect my work can be paid so I not spend hours of the work for free. Thanks you for understanding!