diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
new file mode 100644
index 00000000..f1831869
--- /dev/null
+++ b/.github/workflows/ci.yml
@@ -0,0 +1,40 @@
+name: CI
+
+on:
+ push:
+ path:
+ - 'logparser/*'
+ - 'tests/*'
+ pull_request:
+ path:
+ - 'logparser/*'
+ - 'tests/*'
+
+jobs:
+ build:
+ runs-on: ubuntu-20.04
+ timeout-minutes: 180
+ strategy:
+ fail-fast: false
+ matrix:
+ python-version: [3.6, 3.7, 3.8, 3.9, 3.10.13, 3.11]
+
+ steps:
+ - uses: actions/checkout@v3
+
+ - name: Setup python environment
+ uses: actions/setup-python@v4
+ with:
+ python-version: ${{matrix.python-version}}
+
+ - name: Install dependencies
+ run: |
+ pip install -q deap==1.4.1
+ pip install -q nltk
+ pip install -e .
+
+ - name: Run test
+ timeout-minutes: 180
+ run: |
+ cd tests
+ bash test_all.sh
diff --git a/README.md b/README.md
index d797a752..77b06654 100644
--- a/README.md
+++ b/README.md
@@ -5,8 +5,10 @@
@@ -59,8 +61,13 @@ In particular, the package depends on the following requirements.
+ numpy
+ pandas
+ scipy
++ scikit-learn
+ deap (if using logparser.MoLFI)
++ nltk (if using logparser.SHISO)
+ gcc (if using logparser.SLCT)
++ perl (if using logparser.LogCluster)
+
+Note that regex matching in Python is brittle, so we recommend fixing the regex library to version 2022.3.2.
### Get started
diff --git a/logparser/LenMa/README.md b/logparser/LenMa/README.md
index 04bbafd5..fada5d97 100644
--- a/logparser/LenMa/README.md
+++ b/logparser/LenMa/README.md
@@ -14,6 +14,7 @@ The code has been tested in the following enviornment:
+ pandas 1.0.1
+ numpy 1.18.1
+ scipy 1.4.1
++ sklearn 0.22.1
Run the following scripts to start the demo:
diff --git a/logparser/LenMa/requirements.txt b/logparser/LenMa/requirements.txt
index 05d7ff3f..536bc683 100644
--- a/logparser/LenMa/requirements.txt
+++ b/logparser/LenMa/requirements.txt
@@ -1,4 +1,5 @@
pandas
regex==2022.3.2
numpy
-scipy
\ No newline at end of file
+scipy
+scikit-learn
\ No newline at end of file
diff --git a/logparser/SHISO/README.md b/logparser/SHISO/README.md
index 756a16fe..4ec7c7a6 100644
--- a/logparser/SHISO/README.md
+++ b/logparser/SHISO/README.md
@@ -14,6 +14,7 @@ The code has been tested in the following enviornment:
+ pandas 1.0.1
+ numpy 1.18.1
+ scipy 1.4.1
++ nltk 3.4.5
Run the following script to start the demo:
diff --git a/logparser/SHISO/requirements.txt b/logparser/SHISO/requirements.txt
index 05d7ff3f..c9417f9b 100644
--- a/logparser/SHISO/requirements.txt
+++ b/logparser/SHISO/requirements.txt
@@ -1,4 +1,5 @@
pandas
regex==2022.3.2
numpy
-scipy
\ No newline at end of file
+scipy
+nltk
\ No newline at end of file
diff --git a/requirements.txt b/requirements.txt
index 38b35dd7..ecb70f50 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -2,4 +2,7 @@ regex==2022.3.2
numpy
pandas
scipy
+scikit-learn
tqdm
+nltk
+deap
diff --git a/setup.py b/setup.py
index 54be61d7..dffc8794 100644
--- a/setup.py
+++ b/setup.py
@@ -8,7 +8,7 @@
version="1.0.0",
author="logpai",
author_email="logpai@users.noreply.github.com",
- description="A machine learning toolkit for log parsing",
+ description="A machine learning toolkit for log parsing from LOGPAI",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/logpai/logparser",
@@ -17,7 +17,7 @@
exclude=["tests", "data", "docs", "example"]),
include_package_data=True,
python_requires=">=3.6",
- install_requires=["regex==2022.3.2", "numpy", "pandas", "scipy", "tqdm"],
+ install_requires=["regex==2022.3.2", "numpy", "pandas", "scipy", "tqdm", "scikit-learn"],
classifiers=(
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
diff --git a/tests/test_all.sh b/tests/test_all.sh
index 35749ea1..50076724 100644
--- a/tests/test_all.sh
+++ b/tests/test_all.sh
@@ -9,11 +9,11 @@ echo "=== Testing LenMa ===" && cd $home/LenMa && python demo.py && \
echo "=== Testing LFA ===" && cd $home/LFA && python demo.py && \
echo "=== Testing LKE ===" && cd $home/LKE && python demo.py && \
echo "=== Testing LogCluster ===" && cd $home/LogCluster && python demo.py && \
+echo "=== Testing LogMine ===" && cd $home/LogMine && python demo.py && \
echo "=== Testing LogSig ===" && cd $home/LogSig && python demo.py && \
echo "=== Testing MoLFI ===" && cd $home/MoLFI && python demo.py && \
echo "=== Testing SHISO ===" && cd $home/SHISO && python demo.py && \
echo "=== Testing SLCT ===" && cd $home/SLCT && python demo.py && \
echo "=== Testing Spell ===" && cd $home/Spell && python demo.py && \
-echo "=== Testing logmatch ===" && cd $home/logmatch && python demo.py
-
+echo "=== Testing logmatch ===" && cd $home/logmatch && python demo.py &&\
echo "All tests succeed!"