Skip to main content
Glama

fl_exec

Destructive

Runs Python in FL Studio's embedded interpreter to read or modify the open project via FL modules, returning the assigned result or an error traceback.

Instructions

Run Python inside the running FL's embedded interpreter, where FL's modules (channels, mixer, plugins, transport, patterns, general ...) import. For live reads or changes that need several calls or logic; one call is simpler with fl_call. Returns {ok, value} with what the code assigns to result, or {ok: false, error} with the traceback. FL's sandbox refuses files, sockets and pipes. Changes act on the open project and are not saved. Needs FL open; it is not started for this.

Input Schema

NameRequiredDescriptionDefault
outNowrite the result as JSON to this path (relative to the repo) and return only its size, for large reads; also when `result` is {'__out__': path, 'data': value}
codeYesPython source; assign the answer to `result`
timeoutNoseconds to wait for FL's answer

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.2.1
    • addedInput schema / properties / code / description
      Added value: +"Python source; assign the answer to `result`"
    • addedInput schema / properties / out / description
      Added value: +"write the result as JSON to this path (relative to the repo) and return only its size, for large reads; also when `result` is {'__out__': path, 'data': value}"
    • addedInput schema / properties / timeout / description
      Added value: +"seconds to wait for FL's answer"
  2. First observedv0.2.0

TDQS

A4.4/5.0
Behavior4/5

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

Goes well beyond the annotations by disclosing the sandbox restrictions (no files, sockets, pipes), that changes act on the open project and are not saved, and the exact return shape for success and failure. The destructiveHint=true annotation is qualified rather than contradicted — mutations are real but discarded — which is valuable context. Minor gap: no mention of timeout behavior or long-running code.

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 core purpose and keeps every sentence load-bearing, but the later clauses are packed with multiple semicolon-joined facts in a single sentence, making it slightly denser than necessary.

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?

Despite no output schema, the description fully documents return values, the error/traceback form, sandbox limits, persistence semantics, and the FL-must-be-open prerequisite. Nothing an agent needs to invoke it correctly is missing.

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 code, out, and timeout are already documented. The description reinforces the `result` assignment convention but adds no syntax, format, or edge-case detail about `out` or `timeout` beyond what the schema states, so baseline 3 applies.

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?

Starts with a specific verb+resource ('Run Python inside the running FL's embedded interpreter') and enumerates the importable modules. It also names the sibling it differs from ('one call is simpler with fl_call'), so an agent can pick it out of a crowded toolset without opening a 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 an explicit selection rule: use this when work needs several calls or logic, otherwise prefer fl_call. It also states the prerequisite ('Needs FL open; it is not started for this'), which is exactly the when-not guidance an agent needs.

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