Practical overview
When it fits
Use it when developing an NLU pipeline that combines several tasks, such as intent detection and NER, and you want to configure and train them through one shared-model workflow.
Who it is for
- NLP developers building conversational AI systems with multiple language tasks.
- Teams that need intent classification, named-entity recognition or other supported NLU tasks in a shared-model workflow.
Documented uses
- Define multiple tasks and their data and model settings in a YAML file.
- Prepare task data and train a shared transformer model.
- Request predictions for selected tasks from samples using a trained model.
Requirements & limits
The project is an open-source library under the Apache-2.0 license, distributed through its public GitHub repository.
- The README documents a Python 3.7.3 development and test environment and recommends installation in a virtual environment.
- The workflow requires task-specific YAML configuration and data files before data preparation and training.
- Inference uses a trained model and explicit task names for the predictions requested.
Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.
Prepare data and train a multi-task model
Train a shared transformer model for tasks defined in a YAML task file.
Before you start
- The repository cloned locally with its requirements installed; Python 3.7.3 is the version stated as built and tested.
- Training and development data files named in the YAML task file, and any referenced label-map file.
Steps
Create a YAML task file defining each task's model type, configuration, labels, metrics, loss, task type, and data filenames.
Prepare the data with the command below.
python data_preparation.py --task_file 'sample_task_file.yml' --data_dir 'data' --max_seq_len 50Train with `python train.py --data_dir 'data/bert-base-uncased_prepared_data' --task_file 'sample_task_file.yml' --out_dir 'sample_out' --epochs 5 --train_batch_size 4 --eval_batch_size 8 --grad_accumulation_steps 2 --log_per_updates 25 --save_per_updates 1000 --eval_while_train True --test_while_train True --max_seq_l
Expected outcome
The training command is configured to write model output to `sample_out`; the README describes training a single model across the tasks defined in the file.
Guide limitations
- The documented task-file example uses BERT and specifies a particular prepared-data directory; adjust parameters to match the task configuration and data.
- The repository recommends installing requirements in a virtual environment.
- The documented training workflow does not establish performance or successful execution for a particular dataset or environment.
Run inference with a trained multi-task model
Request predictions for named tasks using a trained model and input samples.
Before you start
- A trained model file, such as
sample_out_dir/multi_task_model.pt. - Input samples and task names corresponding to tasks in the trained model.
Steps
Import the inference class with
from infer_pipeline import inferPipeline.Create a pipeline with
pipe = inferPipeline(modelPath='sample_out_dir/multi_task_model.pt', maxSeqLen=50).Provide samples and task names, then call
pipe.infer(samples, tasks), for example withsamples = [['sample_sentence_1'], ['sample_sentence_2']]andtasks = ['TaskA', 'TaskB'].
Expected outcome
The inference pipeline returns predictions for the supplied samples and requested task names.
Guide limitations
- This workflow assumes a trained model and task names available in that model.
- The documented example shows sample sentences and two tasks; it does not specify output interpretation or guarantees for other inputs.
Compare options for Model inference and serving
These projects document a common task and share a project role. This is a source-based comparison, not an execution benchmark or a guarantee of interchangeability.
| Project | Documented purpose | Platform | Access and requirements |
|---|---|---|---|
| Multi Task Nlp | Define multiple tasks and their data and model settings in a YAML file. | Linux, macOS, Windows | The project is an open-source library under the Apache-2.0 license, distributed through its public GitHub repository. |
| Hyperpose | Customize pose-estimation architectures and datasets. | Docker, Linux, macOS, Windows |
Sources & review
Source record details
- Source availability
- Active
- Sources checked
- 17 October 2026
- Original website title
- hellohaptik/multi-task-NLP · Official homepage title · retained in its source language

