jupyter-ai
jupyter-ai copied to clipboard
Remove hard-coded default list of model aliases in magic commands
Problem
A fresh installation of Jupyter AI has the following aliases predefined. Several of these are obsolete or little-used, and by pre-defining these aliases, we developers seem to be endorsing these models.
| Name | Target |
|---|---|
gpt2 |
huggingface_hub:gpt2 |
gpt3 |
openai:davinci-002 |
chatgpt |
openai-chat:gpt-3.5-turbo |
gpt4 |
openai-chat:gpt-4 |
ernie-bot |
qianfan:ERNIE-Bot |
ernie-bot-4 |
qianfan:ERNIE-Bot-4 |
titan |
bedrock:amazon.titan-tg1-large |
Proposed Solution
Remove these aliases from the default Jupyter AI configuration. This may be a breaking change, if users rely on these aliases.
Additional context
Users could not add custom model aliases when Jupyter AI first launched (#45) but this was added with #136, in June 2023.
To avoid breaking changes with deleting these aliases, I think a nice feature would be for users to specify aliases in the startup configuration.
This would allow users to specify these aliases (amongst others they might always use) in the configuration instead of running the %ai register command in their notebooks. And those aliases will be available without the need for re-registering them in a notebook.
It is possible to add traitlet configuration to magics, in IPython core this is done for %store magic here and then user just sets c.StoreMagics.autorestore = True in their config file. I think these aliases should be moved to a Dict traitlet.