Agent skill

Execution Pipeline

by nteract in nteract/nteract

The end-to-end cell execution pipeline from MCP tool call through daemon to kernel and back.

BSD-3-ClauseAuto-check passedDevelopment

Install Execution Pipeline

skills CLI
$ npx skills add nteract/nteract --skill execution-pipeline -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install nteract/nteract execution-pipeline --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/nteract/nteract.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/execution-pipeline .claude/skills/execution-pipeline && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
execution-pipeline
GitHub stars
179
Token cost
~2.7k tokens
SKILL.md length
1,288 words
Files
1
Skills in repo
10
Repo updated
First seen
Licence
BSD-3-Clause

At a glance

The end-to-end cell execution pipeline from MCP tool call through daemon to kernel and back.

  • Works in 5 steps: Causal Precondition (required_heads) → Request Submission → Daemon Queuing → …
  • Debugging execution failures
  • SKILL.md covers The Five Stages, Execution ID Lifecycle, Run-All Flow and Common Failure Modes, plus 1 more section
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Execution Pipeline is an agent skill from nteract/nteract. The end-to-end cell execution pipeline from MCP tool call through daemon to kernel and back. Use when debugging execution failures, understanding output timing, investigating why outputs are missing or stale, or modifying the execute/run-all flow. Covers requiredheads, CellQueued, RuntimeStateDoc polling, output-sync grace, and output resolution.

Its SKILL.md is about 2.7k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering MCP servers. The repository describes itself as: We're back! Now firing notebooks out of a t-shirt gun. The licence is BSD-3-Clause.

When your agent uses it

  • Debugging execution failures
  • Understanding output timing
  • Investigating why outputs are missing
  • Modifying the execute/run-all flow

Example prompts

  • “/execution-pipeline”

Requirements

  • Python 3

Workflow steps

5 steps, taken from the step headings in SKILL.md.

  1. Causal Precondition (required_heads)
  2. Request Submission
  3. Daemon Queuing
  4. Terminal Wait (RuntimeStateDoc Polling)
  5. Output Resolution

What it can do on your machine

Read from SKILL.md and the folder at commit 414222e. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are rust).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Execution Pipeline loads about 2.7k tokens when it runs. Until then it costs about 92 tokens; SKILL.md has 1,288 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~92
When it runs · the whole SKILL.md, loaded when a task matches
~2.7k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from nteract/nteract at commit 414222e, republished under its BSD-3-Clause licence (© nteract). 1,288 words, ~2,735 tokens.

Download SKILL.mdSave it as .claude/skills/execution-pipeline/SKILL.md (or your agent's skills folder).
name
execution-pipeline
description
The end-to-end cell execution pipeline from MCP tool call through daemon to kernel and back. Use when debugging execution failures, understanding output timing, investigating why outputs are missing or stale, or modifying the execute/run-all flow. Covers required_heads, CellQueued, RuntimeStateDoc polling, output-sync grace, and output resolution.

Cell Execution Pipeline

Use this skill when debugging execution-related issues: cells that don't execute, outputs that don't appear, execution that times out, or MCP tools that return empty results. This traces the full path from tool invocation to resolved outputs.

The Five Stages

Stage 1: Causal Precondition (required_heads)

Before sending an execute request, the client captures the current Automerge heads of the notebook document:

rust
let required_heads = handle.current_heads_hex()?;

These heads are attached to the request envelope. The daemon's wait_for_required_heads() defers processing until all listed change hashes exist in its copy of the notebook document (checked via get_change_by_hash, a ChangeGraph containment check).

Why this matters: Without required_heads, the daemon might execute against stale cell source: the client wrote "x = 1" but the daemon hasn't received that sync frame yet, so it executes the old "x = 0".

Timeout: 10 seconds. If heads don't arrive, the daemon returns NotebookResponse::Error with "Timed out waiting for required notebook heads" without processing the request. See wait_for_required_heads() and its caller in crates/runtimed/src/notebook_sync_server/peer_writer.rs.

Frontend optimization: Before capturing heads, the frontend calls flushSync() to push any pending source edits into the sync stream, minimizing the daemon-side wait.

Stage 2: Request Submission

The client sends an ExecuteCell or batch RunAllCells request:

rust
let request = NotebookRequest::ExecuteCell {
    cell_id: cell_id.to_string(),
    execution_id: None,
};
let response = handle.send_request_after_heads(request, required_heads).await;

send_request_after_heads wraps the request in a NotebookRequestEnvelope with the captured heads and sends it through the sync task.

Stage 3: Daemon Queuing

The daemon receives the request, waits for required heads (Stage 1), reads the cell source from its synced notebook document, and queues execution with the kernel:

  1. Daemon reads source from its NotebookDoc (the CRDT, not the .ipynb file)
  2. Creates a unique execution_id
  3. Writes to RuntimeStateDoc: execution entry with status "queued", then "running" when the kernel starts
  4. Responds with CellQueued { cell_id, execution_id } immediately
  5. Forwards code to the kernel via ZMQ execute_request

Key invariant: The daemon writes set_execution_done(eid, success) to RuntimeStateDoc ONLY AFTER all output manifests for that execution are committed. This ordering guarantee is what makes RuntimeStateDoc polling reliable.

Control-plane invariant: Kernel lifecycle signals (KernelIdle, ExecutionDone, CellError, KernelDied) are not output transport. They must not share bounded queues with stdout floods, display churn, or Output widget replay. If output work is pending, drain lifecycle/control signals first so interrupts and queue release remain responsive.

Output-widget replay: RuntimeStateDoc is the durable source of truth for captured Output widget outputs. The kernel-facing SendCommUpdate replay is best-effort output work on a bounded queue. IOPub output arms must use non-blocking enqueue/drop semantics for replay and must not .await a bounded work-channel send before they can observe later status messages.

Display updates: update_display_data messages with display_id are transient display churn. Coalesce them by display_id and commit only the latest pending update off the IOPub hot path. Flush pending display updates after KernelIdle and before ExecutionDone so terminal runtime state still means durable output state is available. The display-update committer's Notify is only a wake hint; the pending map is the source of truth, and each wake or priority flush drains all currently pending display IDs.

Stream-output committer: stdout/stderr chunks may be coalesced and periodic flushes may be dropped when pressure is high. The terminal buffer holds the latest rendered state. Ordering-sensitive boundaries, such as display/error output after a stream, use the stream committer's priority path and wait for the stream flush before clearing terminal state. ExecutionDone also uses the priority path so the final stream manifest is durable before the runtime state becomes terminal.

Stage 4: Terminal Wait (RuntimeStateDoc Polling)

The client polls RuntimeStateDoc for execution completion:

rust
await_execution_terminal(handle, &execution_id, timeout, None).await

Phase 1: Terminal status poll:

  • Polls every 50ms
  • Checks executions[eid].status for "done" or "error"
  • Also watches for kernel-level failure (kernel.lifecycle == Error|Shutdown)
  • Returns KernelFailed if the kernel dies while execution is pending

Phase 2: Output-sync grace:

  • After terminal status is reached, the output list might still be empty on the client's replica (sync lag)
  • Polls every 10ms for up to 500ms (the grace period)
  • Exits as soon as outputs appear

Why RuntimeStateDoc, not broadcasts: The ExecutionDone broadcast arrives over a separate channel and the client's Automerge replica may not have caught up on the final stream writes. The RuntimeStateDoc is authoritative: once status is "done", outputs are guaranteed to be in the same document.

Stage 5: Output Resolution

Outputs are inline manifest Maps in RuntimeStateDoc, containing ContentRef entries per MIME type:

rust
let outputs = output_resolver::resolve_cell_outputs_for_llm(&output_manifests, ctx).await;

Resolution depends on MIME type:

  • Text MIME (text/*, application/json, image/svg+xml): Inline string if ≤1KB, or fetch from blob store as UTF-8
  • Binary MIME (image/png, audio/*, etc.): Always blob store. Frontend gets http:// URL. Python gets raw bytes.
  • Widget output (application/vnd.jupyter.widget-view+json): References comm topology/output routing in RuntimeStateDoc; mutable widget values live in the paired CommsDoc

MCP execution paths use preview mode: output is truncated for LLM consumption. Agents that need full output call get_cell(full_output=true) separately.

Show full SKILL.md (510 more words)Show less

Execution ID Lifecycle

Client sends ExecuteCell
  → Daemon returns CellQueued { cell_id: "cell-1", execution_id: "exec-abc" }
  → RuntimeStateDoc: executions["exec-abc"] = { status: "queued" }
  → Kernel starts: executions["exec-abc"].status = "running"
  → Outputs arrive: executions["exec-abc"].outputs = [manifest1, ...]
  → Kernel done: executions["exec-abc"] = { status: "done", success: true }
  → Client reads outputs from executions["exec-abc"].outputs

The execution_id is the stable reference for one execution attempt. If the same cell is executed twice, each gets a different execution_id. Agents can pass execution_id to get_cell() to read outputs for a specific execution rather than the cell's current outputs.

Run-All Flow

run_all_cells follows the same pipeline but batched:

  1. Captures required_heads once
  2. Sends RunAllCells { cell_execution_ids: None }; the daemon selects code cells from the synced document
  3. Daemon returns AllCellsQueued { queued }, where queued is a Vec<QueueEntry> of { cell_id, execution_id } pairs. The MCP client converts this list to its cell_execution_ids map
  4. Client polls each execution_id in parallel with a shared deadline
  5. Returns per-cell results

Timeout: The shared deadline applies to the entire run, not per-cell. If one cell takes 90% of the budget, remaining cells get less time.

The request and response types live in crates/notebook-protocol/src/protocol.rs; the MCP queue conversion is in crates/runt-mcp/src/execution.rs.

Common Failure Modes

"Outputs are empty"
  1. Output-sync grace too short: The execution finished but outputs haven't synced yet. The 500ms grace usually suffices, but very large outputs (big DataFrames, many plots) may need more time.
  2. execution_id mismatch: Reading outputs with the wrong execution_id or reading the cell's "current" outputs after re-execution replaced them.
  3. Blob store unreachable: Binary outputs reference blobs. If the blob HTTP server is down, resolution fails silently.
"Cell didn't execute"
  1. required_heads timeout: Daemon rejected the request after waiting 10s for heads that never arrived. Check if the sync stream is healthy before retrying.
  2. Kernel availability: The daemon returns NoKernel when no runtime agent is connected and no launch is in progress, or when the lifecycle is Shutdown or Error. During launch, it can queue work and return CellQueued before the agent connects. See handle_inner() in crates/runtimed/src/requests/execute_cell.rs.
  3. Trust gate: Untrusted notebooks may block execution pending approval.
"Execution timed out"
  1. Long-running cell: The cell genuinely takes longer than the timeout (default varies by caller; MCP uses 120s).
  2. Kernel hung: The kernel process is alive but not responding. Check kernel.lifecycle in RuntimeStateDoc.
  3. Sync stall: Terminal status was written by the daemon but the client's sync stream stopped delivering frames. Check daemon logs for sync errors.
"Stale outputs from previous execution"

The execution completed but the outputs visible belong to an earlier run. This happens when:

  1. Reading cell outputs without using the execution_id: the cell's "current" pointer may not have been updated yet
  2. The RuntimeStateDoc sync hasn't delivered the latest writes

Fix: Always use execution_id from the CellQueued response to read outputs for a specific execution.

Execution Document Architecture

Execution primarily spans NotebookDoc and RuntimeStateDoc in a notebook room:

DocumentWhat it holds for execution
NotebookDocCell source code (what to execute)
RuntimeStateDocExecution lifecycle, outputs, kernel status
CommsDocMutable widget values referenced by widget outputs, gated by RuntimeStateDoc topology

The required_heads gate ensures NotebookDoc is synced before execution starts. RuntimeStateDoc polling ensures outputs are available before the client reads them. CommsDoc sync matters when those outputs include live widgets. All document sync streams run concurrently on the same socket connection.

© nteract, BSD-3-Clause. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/execution-pipeline of nteract/nteract.

Open the folder on GitHubat commit 414222e

Compare with similar skills

Execution Pipeline next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Execution Pipeline compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Execution Pipeline this skillnteract/nteract179—~2.7kAutomated safety check: PassBSD-3-Clause
Analyze Logsactivepieces/activepieces25k1 repos~1.6kAutomated safety check: PassMIT
ReleasePrefectHQ/fastmcp28k—~2.9kAutomated safety check: PassApache-2.0
WebMCP Tool Generatorvercel-labs/agent-browser44k1 repos~752Automated safety check: PassApache-2.0
Review PRPrefectHQ/fastmcp28k—~3.1kAutomated safety check: PassApache-2.0
ObservalObserval/Observal4.2k—~2.2kAutomated safety check: PassApache-2.0

Similar skills

  • Analyze Logs

    activepieces/activepieces

    Analyze application logs from the .evlog/logs/ directory. An agent skill from activepieces/activepieces.

    25k GitHub starsUsed in 1 repo~1.6k tokens
    DevelopmentAuto-check passed
  • Release

    PrefectHQ/fastmcp

    Cut a FastMCP release end to end. An agent skill from PrefectHQ/fastmcp.

    28k GitHub stars~2.9k tokensUpdated today
    DevelopmentAuto-check passed
  • WebMCP Tool Generator

    vercel-labs/agent-browser

    Official

    Builds and validates experimental WebMCP tools that expose a web page's real workflows to agents, with a manifest, init script and evals compared against accessibility-tree automation.

    44k GitHub starsUsed in 1 repo~752 tokens
    DevelopmentAuto-check passed
  • Review PR

    PrefectHQ/fastmcp

    Assess a FastMCP pull request for justified behavior, compatibility, and correctness, then follow CI and review feedback to a revision-specific verdict.

    28k GitHub stars~3.1k tokensUpdated today
    DevelopmentAuto-check passed
  • Observal

    Observal/Observal

    A skill your agent uses when starting any task the organization may already have an approved skill, prompt, MCP server, or Agent for: reviewing code, a commit, a diff, or a pull request; writing…

    4.2k GitHub stars~2.2k tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Ue Code Authoring

    JasonMa0012/MooaToon

    A skill your agent uses when writing or modifying UE C++ (classes, actors, components, subsystems, interfaces, function libraries) with Rider MCP available.

    749 GitHub stars~1.9k tokensUpdated 19 days ago
    DevelopmentAuto-check: notes

More from nteract/nteract

All 10 skills in this repo
  • Automerge Sync

    nteract/nteract

    Automerge sync protocol internals, document model (OpSet, ChangeGraph, fork/merge, save/load lifecycle), and higher-level protocol design patterns.

    179 GitHub stars~4.5k tokensUpdated today
    Auto-check passed
  • Daemon Dev

    nteract/nteract

    Develop, debug, and manage the runtimed daemon, Python bindings, and build system.

    179 GitHub stars~3k tokensUpdated today
    Auto-check passed
  • Nteract Diagnostics

    nteract/nteract

    Pull and triage submitted nteract diagnostics archives from Cloudflare using a diagnostics id/token.

    179 GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Repl

    nteract/nteract

    Use nteract notebooks as a persistent Python REPL. An agent skill from nteract/nteract.

    179 GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Testing

    nteract/nteract

    Run tests, verify changes, and collect diagnostics. An agent skill from nteract/nteract.

    179 GitHub stars~2.2k tokensUpdated today
    Auto-check passed
  • Architecture

    nteract/nteract

    Architecture and documentation framing for cross-cutting repo decisions, docs taxonomy placement, ADRs, memos, PRDs, implementation plans, audits, measurements, runbooks, and source-grounded…

    179 GitHub stars~497 tokensUpdated today
    Auto-check passed

Questions about Execution Pipeline

What does Execution Pipeline do?

The end-to-end cell execution pipeline from MCP tool call through daemon to kernel and back. Execution Pipeline is an agent skill from nteract/nteract. The end-to-end cell execution pipeline from MCP tool call through daemon to kernel and back.

When should I use Execution Pipeline?

Execution Pipeline fits situations like: debugging execution failures; understanding output timing; investigating why outputs are missing; modifying the execute/run-all flow.

How do I install Execution Pipeline in Claude Code?

Run `npx skills add nteract/nteract --skill execution-pipeline -a claude-code`. Or copy the skill folder (.agents/skills/execution-pipeline in nteract/nteract) into .claude/skills/execution-pipeline in your project. Claude Code loads it when a task matches its description.

How do I install Execution Pipeline in Codex?

Run `npx skills add nteract/nteract --skill execution-pipeline -a codex`. Or copy the skill folder (.agents/skills/execution-pipeline in nteract/nteract) into .agents/skills/execution-pipeline in your project. Codex loads it when a task matches its description.

Can I use Execution Pipeline in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add nteract/nteract --skill execution-pipeline -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/execution-pipeline, .gemini/skills/execution-pipeline, .github/skills/execution-pipeline and .opencode/skills/execution-pipeline in your project.

What does Execution Pipeline need to run?

SKILL.md names no scripts, command-line tools or credentials: Execution Pipeline is instructions for the agent only. Our summary lists: Python 3.

Does Execution Pipeline access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Execution Pipeline safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Execution Pipeline use?

Execution Pipeline is published under the BSD-3-Clause licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Execution Pipeline use?

About 2.7k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Execution Pipeline?

Skills that share tags, products or a category with Execution Pipeline: Analyze Logs (activepieces/activepieces, 25k stars), Release (PrefectHQ/fastmcp, 28k stars), WebMCP Tool Generator (vercel-labs/agent-browser, 44k stars) and Review PR (PrefectHQ/fastmcp, 28k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Execution Pipeline?

nteract (a GitHub organization) maintains it in nteract/nteract, which has 179 GitHub stars. The repository holds 10 skills in this directory. The repository was last updated on October 7, 2026.

Source: nteract/nteract on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.