eto-ai / rikai

Parquet-based ML data format optimized for working with unstructured data
https://rikai.readthedocs.io/en/latest/
Apache License 2.0
137 stars 19 forks source link

Model Type Design: optional uri #560

Closed da-liii closed 2 years ago

da-liii commented 2 years ago
CREATE (OR REPLACE)? MODEL (IF NOT EXISTS)? model=qualifiedName
      (FLAVOR flavor=identifier)?
      (MODEL_TYPE modeltype=qualifiedName)?
      (OPTIONS optionList)?
      (RETURNS datatype=dataType)?
      (USING uri=STRING)

URI specifies how to load a model. Sometimes, we load a model in that way:

import ml_pkg

model = ml_pkg.ocr_model()
preds = model(inputs)

For the above use case, we do not need a model registry (or we need an anonymous model registry).

BootstrapModelType is also needed to verify if a ModelType can be bootstrapped.