Skip to content

a2i2/ml-smell-hound

Repository files navigation

MLSmellHound

MLSmellHound is a tool that provides context-aware linting. It is based on Pylint, a popular linter for Python projects that is highly configurable but that does not consider context.

Dependencies

  • Bash
  • Python3
  • Pip3

Currently, the only other dependency is Pylint 2.11.1:

pip3 install -r requirements.txt

Usage

To lint all Python files in example-src (edit mlsh Bash script to run on your own project):

./mlsh

The script will analyse all Python files in the project directory then write the audit report to outputs/<datetime>/lint-context.txt

To compare the results to the default Pylint output:

pylint example-src > pylint-default-output.txt
diff pylint-default-output.txt outputs/<datetime>/lint-context.txt

Sample

Screenshot

The above screenshot shows the difference between Pylint default output (left), and transformed ouput generated by MLSmellHound (right). Pylint warns about “e” and “df”, whereas MLSmellHound accepts these in the context of ML files. The output also shows that trailing-whitespace warnings have been re-ranked to a lower priority for ML files.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages