Skip to main content
Glama

Colab-mcp

An MCP server for bridging your local agent to a Colab session in the browser.

Supported Clients

This MCP server requires client support for notifications/tools/list_changed and for the client to be running locally on your device.

Popular clients that fit these criteria include:

  • Gemini CLI

  • Claude Code

  • Windsurf

Setup

  • Install uv (pip install uv)

  • Configure for usage (eg for mcp.json style services):

...
  "mcpServers": {
    "colab-mcp": {
      "command": "uvx",
      "args": ["git+https://github.com/googlecolab/colab-mcp"],
      "timeout": 30000
    }
  }
...

(If you have a non-standard default package index (Googlers), you may also need to add --index https://pypi.org/simple)

Opening a specific notebook (local fork)

This fork extends open_colab_browser_connection with an optional notebook_url argument so an agent can connect to the notebook you hand it instead of the scratch notebook:

  • Colab links (colab.research.google.com/..., colab.google.com/...)

  • Google Drive share links or bare Drive file ids

  • GitHub .ipynb blob or raw.githubusercontent.com links

  • Gist links

Calling it with a different notebook_url while connected disconnects the current tab and opens the new notebook. A colab_connection_status tool reports whether a tab is connected and which notebook it was opened for, without touching the browser. COLAB_MCP_UI_TIMEOUT (seconds, default 60) controls how long the opener waits for you to accept the connection in the tab.

Run from this checkout with uv run --project /path/to/colab-mcp colab-mcp.

Connection lifecycle (local fork)

  • Persistent identity. The websocket token and port are saved to ~/.colab-mcp/connection.json (owner-readable only; override the directory with --state-dir or COLAB_MCP_STATE_DIR) so a connected tab survives a server restart. --ephemeral restores the upstream behaviour of a fresh token and port each start, and --port pins the websocket port.

  • Token rotation. The token rides in the URL fragment of every Colab link the server opens, so it ends up in browser history. A persisted token is replaced once it is older than COLAB_MCP_TOKEN_MAX_AGE_DAYS (default 30; 0 never), or immediately with --rotate-token. The port and last notebook are kept; an open tab must be re-opened.

  • Automatic re-open. If the tab drops and the agent calls a notebook tool, the server re-opens the notebook it last opened and waits for the connection instead of failing. Only notebooks opened by the running server are re-opened: the one saved by a previous process is reported as previous_notebook_url and named in the "not connected" error, but never opened unprompted. Set COLAB_MCP_AUTO_REOPEN=0 to disable.

  • Cancellation-safe waits. Upstream's wait for the browser used gather inside wait_for; a timeout or a cancelled tool call killed the long-lived MCP client, after which every tab was dropped the instant it connected. The wait no longer cancels the client, and a dead session is recycled before a tab is opened.

  • colab_connection_status also reports the proxy port, the state and log directories, whether the session is dead, and the server pid.

Related MCP server: colab-mcp

Composite notebook tools (local fork)

Colab's in-browser server exposes seven primitives (get_cells, add_code_cell, add_text_cell, update_cell, move_cell, delete_cell, blocking run_code_cell). This fork adds server-side tools built on them:

Tool

What it does

get_notebook_outline

Cells as index, id, type, first line, output and error flags. Cheaper than get_cells.

run_cells

Run code cells by id list or index range, in order, with per-cell stdout/stderr/result/error. background=True returns a job id.

run_notebook

Run every code cell from the top; background by default.

run_code

Run ad-hoc Python through a temporary cell at the end (deleted afterwards unless keep_cell). Plots come back as image content.

job_status, list_jobs, cancel_job

Poll or stop background runs. Colab cannot interrupt a running cell through this bridge, so cancel stops after the current cell.

upload_file

Copy a local file to the runtime in base64 chunks, verified by SHA-256.

download_file

Copy a runtime file to this machine, verified by SHA-256.

export_notebook

Save the connected notebook as .ipynb (nbformat 4).

Executions are serialised per runtime: a foreground run_code or file transfer waits for a background job's current cell to finish and then runs before the job's next cell, so two cells never execute at once and temporary cells never collide.

Large outputs: the websocket bridge now accepts messages up to 64 MiB (the library default of 1 MiB dropped the connection on a ~400 KB output). A proxied or composite call fails fast with a clear error if the tab drops while the call is in flight.

Issues & Discussions

We are using GitHub discussions as the place for issue discussion and feature requests. As discussions mature into action items, we will add those items as issues. This helps us ensure that issues in the issue tracker are well-understood, deduplicated, and actionable. For these reasons, please do NOT open issues directly.

Contributing

We unfortunately don't have the bandwidth to support review of external contributions, and we don't want user PRs to languish, so we aren't accepting any external contributions right now.

If you have a great idea or pain point, we would love to hear about it on our discussions page - the preferred place for issue discussion and feature requests.

Internal - For Colab Developers

Prerequisites

  • uv is required (pip install uv)

  • Configure git hooks to run repo presubmits

git config core.hooksPath .githooks

Gemini CLI setup

...
  "mcpServers": {
    "colab-mcp": {
      "command": "uv",
      "args": ["run", "colab-mcp"],
      "cwd": "/path/to/github/colab-mcp",
      "timeout": 30000
    }
  }
...

Available Tools

12 tools
cancel_jobB

Stop a background run after its current cell. The running cell itself cannot be interrupted.

NameRequiredDescriptionDefault
job_idYes

Output Schema

NameRequiredDescription

No output parameters

TDQS

B3.1/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does disclose genuinely useful behavior: cancellation is deferred until after the current cell, and the in-flight cell cannot be interrupted. It stops short of what an agent still needs — resulting job state (cancelled vs failed), reversibility, and whether the call blocks until the cell finishes.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences, front-loaded with the core action and followed by the single constraint that matters. Nothing is padded and nothing competes for attention.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Output schema exists, so return values needn't be explained, and the deferred-cancellation behavior is covered. But for a mutation tool with zero annotations, the description should say what state the job ends in and where job_id comes from; without that, an agent can call it but cannot predict the outcome.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate, and it says nothing about job_id: no format, no source (e.g., returned by run_cells or list_jobs), no requirement that the job be active. With one undocumented required parameter, this is a real gap.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: 'Stop a background run', which an agent can distinguish from read-only siblings like job_status and list_jobs. The added scope note ('after its current cell') makes the semantics of 'stop' concrete, though it never names job_status/list_jobs as the discovery path for job_id.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies this applies to a running background job, but gives no explicit when-to-use guidance, no prerequisites (job must exist and be running), and no treatment of the already-finished or unknown job_id case. Alternatives such as job_status or run_cells are not mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

colab_connection_statusA

Reports whether a Colab browser session is connected and which notebook it was opened for. Does not open a browser.

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription

No output parameters

TDQS

A4.2/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden, and it does disclose the key trait: this is a non-mutating query that will not spawn or alter a browser session. It does not say what happens when no session exists (error vs. disconnected result) or whether the reported state is live or cached, which are the remaining behavioral unknowns for a status probe.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences, zero waste. The positive capability is front-loaded and the negative scoping clause follows immediately where it is most useful.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return-value shape is already covered and the description needn't restate it; for a zero-param read tool this is nearly enough. Only the no-session / failure behavior is left unstated, a minor gap given the tool's simplicity.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool takes zero parameters, so there is nothing for the description to disambiguate; baseline 4 applies. The description correctly makes no attempt to describe inputs, and the empty schema is self-explanatory.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb ("Reports") and a precise resource (connection state of a Colab browser session plus the notebook it was opened for). The closing clause "Does not open a browser" explicitly separates it from the sibling open_colab_browser_connection, so an agent can route without opening either schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The "Does not open a browser" clause is a genuine when-not boundary that tells the agent this is the inspection path, not the connection path. It stops short of naming open_colab_browser_connection as the alternative to call when a session needs to be created, so it is clear context rather than full when/when-not/alternatives routing.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

download_fileA

Copy a file from the notebook runtime to this machine, verifying its SHA-256.

NameRequiredDescriptionDefault
overwriteNo
local_pathYes
remote_pathYes

Output Schema

NameRequiredDescription

No output parameters

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations exist, so the description carries the full burden. It usefully discloses that a SHA-256 check is performed, but says nothing about what happens on mismatch, whether existing local files are replaced when overwrite is false, or any size/rate limits on the transfer.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single tightly written sentence with the action, source, destination, and integrity guarantee front-loaded. Nothing extraneous.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values need not be explained. However, for an unannotated write-to-local-disk tool, the description omits overwrite semantics and checksum-failure behavior, leaving an agent unable to predict what happens on a name collision or corruption.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so all three parameters are undocumented in structured data. The description implies remote_path lives on the runtime and local_path on this machine, which is some help, but the overwrite parameter is never mentioned and no path format (absolute vs relative) is given.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (copy) and resource (file) plus an explicit direction: from the notebook runtime to this machine. That directionality cleanly separates it from the sibling upload_file without needing to name it.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The direction of the copy implies when this tool applies, but there is no explicit guidance such as 'use this instead of upload_file' or any precondition for when downloading is appropriate or not. Usage must be inferred from one clause.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

export_notebookC

Save the connected notebook as an .ipynb file on this machine.

NameRequiredDescriptionDefault
local_pathYes
include_outputsNo

Output Schema

NameRequiredDescription

No output parameters

TDQS

C2.8/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full behavioral burden. It says the file is saved locally as .ipynb, but does not disclose overwrite behavior, permission needs, whether directories are created, or how include_outputs affects the saved file.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, front-loaded sentence with no filler. It states the core action and destination efficiently.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values need not be explained. However, for a filesystem-writing export tool with no annotations and fully undocumented parameters, the description omits critical details about include_outputs, path semantics, and overwrite behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate for both parameters. It vaguely implies local_path via 'on this machine' but never explains it, and it does not mention include_outputs at all.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: save the connected notebook as an .ipynb file. It is understandable on its own, though it does not explicitly differentiate itself from the sibling download_file tool.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives no explicit guidance on when to use this tool versus alternatives such as download_file, nor does it mention prerequisites like an active notebook connection. Usage is only implied by the phrase 'connected notebook'.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_notebook_outlineB

List cells as index, id, type, first source line and whether outputs exist.

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription

No output parameters

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It implies a read-only listing but never states that it does not execute cells, what permissions are needed, or whether it is safe to call repeatedly — the only behavioral hint is that it reports 'whether outputs exist'.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence enumerating the returned fields with no filler. Every clause earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With zero parameters and an output schema present, the definition is nearly complete for invocation purposes. What is missing is the read-only guarantee and the routing signal versus sibling cell tools.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool takes zero parameters, so there is nothing for the description to disambiguate; the baseline of 4 applies. The sentence instead spends its effort describing the produced columns, which is harmless but not parameter guidance.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb ('List') and resource ('cells') and enumerates exactly what is returned per cell (index, id, type, first source line, output presence). It does not differentiate from siblings such as run_cells or export_notebook, which also operate on notebook cells.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no statement of when to use this versus alternatives like run_cells or export_notebook, and no prerequisites or context. An agent must infer usage from the name alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

job_statusC

Progress and per-cell results of a background run.

NameRequiredDescriptionDefault
job_idYes
max_output_charsNo

Output Schema

NameRequiredDescription

No output parameters

TDQS

C2.4/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full behavioral burden and does not meet it. It never says whether the call blocks, whether results are partial while running, what happens for an unknown or expired job_id, or that output is truncated — only 'progress and per-cell results' hints at in-flight behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single short sentence with no filler, and the key payload terms are front-loaded. It is efficient, though efficiency is not the same as sufficiency for a polling tool.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values need not be spelled out. Everything else an agent needs — polling semantics, terminal states, how job_id is obtained, truncation via max_output_chars — is absent, which is thin for a tool with 0% param coverage and no annotations.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must compensate for two undocumented parameters and does not. It says nothing about job_id being the required run identifier, nor that max_output_chars caps the returned text (default 2000), which is the only non-obvious parameter behavior here.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives the resource ('background run') and the payload ('progress and per-cell results'), but it is a noun phrase rather than a verb+resource statement, and it never names job_id as the handle or distinguishes itself from list_jobs. An agent can infer this is a status poller, but only by guessing.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no guidance on when to call this versus list_jobs, cancel_job, or run_cells, and no hint about polling cadence or whether to call repeatedly until the run finishes. Usage is implied at best.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_jobsB

All known background runs, newest last.

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription

No output parameters

TDQS

B3.3/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations exist, so the description carries the burden. It does disclose two real behavioral traits: scope ('all known', i.e. no status filtering) and ordering ('newest last'). It says nothing about pagination, result limits, or whether running vs. completed runs are distinguished, which matters for a potentially unbounded list.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded clause with zero waste. It is arguably too terse for the confidence it needs to inspire, but no sentence is filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists and there are no parameters, so the bar is low, but the description never defines what a 'job' is relative to the run_* siblings or whether completed/cancelled runs appear. For an enumeration tool that an agent will likely use to discover state before acting, that is a meaningful gap.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool takes zero parameters, so there is nothing for the description to clarify; baseline of 4 applies. The empty schema matches the 'all known' framing with no conflicting filtering notions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States the resource precisely — 'All known background runs' — which effectively communicates that this enumerates jobs rather than querying one. The implied contrast with job_status is inferable from 'All known', though no sibling is named.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No when-to-use guidance and no alternatives mentioned. An agent must infer on its own that list_jobs is for enumeration while job_status is for a single job, and nothing tells it whether to call this first or after run_notebook.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

open_colab_browser_connectionA

Opens a connection to a Google Colab browser session and unlocks notebook editing tools. Pass notebook_url to open a specific notebook instead of the scratch notebook: Colab links, Google Drive share links or file ids, GitHub .ipynb blob/raw links, and gist links are accepted. Calling it with a different notebook_url while connected switches to that notebook. The call waits for the user to accept the connection in the browser tab; on success, list tools again to see the notebook tools.

NameRequiredDescriptionDefault
notebook_urlNo

Output Schema

NameRequiredDescription

No output parameters

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full behavioral burden and does well: it discloses that the call waits for the user to accept the connection in the browser tab and that success requires listing tools again. It could go further by mentioning authentication requirements or failure modes, but the key interactive behavior is clearly surfaced.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is three sentences, front-loads the core purpose, then covers parameter behavior and the post-success step. Every sentence adds useful information without redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the optional single parameter and the presence of an output schema, the description is nearly complete: it covers purpose, URL formats, switching behavior, and the user-acceptance wait. It stops short of describing failure conditions or required authentication details, but an agent has enough to invoke it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description fully compensates by explaining that notebook_url is optional, defaults to the scratch notebook, and accepts Colab links, Drive share links/file ids, GitHub .ipynb blob/raw links, and gist links. It also clarifies switching semantics when a different URL is passed while connected.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource: it opens a connection to a Google Colab browser session and unlocks notebook editing tools. This is clearly distinguishable from siblings such as colab_connection_status, which likely checks status rather than initiating a connection.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explains that notebook_url is optional and that omitting it opens the scratch notebook, while providing it opens a specific notebook. It also notes that calling with a different URL while connected switches notebooks and instructs the agent to list tools after success. It does not explicitly name alternatives like colab_connection_status for status checks, which keeps it from a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

run_cellsA

Run code cells in order: by id list, or by index range (end exclusive), or all.

Each cell blocks until it finishes. For anything that may take more than a minute set background=True and poll job_status; Colab cannot be interrupted through this bridge, so cancel only stops scheduling the next cell.

NameRequiredDescriptionDefault
cell_idsNo
end_indexNo
backgroundNo
start_indexNo
stop_on_errorNo
max_output_charsNo

Output Schema

NameRequiredDescription

No output parameters

TDQS

A3.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does substantial work: per-cell blocking, background/polling pattern, and the important caveat that Colab cannot be interrupted through this bridge so cancel only stops scheduling subsequent cells. It omits error behavior despite stop_on_error defaulting to true, and says nothing about output truncation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the selection modes, then operational caveats, in three tight sentences with no filler. The warning sentence is dense but every clause (blocking, background, interruption limit) earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists so return values need not be described, and the runtime/blocking semantics are well covered. However, for a six-parameter execution tool the silence on stop_on_error and output size limits, plus no mention of connection prerequisites, leaves real gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate for six undocumented parameters. It explains cell_ids, start_index/end_index (notably "end exclusive") and background, but leaves stop_on_error and max_output_chars entirely undefined in both schema and description — two of six parameters unexplained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ("Run code cells") plus the three selection modes (id list, index range, all), which clearly separates it from run_notebook and run_code by granularity. It does not explicitly name those siblings, so differentiation is inferred rather than asserted.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives strong operational guidance (use background=True plus job_status polling for runs over a minute) but never states when to pick this over run_notebook or run_code, nor the prerequisite of an open Colab connection. Usage context for tool selection is implied by the word "cells" alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

run_codeA

Run ad-hoc Python in the notebook's runtime via a temporary cell at the end.

The cell is deleted afterwards unless keep_cell=True. Images in the output (plots) are returned as image content. background=True returns a job id.

NameRequiredDescriptionDefault
codeYes
keep_cellNo
backgroundNo
max_output_charsNo

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description must carry the full load, and it does disclose meaningful behavior: the temporary cell is deleted unless keep_cell=True, plots come back as image content, and background=True returns a job id. However it omits truncation behavior implied by max_output_chars=8000, whether variables persist between calls, and any error/exception reporting.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three short sentences, each carrying distinct information: execution model, cell lifecycle, and output/async behavior. Front-loaded with the core action and no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with no annotations and no output schema, it covers the essentials: where the code runs, the side effect on the notebook, what output comes back, and the async escape hatch. Only truncation semantics and state persistence across calls are missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It explains keep_cell and background (including that it returns a job id), but max_output_chars is never mentioned and 'code' is left entirely self-evident, leaving one of four parameters undocumented anywhere.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Run ad-hoc Python in the notebook's runtime') plus a distinguishing implementation detail ('via a temporary cell at the end'). This implicitly separates it from run_cells and run_notebook, but it never names those siblings, so the agent must infer the boundary.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied by 'ad-hoc Python' – the reader can infer this is for exploratory snippets rather than executing existing notebook cells (run_cells) or the whole notebook (run_notebook), but no explicit when/when-not or alternative routing is given. Nothing states prerequisites such as an active runtime or connection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

run_notebookB

Run every code cell from the top. Background by default: poll job_status.

NameRequiredDescriptionDefault
backgroundNo
stop_on_errorNo
max_output_charsNo

Output Schema

NameRequiredDescription

No output parameters

TDQS

B3/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description must carry the full behavioral burden. It discloses that execution is backgrounded by default and requires polling job_status, but it says nothing about side effects of executing notebook code, failure behavior, stop_on_error semantics, or output truncation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences, front-loaded with the core action and followed by the key operational note. There is no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values need not be described. Still, for a code-execution tool with no annotations and three undocumented parameters, the description omits important details about execution behavior, parameter effects, and failure handling.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate for undocumented parameters. It only hints at the background default; stop_on_error and max_output_chars are never mentioned, leaving two of three parameters unexplained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: run every code cell from the top. The scope (all cells, ordered from top) helps distinguish it from sibling tools like run_cells and run_code, though it never names those alternatives explicitly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The note that background execution is the default and that job_status should be polled gives useful workflow guidance. However, it does not explain when to choose run_notebook over run_cells or run_code, or when background execution should be disabled.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

upload_fileB

Copy a local file into the notebook runtime's filesystem (e.g. /content/data.csv).

Transfers in base64 chunks through temporary cells and verifies the SHA-256 on the runtime afterwards.

NameRequiredDescriptionDefault
overwriteNo
local_pathYes
remote_pathYes

Output Schema

NameRequiredDescription

No output parameters

TDQS

B3.3/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations exist, so the description carries the full burden. It usefully discloses the transfer mechanism (base64 chunks through temporary cells) and post-transfer SHA-256 verification, but omits the highest-risk behavior: the schema's overwrite parameter defaults to true, meaning an existing remote file is silently replaced, and nothing about size limits or runtime filesystem ephemerality is mentioned.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences, zero waste. The core action and destination example come first, with the transport/verification detail following as supporting context.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values need not be explained, and the mechanism is well covered. However, for a write tool with no annotations, the silent-overwrite default and runtime connectivity/size constraints are material omissions that an agent would want before invoking it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across 3 parameters. The description only illustrates remote_path format via the example; local_path format is unaddressed and the destructive default of overwrite=true is never surfaced, which is exactly the gap the description needed to fill.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource pairing — 'Copy a local file into the notebook runtime's filesystem' — with a concrete destination example (/content/data.csv). It implicitly contrasts with the download_file sibling via directionality, but never names the inverse operation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The directional wording ('local file into the runtime') implies when to prefer this over download_file, but there is no explicit when-to-use statement, no prerequisites, and no exclusions such as whether the runtime must be connected first.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 12 tool updatesv1.0.1
    • First observedcancel_job
    • First observedcolab_connection_status
    • First observeddownload_file
    • First observedexport_notebook
    • First observedget_notebook_outline
    • First observedjob_status
    • First observedlist_jobs
    • First observedopen_colab_browser_connection
    • First observedrun_cells
    • First observedrun_code
    • First observedrun_notebook
    • First observedupload_file

TDQS

B3.3/5.0

Scored across 12 tools

Disambiguation4/5

Most tools target clearly distinct actions (connect, check status, outline, job list, cancel, upload, download, export). The only real overlap is the execution trio run_cells, run_notebook, and run_code — run_cells explicitly accepts 'all', which duplicates run_notebook — but the descriptions spell out the difference well enough for an agent to choose correctly.

Naming Consistency4/5

Nearly all names are snake_case and follow verb_noun (get_notebook_outline, run_cells, list_jobs, cancel_job, upload_file, download_file, export_notebook). Minor deviations: the status queries job_status and colab_connection_status are noun-only, and open_colab_browser_connection redundantly embeds 'colab' while its sibling tools do not.

Tool Count5/5

Twelve tools is a well-scoped set for remote Colab notebook control: connection handling, execution, job management, file transfer, and export each get a small number of dedicated tools. Nothing appears padded or redundant beyond the mild execution overlap.

Completeness3/5

Core run lifecycle (connect, inspect cells, execute, poll, cancel, transfer files, export) is covered with no dead ends. However, the notebook-editing tools that open_colab_browser_connection promises to 'unlock' are absent from the surface, and there is no way to insert, delete, or edit cell source or to disconnect a session — notable gaps for a notebook-control server.

Maintenance

ActivityMaintained
ResponsivenessNo recent community issues

Related MCP Connectors

Related MCP Servers

  • A
    license
    A
    quality
    D
    maintenance
    Bridges a local agent to a Colab session in the browser, enabling seamless interaction with Colab from local clients.
    1
    1,429
    Apache 2.0
  • A
    license
    A
    quality
    D
    maintenance
    Bridges a local AI agent to a Colab session in the browser, enabling code execution and file operations through the Model Context Protocol.
    2
    9
    Apache 2.0
  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables MCP clients to execute Python code on Google Colab GPU/TPU runtimes via the official Colab CLI, with session, file, and package management capabilities.
    -