Skip to main content
Glama

arsenal_get_snippet

Extract clean, runnable code snippets from a GitHub repository README without downloading the full file, reducing token use and giving AI agents ready-to-run examples.

Instructions

Extract clean, runnable code snippets directly from any GitHub repo README without downloading the whole README (saves 85% tokens).

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": {
      "repo": "<repo>"
    },
    "name": "arsenal_get_snippet"
  }
}

Input Schema

NameRequiredDescriptionDefault
repoYes
max_blocksNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv6.5.1

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden. It discloses one useful trait — that the full README is not fetched, saving roughly 85% tokens — but says nothing about authentication for private repos, rate limits, behavior when a README has no code blocks, or what 'clean, runnable' filtering actually strips out.

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?

A single front-loaded sentence with the core action first and the token-savings rationale in parentheses. Nothing is wasted, though the value proposition is the only extra detail carried.

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?

This is a simple two-parameter read tool with no output schema, and the description adequately conveys what comes back (code snippets) and the main benefit. The notable hole is the undocumented max_blocks parameter and repo string format, which keeps it just short of complete.

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

Parameters2/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 not. The word 'repo' implies the repo parameter exists but never states the expected format (owner/name vs. URL), and the max_blocks parameter is not mentioned at all, leaving an agent unaware that output size can be capped.

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 a specific verb and resource: 'Extract clean, runnable code snippets directly from any GitHub repo README.' An agent immediately knows the input (a GitHub repo) and the output (code snippets). It does not, however, distinguish itself from look-alike siblings such as arsenal_inspect_repo or arsenal_pull_repo, so an agent must infer the boundary.

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?

There is no explicit when-to-use or when-not-to-use guidance and no named alternative. The token-savings parenthetical hints at a scenario (you want README code without the full README), but the agent is left to infer that context rather than being told it directly.

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