Skip to main content
Glama

aide_observer_end_session

Marks an approved observer session as ended after a HALT prompt, without deleting logs; later reports are flagged, and observation restarts through the observer start action.

Instructions

End another open session of this project, only after the user has approved it. Use it when aide_observer_start answers HALT and the user chooses to end the session it names: pass sessionId exactly as the HALT line gave it — an observer session id, or the Claude session id of a session that never reported (written claude:<id> in the HALT; pass the id without the claude: prefix). Ending only writes a mark that the session has ended: it deletes no log, presence or project file. A later report from the ended session is still recorded and flagged as previously ended; the session reopens only through aide_observer_start, and only while it is the project's most recent session. It never ends the caller's own session, nor an earlier session of the caller's own conversation. Replies are one line: ended <id>, already ended <id> (also for a session whose transcript shows it closed, which gets a transcript mark), refused: <id> is this session, refused: no session <id> in this project, refused: invalid session id, or not ended (<reason>) when the disk could not be written. After ended, call aide_observer_start again.

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": {
      "sessionId": "<sessionId>"
    },
    "name": "aide_observer_end_session"
  }
}

Input Schema

NameRequiredDescriptionDefault
sessionIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.17.1

TDQS

A4.9/5.0
Behavior5/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 so: it discloses that ending only writes a mark and deletes no log/presence/project file, that late reports are still recorded and flagged, and the narrow condition under which a session reopens. It also enumerates every reply line including refusal and disk-failure cases.

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?

Front-loaded with purpose, then usage, then side effects, then reply codes — no filler sentences. It is dense as a single block and the reply enumeration is long, but every clause is load-bearing for correct invocation and response parsing.

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?

For a one-parameter mutation tool with no output schema, the description covers prerequisites, side effects, re-entry semantics, and all terminal reply strings, including the failure path (`not ended (<reason>)`). Nothing needed to call it correctly or interpret its result is missing.

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

Parameters5/5

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

Schema coverage is 0% and the single parameter has no schema description, yet the description explains exactly what to pass: the id verbatim from the HALT line, either an observer session id or a Claude session id with the `claude:` prefix stripped. That is meaning the schema cannot supply.

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?

Opens with a specific verb and resource ("End another open session of this project") and immediately scopes it to sessions other than the caller's own, which separates it from aide_observer_start and aide_observer_event without requiring a schema read.

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?

Gives an explicit trigger (aide_observer_start answered HALT and the user approved ending), explicit exclusions (never the caller's own session, never an earlier session of the caller's own conversation), and an explicit next step (call aide_observer_start again after `ended`). No alternative tool is left to inference.

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