Skip to main content
Glama

verify_citation

Verifies that a citation is exactly present in the cited document, detecting altered, stitched, or misquoted passages. Use it before asserting a source claims something.

Instructions

Vérifie qu'une citation se trouve vraiment dans le document qu'elle nomme.

À utiliser avant d'affirmer qu'un document dit quelque chose, et surtout quand la citation vient d'ailleurs que d'un passage servi à l'instant : d'une note prise plus tôt, d'un résumé, d'une réponse antérieure. Une citation recopiée de travers, recollée à partir de deux endroits ou reformulée reste plausible à la lecture — c'est précisément ce que cet outil détecte, et rien d'autre ne le détecte.

La vérification est déterministe : aucune génération, aucun modèle de langue. La citation est normalisée (ligatures, <sup>/<sub>, tirets, guillemets, blancs, casse) puis cherchée dans le texte canonique du document, celui dont le sha256 est servi par la ligne « ancre : ».

Ce que rend l'outil :

  • trouve — vrai seulement pour une correspondance exacte après normalisation. Une citation dont un seul mot diffère rend false. Mesuré : 50 extraits réels sur 50 retrouvés, 0 accepté sur 50 extraits altérés d'un mot.

  • offsets — la position [début, fin] dans le texte canonique, opposable.

  • plus_proche — quand c'est faux : le passage le plus ressemblant, sa ressemblance et le nombre de mots qui diffèrent. C'est ce qui dit où la citation a dérivé.

  • source — texte canonique, ou texte servi pour les 5 914 tableaux dont le rendu Markdown n'est pas une sous-chaîne du document.

Args: document_id: la clé interne du document, servie par la ligne « interne : ». quote: le texte cité, tel qu'on s'apprête à l'affirmer. Une phrase ou deux suffisent ; au-delà d'un paragraphe, une reformulation invisible fera échouer la vérification pour une raison sans rapport avec l'honnêteté de la citation. chunk_id: facultatif, restreint la recherche du repli « texte servi » à ce passage.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
quoteYes
chunk_idNo
document_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.4.0

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations provided, the description carries full responsibility and meets it thoroughly. It discloses that verification is deterministic (no generation), details the normalization process, specifies exact-match behavior after normalization, provides measured accuracy (50/50 and 0/50), and explains the fallback for tables ('texte servi'). It also warns about quote length limits. This is exceptionally transparent.

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 long but every paragraph earns its place: the main purpose, the deterministic behavior, the return fields, and parameter explanations. It is front-loaded with the core action and structured with bullet points for return values. It could be trimmed slightly (e.g., the measurement anecdote), but overall it's appropriately sized for the complexity.

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?

Given the tool's complexity, the description is complete: it explains the return fields (trouve, offsets, plus_proche, source), the source lines referenced, the fallback behavior, and parameter nuances. It also addresses edge cases like long quotes and the 5,914 tables. An agent has everything needed to invoke this correctly.

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

Parameters5/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 does. Each parameter is explained: document_id as 'la clé interne... servie par la ligne « interne : »', quote with guidance on length and phrasing, and chunk_id as optional with a clear purpose ('restreint la recherche du repli « texte servi »'). This adds meaning far beyond the bare schema.

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 states a specific verb ('Vérifie') and resource ('qu'une citation se trouve dans le document qu'elle nomme'), making the tool's function unmistakable. It also contrasts with the sibling tool 'verify_citations' (plural) by emphasizing it checks exact presence, not just similarity. This is a clear, distinguishing statement.

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 tells when to use the tool: 'À utiliser avant d'affirmer qu'un document dit quelque chose' and especially when the citation comes from somewhere other than the current passage. It also claims 'rien d'autre ne le détecte', effectively routing the agent to this tool. However, it does not explicitly mention alternatives or when NOT to use it, only these strong directives. This is clear context without a full exclusion statement.

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