microsoft / microsoft/dstoolkit-mlops-v2

Create a sample custom model with tutorial

Open
#151 0 comments 0 reactions 1 assignee View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
33
Forks
17
PR merge metrics
No merged PRs in 30d

Description

Description

Currently, the sample models in the DSToolkit Model Factory with AzureML SDKv2 are scikit-learn models. This means that the source-code needed to construct the model objects can be pip installed on any compute. A downstream result of such a setup is that the computes that host the batch and online endpoints can have access to the source code needed to define the model objects with a pip install.

For those who will be developing custom classes necessary for model development., these classes could take the form of utility files or python class definitions of models for instance. Currently, the model factory does not have an example of hosting /src code on the computes serving the batch and online endpoints. /src code which is necessary in the definition of the runtime environments for these models.

This story is to create a custom model and set of /src files useful for the model which are referenced at the online and batch endpoints. The model parameters will be handled by a config file.

Acceptance Criteria

Develop /src code which is necessary to scripts run on batch/online endpoints including:

  • Create data wrangling script to download and store data from a public repo into data folder
  • Create tokenizer module to tokenizer data for training and store tokenizer
  • Create modeling module to enable definition of n-gram model, saving, and loading
  • Create train.py script to create and train n-gram model
  • Create predict.py script to run model over test dataset
  • Create score.py to evaluate acc of the trained model
  • Create model registration script to register the model and its artifacts
  • Create benchmark.py script to benchmark the model
  • Create data inferencing scripts for the batch and online endpoints
  • Enable observability

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.