Coding agents read .agents/glossary.md directly, the same file ESLint, Oxlint, x18n, and the CLI check. Add a script in package.json and run it in CI:
{
"scripts": {
"lint:terms": "glosslint doctor && glosslint check docs"
}
}Both commands exit 0 when clean and 1 on problems or findings, so lint:terms fails CI when the glossary is broken or docs drift. Point agents at the glossary and the script in AGENTS.md:
## Vocabulary
Read `.agents/glossary.md` before writing UI copy or docs. Run `npm run lint:terms` after edits, and `npx glosslint doctor --fix` after changing the glossary.Put a link to the format guide under the glossary's title so an agent opening the file alone can still check its syntax:
# Glossary
<!-- Format and checks: https://glosslint.loadsheet.dev/guide/glossary -->If you also use defineCorpus, pass its module with --corpus: export the merged corpus with npx glosslint print --corpus <module> and run npx glosslint test --corpus <module> after changes. See CLI.
Agent workflow
Section titled "Agent workflow"- Read
.agents/glossary.mdbefore writing copy or docs, or runnpx glosslint explain <word>when unsure which term to use. - Run your project linter, such as ESLint or Oxlint, and
lint:terms, or pass--format jsontoglosslint checkfor structured output. - Follow each finding's
fix.kind: applyautofixas given, readwhyandnuancebefore applying asuggestion, and update every caller for arename.
npx glosslint explain rackDock
"rack" is an avoid word for Dock. Racks are unpowered.
A powered stand where one bike is locked.
A station is a group of docks.
Avoid: rack (racks are unpowered), bay.
Good: "Return the bike to any dock". Bad: "Return the bike to any rack".
See: Docks https://example.com/docs/docks
Related: StationSee Findings for the JSON output and CLI for all commands.
Markdown docs
Section titled "Markdown docs"Every page on this site has a raw Markdown copy at /raw/<page>.md, such as /raw/guide/agents.md, and a full index at /llms.txt.