You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+48Lines changed: 48 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,6 +13,54 @@ ReadSightPy measures text readability across **86 languages** using **17 readabi
13
13
14
14
This is a Python port of [ReadSight](https://github.com/MADEVAL/ReadSight) (PHP).
15
15
16
+
## See It in Action
17
+
18
+
Two texts of almost equal length — a plain sentence and a chunk of legal boilerplate:
19
+
20
+
```python
21
+
from readsight import ReadSight
22
+
23
+
plain ="We made an app that reads your text. It tells you how easy it is to read. You get a score in one second."
24
+
legal ="The parties acknowledge that any unauthorized disclosure of confidential information may cause irreparable harm. In such an event, the affected party shall be entitled to seek injunctive relief."
25
+
```
26
+
27
+
There is no "score everything" call — you loop over the formulas the language supports and call `score()` for each:
All 9 formulas for `en-us` agree the second text is far harder. The bundled example prints this grid plus text metrics and a syllable histogram, for any text and language:
57
+
58
+
```bash
59
+
python examples/demo.py
60
+
```
61
+
62
+
**17 formulas, 86 languages, one consistent API.** Five of the formulas are truly universal — **Gunning Fog, SMOG, Coleman-Liau, ARI and LIX** score text in *every* one of the 86 languages. The remaining **12 are language-aware**, each carrying its own published coefficients: Flesch Reading Ease and Flesch-Kincaid span 12 languages, the Wiener Sachtextformel speaks German, Gulpease speaks Italian, OSMAN speaks Arabic, and the Fernández-Huerta · Szigriszt-Pazos · Gutiérrez-Polini · Crawford family handles Spanish. `get_supported_formulas()` hands each language exactly the slice that fits it — **9** formulas for `en-us`, **11** for `es`, **8** for `de-1996` — so an English-only metric never lands on a Thai sentence by mistake.
0 commit comments