Skip to main content
Glama
youngsu-Kim

macaulay2-mcp

by youngsu-Kim

m2_run_script

Run a Macaulay2 script in a fresh isolated process for long or self-contained computations. Get only printed output without affecting the persistent session.

Instructions

Run a .m2 file in a FRESH, isolated Macaulay2 process.

Does not touch the persistent session (and its state is not visible afterwards). Use for long or self-contained computations, or when a repeated m2_evaluate timeout suggests a heavy job. This is batch mode: only explicit print output is returned — the script must print its own results.

Args: path: ABSOLUTE path to the .m2 file, e.g. "/tmp/compute.m2". timeout_s: Author-set safety limit (default 120, max 3600). On timeout the process is killed and any partial output is returned.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes
timeout_sNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A5/5.0
Behavior5/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 fully discloses the isolated-process semantics, non-persistence of state, batch-mode output constraints, the requirement that the script print its own results, and timeout behavior including process termination and partial output return.

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 concise and well-structured: the primary purpose is front-loaded, followed by usage context, behavioral details, and then clearly separated parameter explanations. 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.

Completeness5/5

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

Given only two simple parameters and no annotations, the description is complete enough for an agent to invoke the tool correctly. It covers path requirements, timeout semantics, isolation behavior, output expectations, and the appropriate use case, leaving no critical gap.

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%, so the description must compensate, and it does. It explains path must be an absolute path with an example, and fully documents timeout_s as an author-set safety limit with default 120, max 3600, and the consequence of a timeout.

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: 'Run a .m2 file in a FRESH, isolated Macaulay2 process.' It also clearly differentiates from sibling tools by emphasizing the isolated process and batch-mode behavior, so an agent can distinguish it from m2_evaluate and the other related tools.

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

Usage Guidelines5/5

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

The description explicitly says when to use this tool: 'Use for long or self-contained computations, or when a repeated m2_evaluate timeout suggests a heavy job.' It also implies when not to use it by noting it does not touch the persistent session and that output is only explicit print output, which gives clear routing guidance.

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