Crates.io | szovegertesimutato-score |
lib.rs | szovegertesimutato-score |
version | 0.1.0 |
source | src |
created_at | 2024-08-07 13:18:05.748813 |
updated_at | 2024-08-07 13:18:05.748813 |
description | Calculate szovegertesimutato score for a given text and language. |
homepage | |
repository | https://github.com/astuanax/szovegertesimutato |
max_upload_size | |
id | 1328423 |
size | 12,425 |
The Text Comprehension Index library provides a tool to calculate the readability score for Hungarian texts based on the Szövegértési mutató formula. This formula helps determine the ease of understanding a given text, making it useful for writers, educators, and content creators who want to ensure their material is accessible to their intended audience.
Calculate the Text Comprehension Index for Hungarian texts.
Automatically count sentences, words, and syllables in the text.
Provides a score clamped between 0 and 100 for easy interpretation.
Includes comprehensive tests for accuracy and reliability.
Text Comprehension Index Formula:
Helper Methods:
count_sentences
: Counts the number of sentences using regex.count_words
: Counts the number of words using regex.count_syllables
: Counts the number of syllables using regex by matching vowel groups.Score Clamping:
We use score.clamp(0.0, 100.0)
to ensure that the Text Comprehension Index is within a reasonable range.
cargo install szovegertesimutato
Licensed under:
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the MIT license, shall be dual licensed as above, without any additional terms or conditions.
See CONTRIBUTING.md.