Skip to main content
Glama

Run in Agentic Mode

agentic_run

Runs a Xojo project through Agentic Mode and returns real compiler errors with file and line locations, using project-folder files when IDE scripting is unavailable.

Instructions

Agentic Mode only (Xojo 2026r3+): runs the project and returns its compile errors, if any. Unlike run_project, this reports real compiler errors with their locations. It works through files in the project folder rather than IDE scripting, so it also works when the IDE socket does not: it drops XojoRunProject.txt into the project folder and reads back XojoCompileErrors.txt. Compile errors fail the call, one ', line : ' per line. A successful run launches the app in the debugger; stop it with stop_project. If Xojo has not taken the request within 10 seconds, Agentic Mode is off or the project is not open: the request file is removed again and the call fails saying how to turn the mode on. Agentic Mode is the user's opt-in to having the project run to check edits, so this may be called without asking each time.

Input Schema

NameRequiredDescriptionDefault
project_dirNoAbsolute path of the folder containing the .xojo_project. Omit to use the project open in the IDE, which needs the IDE socket.
wait_secondsNoHow long to wait for errors or a launch once Xojo starts the run (default 15, max 120). Raise it for large projects.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv3.7.1
    • changedInput schema / properties / project_dir / description
      Previous value: -"Folder containing the .xojo_project. Defaults to the project open in the IDE."New value: +"Absolute path of the folder containing the .xojo_project. Omit to use the project open in the IDE, which needs the IDE socket."
  2. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Goes well beyond the annotations: it discloses the file-based mechanism (XojoRunProject.txt / XojoCompileErrors.txt), the exact error line format, that compile errors fail the call, that a success leaves the app running in the debugger, the 10-second request handoff, and the cleanup of the request file on failure. None of this is inferable from readOnlyHint=false / destructiveHint=false alone.

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-loads the mode constraint and the run_project contrast, then layers mechanism, error format, and failure mode in a logical order. The temp-filename detail and the sentence on stop_project overlap slightly with what an agent needs, but no sentence is wasted.

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?

With no output schema, the description carries the return-value burden and does: error line format, the failure case where errors are reported, and the success case where the app launches. Timeout behavior, prerequisites, and the stop path are all covered, which is complete for a two-parameter run tool.

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 coverage is 100%, so both parameters, their defaults and the max are already documented in the schema. The description adds only indirect color: the file-based mechanism explains why project_dir might be needed, and the 10-second handoff window hints at the wait semantics. It does not clarify the relationship between that 10-second handoff and wait_seconds, so the baseline 3 holds.

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 and resource ('runs the project and returns its compile errors') and pins the scope to Agentic Mode only (Xojo 2026r3+). It explicitly contrasts with the sibling run_project, so an agent can pick it apart from the near-identical alternative 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 Guidelines5/5

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

Gives explicit when-to-use (Agentic Mode on, or when the IDE socket is unavailable), when it fails (mode off / project not open, with a 10-second criterion), and names the follow-up tool ('stop it with stop_project'). It also pre-authorizes repeated calls as the user's opt-in, which removes a common agent hesitation.

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