Skip to content
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

Enable chat editing #339

Open
vitalwarley opened this issue Aug 12, 2023 · 3 comments
Open

Enable chat editing #339

vitalwarley opened this issue Aug 12, 2023 · 3 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@vitalwarley
Copy link

Problem

It is not good to clear the chat or continue to prompt in a somewhat "dirty" chat history, both from a cost and quality perspective.

Proposed Solution

In that vein, I would like to edit any message in the chat history. A simple edit button that enables me to alter my previous prompt should be enough.

Additional context

Just like the ChatGPT default UI, I think.


Thanks for the project!

@vitalwarley vitalwarley added the enhancement New feature or request label Aug 12, 2023
@welcome
Copy link

welcome bot commented Aug 12, 2023

Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! 🤗

If you haven't done so already, check out Jupyter's Code of Conduct. Also, please try to follow the issue template as it helps other other community members to contribute more effectively.
welcome
You can meet the other Jovyans by joining our Discourse forum. There is also an intro thread there where you can stop by and say Hi! 👋

Welcome to the Jupyter community! 🎉

@krassowski
Copy link
Member

Folks, what do you think would make better UX here?

a) Menu

Move existing delete icon into menu and add edit option there

  • times are visually aligned
  • options are less discoverable (different option are available for human/agent messages)

image

b) Both buttons together

image

  • times are misaligned
  • options are discoverable
  • visually overwhelming

c) Show edit button left to the time on hover only

Hover state:

image

  • times are aligned
  • option are more discoverable than in (a) but less than in (b)
  • less visually overwhelming than (b) because by default the edit icon is not shown (until users hovers over the message)

@dlqqq
Copy link
Member

dlqqq commented Oct 10, 2024

@krassowski Thanks for reviving this issue and looking into how this feature can be implemented today! I'm dropping by to mention that we do have plans with Quantstack to simplify the implementation of chat messaging by migrating to a new jupyter-chat dependency, which uses a backend that represents the chat state as a Yjs CRDT. This will allow for messages to be edited more easily than with our existing backend, where message objects are mostly treated as immutable. The new jupyter-chat package will also allow users to have multiple chats. Here is the WIP tracking issue: #862

The work on this is still ongoing and very early-stage, but we are planning to migrate Jupyter AI to jupyter-chat within the next 6 months. I still need time to review the code in jupyter-chat, prepare a high-level design, document the roadmap publicly in a pinned issue, as well as participate in the engineering effort required by the migration.

If you plan on opening a PR for this, I would be happy to review it. My only additional request is that a smaller PR (with fewer changed lines of code) would be preferred over large ones, especially for features that are already planned as being part of the migration. Making large code changes could make the migration towards jupyter-chat more challenging.

Folks, what do you think would make better UX here?

I personally recommend option a). I like the visual symmetry it provides, and I'm OK with hiding the "delete exchange" button in a menu. I don't imagine that editing/deleting exchanges will be very common user actions, so keeping them nested within a menu seems sensible.

@dlqqq dlqqq modified the milestones: Future, v3.0.0 Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants