jupyterlab / jupyter-ai

A generative AI extension for JupyterLab
https://jupyter-ai.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
3.21k stars 324 forks source link

Improvements to user identity #75

Closed ellisonbg closed 1 year ago

ellisonbg commented 1 year ago

When this extension is run by a single user without collaboration model enables in JupyterLab, it is a bit confusing to see the anonymous planet name for yourself. I was thinking of how we can improve this for the user and attempt to use their real name or username. It looks like os.getlogin() can return this information. This would probably be an upstream contribution to JupyterLab itself though, but I think it would really help the user experience for single users.

When this is run in collaboration mode, I think it would be helpful to show the user which user they are in the chat, so instead of showing something like "Anonymous Callisto" show "Anonymous Callisto (me)" for just your username. I think the awareness API of JupyterLab can be to see if the user in the current user.

JasonWeill commented 1 year ago

Related: https://github.com/jupyterlab/jupyterlab/issues/14327

Per discussion about that issue at JupyterLab triage, this may end up getting fixed in jupyter_collaboration if a server component is needed.