marimo-pair
Adapted from
marimo-team/marimo-pairat commitde98ee4e268df1b44fa777f360aa58e241a7a635(Apache-2.0).
marimo is a reactive Python runtime for building reproducible Python programs
(marimo notebooks). Cells are connected by the variables they define and
reference. Running a cell re-executes dependents in dataflow order. The active
runtime holds the kernel namespace, cell state, and dataflow graph. The
notebook (.py file) is the artifact the kernel writes from that state while a
session is running.
A user interacts with the same runtime via a notebook UI with cells, outputs, and widgets.
WARNING. The active runtime is the source of truth. During a session, you
SHOULD NOT modify the associated .py file directly. File edits WILL NOT reach
the active kernel or user, and the kernel may overwrite them on save. Use
marimo._code_mode (cm) for notebook changes. Reading disk is fine, but
prefer ctx.cells[...].code for current cell code.