Skip to main content

Updated Oct 31, 2026Verified against the product Oct 31, 2026

Grounding agents in your product docs

When you bring in your product documentation — through the Documentation site or Uploaded documents connections, or a Product Docs data model over a warehouse — FunnelStory makes it searchable by your AI Agent flows and by MCP clients. Reach for this when you want an agent to reason about your own product accurately: name features the way your docs do, point to the right setting or error, and cite where it came from instead of guessing.

How it works​

Your documentation is stored in the workspace semantic database as the table product_docs_sources — one row per document, whether it was crawled, uploaded, or mapped in from a warehouse:

ColumnDescription
idDocument identifier (read a document by this).
titleThe document's title.
urlWhere it came from (a crawled page's URL, the uploaded file, or a value your model maps in).
contentThe full document text — often very large.
kindpage (crawled), file (uploaded), or doc (from a Product Docs model).
product_idUsually empty; most documents aren't scoped to a single product.
updated_atWhen the document was last ingested.

There's no pre-built summary or "map" — agents search the documents themselves with SQL, the same way they query the rest of the semantic database.

Because a single document can be megabytes, the pattern is find, then read: search titles and short snippets first (with a LIMIT), then read around the matches by id — never select a whole content column, and don't filter by product_id (most documents leave it empty, so filtering hides matches).

-- 1. Find: search for matches, return a short snippet, not the whole document
SELECT id, title,
substr(content, max(1, instr(lower(content), lower('timeout')) - 150), 300) AS snippet
FROM product_docs_sources
WHERE content LIKE '%proxy%' AND content LIKE '%timeout%'
LIMIT 20;

-- 2. Read: pull a window around the match in the document you chose, by id
SELECT substr(content, max(1, instr(lower(content), lower('proxy timeout')) - 500), 3000)
FROM product_docs_sources
WHERE id = '...';

In an AI Agent flow​

On an AGENT step (see LLM steps):

  1. Grant a query tool. Attach a semantic.query tool so the model can run SQL. Scope it to product_docs_sources when the step should only read the docs.
  2. Attach the "Search the product docs" skill. This built-in skill teaches the model the find-then-read pattern above — searching several phrasings, keeping results small, and reading by id — so you don't have to spell it out in the prompt. Pick it from the built-in skills on the step.

An AI Agent step in the flow builder with the Semantic DB tool selected and the "Search the product docs" skill added, alongside the other available tools and skills

The Agent Skills page listing the built-in skills an agent step can use, including "Search the product docs" (default) and "Query the semantic DB" (default), each with a Show instructions link

The agent then searches for the customer's wording, the product's own names for its parts, and the exact error or setting, reads the documents that bear on the question, and answers with a citation to the source url.

FunnelStory's own built-in needle mover investigation works this way: it reads your product docs to say whether a reported problem maps to an existing capability, a documented limitation, or something not covered — so it's a working example of the same wiring.

Through MCP​

An MCP client reaches the same content with the query_semantic_db tool — product_docs_sources is one of the queryable tables. Read the schema (file://semantic/schema.sql) and usage (file://semantic/usage.md) resources first, then use the same find-then-read pattern.

Searching well​

The quality of the answer depends on how the docs are searched, so a few habits matter:

  • Try several phrasings before concluding something isn't documented — the customer's words, the product's names for its parts, and the exact error, setting, or command. Search is case-insensitive but literal; it doesn't know synonyms.
  • "Not found in the product docs" is not evidence of absence. It never means a capability is unsupported or impossible — only that the search didn't surface it.
  • Name parts as the docs do, and cite the source. Ground every product claim in a document and link its url, rather than paraphrasing from memory.