Example gallery¶
Every notebook under examples/ in the repo demonstrates a specific
Strata capability. A card's picture is what that notebook makes, taken
from a real run. Click through for the notebook as it ran: every cell
with its outputs, without cloning the repo.
To run the examples, start the server on the repo's examples/ directory
from a clone:
Every example then appears under Open Notebook on the Strata home page:
open one, click Run All, edit a cell and watch only what depends on it
run again. To keep the examples apart from your own work, copy the one you
want under your storage root instead:
cp -R examples/iris_classification ~/.strata/notebooks/.
Walkthroughs: start here¶
-
caching: a two-minute tutorial on what the cache saves and what an edit runs again.
strata tutorial cachingopens a copy. -
keeling_curve: NOAA's Mauna Loa record, downloaded with
# @fetch, the curve and its yearly cycle, then a published figure whose page shows the code and NOAA's bytes behind it.strata tutorial keeling_curveopens a copy. -
iris_classification: end-to-end ML in seven cells (load, split, train, evaluate, plot). The canonical multi-cell DAG with caching.
-
pandas_basics: core DataFrame operations fanning out from one dataset, with per-cell unit tests.
-
titanic_ml: feature engineering, then three classifiers trained and the best one evaluated. Closer to a real ML workflow.
-
data_viewer: a DataFrame larger than the inline preview, in the interactive viewer. Page through and sort the full cached artifact.
-
agent_demo: the notebook a coding agent builds live in the
strata agentdemo. The expensive training cell stays cached while only the evaluation runs again.
Variant cells¶
-
model_variants: three classifier variants (logistic regression, random forest, gradient boosting) sharing one DAG slot. Switch tabs and the downstream cells run again; the other variants stay cached.
-
model_variants_sweep: sweep mode. Every variant runs and one downstream cell compares them as a
{variant: value}dict, plus a# @per_variantfan-out.
Prompt cells and AI¶
These call an LLM: set ANTHROPIC_API_KEY or OPENAI_API_KEY in the
notebook's Runtime panel first.
-
review_triage: a prompt cell with
@output_schema, validated against JSON Schema and retried on a bad answer. -
arxiv_classifier: arXiv papers aggregated on a DataFusion worker, embedded on a GPU worker, classified, and summarized by prompt cells. Needs two local workers (
run_local_workers.sh) and an LLM key. -
news_alpha_trader: a secret manager, an AI pricing lookup and a multi-cell DAG over market news. Needs Alpaca keys and an LLM key.
SQL cells¶
The server needs the sql and sql-sqlite extras for this one
(uv tool install "strata-notebook[sql,sql-sqlite]"); the development
environment and the Docker image carry both.
-
sql_orders_report: named connections, bind parameters from a Python cell upstream, and schema-aware caching.
Loops, widgets and library cells¶
-
loop_hill_climb:
# @loopwith carried state and an early-termination predicate. -
widget_playground: a widget cell (slider, number, dropdown) driving a downstream DataFrame and plot, with
# @liverecomputing on every change. -
library_cells:
defandclassshared across cells through the synthetic-module slicing path, and the diagnostic when a helper closes over a runtime value.
Mounts and tables¶
-
s3_mount: a
[[mounts]]entry makes a public S3 prefix a localpathlib.Pathinside the cell. Needs thes3extra. -
each_pipeline:
# @eachover 287 real files from a public bucket, each cached on its own, and# @write_table ... synckeeping a table in a REST catalog in step. Needs Docker and thes3andsqlextras.
Markdown¶
-
markdown_showcase: every markdown rendering path: headings, lists, tables, code blocks, the security guards, and dynamic
Markdown(...)output.
R cells¶
These need R (Rscript on the server's PATH).
-
r_mtcars_analysis: a pure-R notebook:
lm(),aggregate(), and inline ggplot2 and base-graphics plots, withdata.frameand R-only (RDS) handoff between R cells. -
r_lm_vs_sklearn: Python and R in one graph. Fit a model with R's
lm()and compare it with scikit-learn over a cross-language Arrow handoff.































