Skip to main content
Glama

engineering_context_tool

Assembles relevant engineering context by matching tags, scoring and sorting memories, and applying token budget truncation while never dropping conflicts or warnings.

Instructions

Assemble engineering context with output ordering.

Pipeline: tag match -> score -> sort -> truncate -> serialize. Conflicts and warnings are NEVER dropped for budget.

Args: tags: Tags to match against task: Optional task description (shown in output header) token_budget: Optional token budget for truncation types: Filter by memory types include_stale: Whether to include potentially stale items current_task: Description of what you're working on right now. Boosts scoring for memories relevant to this task. paths: Filter items whose evidence matches these file paths project: Optional project root path. Auto-detected from git root if omitted.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagsYes
taskNo
pathsNo
typesNo
projectNo
current_taskNo
token_budgetNo
include_staleNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.5.1
    • addedInput schema / properties / paths
      Added value: +{
      +  "anyOf": [
      +    {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Paths"
      +}
  2. First observedv0.1.0

TDQS

B3.3/5.0
Behavior3/5

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

The description reveals a read-like operation through its pipeline (match, score, sort, truncate) and explicitly states that conflicts and warnings are never dropped for budget, which is a notable behavior. However, it does not mention side effects, whether it modifies any state, or what happens on errors, and the absence of annotations places the burden on the description.

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?

The description is brief and to the point, containing a concise pipeline overview and parameter explanations. It avoids redundant elaboration and front-loads the core behavior, making it easy to scan.

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

Completeness2/5

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

The description omits critical information about the output format (e.g., what 'serialize' returns, the structure of results) and does not mention error handling or edge cases. An agent may be unsure what to expect from the tool beyond a generic 'context' assembly, limiting complete usability.

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?

Each parameter is described in the prose listing (e.g., 'tags: Tags to match against', 'include_stale: Whether to include potentially stale items'), which adds clarity beyond the bare schema. Some descriptions are terse (e.g., 'types' and 'paths' lack further detail), but they are generally understandable in context.

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?

The description states the tool's purpose as 'Assemble engineering context with output ordering' and hints at a processing pipeline, which conveys its primary function. However, it does not explicitly define what 'engineering context' covers (e.g., memories, decisions, bugs), relying partly on sibling tool names for context.

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?

The description provides no guidance on when to use this tool instead of alternatives like memory_search_tool or memory_recent_tool. It does not mention use cases, suitability, or comparisons, leaving the agent to infer when this tool is the right choice.

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