Skip to main content
Glama

write_project_script

Create or replace a project library script from Python/Jython source, with dry-run validation and confirmation before writing.

Instructions

Create or replace a project library script.

Args: module_path: Dotted module path, e.g. MyModule.NewModule. code: Python/Jython source. project: Project name; defaults to the active project. confirm: Must be True to write. dry_run: Validate and preview without writing.

Returns: Write acknowledgement, or validation issues in dry-run mode.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "module_path": "<module_path>",
      "code": "<code>"
    },
    "name": "write_project_script"
  }
}

Input Schema

NameRequiredDescriptionDefault
codeYes
confirmNo
dry_runNo
projectNo
module_pathYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations at all, the description does real disclosure work: it names the destructive "replace" behavior, states that confirm must be True to actually write, and explains that dry_run validates and previews. It leaves unstated what happens to the existing script body on replace and whether a backup/snapshot is taken.

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 purpose sentence is front-loaded and the Args/Returns structure is easy to scan. Some lines restate schema keys verbatim, but the format is appropriate for a five-parameter mutation tool.

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 values need no elaboration, and the description covers all parameters plus the confirm gate. What remains thin is the blast radius of "replace" and the absence of an explicit pointer to validation or snapshot siblings for pre-flight checks.

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 carries the full burden and does: it labels all five parameters, gives a dotted-path example for module_path, identifies code as Python/Jython source, explains the project default, and adds the non-schema-enforceable rule that confirm must be True to write.

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?

"Create or replace a project library script" gives a specific verb pair and resource, and the Args block makes the scope concrete. It stops short of differentiating itself from the sibling write_project_resource, which is the nearest ambiguity an agent would face.

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 never says when to reach for this tool instead of write_project_resource, read_project_script, or set_event_script, nor what prerequisites (permissions, existing script ownership) must hold. Only the internal mechanics of confirm/dry_run are conveyed, not the selection logic.

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

Deploy Server

Other Tools