Understand wordfreq wordlists and precision
masterWordlist Types
- 'small': Optimized for low memory usage. Covers words appearing at least once per million words.
- 'large': More comprehensive. Covers words appearing at least once per 100 million words.
- 'best': The default setting. It automatically selects
'large'if available for the requested language, falling back to'small'otherwise.
Precision and Frequency Bins
To optimize loading speed and storage, wordfreq uses frequency bins. Instead of storing high-precision decimals, all words with the same Zipf frequency (rounded to the nearest hundredth) share the same frequency value. This ensures the frequency of any word is precise to within 1%.