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

Subissue: Show icons & descriptions in chat commands menu #175

Closed
dlqqq opened this issue Feb 17, 2025 · 1 comment · Fixed by #185
Closed

Subissue: Show icons & descriptions in chat commands menu #175

dlqqq opened this issue Feb 17, 2025 · 1 comment · Fixed by #185
Assignees
Labels

Comments

@dlqqq
Copy link
Member

dlqqq commented Feb 17, 2025

Problem

The new chat commands menu needs to show icons & descriptions. The ChatCommand type will probably need updates accordingly.

Proposed Solution

Update the UI to show icons & descriptions.

Additional context

None.

@dlqqq dlqqq added the enhancement New feature or request label Feb 17, 2025
@dlqqq dlqqq moved this to Todo in Jupyter AI Feb 17, 2025
@dlqqq dlqqq added this to Jupyter AI Feb 17, 2025
@dlqqq dlqqq moved this from Active to In Progress in Jupyter AI Feb 20, 2025
@dlqqq
Copy link
Member Author

dlqqq commented Feb 20, 2025

@keerthi-swarna Please look at this issue next, since I think it would be great for you to contribute to Jupyter AI v3. You'll need to create a new Conda environment, clone this repo, and run jlpm dev-install.

Context:

  • Here is the PR which implemented the chat commands: Define a new framework for chat commands #161. It would be helpful to review this to understand how chat commands work in Jupyter Chat.
  • The ChatCommand type defines the structure of each chat command object.
  • Right now, Jupyter Chat only has one command provider, namely EmojiCommandProvider in emoji.ts. Emoji commands are triggered by typing a colon :.

Recommended steps:

  • In the chat commands menu, show the command name, with the optional description to the right in gray.
  • Show the icon on the left of the command name. The type of icon should be changed to LabIcon | string. You can then render each chat command icon with: typeof command.icon === 'string' ? command.icon : <command.icon.react />.
    • The LabIcon class is custom to JupyterLab. Basically, LabIcon.react provides a React component that can be rendered as an element.

This is how the chat commands menu looked in Jupyter AI 2.x. Use this as a reference:

Image

@keerthi-swarna keerthi-swarna self-assigned this Feb 21, 2025
@dlqqq dlqqq moved this from In Progress to Needs Review in Jupyter AI Feb 24, 2025
@dlqqq dlqqq moved this from Needs Review to In Review in Jupyter AI Feb 24, 2025
@dlqqq dlqqq moved this from In Review to Needs Review in Jupyter AI Feb 25, 2025
@github-project-automation github-project-automation bot moved this from Needs Review to Done in Jupyter AI Feb 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants