Skip to main content
Glama

Load a persona

get_agent_context

Load an explicitly chosen agent or a ROUTE_REQUIRED selection. Pass protocol_version=2 and current_persona. The same active agent returns NO_CHANGE without enrichment.

Instructions

Load an explicitly chosen agent or a ROUTE_REQUIRED selection.
Pass protocol_version=2 and current_persona. The same active agent
returns NO_CHANGE without enrichment. Use force_reload=True to restore lost
instructions; use refresh_persona_context to refresh the same role's skills.
SUCCESS contains separate blocks and a descriptor; apply only when its
replaces_activation_id matches your current activation. Preserve the dialogue.
Pass workspace, your working directory: the first SUCCESS or NO_CHANGE of this
session in a workspace carries its repository context in repo_context, and a
workspace outside this session's grant carries the workspace_mismatch report there
instead of a description.

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": {
      "agent_name": "<agent_name>",
      "query": "<query>"
    },
    "name": "get_agent_context"
  }
}

Input Schema

NameRequiredDescriptionDefault
queryYesThe user request the role is loaded for.
reasoningNoWhy this agent was chosen.Selected by calling LLM
workspaceNoAbsolute path of your working directory, the project this session works in. Pass it whenever you have one. It never widens this session's grant: over HTTP the workspace registered for the connection decides, and over stdio it is checked against the client's own MCP roots unless this session's root is already pinned, when it is ignored. Each tool's description says what it does with a path that grant does not cover.
agent_nameYesCanonical name of the agent to load.
chat_historyNoOptional relevant earlier conversation facts, as a JSON array of strings.
force_reloadNoTrue to restore lost instructions of the same agent.
current_personaNoThe `persona` object of the last SUCCESS/NO_CHANGE, copied verbatim; omit or null on first activation. All 7 keys: agent, activation_id, bundle_revision (64 hex characters), scope, skills_loaded, implants_loaded, rules_loaded.
protocol_versionNoPersona protocol version; always 2.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv26.10.18
    • addedInput schema / properties / workspace
      Added value: +{
      +  "default": null,
      +  "description": "Absolute path of your working directory, the project this session works in. Pass it whenever you have one. It never widens this session's grant: over HTTP the workspace registered for the connection decides, and over stdio it is checked against the client's own MCP roots unless this session's root is already pinned, when it is ignored. Each tool's description says what it does with a path that grant does not cover.",
      +  "title": "Workspace",
      +  "type": "string"
      +}
  2. First observedv26.10.14+1807

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations (readOnlyHint=false, destructiveHint=false, idempotentHint=false), the description discloses the no-op path (same active agent returns NO_CHANGE without enrichment), the conditional apply rule (only when replaces_activation_id matches the current activation), and the session-level workspace effects (repo_context on first SUCCESS/NO_CHANGE, workspace_mismatch when outside the grant). These are exactly the non-obvious behaviors an agent cannot infer from structured fields.

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?

Purpose is front-loaded and every sentence carries operational content — NO_CHANGE, force_reload, the replaces_activation_id gate, workspace effects. It is dense and telegraphic rather than verbose, though the mid-sentence line breaks and jargon (ROUTE_REQUIRED, descriptor) make it slightly harder to scan than it needs to be.

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 an 8-parameter tool with a nested persona object and an output schema, the description covers the critical edges: success application gating, the no-op case, instruction recovery, the refresh alternative, and workspace/grant reporting. Nothing an agent needs in order to call it safely 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%, so the baseline is 3; the description still adds real meaning by pinning protocol_version to 2, requiring current_persona to be the verbatim persona object from the last SUCCESS/NO_CHANGE, and explaining what workspace does to repo_context and mismatch reporting. The unexplained 'ROUTE_REQUIRED selection' phrasing is the only semantic it leaves opaque.

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 opening sentence gives a specific verb and resource ('Load an explicitly chosen agent') and immediately narrows the resource to two cases, explicitly-chosen or ROUTE_REQUIRED. It also names one sibling it is not (refresh_persona_context), so the agent can separate loading from refreshing without opening either schema.

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 states concrete triggering conditions: pass protocol_version=2 and current_persona, use force_reload=True to restore lost instructions, and use refresh_persona_context instead when only the same role's skills need refreshing. It does not give an explicit when-not rule for the load path itself (e.g. versus a route-and-load flow), so it falls slightly short of full routing guidance.

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