Add speciesist language linter (woke integration or dedicated) #6390
Unanswered
stuckvgn
asked this question in
Linter Ideas
Replies: 1 comment
-
|
Hey, thank you for opening your first Issue ! 🙂 If you would like to contribute we have a guide for contributors. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Welcome
Is your feature request related to a problem? Please describe.
golangci-lint currently has no linter for inclusive language. Other ecosystems have tools like woke (Go-based, MIT, 500+ stars) and alex that detect non-inclusive terminology in source code — covering racial, gender, and ableist language.
However, none of the existing inclusive language tools cover speciesist language: phrases that normalize violence toward animals, particularly in technical contexts. This is relevant to Go codebases because:
Research backing this: Takeshita, Rzepka & Araki (2022) documented speciesist language patterns in code in Information Processing & Management. Hagendorff, Bossert, Tse & Singer (2023) documented speciesist bias in AI systems in AI and Ethics (DOI: 10.1007/s43681-023-00380-w).
The Inclusive Naming Initiative (founded by CNCF/Kubernetes maintainers) has already driven terminology changes in the Go ecosystem — this extends that work to a category not yet covered.
Describe the solution you'd like.
A
go/analysis-based linter that detects speciesist language in Go source code (comments, string literals, identifiers, documentation). Two possible approaches:Option A: Wrap woke's detection logic
get-woke/woke is already written in Go and MIT-licensed. Its rule matching engine could be adapted into a
go/analysisanalyzer. The Open-Paws/speciesist-language-scanner project provides woke-compatible rule files specifically for speciesist terminology with curated alternatives.Option B: Dedicated
go/analysislinterA new analyzer (similar in approach to
misspellordupword) that scans comments, string literals, and identifiers for speciesist terms and suggests alternatives. This could be built as a standalonego/analysismodule that golangci-lint integrates.What it would flag (Go-specific examples):
Configuration should allow:
Describe alternatives you've considered.
Running woke separately — This works but misses golangci-lint's Go-aware AST context (distinguishing comments from identifiers from string literals), unified configuration, IDE integration, and
nolintdirective support.Module plugin — The golangci-lint module plugin system allows adding custom linters without upstream changes. A speciesist language analyzer could be distributed as a module plugin. However, upstream inclusion would give this much broader adoption and signal that the Go ecosystem takes this category of inclusive language seriously.
Vale/pre-commit hooks — Tools like Vale can scan documentation but don't understand Go syntax, can't distinguish between code and comments, and aren't integrated into the Go development workflow.
Additional context.
Existing rule sets are ready to use:
The Open-Paws/speciesist-language-scanner repository provides curated rule files for woke, Vale, and alex covering 25+ speciesist terms across three categories:
Each rule includes severity levels, word boundary settings, and academically sourced notes explaining why the term is problematic and why the alternative is more precise.
This fits golangci-lint's existing pattern:
misspellalready does text-level analysis across comments and identifiersdupwordanalyzes comment text for repeated wordsgodotenforces comment stylegosmopolitanflags internationalization issuesA speciesist language linter would be a natural addition to this text-analysis category.
Open Paws (openpaws.ai) is a 501(c)(3) nonprofit building AI infrastructure for animal advocacy organizations. We're happy to contribute the implementation or collaborate on it.
Beta Was this translation helpful? Give feedback.
All reactions