Class SnippetSpec (0.8.1)

SnippetSpec(mapping=None, *, ignore_unknown_fields=False, **kwargs)

The specification that configs the snippet in the search results.

Attributes

NameDescription
max_snippet_count int
Max number of snippets returned in each search result. If the matching snippets is less than the max_snippet_count, return all of the snippets; otherwise, return the max_snippet_count. At most 5 snippets will be returned for each SearchResult.
reference_only bool
if true, only snippet reference is returned.