All Projects → retextjs → Retext Equality

retextjs / Retext Equality

Licence: mit
plugin to check for possible insensitive, inconsiderate language

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Retext Equality

Ludwig
Data-centric declarative deep learning framework
Stars: ✭ 8,018 (+6694.92%)
Mutual labels:  natural-language
Stemmer
Fast Porter stemmer implementation
Stars: ✭ 86 (-27.12%)
Mutual labels:  natural-language
Natural logic interpreter
Automatically interpret and validate nested natural logic arguments based on rules of inference and propositional logic
Stars: ✭ 110 (-6.78%)
Mutual labels:  natural-language
Bert In Production
A collection of resources on using BERT (https://arxiv.org/abs/1810.04805 ) and related Language Models in production environments.
Stars: ✭ 58 (-50.85%)
Mutual labels:  natural-language
Cognitive Social Crm
An application that monitors a Twitter feed and determines customer sentiment using IBM Watson Assistant, Tone Analyzer, Natural Language Understanding, as well as CloudantDB
Stars: ✭ 71 (-39.83%)
Mutual labels:  natural-language
Tagan
An official PyTorch implementation of the paper "Text-Adaptive Generative Adversarial Networks: Manipulating Images with Natural Language", NeurIPS 2018
Stars: ✭ 97 (-17.8%)
Mutual labels:  natural-language
Coursera Natural Language Processing Specialization
Programming assignments from all courses in the Coursera Natural Language Processing Specialization offered by deeplearning.ai.
Stars: ✭ 39 (-66.95%)
Mutual labels:  natural-language
Nlcst
Natural Language Concrete Syntax Tree format
Stars: ✭ 116 (-1.69%)
Mutual labels:  natural-language
Retext Simplify
plugin to check phrases for simpler alternatives
Stars: ✭ 81 (-31.36%)
Mutual labels:  natural-language
Getlang
Natural language detection package in pure Go
Stars: ✭ 110 (-6.78%)
Mutual labels:  natural-language
When
A natural language date/time parser with pluggable rules
Stars: ✭ 1,113 (+843.22%)
Mutual labels:  natural-language
Rasa nlu chi
Turn Chinese natural language into structured data 中文自然语言理解
Stars: ✭ 1,166 (+888.14%)
Mutual labels:  natural-language
Assistantjs
TypeScript framework to build cross-platform voice applications (alexa, google home, ...).
Stars: ✭ 100 (-15.25%)
Mutual labels:  natural-language
Shift Ctrl F
🔎 Search the information available on a webpage using natural language instead of an exact string match.
Stars: ✭ 1,023 (+766.95%)
Mutual labels:  natural-language
Ai Chatbot Framework
A python chatbot framework with Natural Language Understanding and Artificial Intelligence.
Stars: ✭ 1,564 (+1225.42%)
Mutual labels:  natural-language
Ieml
IEML semantic language - a meaning-representation system based on semantic primitives and a regular grammar. Basic semantic relationships between concepts are automatically computed from syntactic similarities.
Stars: ✭ 41 (-65.25%)
Mutual labels:  natural-language
Forte
Forte is a flexible and powerful NLP builder FOR TExt. This is part of the CASL project: http://casl-project.ai/
Stars: ✭ 89 (-24.58%)
Mutual labels:  natural-language
Pytextrank
Python implementation of TextRank for phrase extraction and summarization of text documents
Stars: ✭ 1,675 (+1319.49%)
Mutual labels:  natural-language
Nodejs Language
Node.js client for Google Cloud Natural Language: Derive insights from unstructured text using Google machine learning.
Stars: ✭ 113 (-4.24%)
Mutual labels:  natural-language
Node Sdk
☄️ Node.js library to access IBM Watson services.
Stars: ✭ 1,471 (+1146.61%)
Mutual labels:  natural-language

retext-equality

Build Coverage Downloads Size Sponsors Backers Chat

retext plugin to check for possible insensitive, inconsiderate language.

Install

npm:

npm install retext-equality

Use

Say we have the following file, example.txt:

He’s pretty set on beating your butt for sheriff.

…and our script, example.js, looks like this:

var vfile = require('to-vfile')
var report = require('vfile-reporter')
var unified = require('unified')
var english = require('retext-english')
var stringify = require('retext-stringify')
var equality = require('retext-equality')

unified()
  .use(english)
  .use(equality)
  .use(stringify)
  .process(vfile.readSync('example.txt'), function (err, file) {
    console.error(report(err || file))
  })

Now, running node example yields:

example.txt
  1:1-1:5  warning  `He’s` may be insensitive, use `They`, `It` instead  he-she  retext-equality

⚠ 1 warning

API

retext().use(equality[, options])

Check for possible insensitive, inconsiderate language.

options.ignore

List of phrases not to warn about (Array.<string>).

options.noBinary

Do not allow binary references (boolean, default: false). By default he is warned about unless it’s followed by something like or she or and she. When noBinary is true, both cases would be warned about.

Messages

See rules.md for a list of rules and how rules work.

Each message is emitted as a VFileMessage on file, with the following fields:

message.source

Name of this plugin ('retext-equality').

message.ruleId

See id in rules.md.

message.actual

Current not ok phrase (string).

message.expected

Suggest ok phrase (Array.<string>).

message.note

Extra information, when available (string?).

Related

Contributing

See contributing.md in retextjs/.github for ways to get started. See support.md for ways to get help.

To create new patterns, add them in the YAML files in the data/ directory, and run npm install and then npm test to build everything. Please see the current patterns for inspiration. New English rules will be automatically added to rules.md.

Once you are happy with the new rule, add a test for it in test.js and open a pull request.

This project has a code of conduct. By interacting with this repository, organization, or community you agree to abide by its terms.

License

MIT © Titus Wormer

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].