Metadata-Version: 2.1
Name: rulekit
Version: 1.7.5
Summary: Comprehensive suite for rule-based learning
Home-page: https://github.com/adaa-polsl/RuleKit
Author: Cezary Maszczyk
Author-email: cezary.maszczyk@gmail.com
Project-URL: Bug Tracker, https://github.com/adaa-polsl/RuleKit-python/issues
Project-URL: Documentation, https://adaa-polsl.github.io/RuleKit-python/
Project-URL: Source Code, https://github.com/adaa-polsl/RuleKit-python
Classifier: Development Status :: 4 - Beta
Classifier: License :: OSI Approved :: GNU Affero General Public License v3
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Java
Classifier: Operating System :: Microsoft :: Windows
Classifier: Operating System :: Unix
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pandas <2.3.0,>=1.5.0
Requires-Dist: scikit-learn <1.4.0,>=1.1.0
Requires-Dist: JPype1 <1.6.0,>=1.5.0
Requires-Dist: pydantic <2.6.0,>=2.0.0

# Rulekit
 
This package is python wrapper for [RuleKit](https://github.com/adaa-polsl/RuleKit) library - a versatile tool for rule learning. 
 
Based on a sequential covering induction algorithm, it is suitable for classification, regression, and survival problems.
 
## Installation
 
> **NOTE**: 
This package is a wrapper for Java library, it requires Java (version 1.8.0 tested) to be installed on the computer. Both Open JDK and Oracle implementations are supported.
## 
 
```bash
pip install rulekit
 
# after installation
python -m rulekit download_jar
```
 
The second command will fetch the latest RuleKit library jar file from its Github releases page. It is required to use this package.
 
## Running tests
 
If you're running tests for the first time (or you want to update existing tests resources) you need to download tests resources from RuleKit repository. You can do it by running:
```
python tests/resources.py download
```
Runing tests:    
In directory where `setup.py` file exists.
```
python -m unittest discover ./tests
```
 
## Sample usage
 
```python
from rulekit import RuleKit
from rulekit.classification import RuleClassifier
from sklearn.datasets import load_iris
 
X, y = load_iris(return_X_y=True)
 
clf = RuleClassifier()
clf.fit(X, y)
prediction = clf.predict(X)
 
print(prediction)
```
 
## Documentation
 
Full documentation is available [here](https://adaa-polsl.github.io/RuleKit-python/)

