All skills
marimo-team avatar

/jupyter-to-marimo

@6454470
by marimomarimo-team/skills173 stars
15

Convert a Jupyter notebook (.ipynb) to a marimo notebook (.py).

Use this Skill: https://skilld.dev/gh/marimo-team/skills/jupyter-to-marimo

This session only. Nothing lands on disk.

referenceslatex.md

≈436 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Porting LaTeX from Jupyter to marimo

Jupyter uses MathJax. marimo uses KaTeX (faster, slightly narrower coverage, silent errors).

Use raw strings

LaTeX lives in Python strings in marimo, so use r"..." to preserve backslashes:

mo.md(r"$\frac{1}{2}$")   # correct
mo.md("$\frac{1}{2}$")    # wrong — \f is a form-feed character

Jupyter (MathJax) → marimo (KaTeX)

Category Jupyter (MathJax) marimo (KaTeX)
Text \mbox, \bbox \text{}
Text style \textsc, \textsl \text{}
Environments \begin{eqnarray} \begin{align}
\begin{multline} \begin{gather}
References \label, \eqref, \ref \tag{} for manual numbering
Arrays \cline, \multicolumn, \hfill, \vline not supported
Macros \DeclareMathOperator \operatorname{} inline
\newenvironment not supported
Spacing \mspace, \setlength, \strut, \rotatebox not supported
Conditionals \if, \else, \fi, \ifx not supported

These DO work in KaTeX (despite outdated claims): \newcommand, \def, \hbox, \hskip, \cal, \pmb, \begin{equation}, \begin{split}, \operatorname*.

Migration checklist

  1. Find-replace \mbox{ → \text{
  2. Use raw strings (r"...")
  3. Replace \begin{eqnarray} → \begin{align}
  4. Replace \DeclareMathOperator → \operatorname{}
  5. Remove \label/\eqref → use \tag{} if needed
  6. Visually verify — KaTeX fails silently

References

Source: SKILL.md on GitHub

No alerts17d5 checks · Risk SAFE
  • Gen Agent Trust Hub17d

    This skill provides a comprehensive guide for converting Jupyter notebooks (.ipynb) to marimo notebooks (.py). It outlines a conversion workflow using the 'marimo' CLI tool, provides mapping tables for LaTeX and UI widgets, and includes best practices for security such as secret management and output validation.

  • Socket17d

    No alerts

  • Snyk17d

    Risk: LOW · No issues

  • Runlayer7mo

    1/1 file flagged

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at 6454470. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 days ago.

Steadyupdated last month

README badge

README badge for marimo-team/skills

Converts Jupyter notebooks to marimo notebooks using the `marimo convert` CLI command, then validates and cleans up the output by removing Jupyter artifacts and ensuring compatibility with marimo's cell rendering model. Handles ipywidgets-to-marimo widget migration, LaTeX syntax conversion, and environment variable configuration.

Generated from the current SKILL.md.

Does this skill handle ipywidgets conversion?
The skill includes a reference mapping ipywidgets to marimo equivalents with patterns for callbacks and linking, but you must manually apply those conversions after running the CLI convert command.
What happens to Jupyter magic commands and display() calls?
The marimo converter may leave these artifacts in place; you need to manually remove or adapt them during the cleanup step, as they don't apply in marimo notebooks.
Do I need to install marimo separately?
No. The skill uses `uvx marimo convert` and `uvx marimo check`, which run marimo without a local install.
Will the converter catch all missing package dependencies?
No. The converter may miss some required packages in the metadata block, so you must review and update the script's package list after conversion.
How does this skill handle LaTeX in notebooks?
The skill provides a reference guide for converting MathJax syntax to KaTeX, which marimo uses, but conversion must be done manually.

Generated from the current SKILL.md. These answers refresh after source changes.