
Combining Snapshot Site with a Vector Database for Visual RAG

Snapshot Site Team
18 Apr 2025 - 02 Mins read
Most retrieval-augmented generation (RAG) pipelines index text — documents, help articles, transcripts. That works poorly for questions about what a web page actually looks like or currently shows, because raw HTML doesn't reliably describe the rendered page, especially for JavaScript-heavy sites. Capturing a real screenshot and running it through AI analysis produces a text description grounded in what actually rendered, which is exactly the kind of content a vector database is built to index.
The Pipeline, Step by Step
This is two ordinary building blocks chained together, not a new feature:
- Capture and summarize a page with
v3/analyzeandenableSummary: true. - Embed the resulting summary text with your embedding model of choice.
- Store the embedding, alongside the source URL and screenshot link, in a vector database.
- Query the vector database with a natural-language question, and retrieve the most relevant summaries as context for an LLM to answer from.
curl --request POST \
--url https://api.prod.ss.snapshot-site.com/api/v3/analyze \
--header 'Content-Type: application/json' \
--header 'x-snapshotsiteapi-key: YOUR_API_KEY' \
--data '{
"url": "https://example.com/product-page",
"format": "png",
"width": 1440,
"fullSize": true,
"enableSummary": true
}'
The response's summary text is what gets embedded — the screenshot itself stays attached as supporting evidence a human (or a multimodal model) can look at directly, but the text is what the vector database actually indexes and searches over.
Why This Beats Indexing Raw HTML
Raw HTML reflects the markup, not what a visitor sees — content injected by JavaScript, conditionally rendered sections, and anything behind a loading state are all invisible to a plain HTML fetch. An AI summary generated from an actually-rendered page describes what's really there, which makes it a more honest source of truth for a RAG pipeline answering questions like "what does our pricing page currently say" or "did this competitor's landing page change its messaging."
A Practical Use Case: Internal Knowledge Base of Live Pages
Teams that need to answer questions about the current state of many pages — a large marketing site, a partner network's pages, a set of internal tools — can build a simple internal search tool this way: capture and summarize every relevant page on a schedule, re-embed and update the vector store when a summary changes meaningfully, and expose a natural-language query interface on top. This turns "what does that page currently say" from a manual click-through into a searchable question.
Keeping the Index Fresh
Since pages change, the embeddings need to be refreshed on a schedule, not indexed once and forgotten. A practical pattern: re-run the capture-and-summarize step periodically, and only re-embed when the new summary differs meaningfully from the stored one — comparing the actual screenshot with v3/compare first is a cheap way to decide whether a re-embed is even necessary, avoiding wasted embedding calls on pages that haven't visually changed.
Where This Fits Alongside Other AI-Analysis Use Cases
This pipeline reuses the same enableSummary output already covered in From Screenshot to AI Insights — the difference here is what happens to that summary downstream, feeding a retrieval system instead of a one-off report.
Grounding a RAG pipeline in what a page actually renders, rather than its raw markup, is a small addition to a pipeline that likely already exists, and Snapshot Site produces the text that pipeline needs in the same call that produces the screenshot.

