Replies: 2 comments 1 reply
-
@jph00 thanks for aplnb! Any thoughts/suggestions? What features would you like to see? |
Beta Was this translation helpful? Give feedback.
-
Oh cool! tbh aplnb is a extremely basic implementation -- I'd love to see an official Dyalog ipython magic to replace it. There are big benefits to using a magic instead of a kernel in many situations. I'd also love to see https://github.com/Dyalog/pynapl get some love again. It's been a long time since anyone at dyalog worked on it, and is currently in a broken state -- but it's critical infrastructure for the vast majority of the world that spends more time in Python than APL (but still loves APL!) |
Beta Was this translation helpful? Give feedback.
-
Dyalog Jupyter Projects
See:
The Dyalog Jupyter Kernel implements a subset of the jupyter protocol, enabling the
creation of APL notebooks. There are several tasks of varying difficulty that can be
undertaken in this project:
A Dyalog version selector
Currently, the kernel will select the "latest" Dyalog it finds installed to talk to. Whilst this is a good default, it would be nice to have the option to run the kernel with a Dyalog version of your choice. In the simplest form, this could be an environment variable that
the kernel checks during start-up. A more sophisticated version might make this selectable from within the JupyterLab interface.
Dyalog Magics
The Dyalog Kernel currently does not implement any of the Jupyter "magics" -- meta commands that don't get executed by the kernel itself, typically interfacing with the operating system, or with Jupyter extensions, "escaping" the Dyalog kernel in this case.
The Jupyter AI extension is an example of what can be done with magic commands. We would like to implement the magics protocol in the Dyalog Kernel, and implement some of the more commonly used magic commands on top of this. Hooking Dyalog up to the Jupyter AI magics would be a great stretch goal for this. There is a floating boundary on this -- the bulk of this will still be a Python job, but depending on how deep you go, you may want to pick up some Dyalog APL to let the backend drive some of the implementation. This is a good project for the Pythonista that has a burgeoning interest in array programming and APL.
Jeremy Howard has implemented Dyalog magics for the Python kernel -- the opposite direction: it makes it possible to execute Dyalog APL commands in a Python notebook.
Dyalog Jupyter Widgets
Jupyter supports "widgets" -- simple in-cell interactive controls, such as sliders, buttons etc. The widget architecture is kernel-agnostic, and any kernel can implement access to such widgets. In this project, we'd like to implement the widget protocol for the Dyalog Jupyter kernel, so that we can show a slider that sets an APL value. This would greatly enhance exploratory programming in a Dyalog APL notebook: hook a slider up to a parameter in a model and see what the effects are without having to actually type and execute cells.
Implementing the widgets protocol needs to be done firstly in Python, to implement the callbacks, and secondly on the APL side to define ways to create the widgets.
EWC integration
EWC is Dyalog's new APL-to-JavaScript "bridge", enabling APL developers to create user interfaces using web technologies. One of the exciting aspects of EWC is that it can serve as a plug-in mechanism for various JavaScript frameworks. For example, EWC has support for ApexCharts, but it should be possible to hook up more complete charting libraries such as D3.js. Charting is a weakness of the Dyalog Jupyter kernel. It is possible, but cumbersome. This project explores the possibility of using EWC within the Jupyter kernel. A good target would be to show how you could leverage ApexCharts in a cell in the notebook, via EWC.
Beta Was this translation helpful? Give feedback.
All reactions