From 5d6fd6a828a8497208dbcfda4fdb7a766a8d9c71 Mon Sep 17 00:00:00 2001 From: "aniket.kumar" Date: Tue, 24 Oct 2023 17:31:52 +0530 Subject: [PATCH 1/5] merged lightwood & release.yml --- .github/workflows/ligthtwood.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ligthtwood.yml b/.github/workflows/ligthtwood.yml index 9cea8d930..5986e43f7 100644 --- a/.github/workflows/ligthtwood.yml +++ b/.github/workflows/ligthtwood.yml @@ -6,6 +6,8 @@ on: branches: - stable - staging + release: + types: [ published ] jobs: @@ -46,7 +48,7 @@ jobs: deploy: runs-on: ubuntu-latest needs: test - if: github.ref == 'refs/heads/stable' + if: github.ref == 'refs/heads/stable' || github.event_name == 'release' steps: - uses: actions/checkout@v2 - name: Set up Python From 5d4701192198cd5c3260bde21c0f4dd75407c116 Mon Sep 17 00:00:00 2001 From: hamishfagg Date: Tue, 12 Dec 2023 16:23:38 +1300 Subject: [PATCH 2/5] include extras requirements files --- MANIFEST.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MANIFEST.in b/MANIFEST.in index 540b72040..47e0d9457 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1 +1 @@ -include requirements.txt \ No newline at end of file +include requirements*.txt \ No newline at end of file From b3fd4c427201a376d2f314c1f87e3dc50021cbd0 Mon Sep 17 00:00:00 2001 From: Hamish Fagg Date: Wed, 13 Dec 2023 09:16:58 +1300 Subject: [PATCH 3/5] Bump version --- lightwood/__about__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lightwood/__about__.py b/lightwood/__about__.py index a55b713f2..8767aba7b 100644 --- a/lightwood/__about__.py +++ b/lightwood/__about__.py @@ -1,6 +1,6 @@ __title__ = 'lightwood' __package_name__ = 'lightwood' -__version__ = '23.11.1.0' +__version__ = '23.12.2.0' __description__ = "Lightwood is a toolkit for automatic machine learning model building" __email__ = "community@mindsdb.com" __author__ = 'MindsDB Inc' From 64b2c202ea3b33b5d19a30ae6393928543156051 Mon Sep 17 00:00:00 2001 From: Patricio Cerda Mardini Date: Mon, 25 Dec 2023 19:39:08 +0900 Subject: [PATCH 4/5] fix: add compatibility for type-infer==0.0.18 --- .../tutorial_data_analysis/tutorial_data_analysis.ipynb | 4 ++-- lightwood/api/high_level.py | 4 ++-- lightwood/encoder/text/short.py | 2 +- tests/unit_tests/encoder/text/test_short.py | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docssrc/source/tutorials/tutorial_data_analysis/tutorial_data_analysis.ipynb b/docssrc/source/tutorials/tutorial_data_analysis/tutorial_data_analysis.ipynb index 32739df69..f24944815 100644 --- a/docssrc/source/tutorials/tutorial_data_analysis/tutorial_data_analysis.ipynb +++ b/docssrc/source/tutorials/tutorial_data_analysis/tutorial_data_analysis.ipynb @@ -295,10 +295,10 @@ } ], "source": [ - "from type_infer.infer import infer_types\n", + "from type_infer.api import infer_types\n", "from type_infer.base import TypeInformation\n", "\n", - "type_information = infer_types(df, problem_definition.pct_invalid)\n", + "type_information = infer_types(df, config={'engine': 'rule_based', 'pct_invalid': problem_definition.pct_invalid})\n", "\n", "{field.name for field in fields(TypeInformation)} # show the fields this dataclass has" ] diff --git a/lightwood/api/high_level.py b/lightwood/api/high_level.py index 36d2dd9b3..17e7c36dd 100644 --- a/lightwood/api/high_level.py +++ b/lightwood/api/high_level.py @@ -4,7 +4,7 @@ import pandas as pd from lightwood.api.types import JsonAI, ProblemDefinition from dataprep_ml.insights import statistical_analysis -from type_infer.infer import infer_types +from type_infer.api import infer_types from lightwood.api.predictor import PredictorInterface from lightwood.api.json_ai import generate_json_ai from lightwood.helpers.codegen import code_from_json_ai as _code_from_json_ai, _module_from_code, _predictor_from_code @@ -65,7 +65,7 @@ def json_ai_from_problem(df: pd.DataFrame, problem_definition: Union[ProblemDefi log.info(f'Dropping features: {problem_definition.ignore_features}') df = df.drop(columns=problem_definition.ignore_features) - type_information = infer_types(df, problem_definition.pct_invalid) + type_information = infer_types(df, config={'engine': 'rule_based', 'pct_invalid': problem_definition.pct_invalid}) stats = statistical_analysis( df, type_information.dtypes, problem_definition.to_dict(), type_information.identifiers) diff --git a/lightwood/encoder/text/short.py b/lightwood/encoder/text/short.py index 127bb863f..3a3409af7 100644 --- a/lightwood/encoder/text/short.py +++ b/lightwood/encoder/text/short.py @@ -2,7 +2,7 @@ import torch from lightwood.encoder import BaseEncoder from lightwood.encoder.categorical import CategoricalAutoEncoder -from type_infer.helpers import tokenize_text +from type_infer.rule_based.helpers import tokenize_text from lightwood.helpers.torch import concat_vectors_and_pad, average_vectors import pandas as pd diff --git a/tests/unit_tests/encoder/text/test_short.py b/tests/unit_tests/encoder/text/test_short.py index 087ac4ac4..055e18b43 100644 --- a/tests/unit_tests/encoder/text/test_short.py +++ b/tests/unit_tests/encoder/text/test_short.py @@ -1,7 +1,7 @@ import random import unittest from lightwood.encoder.text.short import ShortTextEncoder -from type_infer.helpers import tokenize_text +from type_infer.rule_based.helpers import tokenize_text import torch VOCAB = [ From e4e5344de5ca1fa0c6fae2d2f15b7d53014e11a4 Mon Sep 17 00:00:00 2001 From: Patricio Cerda Mardini Date: Mon, 25 Dec 2023 20:24:49 +0900 Subject: [PATCH 5/5] version bump: 23.12.4.0 --- lightwood/__about__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lightwood/__about__.py b/lightwood/__about__.py index 8767aba7b..43a661b89 100644 --- a/lightwood/__about__.py +++ b/lightwood/__about__.py @@ -1,6 +1,6 @@ __title__ = 'lightwood' __package_name__ = 'lightwood' -__version__ = '23.12.2.0' +__version__ = '23.12.4.0' __description__ = "Lightwood is a toolkit for automatic machine learning model building" __email__ = "community@mindsdb.com" __author__ = 'MindsDB Inc'