Skip to main content
Glama

ecosystem_apply_shallow_summary

Writes back a Stage 0 shallow summary or reports a classified failure, letting AI Team OS update review status, retry, or feed its learning loop.

Instructions

Stage 0 worker callback: write back a shallow summary OR report a failure.

Success path (default): pass shallow_summary (200-400 char Chinese markdown) and deep_review_id; the OS will persist the summary, advance stage_status -> shallow_done, and mark the deep_review row as completed.

Failure path: leave shallow_summary empty and pass error_kind, which routes the failure through the §3.1 classifier so the OS can decide whether to immediate-retry, mark deleted/private, or feed the self-learning loop. Valid error_kind values: http / agent_read / agent_timeout / json_parse / fetch_style.

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": {
      "repo_id": "<repo_id>"
    },
    "name": "ecosystem_apply_shallow_summary"
  }
}

Input Schema

NameRequiredDescriptionDefault
repo_idYesEcosystemRepoProfile.id.
error_kindNofailure category hint (failure path only).
http_statusNoHTTP status code when error_kind='http'.
error_messageNoshort message stored in profile.last_fetch_error.
deep_review_idNoassociated deep_review row id (Stage 0 dispatch).
shallow_summaryNoa 200-400-word English markdown summary (success path).
rate_limit_remainingNowhen http_status=403, ``0`` indicates rate-limit.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.11.2

TDQS

A4.3/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 behavioral burden and does well: it discloses side effects (persisting the summary, advancing stage_status to shallow_done, marking the deep_review row completed) and the failure routing through the §3.1 classifier to immediate-retry, deleted/private, or the self-learning loop. Remaining gaps are idempotency (what happens on a duplicate callback) and whether the repo must first be claimed via ecosystem_claim_shallow.

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?

Well structured with success and failure paths front-loaded and labeled, so an agent can scan to the relevant branch. It is slightly verbose and leans on internal shorthand ('§3.1 classifier', 'the OS') that adds assumed context, but no sentence is pure filler.

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?

For a 7-parameter mutation callback with an output schema (so return values need no explanation), the description covers both modes, the error taxonomy, and downstream state changes. It falls short only on preconditions such as claim ownership and duplicate-callback behavior, plus the char-vs-word format conflict.

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%, so the baseline would be 3, but the description adds real meaning the schema lacks: it enumerates the valid error_kind values (http / agent_read / agent_timeout / json_parse / fetch_style), which the schema does not bound with an enum, and it explains the coupling of shallow_summary with deep_review_id. One blemish is an inconsistency with the schema: the description specifies '200-400 char Chinese markdown' while the schema says '200-400-word English markdown', leaving the format genuinely ambiguous.

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?

The definition opens with a specific verb+resource framing: 'Stage 0 worker callback: write back a shallow summary OR report a failure.' That immediately distinguishes it from claim/queue-status siblings such as ecosystem_claim_shallow and ecosystem_shallow_queue_status by making clear this is the write-back endpoint of the Stage 0 lifecycle.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

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

It gives explicit branching guidance: the 'success path (default)' requires shallow_summary plus deep_review_id, and the 'failure path' requires leaving shallow_summary empty and passing error_kind. That is strong when-to-use-each-mode guidance, though it names no alternative tool for cases where the worker should instead release or cancel its claim.

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