Your Gemini Answer Has Citations. Is It Actually Grounded?
Adding citations to an AI answer feels like the moment the system becomes trustworthy. The response looks researched. Source links appear beside the text. The model is no longer answering only from its training data. But a cited answer can still be wrong. A citation may support a nearby sentence rather than the claim the user cares about. A source may be authoritative while the retrieved passage…
Citations in AI responses act as trust indicators, but they can still be misleading. A cited passage might support a sentence unrelated to the claim being made. An authoritative source can yield outdated information. Search queries may target the incorrect storage location or document version. Even with good evidence, the model may draw conclusions beyond the evidence itself.
Grounding is a valuable skill, but trust also depends on an explicit application contract. The Interactions API provides transparency through execution steps and citation annotations. A basic Google Search interaction might look like this:
```javascript
import { GoogleGenAI } from '@google/genai';
const ai = new GoogleGenAI({});
const interaction = await ai.interactions.create({
model: process.env.GEMINI_MODEL ?? 'gemini-3.8-flash',
input: 'What changed in the public policy this week?',
tools: [{ type: 'google_search' }],
});
```
Parsing the response reveals the search citations with their title, URL, and the cited text. The JavaScript code iterates through the interaction's steps, identifying non-text content blocks and extracting the URL citations that annotate the text blocks. The captured citations follow the current JavaScript schema, containing optional title, URL, and citedText properties in the SDK.
Applications can enforce evidence policies by defining contract rules before generating responses. For example, requiring at least two citations, limiting to web sources, and treating missing evidence as a suppression failure. The contract enforces that the grounding tool executed, the right sources and filters applied, and that the answer received the appropriate failure handling when evidence was insufficient.
However, semantic entailment still requires human review to distinguish between what the system can prove and what it only hopes to be true.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.