Back to Blog

How AI Systems Select and Cite Content: The RAG Pipeline

Written by Andrei Muresan

Published May 22, 202615 min read
How AI systems retrieve, rank, and cite web content

The invisible selection

A RAG pipeline is a retrieval augmented generation architecture that combines traditional information retrieval with generative language models. It retrieves passages from an index, scores them for semantic similarity, reranks candidates, and synthesizes answers with citations.

You type a question into Perplexity, and four seconds later, a paragraph appears with six numbered citations, each linking to a different source. The answer reads as though someone read all six articles and distilled them into three clean sentences.

Guess what? Nobody did.

What happened in those four seconds is a retrieval pipeline. It scanned an index of billions of web pages, converted your question into a mathematical vector, scored hundreds of candidate passages against it, reranked the survivors for precision and extractability, assembled the top results into a prompt, and generated a synthesized answer constrained by the retrieved evidence.

Your page was either selected, or it wasn’t, as most content never enters the frame.

Content is selected for AI systems through retrieval augmented generation (RAG) pipelines, architectures that combine traditional information retrieval with generative language models. These systems don’t rank pages the way traditional search engines do. Instead, they retrieve passages, score them for semantic similarity and factual density, rerank candidates using neural scoring models, and synthesize answers from the highest-scoring fragments with citations attached.

The mechanics behind this process determine which businesses appear in AI-generated answers and which remain invisible, regardless of how well their content performs in traditional search.

This is what generative engine optimization aims to do. We have defined the term "generative engine optimization" and explained its importance in our previous article on the same topic. This blog is an attempt to expose the inner workings of the machine.

Needless to say, AI systems are reshaping search. To clearly see the extent, Ahrefs published a study in 2025 that revealed that AI overviews appear in 54% of Google searches by volume. In the next sections, we’ll show how the selection process works and what it demands of content.

How the machine reads

The architecture behind AI answer engines follows a consistent pattern regardless of provider. Lewis et al. introduced the retrieval augmented generation framework at NeurIPS in 2020, combining a pretrained language model with access to an external data source through a neural retriever.

The model they described, where parametric memory (the language model) is augmented by nonparametric memory (a searchable index of documents), established the blueprint that every major AI search system now follows. Gao et al. documented this evolution in their comprehensive 2023 survey, tracing how RAG shifted from a pretraining technique to an inference-time architecture that lets systems ground their outputs in retrieved evidence.

The pipeline works in stages. 

In the first stage, documents are broken into passages and converted to vector embeddings, numerical representations that capture semantic meaning in high-dimensional space. When a query arrives, it is embedded in the same vector space, and the system retrieves the passages with the highest cosine similarity.

Google Cloud’s RAG documentation describes this as using “vector databases to efficiently retrieve relevant documents” through “semantic search and keyword search together (called hybrid search), and a re-ranker which scores search results to ensure the top returned results are the most relevant”. Microsoft’s Azure OpenAI implementation follows the same pattern, chunking documents and retrieving them based on semantic proximity to the query.

During the second stage, the reranking takes place, and it’s where the pipeline narrows most dramatically. After initial retrieval pulls hundreds of candidates, cross-encoder models score a shortened list for precision, evaluating each passage against the query with much higher accuracy than the initial embedding lookup, but at significantly higher computational cost. 

The surviving passages are assembled into a prompt, and the language model generates its answer constrained by the retrieved evidence.

From pages to passages

This architecture changes what it means for content to be found. While traditional search ranked whole pages, the AI retrieval scores passages. A page can rank first in Google and never be cited by an AI system if its individual passages are not extractable.

Liu et al. at Stanford demonstrated a related principle directly: language models show a U-shaped performance curve, using information most effectively when it appears at the beginning or end of a long context, and degrading significantly when relevant content sits in the middle. Position within a document matters architecturally, not just editorially.

We explored this evolution in one of our previous blogs, namely “Search Is Not Dying. It Is Becoming Something More Demanding”. What that blog framed philosophically, search as an increasingly intelligent filter, finds its technical mechanism here. The filter is a retrieval pipeline, and what it filters for is passage-level extractability, not page-level relevance.

What makes a passage worth citing

The Princeton GEO paper, published at KDD 2024, provided the first large-scale answer. Aggarwal et al. tested nine content optimization tactics across 10,000 queries on a system designed to replicate generative search behavior, then validated their findings on Perplexity.

Five tactics produced measurable citation rate increases of 30% to 41%. Four failed or made things worse. The tactics that worked are:

  1. Citing sources within the content

  2. Adding quotations from named authorities

  3. Adding statistics with clear attributions

  4. Optimizing for fluency

  5. Writing in an authoritative voice

The tactics that failed: keyword stuffing, simplifying language for readability, padding content for length, and using purely persuasive language.

The content practices most marketing teams default to (more keywords, simpler language, longer pages, stronger calls to action) are the ones the research says don't work in generative engines.

The AI pattern is quite precise, rewarding specificity, verifiability, and density. In parallel, they deprioritize volume, persuasion, and the keyword mechanics from the SEO era that many content strategies still revolve around.

Entity density as a citation signal

Entity density is the clearest single predictor. Digital Strategy Force’s eighteen-month testing program across major AI answer engines found that passages with high factual density (specific numbers, dates, named entities, and attributed claims) earned measurably higher citation rates than passages with equivalent topical relevance but lower density.

Presenc.ai’s analysis of Perplexity citation patterns in 2026 confirmed the same directional finding: pages with verifiable data points per paragraph were cited 2.2 times more frequently than pages with general qualitative statements. A paragraph that names a researcher, cites a specific year, and attributes a finding to a named publication is architecturally more citable than a paragraph that makes the same argument in general terms.

This is not a stylistic preference, but rather a function of how retrieval augmented generation pipelines extract and verify claims, a process that Hirsch et al. at ACL 2025 formalized as localized attribution, where AI systems map generated claims to specific spans in source documents at sub-sentence granularity.

We have written about why people ignore most marketing, exploring the filtering mechanisms that cause audiences to tune out undifferentiated content.

AI systems filter content for structurally similar reasons(e.g., low signal density gets filtered out before it reaches the synthesis stage).

Tactic

Citation impact

Mechanism

Citing sources

+30 to 40%

Enables verification and attribution

Adding statistics

+30 to 40%

Increases entity density and extractability

Quotation addition

+30 to 40%

Provides named, verifiable claims

Authoritative voice

+30 to 40%

Signals expertise and editorial confidence

Fluency optimization

+30 to 40%

Improves passage-level readability for extraction

Keyword stuffing

Negative

Degrades passage quality; detected as manipulation

Readability simplification

No effect

Strips the specificity retrieval systems reward

Content padding

Negative

Dilutes entity density across longer text

Persuasive language

No effect

Adds no verifiable information

The structured data layer

Structured data functions as a machine-readable trust signal. Schema markup in JSON-LD does not replace quality content, but it reduces the friction between a page and the AI system trying to parse it.

Google Search Central describes structured data as providing “explicit clues about the meaning of a page,” a standardized format for classifying page content that enables richer search results and helps machines understand what a page contains.

Schema.org, the vocabulary that underpins this markup, provides a shared language that both traditional search engines and AI systems use to interpret content. Google recommends JSON-LD as the preferred format for implementation, noting it is “the easiest solution for website owners to implement and maintain at scale”.

The evidence that structured data matters for AI citation is growing, though it should be read carefully. An analysis by ALM Corp reported that approximately 65% of pages cited by Google AI Mode included structured data markup, and roughly 71% of pages cited by ChatGPT carried some form of schema.

Stackmatix’s 2026 guide found that content with proper schema markup had a 2.5 times higher chance of appearing in AI-generated answers. These are directional signals from industry analyses, not controlled experiments, but the consistency across studies is notable.

The schema types with the clearest relevance to AI citation include Article, FAQPage, HowTo, Organization, and SpeakableSpecification. FAQPage schema is particularly effective because it formats content as question and answer pairs, exactly the structure that AI extraction systems are built to parse.

Answer first formatting

Beyond schema, answer first formatting serves a parallel function as AI Overviews average roughly 157 words. A concise, self-contained answer of 40 to 60 words placed immediately after an H2 heading that mirrors a common query phrasing creates the cleanest extraction target.

Google’s passage ranking system already identifies individual sections of a web page to assess relevance, and AI Overviews extend the same logic to synthesized answers.

This is the technical mechanism behind the trust argument we have explored on our blog: why SEO is really about trust, not keywords. As a conclusion, structured data and extractable formatting are how that trust is made legible to machines.

As we have previously found and highlighted on our blog, the businesses that rank best are the ones whose teaching is already structured in ways AI systems can parse: clear claims, named sources, and answer-first organization.

The divergence nobody planned for

However, AI systems don’t select content identically. ZipTie.dev has conducted a comparative analysis across platforms and found that only 11% of domains were cited by both ChatGPT and Perplexity for the same query, and 71% of all cited sources appeared on only one platform.

This information has been taken from a single industry report, and is therefore only indicative, not conclusive. However, this trend is similar to what practitioners see in engines.

The divergence is architectural, not random.

Three pipelines. Three selection criteria.

Google AI Overviews draw from Google’s own search index and Knowledge Graph, making them the most closely aligned with traditional ranking signals. Google’s ranking systems documentation describes passage ranking, neural matching, and link analysis systems that all feed into how individual sections of pages are evaluated. Structured data and Knowledge Graph alignment are primary determinants of inclusion in AI Overviews.

Perplexity runs a live web query for every prompt using a six-stage RAG pipeline with custom embedding models. It applies what observers describe as a 12 to 18 month freshness window for source selection, and its citation density has increased. Presenc.ai reports an average of 5.8 sources per response in 2026, up from 4.2 in 2024.

Perplexity was built as a citation-first search engine from the outset. Source attribution is not a feature that was added later, but the product’s organizing principle.

ChatGPT’s grounded search mode operates differently again. LLMRefs documented that OpenAI maintains a cached internal index of web pages, with a verifiable API parameter that reveals whether a page exists in the cache.

The system retrieves from this cached index and assembles selected passages with source URLs into prompts for generation. Not every crawled page makes it into the cache, and the selection criteria remain unclear.

Each system embeds differently, retrieves from different indexes, reranks with different models, and scores passages against different criteria. A content strategy built for AI citation cannot optimize for a single engine without understanding this divergence.

Platform

Index source

Citation style

Key signal

Google AI Overviews

Google Search index + Knowledge Graph

Integrated into the synthesized answer

Structured data, page authority

Perplexity

Live web retrieval (BM25 + dense embeddings)

Numbered inline citations (~5.8 per response)

Freshness, factual density, passage extractability

ChatGPT

Cached internal index + live fetch option

In-text source links

Cache inclusion, topical relevance, passage quality

Our earlier blog post on the shift from content creation to content thinking framed this challenge at the strategic level, the argument that content requires the same rigor as consulting or journalism.

The multi-engine divergence in AI citation makes that argument concrete. Producing content is a logistics problem, and thinking about how that content will be parsed by fundamentally different architectures is the strategic layer that most content operations have not yet built.

The architecture of being found

The query that opened this piece, four seconds from question to cited answer, is happening hundreds of millions of times per month across platforms. Ahrefs reported AI Overviews appearing in over 54% of Google searches by volume. Perplexity processes approximately 780 million monthly queries.

Every one of those queries runs a retrieval pipeline that selects or passes over content in fractions of a second.

The businesses that appear inside those answers are not necessarily the ones with the strongest brands, the highest domain authority, or the most content. They are the ones whose content is structurally built for citation. Dense with verifiable claims. Clearly attributed. Answer first in structure. Technically accessible to the systems that now mediate discovery.

This is a structural discipline that sits at the intersection of editorial quality and machine architecture.

At Mediasphere, we work with businesses that understand this intersection, organizations that recognize content thinking, not content production, as the capability that determines whether their knowledge ever reaches the people asking for it. If the mechanics described in this piece map to questions you are already asking about your own content, let’s talk!

Mediasphere is a strategic content marketing agency that builds content architectures rooted in thinking, not volume, and explores why marketing works. To learn more, visit mediasphere.digital.

The Mediasphere Hot Take

Our take is that most content is invisible to retrieval systems for structural reasons, not quality reasons. Good thinking trapped inside a badly built page does not get cited. Here is what we would do:

  • Make every important passage able to stand alone. If a paragraph only makes sense after reading the two before it, a retrieval system will pass it over.
  • Put the answer first and the context second, in every section. This is the highest return structural change available.
  • Add the structured data layer. It is unglamorous, it takes an afternoon, and it decides whether machines can read what you published. Being found used to be about pages. It is now about passages. The businesses that restructure for that will be cited by systems their competitors are still arguing about.
Andrei Muresan

About the author

Andrei Muresan

Founder

Andrei is the founder of Mediasphere, a strategic content marketing agency. He is an experienced copywriter and content strategist who has worked across international environments, with a focus on B2B SaaS, IT, healthcare, and public services. His work centers on building editorial systems that earn attention rather than rent it, and on helping growth stage companies treat content as a strategic capability rather than a production function.

Keep Reading

Want more insights like this?

We write about content strategy, search visibility, and what actually works in marketing.

Browse All Articles