Skip to main content
Glama
Ian3738
by Ian3738

r_run

Run any R code in a persistent session to get console output and plots. Use it for custom models, package functions, or data wrangling not covered by structured tools.

Instructions

Run arbitrary R code in the persistent session and return the console output plus any plots. This is the escape hatch for anything the structured tools do not cover: custom models, package-specific functions, data wrangling, or follow-up on a saved model (e.g. summary(anova_fit1)). Objects created here persist and are visible to the other tools; a data frame you create is usable as data="<name>" everywhere.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYesR code to evaluate. Multiple lines are fine.
timeoutNoSeconds to allow before aborting.
plot_widthNoPlot width in inches.
plot_heightNoPlot height in inches.

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations provided, the description carries the full behavioral disclosure burden. It clearly reveals the persistent-session side effect ('Objects created here persist and are visible to the other tools'), the output format, and offers a concrete persistence example. It does not explicitly mention destructive side effects like overwriting objects, but the word 'arbitrary' and the persistence warning convey the powerful, stateful nature of the tool.

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 dense sentences with no wasted words. The first sentence front-loads the core action and return value, the second provides use cases and positions the tool relative to siblings, and the third covers the critical persistence behavior. Every sentence earns its place.

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?

The description covers the essentials for a general-purpose code runner: what it executes, what it returns, and the stateful persistence behavior. There is no output schema and no annotations, so explaining return values and side effects is essential and the description does both. It does not describe error behavior or what happens when code fails, but this is a minor gap given the tool's open-ended nature.

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 100%, so the schema already documents all four parameters. The description adds a useful usage example for the `code` parameter via `summary(anova_fit1)` and clarifies object persistence, but it does not add meaning beyond the schema for `timeout`, `plot_width`, or `plot_height`. The baseline of 3 is appropriate.

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 clear verb and resource: 'Run arbitrary R code in the persistent session' and explicitly names the return values ('console output plus any plots'). It further differentiates itself from the structured sibling tools by calling itself the 'escape hatch' for custom models, package-specific functions, and data wrangling, making it immediately identifiable.

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 description provides explicit when-to-use guidance: 'This is the escape hatch for anything the structured tools do not cover' followed by concrete example categories. It implies that structured tools should be preferred when they do cover the task, though it does not name specific sibling alternatives or describe specific exclusion scenarios.

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

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Ian3738/r-stats-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server