git clone https://github.com/puneethkotha/humanizer-workbench
cd humanizer-workbench
python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"Set your API key:
export ANTHROPIC_API_KEY=your_key_hereUnit tests (no API key required):
pytest tests/ -m "not integration"Integration tests (requires API key):
pytest tests/ -m integrationAll tests:
pytest tests/ruff check src/ tests/
ruff format src/ tests/
mypy src/The best contributions at this stage:
Detectors — The current lexical and structural detectors cover common patterns but miss some. Adding more structural patterns (question-then-answer openers, paragraph-length uniformity) or expanding the vocabulary list is low-risk and high-value.
Style presets — New styles need to produce meaningfully different output, not just different system prompts. If you add a style, include examples of what the voice sounds like and tests that validate the preset fields.
Scoring calibration — The scorer's thresholds were set against a small test set. Better calibration against a larger corpus of AI-generated and human-written text would improve reliability.
Chunking for long texts — Long documents (> 2000 words) should be split into chunks, processed independently, and reassembled. The engine currently warns but doesn't split.
- One concern per PR. Don't combine a new style with scoring changes.
- Unit tests for all new code.
- Update
CHANGELOG.mdunder[Unreleased]. - The CI must pass before merging.
- Define a
StylePresetinsrc/humanizer/styles/presets.py - Add a
StyleNameentry insrc/humanizer/core/models.py - Register it in
STYLE_REGISTRY - Add tests in
tests/unit/test_styles.py
The style's voice_description, structural_guidance, and vocabulary_guidance fields drive the prompt. Make them specific and substantive — "write conversationally" is not useful guidance; "use contractions, mix short and long sentences, trust the reader" is.
- Subclass
BaseDetectorinsrc/humanizer/detectors/ - Implement
detect()returning aDetectionResult - Add it to the
CompositeDetectorinstantiation inengine.py - Add tests in
tests/unit/test_detectors.pywith positive and negative cases
Include:
- The input text (or a representative sample)
- The style and intensity used
- The actual output
- What you expected
If the issue is scoring-related, include the before and after scores and the component breakdown (run with --score --explain).