Grafana Labs’ dictionary
The Grafana Labs documentation team maintains a dictionary used for spell checking. The same dictionary is used to generate some Vale rules from the metadata in the word definition.
The dictionary uses the Hunspell format generated from a Jsonnet template.
If a word doesn’t yet exist in the dictionary, you can add one by modifying the appropriate dictionary template file.
To add a new word to the dictionary, refer to Add words to the Grafana Labs dictionary.
Word metadata
Each word in the dictionary has metadata that describes it. The structure of that metadata is a Jsonnet object with the following fields:
| Key | Value type | Description | 
|---|---|---|
| word | string | The spelling of the word. | 
| affixes | string | A concatenation of the letters corresponding to Hunspell affixes. For more information, refer to Hunspell affixes | 
| po | string | The part of speech descriptor for the word. Known acceptable values include 'noun','adjective', and'verb'. | 
| description | string | A description of the word. | 
| abbreviation | boolean | If true, the word is an abbreviation. Defaults tofalse. | 
| established_abbreviation | boolean | If true, the abbreviation doesn’t generally need explaining, like the abbreviation HTTP. Defaults tofalse | 
| product | boolean | If true, the word is the name of any product, like Mimir or Facebook. Defaults tofalse. | 
| Amazon | boolean | If true, the word is the name of an Amazon product, like Amazon CloudWatch. Defaults tofalse. | 
| Apache | boolean | If true, the word is the name of an Apache project, like Apache Mesos. Defaults tofalse. | 
You don’t create the object directly in the dictionary template file.
Instead, you use the word.new function which prescribes the required fields.
To add new word, refer to Add words to the Grafana Labs dictionary.
To understand the Hunspell affixes, refer to Hunspell affixes.
Hunspell affixes
Hunspell affixes teach the dictionary multiple words by applying affix rules to the stem word.
The affix rules are defined in en_US-grafana.aff.
Note
Affixes are case sensitive.
dis a different affix toD
| Letter | Kind | Description | 
|---|---|---|
| d | Prefix | Adds the deprefix to the stem, making deprovision from provision. | 
| m | Prefix | Adds the misprefix to the stem, making misconfigure from configure. | 
| p | Prefix | Adds the preprefix to the stem, making preconfigure from configure. | 
| u | Prefix | Adds the unprefix to the stem, making unregister from register. | 
| D | Suffix | Adds the past tense suffix edto the stem, making ingested from ingest. | 
| G | Suffix | Adds the gerund suffix ingto the stem, making singing from sing. | 
| M | Suffix | Adds the possessive suffix 'sto the stem, making ingester’s from ingester. | 
| R | Suffix | Adds the rsuffix to the stem, making profiler from profile. | 
| S | Suffix | Adds the plural suffix sto the stem, making namespaces from namespace. | 




