N-grams are groups of sequential words that occur in the text of a Work.
N-grams list the words and phrases that occur in the full text of a Work. We obtain them from Internet Archive's publicly (and generously
) available General Index and use them to enable fulltext searches on the Works that have them, through both the fulltext.searchfilter, and as an element of the more holistic searchparameter.
Note that while n-grams are derived from the fulltext of a Work, the presence of n-grams for a given Work doesn't imply that the fulltext is available to you, the reader. It only means the fulltext was available to Internet Archive for indexing. Work.open_access is the place to go for information on public fulltext availability.
In addition to enabling fulltext search capabilities, a Work's n-grams are viewable directly through an endpoint that accepts either an OpenAlex ID or a DOI.
Unlike other API endpoints, n-grams are cached via CDN, which means this one is super fast, and you can call it as fast as you want - rate limits don't apply.