agentleFS
stevemarksavastevemarksava/superteam/skills/fabric-notebooks/SKILL.md

fabric-notebooks

Skill1 starsChanged 2 months agoMITView on GitHub

Fabric notebooks and Spark — environment libraries, notebookutils, lakehouse read/write, cross-notebook dependencies, scheduling.

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Notebook environment setup: Create a Fabric Environment — pin the Spark runtime version, list required libraries (PyPI or custom wheels), …

    line 18
  2. Very specific:

    notebookutils patterns: Use notebookutils.credentials.getSecret(<vault>, <name>) for Key Vault access — never inline.

    line 20
  3. Very specific:

    Lakehouse read/write: Read: spark.read.format("delta").load("abfss://...") or spark.table("<lakehouse>.<schema>.<table>").

    line 21
  4. Distinctive:

    Every production notebook has an attached Environment — no reliance on workspace defaults

    line 33
  5. Distinctive:

    Every scheduled notebook writes a monitoring row — silent success is as bad as silent failure

    line 35

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

/fabric-notebooks — PySpark Notebooks on Microsoft Fabric

Fabric notebooks are the primary compute surface for Spark-based ETL and analytics on OneLake. This skill lays out environment configuration, notebookutils patterns, lakehouse I/O, and how notebooks depend on and schedule each other cleanly.

When to invoke

  • Atlas or Diesel is building a Fabric ETL pipeline in Python / PySpark
  • A notebook needs to be productionised (scheduled, parameterised, monitored)
  • Environment libraries (custom wheels, pinned versions) need standardising across notebooks
  • Cross-notebook orchestration is required (run notebook B after notebook A)

Steps

  1. Notebook environment setup. Create a Fabric Environment — pin the Spark runtime version, list required libraries (PyPI or custom wheels), set Spark pool size. Attach the environment to notebooks explicitly — never rely on the workspace default in production.
  2. PySpark session config. Set adaptive query execution (spark.sql.adaptive.enabled = true), delta autotune, and Fabric-specific optimisations (V-Order enabled for gold writes). Log the Spark UI link on session start so failures are diagnosable.
  3. notebookutils patterns. Use notebookutils.credentials.getSecret(<vault>, <name>) for Key Vault access — never inline. Use notebookutils.notebook.run(<path>, <timeout>, <params>) to chain notebooks. Use notebookutils.fs for OneLake file operations. Verify SDK method names against current docs at author time.
  4. Lakehouse read/write. Read: spark.read.format("delta").load("abfss://...") or spark.table("<lakehouse>.<schema>.<table>"). Write: df.write.format("delta").mode("overwrite").saveAsTable("...") with overwriteSchema=true only when intentional. Prefer partitioned writes for large tables.
  5. Cross-notebook dependencies. Orchestrate with Fabric Data Pipelines (activity per notebook) rather than deep notebook.run chains — pipelines give retries, monitoring, and DAG visibility. Pass parameters via pipeline activity, not by string interpolation in the notebook.
  6. Schedule. Attach a schedule via Fabric Data Pipeline trigger or notebook schedule. Set alerting on failure (email or Teams webhook). Log run metadata (start, end, row counts) to a monitoring table in the lakehouse.

Deliverable format

  • notebooks/*.ipynb — parameterised, environment-attached notebooks committed to Git
  • environment.yaml — Fabric Environment definition with pinned Spark runtime and libraries
  • Pipeline JSON export defining the DAG and schedule
  • Monitoring table schema (monitoring.runs) for observability

Non-negotiables

  • Secrets always via notebookutils.credentials + Key Vault — never inline, never in cell metadata
  • Every production notebook has an attached Environment — no reliance on workspace defaults
  • Long chains of notebook.run are refactored into Data Pipelines — DAG visibility is not optional
  • Every scheduled notebook writes a monitoring row — silent success is as bad as silent failure

References

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.