/search can now return snippets instead of, or alongside, its full content. Snippets are a document’s highest-scoring passages, in the order they appear in the document. Set fields.snippets to true to get focused excerpts without passing an entire document into your prompt or pipeline.
Highlights
- Focused excerpts — Each document’s
snippetsarray holds its highest-scoring passages, in the order they appear in the document. - Independent of
content—fieldsselects each member on its own, so requestsnippets,content, or both in the same call. - Available on
newsandwikipedia— Thecompaniesandpeoplescopes don’t produce snippets;snippetscomes back as an empty array for those scopes even when requested.
Quick Start
Get Snippets
Requesting snippets alongside or instead of content
API Reference
Full
fields parameter specification