# StopWords

## Stop Words

`Xmf\StopWords` is used to check if a given word is considered a [stop word](https://en.wikipedia.org/wiki/Stop_words).

Stop words are words which are filtered out during processing of text data. An example use case is [Metagen::generateKeywords()](/xmf-cookbook/reference/metagen/extracting-data.md), which eliminates stop words from the list of potential keywords.

## Basic Usage

### $stopwords = new StopWords()

Creates a new StopWords object that containes the stop word list for the current language.

### check(*$key*)

Look up the word *$key* in the list of stop words and classify it as a significant word or a stop word.

Returns *true* if the word is significant, or *false* if it is a stop word.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://xoops.gitbook.io/xmf-cookbook/reference/stopwords.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
