Formal Writing Checker
Project description
Formal Writing Checker
A script for raising some warnings to you when writing formal documents.
Warnings are raised for:
- sentence length: 30 words (can be changed)
- passive voice
- rare terms? NOT IMPLEMENTED
Installation
You can install this package from:
- PyPI:
pip install formal-writing-checker
- GitHub:
pip install git+https://github.com/MartinoMensio/formal-writing-checker.git
This package requires the en_core_web_lg
from spacy, which you can install with one of the following:
formal-writing-checker-install
python -m spacy download en_core_web_lg
Usage
Once installed, the script is available as
formal-writing-checker "Let's say I am told to check this sentence. Why am I using the passive voice anyways?"
# Or use a text file as input
cat > example_long_text.txt <<EOF
On offering to help the blind man, the man who then stole his car, had not, at that precise moment, had any evil intention, quite the contrary, what he did was nothing more than obey those feelings of generosity and altruism which, as everyone knows, are the two best traits of human nature and to be found in much more hardened criminals than this one, a simple car-thief without any hope of advancing in his profession, exploited by the real owners of this enterprise, for it is they who take advantage of the needs of the poor.
EOF
cat example_long_text.txt | formal-writing-checker
# or in a pipe after any other command (e.g. to take as input a latex files)
detex example_latex.tex | formal-writing-checker
Options
The behaviour can be customised with the following options (can be seen with formal-writing-checker --help
):
-m, --max-sentence-length INTEGER
Maximum sentence length [default: 30]
-s, --use-statistical-sentencizer
Use statistical sentencizer instead
of rule-based sentencizer [default: False]
-l, --ignore-sentence-length Disable passive voice check [default:
False]
-p, --ignore-passive-voice Disable passive voice check [default:
False]
Deploy utils
python setup.py sdist
# upload to pypi
twine upload dist/formal_writing_checker-0.0.4.tar.gz
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file formal_writing_checker-0.0.4.tar.gz
.
File metadata
- Download URL: formal_writing_checker-0.0.4.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.9.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5390413db028ab970da1d56b8b3685a525dfc99eb1b5572985ad83ea487b3828 |
|
MD5 | a293fb070e0e9ff61e35a4e20b6ab259 |
|
BLAKE2b-256 | 980cc87f9dfa45831071bea8a2bbf8e01e31ddd95fb328a8024f4fd5d21c55f4 |