Skip to main content
Glama
AstralVoidZ
by AstralVoidZ

ppsspp_batch_status

Read-onlyIdempotent

Poll the progress of a background PPSSPP batch job without locking the emulator session. Check status, executed steps, and results read-only, or survey all retained jobs to recover a lost batch ID.

Instructions

PURPOSE: Poll the state and progress of a background batch job without touching the session.

USAGE: batch_id from ppsspp_batch_step(background=true); omit batch_id for survey/list mode (e.g. to recover a lost batch_id or audit background activity before touching the session).

BEHAVIOR: Lock-free registry read — never opens the WS transport and never waits for the per-session lock, so it is safe to call while a background batch (or any other tool) owns the session. Executed-step count updates as steps complete; 'completed' carries the full foreground-shaped result. READ-ONLY.

RETURNS: with batch_id → {batch_id, session_id, status: queued|running|completed|failed|cancelled, executed, total, error, result, retention_jobs}; with batch_id omitted (survey) → {jobs: [{batch_id, session_id, status, executed, total, error, result_present}], retention_jobs} in submission order (finished jobs beyond retention are evicted and absent).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
batch_idNoJob id returned by ppsspp_batch_step(background=true). Omit to survey ALL retained jobs instead (list mode; recovers a batch_id after the submit response was lost).

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
jobsNoAll retained jobs, in submission order
errorNoError message if failed/cancelled (null when none; real runner emits null)
totalNoTotal steps in the batch
resultNoFinal ppsspp_batch_step-shaped response; present once the batch completed
statusNo'queued' / 'running' / 'completed' / 'failed' / 'cancelled' (protocol Tasks mapping: 'queued'→'working')
batch_idNoJob id
executedNoSteps executed so far
session_idNoSession the batch runs on
retention_jobsNoFinished-job retention window (in job count): finished jobs beyond the oldest this many are evicted and absent from jobs

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed12 schema fields changedv0.1.6
    • addedInput schema / properties / batch_id / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / batch_id / default
      Added value: +null
    • changedInput schema / properties / batch_id / description
      Previous value: -"Job id returned by ppsspp_batch_step(background=true)."New value: +"Job id returned by ppsspp_batch_step(background=true). Omit to survey ALL retained jobs instead (list mode; recovers a batch_id after the submit response was lost)."
    • removedInput schema / properties / batch_id / type
      Removed value: -"string"
    • removedInput schema / required
      Removed value: -[
      -  "batch_id"
      -]
    • addedOutput schema / $defs
      Added value: +{
      +  "BatchJobSummaryView": {
      +    "additionalProperties": false,
      +    "description": "One retained background batch job in the ppsspp_batch_list survey.",
      +    "properties": {
      +      "batch_id": {
      +        "description": "Job id (for ppsspp_batch_status / _cancel)",
      +        "title": "Batch Id",
      +        "type": "string"
      +      },
      +      "error": {
      +        "default": "",
      +        "description": "Error message if failed/cancelled",
      +        "title": "Error",
      +        "type": "string"
      +      },
      +      "executed": {
      +        "description": "Steps executed so far",
      +        "title": "Executed",
      +        "type": "integer"
      +      },
      +      "result_present": {
      +        "description": "Whether the final result is retained (true once completed; fetch it via ppsspp_batch_status)",
      +        "title": "Result Present",
      +        "type": "boolean"
      +      },
      +      "session_id": {
      +        "description": "Session the batch runs / ran on",
      +        "title": "Session Id",
      +        "type": "string"
      +      },
      +      "status": {
      +        "description": "'queued' / 'running' / 'completed' / 'failed' / 'cancelled' (protocol Tasks mapping: 'queued'→'working')",
      +        "title": "Status",
      +        "type": "string"
      +      },
      +      "total": {
      +        "description": "Total steps in the batch",
      +        "title": "Total",
      +        "type": "integer"
      +      }
      +    },
      +    "required": [
      +      "batch_id",
      +      "session_id",
      +      "status",
      +      "executed",
      +      "total",
      +      "result_present"
      +    ],
      +    "title": "BatchJobSummaryView",
      +    "type": "object"
      +  }
      +}
    • addedOutput schema / properties / error / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedOutput schema / properties / error / description
      Previous value: -"Error message if failed/cancelled"New value: +"Error message if failed/cancelled (null when none; real runner emits null)"
    • removedOutput schema / properties / error / type
      Removed value: -"string"
    • addedOutput schema / properties / jobs
      Added value: +{
      +  "description": "All retained jobs, in submission order",
      +  "items": {
      +    "$ref": "#/$defs/BatchJobSummaryView"
      +  },
      +  "title": "Jobs",
      +  "type": "array"
      +}
    • changedOutput schema / properties / retention_jobs / description
      Previous value: -"Finished-job retention window of the registry (in job count, not seconds): completed/failed/cancelled jobs beyond the oldest this many are evicted. Precursor of the protocol-level Task ttl."New value: +"Finished-job retention window (in job count): finished jobs beyond the oldest this many are evicted and absent from jobs"
    • removedOutput schema / required
      Removed value: -[
      -  "batch_id",
      -  "session_id",
      -  "status",
      -  "executed",
      -  "total",
      -  "error",
      -  "result",
      -  "retention_jobs"
      -]
  2. First observedv0.1.0

TDQS

A4.9/5.0
Behavior5/5

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

Annotations only declare the safety profile (readOnly/idempotent/non-destructive); the description goes further by explaining WHY it is safe — lock-free registry read, no WS transport, no per-session lock wait — which tells the agent it can be called concurrently with a batch owning the session. It also discloses eviction behavior (finished jobs beyond retention are absent).

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Four labeled sections (PURPOSE/USAGE/BEHAVIOR/RETURNS) with the most decision-relevant fact — what it does and that it is session-safe — front-loaded. Dense but every sentence carries operational information; no filler.

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?

Even though an output schema exists, the description supplies the concurrency/safety model and retention eviction caveat that an agent needs to call this correctly alongside a running batch. Nothing required for correct invocation is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% and the schema already documents the omit-to-survey semantics, so the baseline is 3. The description earns an extra point by tying each parameter mode to a distinct return shape (single job vs. jobs array in submission order), which is meaning the schema alone does not convey.

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 — 'poll the state and progress of a background batch job' — and immediately scopes it with 'without touching the session'. An agent can distinguish it from ppsspp_batch_step and ppsspp_batch_cancel purely from this line.

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 names where batch_id comes from (ppsspp_batch_step with background=true) and defines the no-argument survey/list mode with concrete use cases (recovering a lost batch_id, auditing background activity before touching the session). Both modes and their selection conditions are stated, not implied.

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