Skip to main content
Glama

ledger_upsert_task

Create or update a shared cross-agent task entry to track status, who has the ball, worktree ownership, branch, commit SHA, and next step in the session-bridge ledger.

Instructions

Create or update a task on the shared cross-agent ledger (~/.local/share/session-bridge/bridge.db & LEDGER.md). Tracks status, who has the ball ('claude', 'antigravity', 'codex', 'gemini', 'user', 'none'), worktree ownership, branch, commit SHA, and next step.

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": {
      "slug": "<slug>"
    },
    "name": "ledger_upsert_task"
  }
}

Input Schema

NameRequiredDescriptionDefault
slugYesShort unique task identifier (e.g. 'auth-refactor').
titleNoHuman-readable task title.
branchNoGit branch name.
pr_urlNoOptional pull request URL.
statusNoTask lifecycle state.
summaryNoConcise summary of current state / what was done.
worktreeNoAbsolute path to the git worktree (warns on active collision).
ball_withNoWho owns the next action ('claude', 'antigravity', 'codex', 'gemini', 'user', 'none').
next_stepNoConcrete next step for whoever has the ball.
commit_shaNoLatest commit SHA.
updated_byNoAgent + session ID making this update.
owner_sessionNoSession/conversation ID currently holding the worktree.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.9/5.0
Behavior2/5

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

With no annotations, the description carries the full behavioral burden. It does disclose the dual-write target (SQLite DB plus LEDGER.md), but it omits the single most consequential behavior for an upsert: whether unspecified fields are preserved or cleared, since only 'slug' is required. Nothing about concurrency between agents, file locking, permissions, or what happens when a slug does not yet exist.

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?

Two sentences, no padding, with the verb and storage location front-loaded. The tracked-field list is dense but useful as a scannable inventory. Slight redundancy in re-listing the ball_with enum values that already appear in the schema.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 12-parameter coordination tool with no annotations and no output schema, the definition covers identity, storage, and tracked fields adequately. It falls short on partial-update semantics, concurrency/ownership conflict behavior, and any indication of what is returned or how errors surface — all relevant for a cross-agent shared-state mutation.

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 every one of the 12 parameters is already documented in the schema, including the 'worktree warns on active collision' note and both enum value sets. The description mostly restates those fields and repeats the ball_with enum, adding no syntax, format, or precedence rules beyond what the schema provides. Baseline 3 applies when the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Names a specific verb (create or update) and resource (a task on the shared cross-agent ledger), plus concrete storage locations (~/.local/share/session-bridge/bridge.db and LEDGER.md) and the fields it carries. An agent knows exactly what this does; the only gap is that it never names ledger_list_tasks as the read counterpart, so sibling differentiation is left implicit.

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

Usage Guidelines2/5

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

There is no explicit when-to-use or when-not guidance and no reference to any alternative tool. The word 'upsert' implies that it handles both creation and updates, but nothing tells an agent whether to prefer this over ledger_list_tasks when checking state or how this participates in a handoff workflow with bridge_send_message.

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