Ktrain

Latest version: v0.41.3

Safety actively analyzes 638466 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 13 of 29

0.22.0

New:
- added `breakup_docs` argument to `index_from_list` and `index_from_folder` that potentially speeds up `ask` method substantially
- added `batch_size` argument to `ask` and set default at 8 for faster answer-retrieval

Changed
- refactored `QA` and `SimpleQA` for better extensibility


Fixed:
- Ensure `save_path` is correctyl processed in `Learner.evaluate`

0.21.4

New:
- N/A

Changed
- Changed installation instructions in `README.md` to reflect that using *ktrain* with TensorFlow 2.1 will require downgrading `transformers` to 3.1.0.
- updated requirements with `keras_bert>=0.86.0` due to TensorFlow 2.3 error with older versions of `keras_bert`
- In `lr_find` and `lr_plot`, check for TF 2.2 or 2.3 and make necessary adjustments due to TF bug 41174.

Fixed:
- fixed typos in `__all__` in `text` and graph` modules (PR 250)
- fixed Chinese language translation based on on name-changes of models with `zh` as source language

0.21.3

New:
- N/A

Changed
- added `TopicModel.get_word_weights` method to retrieve the word weights for a given topic
- added `return_fig` option to `Learner.lr_plot` and `Learner.plot`, which allows the matplotlib `Figure` to be returned to user

Fixed:
- N/A

0.21.2

New:
- N/A

Changed
- `SUPPRESS_KTRAIN_WARNINGS` environment variable changed to `SUPPRESS_DEP_WARNINGS`

Fixed:
- N/A

0.21.1

New:
- N/A

Changed
- added `num_beams` and `early_stopping` arguments to `translate` methods in `translation` module that can be set to improve translation speed
- added `half` parameter to `Translator` construcor

Fixed:
- N/A

0.21.0

New:
- Added `translate_sentences` method to `Translator` class that translates list of sentences, where list is fed to model as single batch

Changed
- Removed TensorFlow dependency from `setup.py` to allow users to use *ktrain* with any version of TensorFlow 2 they choose.
- Added `truncation=True` to tokenization in `summarization` module
- Require `transformers>=3.1.0` due to breaking changes
- `SUPPRESS_TF_WARNINGS` environment variable changed to `SUPPRESS_KTRAIN_WARNINGS`

Fixed:
- Use `prepare_seq2seq_batch` insteadd of `prepare_translation_batch` in `translation` module due to breaking change in `transformers==3.1.0`

Page 13 of 29

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.