Skip to main content
Glama

Get feature

get_feat

Read and parse a full feature document by ID, including frontmatter and body, or return the raw body text with optional line offset, limit, and numbering.

Instructions

Read, parse, and return a full feature document (frontmatter and body) by its id. Pass raw=True to return the frontmatter-stripped body text verbatim instead. With raw=True, optional read-style offset/limit window the raw read: offset (1-based, default 1) is the first body line to return, limit (line count, default through end of body) how many; out-of-range values clamp (offset > N returns the empty string), and coordinates with raw=False raise ValueError. A document that exists but fails to parse returns a ParseFailureResult (error/path/id) instead of raising; get_feat always fully parses, so its error text is the full-fidelity authority for this document -- byte-identical to list_feat's own failed-row error for the same file once list_feat's background warmup (or this very call) has fully parsed it; before that (or under SPECMGR_FEAT_WARMUP_DISABLED), list_feat's row may carry a transiently-healthy or dirty-stage-specific error instead (ADR 3982712a-a46b-4b2b-809f-9c6925a49b44, time-qualifying ADR 9080b37c-82b3-4f63-81f1-79641d0bf14c for feat only; every other domain's list/get error byte-identity stays unconditional). An invalid id (path-injection attempt or wrong format) is also a ValueError, raised before any file access. With raw=True, an optional numbered=True prefixes every returned body line with its 1-based absolute body-line number in the "<n>: " form (plain decimal, no padding) -- under offset/limit windowing the numbers start at the clamped offset and never restart at 1, so a number seen in the output can be fed straight back into the generic update tool's offset. numbered is meaningful only with raw=True: combining it with raw=False raises ValueError (like offset/limit), and a numbered read of a document that fails to parse returns the ParseFailureResult described above, never numbered text. Numbered output must never be fed back verbatim into content for update or create_feat -- strip the "<n>: " prefix from each line first (it is likewise never a valid edit old_str).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYes
rawNo
limitNo
offsetNo
numberedNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.36.0

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations provided, the description carries the full behavioral burden and does add substantive context: parse failures return a ParseFailureResult rather than raising, invalid ids raise ValueError before file access, out-of-range offset/limit clamp, and conflicting parameters raise ValueError. The dense ADR cross-references and warmup-qualification discussion (ADR 3982712a, ADR 9080b37c) are far more detail than any agent needs and dilute the useful signal, keeping it from a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The core content is front-loaded correctly (purpose and raw mode first), but the middle section balloons with ADR identifiers, warmup timing, and byte-identity qualifiers that serve maintainers rather than an agent selecting or invoking the tool. Substantial trimming would preserve all actionable information.

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

Completeness4/5

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

For a 5-param read tool with an output schema (so return values need not be re-explained), the description covers modes, parameter interactions, failure modes, and cross-tool round-tripping warnings adequately. The completeness is undermined only by the inclusion of internal ADR/warmup detail that doesn't help an agent call the tool correctly.

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 description coverage is 0%, so the description must compensate, and it largely does: it explains raw, offset/limit semantics (1-based, defaults, clamping, interaction with raw=False), and numbered (line-number prefix format, offset-relative numbering, only valid with raw=True). The only required param, id, gets modest treatment (described mainly via its ValueError failure modes), leaving a small gap that prevents a 5.

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?

States a specific verb+resource: read, parse, and return a full feature document (frontmatter and body) by id, plus the raw=True variant returning the frontmatter-stripped body verbatim. It's clear what the tool does, but it doesn't distinguish itself from sibling getter tools like parse_feat or list_feat beyond the incidental listing of list_feat's error behavior, so it falls short of a 5.

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

Usage Guidelines3/5

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

Usage is implied through mode/parameter descriptions (use raw=True for verbatim body, offset/limit for windowing, numbered=True for line numbers) rather than explicit when-to-use/when-not guidance. The description repeatedly names alternatives (list_feat, update, create_feat, edit) but mostly as caveats about error text or round-tripping, not as routing guidance for choosing this tool over parse_feat or list_feat.

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