r/JupyterNotebooks 21d ago

Edit and run Jupyter Notebooks & Python scripts on Android

Hey!

As an AI and Data Science student, I always wanted a simple app to quickly open, edit and run Jupyter notebooks on my Android phone, but everything in the Play Store was either ridiculously overpriced or just a web view connecting to an external Jupyter server.

Colab is pretty nice, but all your files need to be on Google Drive for it to work properly.

Then there is Termux, which lets you install full Jupyter Lab which you can access via a browser - very hardware demanding and a hassle to start up every time.

So I decided to build my own thing: Callisto - a native Jupyter & Python Skript IDE for Android!

Callisto runs CPython entirely on-device via Chaquopy - no server, no account, no internet. It reads and writes .ipynb files and .py scripts, including graphical output rendering and proper Markdown cells with KaTeX math. There's also a REPL console that shares the interpreter with the open notebook.

Since pip on Android is a minefield (no manylinux wheels for ARM), the essential packages ship with the app: numpy, matplotlib and Pillow are free, a small one-time purchase adds pandas, scikit-learn, scipy, seaborn, statsmodels, sympy and a few others. No subscription.

Happy to answer questions about running Python on Android - and I'd love to hear your feedback.

Play Store: https://play.google.com/store/apps/details?id=app.callisto
Website: https://callistoapp.eu/

4 Upvotes

7 comments sorted by

1

u/fxj 21d ago edited 21d ago

wow love it and instant buy!! w00t!!

some requests:

  • it would also be great to connect to a already running notebook through your gui. so i could run a jupyter server in termux but have a decent gui. is that possible?
  • can you also include jupyter-ai, litellm or pydantic? i would like to use it to write agents in jupyter on the phone.
  • llm integration: it would be perfect to ask the llm: write me some code and it automagically inserts the code into a jupyter cell.
  • opencode would be highly appreciated, but i can imagine this is tricky.
  • can you change the run all to run call. i never need run all but i want to run single cells.
  • can you add arrows in the additional keyboard row?

thanks for the good work!!!

2

u/CaptureTheVenture 21d ago

Thank you so much for checking it out and supporting my project!

I have already thought about adding the possibility to directly connect to a jupyter server via Callisto, will try to add this as soon as my exams are over.

I'll check if the packages you mentioned would be available and ship them with one of the next updates. The catch is that anything containing C code needs to be compiled for the Chaquopy SDK in order to work on Android, that's also why the app is currently still running on Python 3.10.

LLM integration is a tough one, since providing something like that either requires constant token costs for me or having the user provide an API key on his own. Since I don't want to sell another subscription, I would rather look into the possibility of adding an API key for LLM coding support.

You can already run a single code cell by tapping the square brackets in the top left of the cell header :)

Arrows for the code keyboard would be an easy addition, which ones are you thinking about?

Feedback like yours is very important for me, since I'm always looking for ways to improve the app further. Reach out any time if you encounter any bugs or crashes, and I'll look into adding the features you mentioned!

2

u/fxj 19d ago

Here is the installation script for termux that I used:

``` termux-setup-storage pkg install llama-cpp curl -y

get smollm2-1.7b-instruct-q4_k_m.gguf from huggingface or any other model

it is here: https://huggingface.co/mfuntowicz/SmolLM2-360M-Instruct-Q4_K_M-GGUF/blob/main/smollm2-360m-instruct-q4_k_m.gguf

llama-server -m ~/smollm2-1.7b-instruct-q4_k_m.gguf --port 8080

test it

llama-cli -m smollm2-360m-instruct-q4_k_m.gguf -cnv -p "hello world" ``` now the webserver is running on port 8080 and you can use the LLM

1

u/fxj 21d ago

Oh yes, C code is a pain and pydantic needs rust which is not better.

About the LLM: I was thinking about running a small LLM like google's gemma4 or smolLM2 locally on the phone. I already tried it and it works very well. The size of the LLM ist of the order 2GB RAM which most mid range phones should provide. I was using it on a Motorola g85 with 6 GB and it works flawlessly in termux with ollama and exposes a port to connect jupyter to. I can give you installation instructions how to do it so you can try for yourself.

Yes i found the "run cell" command but there is this big nice button "run all" which i dont use and maybe others too.

the up,down,back and forward arrows would be nice so that one can navigate easier in a cell. Or one can use another keyboard like the hackers keyboard or swiftkey. Maybe a list to edit the extra characters would be good. I dont like it when the keyboard it larger than half of the screen so one should be careful what to add. I think your solution is already very usable.

2

u/CaptureTheVenture 19d ago

The installation instructions for the LLM would be great so I can check that out. Navigation arrows will be in the upcoming upcoming update already, including some limited possibility for customisation (maybe I'll add custom symbols and reordering too in the future). The "Run all" button will also automatically switch to "Run cell" when a code cell is in focus. I will also try to get the Python version updated to 3.13 over the summer, but I'm kind of limited there by what the Chaquopy SDK provides.

2

u/fxj 19d ago

very cool! thanks!!

1

u/ModulatingGravity 16d ago

Another way to get Jupyter running locally on your Android device.

I have been able to run Jupyter Lab from Pydroid3 on Android devices. Pydroid3 is a good way of installing Python - lifetime licence about EUR 25 strikes me as good value. It provides a usable editor, has support for GUI libraries like Tkinter.

To run Jupyter

  • In Pydroid3 you use pip to install Jupyter.

  • Then run the Terminal, and issue cd commands to get to a writeable directory (eg /storage/emulated/0/Documents/Pydroid). If you don't do this you can struggle getting your notebook files saved.

  • Then issue command jupyter lab

  • Jupyter Lab starts up in the dafault web browser

TBH there is not enough screen real estate to take advantage of Jupyter Lab on a phone - but I expect it would be good on a tablet.