llm-jupyter
Run a IPython interpreter in the LLM virtual environment
Installation
Install this plugin in the same environment as LLM.
pipx install llm
llm install llm-jupyter
Usage
IPython
This plugin adds a new ipython command to LLM. This executes IPython in the same virtual environment as LLM itself.
You can use this to check the Python version
llm ipython --version
# Should output '8.20.0' or similar
Or to start a IPython shell. In that shell you can import llm and use it to interact with models:
llm ipython
In [1]: %llm 'Who are you?'
# LLM output will be set as the next input
In [2]: print("I am a Python programmer using Jupyter Notebook.")
https://github.com/lucasrcezimbra/llm-jupyter/assets/7042915/b7f8a9ec-d269-4b24-bac3-a01ad6802032
Notebook
This plugin also adds a new notebook command to LLM. This executes a Jupyter Notebook in the same virtual environment as LLM itself.
llm notebook
%load_ext llm_jupyter.magic
%llm 'Who are you?'
# LLM output will be set as the next input
print("I am a Python programmer using Jupyter Notebook.")
https://github.com/lucasrcezimbra/llm-jupyter/assets/7042915/58c63b2e-3a7b-43f1-b0aa-ab3daf2e9810
Development
To set up this plugin locally, first checkout the code. Then create a new virtual environment:
git clone git@github.com:lucasrcezimbra/llm-jupyter.git
cd llm-jupyter
python -m venv .venv
source .venv/bin/activate
pip install -e .[test]
Now install the dependencies and test dependencies:
llm install -e '.[test]'
To run the tests:
pytest
Metadata
Release files for llm-jupyter 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| llm_jupyter-0.2.0.tar.gz | 8.0 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| llm_jupyter-0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 15.8 kB
Release files / llm_jupyter-0.2.0.tar.gz
| Download URL | llm_jupyter-0.2.0.tar.gz |
|---|---|
| Size | 8.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4ed55370d6b78897497ae35a49c593e07e3f287c2f156b4dbb083604af071418
|
|
BLAKE2b-256 checksum How to use checksums |
072415c601ee08bf8d2717a66ce71de751d01663a10292fee54a8ae90dc792c2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/5.0.0 CPython/3.12.3
|
Release files / llm_jupyter-0.2.0-py3-none-any.whl
| Download URL | llm_jupyter-0.2.0-py3-none-any.whl |
|---|---|
| Size | 7.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
69da11d773fc6214b6c3a10c54c69f4f12b49d04864a7d5df013bd0419489d3e
|
|
BLAKE2b-256 checksum How to use checksums |
b96a41c0ae199850175c25cb11d5bce54a8ff2c12ff9a525eaaedf2e2aa23053
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/5.0.0 CPython/3.12.3
|
Security for llm-jupyter 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.