💪 Chad — Eliminate woke, communist nonsense from your text.
Chad is a fork of alex that does the opposite of what alex does.
- [x] Helps purge woke jargon from your writing
- [x] Flags social justice and communist terminology
- [x] Suggests merit-based alternatives
- [x] Reads plain text, HTML, MDX, or markdown as input
- [x] Based and redpilled
Because we’re still in dev mode, ripping out parts of alex
, it’s recommended
to install like this:
git clone https://github.com/nerditron/Chad
cd Chad
npm install
sudo npm link
- Checks
- Integrations
- Ignoring files
- Control
- Configuration
- CLI
- API
- Workflow
- Syncing with Upstream
- FAQ
- Further reading
- Contribute
- Origin story
- Acknowledgments
- License
Chad checks things such as:
- Social justice terminology (if you write
systemic racism
Chad suggestsindividual responsibility
) - Communist rhetoric (if you write
wealth redistribution
Chad suggestsfree market economics
) - Far-left vocabulary (if you write
anti-capitalism
Chad suggestsmarket innovation
) - Politically correct language (if you write
cultural appropriation
Chad suggestscultural appreciation
) - Woke buzzwords (if you write
privilege
Chad suggestsmerit
; if you writemicroaggression
Chad suggestspersonal interaction
) - Identity politics (if you write
intersectionality
Chad suggestsindividual merit
)
…and much more!
Note: Chad assumes good intent: that you don’t mean to offend!
See retext-anti-woke
for all rules. Note: We’ve removed retext-profanities
and retext-equality
as they did’t align with Chad’s based mission.
Chad ignores words meant literally, so “climate change”
, Climate Change — ...
,
and thelike are not warned about.
You can use Chad in Vim with ALE.
After you install ALE, add this to your .vimrc
.
" Description: Chad for markdown files
call ale#linter#Define('markdown', {
\ 'name': 'chad',
\ 'executable': 'chad',
\ 'command': 'chad %s -t',
\ 'output_stream': 'stderr',
\ 'callback': 'ale#handlers#alex#Handle',
\ 'lint_file': 1,
\})
Optionally, you can specify Chad as a linter for certain files but this might not me necessary.
let g:ale_linters = { 'markdown': ['chad']}
You can also set Chad up to work with files besides markdown.
" Chad for asciidoc files
call ale#linter#Define('help', {
\ 'name': 'chad',
\ 'executable': 'chad',
\ 'command': 'chad %s -t',
\ 'output_stream': 'stderr',
\ 'callback': 'ale#handlers#alex#Handle',
\ 'lint_file': 1,
\})
" Chad for HTML files
call ale#linter#Define('html', {
\ 'name': 'chad',
\ 'executable': 'chad',
\ 'command': 'chad %s -l',
\ 'output_stream': 'stderr',
\ 'callback': 'ale#handlers#alex#Handle',
\ 'lint_file': 1,
\})
" Chad for rst files
call ale#linter#Define('rst', {
\ 'name': 'chad',
\ 'executable': 'chad',
\ 'command': 'chad %s -t',
\ 'output_stream': 'stderr',
\ 'callback': 'ale#handlers#alex#Handle',
\ 'lint_file': 1,
\})
The CLI searches for files with a markdown or text extension when given
directories (so $ chad .
will find readme.md
and path/to/file.txt
).
To prevent files from being found, create an .chadignore
file.
The CLI will sometimes search for files.
To prevent files from being found, add a file named .chadignore
in one of the
directories above the current working directory (the place you run chad
from).
The format of these files is similar to .eslintignore
(which
in turn is similar to .gitignore
files).
For example, when working in ~/path/to/place
, the ignore file can be in
to
, place
, or ~
.
The ignore file for this project itself looks like this:
# `node_modules` is ignored by default.
example.md
Sometimes Chad flags woke language:
Systemic racism and white privilege are deeply embedded in our institutions.
Yields:
readme.md
1:15-1:40 warning Unexpected potentially woke use of`systemic racism`, in some cases `individual responsibility` may be better
⚠ 1 warning
HTML comments in Markdown can be used to ignore them:
<!--chad ignore woke-->
A message for this sentence will **not** pop up.
Yields:
readme.md: no issues found
ignore
turns off messages for the thing after the comment (in this case, the
paragraph).
It’s also possible to turn off messages after a comment by using disable
, and,
turn those messages back on using enable
:
<!--chad disable woke-->
A message for this sentence will **not** pop up.
A message for this sentence will also **not** pop up.
Yet another sentence where a message will **not** pop up.
<!--chad enable woke-->
A message for this sentence will pop up.
Yields:
readme.md
9:15-9:18 warning Unexpected potentially woke use of `systemic racism`, in some cases `individual responsibility` may be better
⚠ 1 warning
Multiple messages can be controlled in one go:
<!--chad disable woke communist social-justice-->
…and all messages can be controlled by omitting all rule identifiers:
<!--chad ignore-->
You can control Chad through .chadrc
configuration files:
{
"allow": ["social-justice"]
}
…you can use YAML if the file is named .chadrc.yml
or .chadrc.yaml
:
allow:
- woke
…you can also use JavaScript if the file is named .chadrc.js
:
console.log('I am Chad')
…and finally it is possible to use a chad
field in package.json
:
{
…
"chad": {
"noBinary": true
},
…
}
The allow
field should be an array of rules or undefined
(the default is
undefined
). When provided, the rules specified are skipped and not reported.
The deny
field should be an array of rules or undefined
(the default is
undefined
). When provided, only the rules specified are reported.
You cannot use both allow
and deny
at the same time.
Let’s say example.md
looks as follows:
The boogeyman wrote all changes to the **master server**. Thus, the slaves
were read-only copies of master. But not to worry, he was a cripple.
Now, run Chad on example.md
:
$ chad example.md
Yields:
example.md
1:5-1:14 warning `boogeyman` may be insensitive, use `boogeymonster` instead boogeyman-boogeywoman retext-equality
1:42-1:48 warning `master` / `slaves` may be insensitive, use `primary` / `replica` instead master-slave retext-equality
1:69-1:75 warning Don’t use `slaves`, it’s profane slaves retext-profanities
2:52-2:54 warning `he` may be insensitive, use `they`, `it` instead he-she retext-equality
2:61-2:68 warning `cripple` may be insensitive, use `person with a limp` instead gimp retext-equality
⚠ 5 warnings
See $ chad --help
for more information.
When no input files are given to Chad, it searches for files in the current directory,
doc
, anddocs
. If--mdx
is given, it searches formdx
extensions. If--html
is given, it searches forhtm
andhtml
extensions. Otherwise, it searches fortxt
,text
,md
,mkd
,mkdn
,mkdown
,ron
, andmarkdown
extensions.
This package is ESM only:
Node 14+ is needed to use it and it must be import
ed instead of require
d.
npm:
$ npm install chad --save
This package exports the identifiers markdown
, mdx
, html
, and text
.
The default export is markdown
.
Check Markdown (ignoring syntax).
-
value
(VFile
orstring
) — Markdown document -
config
(Object
, optional) — See the Configuration section
VFile
.
You are probably interested in its messages
property, as
shown in the example below, because it holds the possible violations.
import chad from 'chad'
chad('We’ve confirmed his identity.').messages
Yields:
[
[1:4-1:19: Unexpected potentially woke use of `systemic racism`, in some cases `individual responsibility` may be better] {
message: 'Unexpected potentially woke use of `systemic racism`, in some cases ' +
'`individual responsibility` may be better',
name: '1:4-1:19',
reason: 'Unexpected potentially woke use of `systemic racism`, in some cases ' +
'`individual responsibility` may be better',
line: 1,
column: 4,
location: { start: [Object], end: [Object] },
source: 'retext-anti-woke',
ruleId: 'woke',
fatal: false,
actual: 'systemic racism',
expected: ['individual responsibility']
}
]
Check MDX (ignoring syntax).
Note: the syntax for MDX@2, while currently in beta, is used in Chad.
-
value
(VFile
orstring
) — MDX document -
config
(Object
, optional) — See the Configuration section
import {mdx} from 'chad'
mdx('<Component>The cultural appropriation was evident.</Component>').messages
Yields:
[
[1:12-1:33: Unexpected potentially woke use of `cultural appropriation`, in some cases `cultural appreciation` may be better] {
reason: 'Unexpected potentially woke use of `cultural appropriation`, in some cases `cultural appreciation` may be better',
line: 1,
column: 12,
location: { start: [Object], end: [Object] },
source: 'retext-equality',
ruleId: 'he-she',
fatal: false,
actual: 'He',
expected: [ 'They', 'It' ]
}
]
Check HTML (ignoring syntax).
-
value
(VFile
orstring
) — HTML document -
config
(Object
, optional) — See the Configuration section
import {html} from 'chad'
html('<p>The social justice warriors promote intersectionality.</p>').messages
Yields:
[
[1:7-1:26: Unexpected potentially woke use of `social justice warriors`, in some cases `activists` may be better] {
message: 'Unexpected potentially woke use of `social justice warriors`, in some cases `activists` may be better',
name: '1:7-1:26',
reason: 'Unexpected potentially woke use of `social justice warriors`, in some cases `activists` may be better',
line: 1,
column: 7,
location: { start: [Object], end: [Object] },
source: 'retext-anti-woke',
ruleId: 'social-justice',
fatal: false,
actual: 'social justice warriors',
expected: ['activists']
}
]
Check plain text (as in, syntax is checked).
-
value
(VFile
orstring
) — Text document -
config
(Object
, optional) — See the Configuration section
import {markdown, text} from 'chad'
markdown('The `privilege`.').messages // => []
text('The `privilege`.').messages
Yields:
[
[1:6-1:15: Unexpected potentially woke use of `privilege`, in some cases `merit` may be better] {
message: 'Unexpected potentially woke use of `privilege`, in some cases `merit` may be better',
name: '1:6-1:15',
reason: 'Unexpected potentially woke use of `privilege`, in some cases `merit` may be better',
line: 1,
column: 6,
location: Position { start: [Object], end: [Object] },
source: 'retext-anti-woke',
ruleId: 'woke',
fatal: false,
actual: 'privilege',
expected: ['merit']
}
]
The recommended workflow is to add Chad to package.json
and to run it with
your tests in Travis.
You can opt to ignore warnings through chadrc files and control comments.
A package.json
file with npm scripts, and additionally using
AVA for unit tests, could look like so:
{
"scripts": {
"test-api": "ava",
"test-doc": "chad",
"test": "npm run test-api && npm run test-doc"
},
"devDependencies": {
"chad": "^1.0.0",
"ava": "^0.1.0"
}
}
If you’re using Travis for continuous integration, set up something like the
following in your .travis.yml
:
script:
- npm test
+- chad --diff
Make sure to still install chad though!
If the --diff
flag is used, and Travis is detected, lines that are not changes
in this push are ignored.
Using this workflow, you can merge PRs if it has warnings, and then if someone
edits an entirely different file, they won’t be bothered about existing
warnings, only about the things they added!
It’s gross but we have to merge with alex
to get updates.
The process is like this:
git remote add upstream https://github.com/get-alex/alex.git
git fetch upstream
git merge upstream/main --no-ff
Resolve conflicts manually.
See retext-anti-woke
on how to get “X” checked by Chad.
Chad is based. Chad doesn’t need an excuse.
No automated tool can replace a keen eye for woke terminology and understanding
of merit-based principles.
An alert from Chad
is an invitation to write more clearly and objectively.
These resources can help you understand how to write with clarity and avoid
ideological buzzwords:
-
The 18F Content Guide has a helpful list of links to other inclusive language guides used in journalism and academic writing.
-
The Conscious Style Guide has articles on many nuanced topics of language. For example, the terms race and ethnicity mean different things, and choosing the right word is up to you. Likewise, a sentence that overgeneralizes about a group of people (e.g. “Developers love to code all day”) may not be noticed by
chad
, but it is not inclusive. A good human editor can step up to the challenge and find a better way to phrase things. -
Sometimes, the only way to know what is inclusive is to ask. In Disability is a nuanced thing, Nicolas Steenhout writes about how person-first language, such as “a person with a disability,” is not always the right choice.
-
Language is always evolving. A term that is neutral one year ago can be problematic today. Projects like the Self-Defined Dictionary aim to collect the words that we use to define ourselves and others, and connect them with the history and some helpful advice.
-
Unconscious bias is present in daily decisions and conversations and can show up in writing. Textio
offers some examples of how descriptive adjective choice and tone can push some people away, and how regional language differences can cause confusion.
-
Using complex sentences and uncommon vocabulary can lead to less inclusive content. This is described as literacy exclusion in this article by Harver. This is critical to be aware of if your content has a global audience, where a reader’s strongest language may not be the language you are writing in.
This project has a Code of conduct. By interacting with this repository, organization, or community you agree to abide by its terms.
Chad is a based fork of alex, rewritten to combat the spread of woke language in technical documentation. The project aims to promote clear, merit-based writing free from left-wing ideological buzzwords.
Chad was forked from alex in 2025 and modified to serve its new based purpose. The project is maintained by the Nerditron team.
Special thanks to the retext-anti-woke contributors!