Skip to main content
Glama

get_context

Retrieve source files for a feature or route to understand real field names, API endpoints, and component structure before writing precise test steps.

Instructions

Retrieve the most relevant source files for a given feature or route. Returns actual source code (budget-capped) so you understand real field names, API endpoints, and component structure before writing test steps. Call this after scan_codebase when you want to write precise test scenarios for a specific feature — it eliminates guesswork about selectors and form fields.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
featureYesFeature name or route path to retrieve context for (e.g. "login", "checkout", "/dashboard").
max_filesNoMax source files to return (default 5, max 8).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior2/5

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

No annotations are provided, so the description must carry the full behavioral burden. It mentions that output is budget-capped, which is a limitation, but it doesn't disclose whether the operation is read-only, if it has side effects, or how errors are handled. Since it retrieves data, the read-only nature is implied but not stated. This is a significant gap for a tool with zero annotation coverage.

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?

The description is two sentences with no filler. It front-loads the core purpose and then adds usage guidance. It is concise and structured effectively, though slightly longer than strictly necessary, it earns its length.

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?

There is no output schema, so the description should explain what the tool returns. It says 'Returns actual source code' but doesn't specify the format (e.g., list of files with content, metadata) or how budget-capping affects the output. Error behavior and edge cases (e.g., feature not found) are not covered. For a moderately simple tool, this is acceptable but leaves some ambiguity.

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 description coverage is 100%, and both parameters are well-documented in the schema. The description adds no extra semantic detail about the parameters themselves; it only contextualizes the return value. With full schema coverage, a baseline of 3 is appropriate.

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 description clearly states the action (retrieve) and the resource (source files for a given feature or route). It explicitly says it returns actual source code to understand field names, endpoints, and structure, which distinguishes it from siblings like scan_codebase or scan_page_elements by focusing on a specific feature.

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?

The description explicitly instructs to call this after scan_codebase and when writing precise test scenarios for a specific feature. It provides a clear usage condition and rationale, though it doesn't explicitly name alternative tools for different use cases. The context is sufficient for an agent to decide when to invoke it.

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