Skip to main content
Glama

ai_qa

Read-only

AI answer-from-context (RAG) — Answer a question using only the context text you supply; returns grounded=false instead of guessing when the answer is not there. Pass ?question= and ?context=. Price: $0.008 USDC (Base, via x402).

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": {
      "question": "<question>",
      "context": "<context>"
    },
    "name": "ai_qa"
  }
}

Input Schema

NameRequiredDescriptionDefault
contextYesthe text to answer from (up to 12000 chars)
questionYesthe question

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, destructiveHint=false and openWorldHint, so the safety profile is covered. The description adds genuinely useful behavior beyond that: it returns grounded=false rather than guessing, and it discloses a per-call price ($0.008 USDC via x402 on Base), which is critical operational context for a paid endpoint.

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?

Three tight sentences, front-loaded with the core purpose before the fallback behavior and price. The '?question= and ?context=' sentence is slightly redundant with a 100%-covered schema but still earn its place for a GET/x402 endpoint.

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 two-parameter, read-only tool with no output schema, the description covers purpose, failure semantics, input convention, and cost. Only the shape of a successful answer (field names beyond grounded) is left implicit, a minor gap given the simplicity.

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 the context parameter already documents its 12000-char limit. The description adds only the query-string passing convention ('Pass ?question= and ?context='), which is marginal value over the schema, so the baseline 3 is appropriate.

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 and resource: 'Answer a question using only the context text you supply', with the parenthetical RAG label clarifying the mechanism. The phrase 'using only the context text' implicitly separates it from sibling ai_chat, but no sibling is named explicitly, so it falls short of full differentiation.

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 use case is clear: grounded question answering when you have source text and want to avoid hallucination. It does not state exclusions or name an alternative (e.g., ai_chat for open-domain questions), which keeps it below a 5.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources