Skip to main content
Glama

Answer With Cited Sources

library_answer
Read-only

Ask a plain-English question and receive a synthesized answer with inline citations, fused across multiple library sources. Every factual claim is cited or dropped, with warnings for uncited content.

Instructions

Ask a question in plain English and get a synthesized answer with inline [n] citations, fused across sources with reciprocal rank fusion. Use this instead of library_ask when you want a cited answer rather than raw results. Every factual sentence is cited or dropped; an uncited or all-dropped answer is flagged in warnings[]. Requires OPENAI_API_KEY (or ALEXANDRIA_SYNTH_API_KEY). Set response_format: "detailed" for the full result set, routing, citation grades, and resolvability.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesNatural language question
read_topNoHow many top full-text results to read and cite (default 4)
max_sourcesNoMax number of sources to search (default 6)
response_formatNoconcise (default) trims results/citations to high-signal fields; detailed returns the full payload, including routing reasons, scores, and stage diagnostics.concise
results_per_sourceNoResults to fetch per source (default 5)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
answerYes
resultsNo
routingNo
warningsNo
citationsYes

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv11.0.0

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already mark it read-only/open-world; the description adds genuine behavioral detail: 'Every factual sentence is cited or dropped', warnings[] flagging, 'fused across sources with reciprocal rank fusion', and the required API key. These are not visible in annotations or schema.

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?

Purpose and sibling routing are front-loaded, and each subsequent sentence adds distinct information: citation behavior, warning flags, auth requirement, and response_format variant. No filler.

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

Completeness5/5

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

With an output schema present, return structure does not need description. The description covers purpose, when-to-use, safety/behavior, auth prerequisites, and the detailed variant, leaving no critical gap for an agent deciding to call this tool.

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 covers 100% of the 5 params, so the baseline is 3. The description enriches two critical params: query is framed as 'plain English', and response_format:'detailed' is tied to specific outputs (routing, citation grades, resolvability).

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?

States the exact operation: 'Ask a question in plain English and get a synthesized answer with inline [n] citations'. The sentence 'Use this instead of library_ask when you want a cited answer rather than raw results' explicitly differentiates it from the closest sibling, so an agent can select it without opening schemas.

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

Usage Guidelines5/5

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

Names the alternative 'library_ask' and the condition that selects it ('when you want a cited answer rather than raw results'). Also gives a conditional usage branch: 'Set response_format: "detailed" for the full result set, routing, citation grades, and resolvability.'

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

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/The-40-Thieves/alexandria-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server