* unify softmax implementations
* Refine mypy type hint in _set_fine_search_range function
- Update type hint for `min_entropy_ind` from built-in `int` to `np.intp`.
- This refinement addresses a type compatibility warning.
- `np.intp` is the integer type used by numpy for indexing and can differ in size from the built-in Python `int` depending on the platform (32-bit vs 64-bit).
- Mypy highlighted this type hint discrepancy.
* add unit tests for softmax
---------
Co-authored-by: Hui Wen <45724323+huiwengoh@users.noreply.github.com>
* docs: 📝 add usage example for get_sentence
Also remove types in docstrings.
* docs: 📝 add usage examples for filter_sentence
* docs: 📝 add page for internal.token_classification_utils
* docs: 📝 remove name of return variable
auto-tagging won't work correctly for the return value if it's not a tuple
* 📝 add pages for modules in cleanlab.token_classification
* fix indentation
* 📝 add token classification api to toctree
* 🎨 format docstrings
* 📝 add usage examples
* update example comment
* 📝 add usage examples
* 📝 add return variable name in docstring
* 📝 remove some hard-coded params types in rank module
Keep more complex parameters hard-coded for now. E.g. "enum"-like parameters.
* 🎨 remove indentation of parameters in docstrings
* 🎨 fix indentation
* colored docstring typo + formatting
* typo: occurence
* probs_merged docstring typo + formatting
Co-authored-by: Jonas Mueller <1390638+jwmueller@users.noreply.github.com>
* header for multiannotator module
* header for outlier module
* header for token_classification.filter
* header for token_classification.rank
* header for token_classification.summary
* header for util
* header for latent_algebra
* header for label_quality_utils
* header for token_classification_utils
* header for huggingfacekerasclassifier
* add experimental modules' dependencies to readme
* 🎨 remove wildcard imports
* 🏷️ review type annotations in display_issues
Restrict nested lists with `List`. Keep unrestricted lists as `list`. Remove hard-coded tags from docstrings, should be auto-tagged in later PR.
* ♻️ use `isinstance` for type-check at runtime
* 🏷️ review type annotations in common_label_issues and filter_by_token
Remove hard-coded tags in docstrings. Should be auto-tagged in later PR.
* ✅ improve test coverage of display issues
No part of the function is easily testable except ensuring it completes exection. Some parts handle edge cases that were never reached during testing.
* ✅ parametrize tests for coverage on common_label_issues and filter_by_token
* ✅ add test fixture for get_label_quality_scores
* ✅ test softmin_sentence_score
include test cases for temperature limits
* ♻️ cleanup softmin_sentence_score
Remove unused keyword-only args, Fix tag in docstring, Change format of nested functions.
* ⚡ specialize edge-case temperature=inf in softmin_sentence_score
* ♻️ simplify temperature lookup
* ♻️ cleanup get_label_quality_scores
Remove unused args/variables. Update parameter list in docstring. Rename parameter of inner function. Function always returns a tuple.
* 🏷️ tag token_scores as optional
* ✅ test raised error
* 🩹 skip untestable elif statement
the elif statement only gets partial coverage because it can't evaluate to False due to the `assert sentence_score_method` at the start of the function