Skip to main content
Glama

ddflow_job_run

Launch a long-running command in a detached session so it outlives the agent, and get its job ID, PID, and log path for monitoring.

Instructions

Launch a LONG-RUNNING command for an item -- a training run, a data generation, a model server -- detached into its own session so it outlives you, this server and a restarted remote-control service, and record it. Runs in the item's worktree. Returns the job id, pid and log path. Then WAIT with ddflow_job_list rather than polling the process yourself; ddflow_brief shows running jobs to whoever starts the next session. Declare the item's resources (ddflow_update) so nobody else starts a run on the same GPUs.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cwdNoWorking directory (default: the item's worktree).
logNoOutput file (default .ddflow/local/jobs/<item>-<t>.log).
itemYesItem the job is for.
commandYesThe shell command.
as_agentNoSubagent sharing the parent's connection: your own stable name, for this call only (see ddflow_identify).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.10

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses that the process is detached into its own session and survives the caller, the server, and a restarted remote-control service, and that it runs in the item's worktree. It does not cover failure modes, permissions, or whether the call returns immediately, which keeps it short of a 5.

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 key facts -- long-running, detached, persistence, return values -- are front-loaded and every sentence adds routing or prerequisite information. It is slightly run-on in the persistence clause but wastes no sentences.

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?

There is no output schema, yet the description states exactly what is returned (job id, pid, log path), the execution context (the item's worktree), the follow-up action, and the GPU/resource precondition. Nothing essential for invoking 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 description coverage is 100%, so the defaults for cwd, log, and the as_agent cross-reference are already documented in the schema. The description only echoes the worktree default and adds no new syntax or format detail, so the baseline of 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?

States a precise verb (launch) and resource (a LONG-RUNNING, detached, recorded command for an item), reinforced by concrete examples (training run, data generation, model server). It also names the sibling it hands off to (ddflow_job_list) and the one that surfaces results (ddflow_brief), so an agent can distinguish it from the other job_* 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?

Explicitly routes the agent: wait via ddflow_job_list instead of polling, and surfaces running jobs to the next session through ddflow_brief. It also states a concrete precondition -- declare the item's resources with ddflow_update so nobody else starts a run on the same GPUs.

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