jupyter-ai icon indicating copy to clipboard operation
jupyter-ai copied to clipboard

Contributor documentation: Add guidance on contributing a new provider

Open dlqqq opened this issue 1 year ago • 1 comments
trafficstars

Problem

Open source contributors are opening PRs to add new providers to Jupyter AI. This is extremely helpful to everybody, and we greatly appreciate others taking the time to write and test these. However, contributors have had difficulty doing so due to subtle and mostly undocumented details of how the Python source works.

The contributor documentation should have a new section that:

  1. Describes how to contribute a new provider, end-to-end,
  2. Indicates that contributors need to run jlpm dev-install again to make new providers show in the UI after declaring the entry point in pyproject.toml, and
  3. Indicates that contributors should define providers in separate files to keep third-party dependencies optional.

dlqqq avatar Mar 05 '24 23:03 dlqqq

Just wanted to point out that the installation instruction with nodejs=20 does not work on my linux machine. Removing the version pin installs nodejs v18.18.2, which works fine with jupyter-ai. The reason is that the latest version of nodejs on the anaconda channel is v18.18.2, while the latest version on the conda-forge channel is v0.20.9. So we either have to remove the nodejs version pin or force it to install from the conda-forge channel.

conda create -n jupyter-ai python=3.11 nodejs=20

image

conda create -n jupyter-ai python=3.11 nodejs

image

conda create -n jupyter-ai python=3.11 conda-forge::nodejs

image

giswqs avatar Mar 06 '24 02:03 giswqs