What is it
TFKit is a tool kit mainly for language generation.
It leverages the use of transformers on many tasks with different models in this all-in-one framework.
All you need is a little change of config.
Task Supported
With transformer models - BERT/ALBERT/T5/BART......
| Text Generation | 📝 seq2seq language model |
| Text Generation | 🖊️ causal language model |
| Text Generation | 🖨️ once generation model / once generation model with ctc loss |
| Text Generation | 📝 onebyone generation model |
Getting Started
Learn more from the document.
How To Use
Step 0: Install
Simple installation from PyPI
pip install git+https://github.com/voidful/TFkit.git@refactor-dataset
Step 1: Prepare dataset in csv format
input, target
Step 2: Train model
tfkit-train \
--task clas \
--config xlm-roberta-base \
--train training_data.csv \
--test testing_data.csv \
--lr 4e-5 \
--maxlen 384 \
--epoch 10 \
--savedir roberta_sentiment_classificer
Step 3: Evaluate
tfkit-eval \
--task roberta_sentiment_classificer/1.pt \
--metric clas \
--valid testing_data.csv
Advanced features
Multi-task training
tfkit-train \
--task clas clas \
--config xlm-roberta-base \
--train training_data_taskA.csv training_data_taskB.csv \
--test testing_data_taskA.csv testing_data_taskB.csv \
--lr 4e-5 \
--maxlen 384 \
--epoch 10 \
--savedir roberta_sentiment_classificer_multi_task
Not maintained task
Due to time constraints, the following tasks are temporarily not supported
| Classification | 🏷️ multi-class and multi-label classification |
| Question Answering | 📃 extractive qa |
| Question Answering | 🔘 multiple-choice qa |
| Tagging | 👁️🗨️ sequence level tagging / sequence level with crf |
| Self-supervise Learning | 🤿 mask language model |
Supplement
- transformers models list: you can find any pretrained models here
- nlprep: download and preprocessing data in one line
- nlp2go: create demo api as quickly as possible.
Contributing
Thanks for your interest.There are many ways to contribute to this project. Get started here.
License 
Icons reference
Icons modify from Freepik from www.flaticon.com
Icons modify from Nikita Golubev from www.flaticon.com
Metadata
Release files for tfkit 0.8.20
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| tfkit-0.8.20.tar.gz | 220.6 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| tfkit-0.8.20-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 278.8 kB
Release files / tfkit-0.8.20.tar.gz
| Download URL | tfkit-0.8.20.tar.gz |
|---|---|
| Size | 220.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
dae96214129b8c752a6148452e4046a4c583b145a0d075dd64cd55c0070ebbf6
|
|
BLAKE2b-256 checksum How to use checksums |
e42c3fcd1b598bf9df1fa113f9a6b962ac9be7cf4f2ba61683c1c9b7b775c238
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.10
|
Release files / tfkit-0.8.20-py3-none-any.whl
| Download URL | tfkit-0.8.20-py3-none-any.whl |
|---|---|
| Size | 58.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
edb6d45fdbf29fc2ea42fbf772500afd8399b3c3490c6c90efb0c0aea0b42898
|
|
BLAKE2b-256 checksum How to use checksums |
26ffeb68833818fa4a1693705ea84eb9e5d5ba84a86b2beffb79f52d19f6a11d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.10
|
Security for tfkit 0.8.20
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.