Skip to main content
Glama

generate_sympy_script

Generate a complete SymPy script that performs specified symbolic operations on given expressions, producing a standalone runnable script for reproducible derivations.

Instructions

    Generate a standalone SymPy script for a computation.

    This generates a complete, runnable Python script that can be
    executed independently to reproduce the derivation.

    Args:
        expressions: List of {"name": str, "expr": str, "description": str}
        operations: List of operations to perform
            {"op": "simplify|solve|diff|integrate", "input": str, ...}

    Returns:
        Complete Python script

    Example:
        generate_sympy_script(
            expressions=[
                {"name": "momentum", "expr": "m1*v1 + m2*v2", "description": "Total momentum"},
            ],
            operations=[
                {"op": "solve", "input": "momentum = (m1+m2)*v_f", "for": "v_f"},
            ]
        )
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
operationsYes
expressionsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool generates a runnable script but does not explicitly declare whether it is read-only, has side effects, or requires specific permissions. This is insufficient for a generation tool.

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?

The description is well-structured with a summary, brief explanation, Args/Returns, and an example. It is front-loaded with the action. Minor wordiness in the example but overall efficient and clear.

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?

Given the tool has an output schema (true) but not shown, the description states it returns a 'Complete Python script,' which is adequate. However, it lacks details on input constraints (e.g., valid SymPy syntax) and error conditions, making it minimally complete for a script-generation tool.

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 detailing the structure and allowed values for both parameters, including nested objects and permitted operations (simplify, solve, etc.). This adds significant meaning beyond the raw schema.

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 clearly states the tool generates a standalone SymPy script for a computation, using a specific verb and resource. It distinguishes from siblings like generate_derivation_report or generate_python_function by specifying 'SymPy script'.

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 implies usage through the example but does not provide explicit guidance on when to use this tool versus alternatives (e.g., generate_python_function). No when-not-to-use or exclusions are stated.

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

Install Server

Other Tools

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/LBurny/symkit-mcp'

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