Skip to main content
Glama

aiworkhub_dashboard_terminal_log_usage_backfill

USER WRITE: idempotently backfill missing provider usage receipts from retained terminal stdout logs.

Instructions

USER WRITE: idempotently backfill missing provider usage receipts from retained terminal stdout logs.

Use this before aiworkhub_dashboard_terminal_log_quarantine when terminal runs remain protected due to missing usage capture receipts; use aiworkhub_dashboard_terminal_log_retention_preview to inspect protected runs first. Requires confirm=True, parses retained worker stdout logs without estimating tokens or cost, appends canonical usage capture events to the task store, and leaves already-captured runs unchanged.

Input Schema

NameRequiredDescriptionDefault
confirmNobool (default False); must be True to scan terminal logs and append usage capture events.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.12.62
    • addedInput schema / properties / confirm / description
      Added value: +"bool (default False); must be True to scan terminal logs and append usage capture events."
  2. First observedv0.1.0

TDQS

A4.6/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 declares the write is idempotent, that confirm=True is required, that it reads retained stdout without estimating tokens or cost, that it appends canonical usage capture events, and that already-captured runs are untouched. It stops short of failure modes (no logs present, partial scan) or any permission/rate context.

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?

Two tight sentences with the operation class and idempotency front-loaded, then routing guidance, then side effects. No filler and nothing important buried.

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 mutating backfill tool with an output schema already covering return values, the description covers purpose, gate, side effects, and idempotency. Minor residual gap: what happens when no qualifying logs exist or how partial/failed backfills leave the task store.

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% for the single 'confirm' parameter, so baseline is 3; the description adds the consequence of the flag ('Requires confirm=True' gating a log scan plus event append), reinforcing what the parameter unlocks rather than just restating it.

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 ('idempotently backfill missing provider usage receipts from retained terminal stdout logs') and labels the operation class up front with 'USER WRITE'. An agent can distinguish it from quarantine/restore/purge siblings without opening the 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?

Explicitly names the sibling it must precede ('Use this before aiworkhub_dashboard_terminal_log_quarantine when terminal runs remain protected due to missing usage capture receipts') and names the read-only alternative to inspect state first ('retention_preview'). The triggering condition is spelled out, not inferred.

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