Skip to content

[2d] Extend the python library to support declaring models #8

Open
@alaric-dotmesh

Description

@alaric-dotmesh

As a dotscience user, I'd like to be able to use the Python library to declare that my run has produced one or more models, so that I can then use CI integration features to publish those models to production.

See #7 for general support for declaring directories as outputs, which might be a useful first step.

ACs

  • I can declare a file or directory as a named model: If I write code like ds.model("roadsigns", "./model"), the library will attach a label to this run of the form model:roadsigns={"files":{"main":"./model"},"metadata":{}}, and declare ./model as an output if it's a file, or recursively declare all of the files inside it as outputs if it's a directory.
  • I can declare a map of names to files/directories as parts of a named model: If I write code like ds.model(“roadsigns”, {“main”: “./model”, “classes”: “./classes.csv”}), the library will attach a label of the form model:roadsigns={"files":{“main”:”./model”, “classes”: “./classes.csv”},"metadata":{}}, and likewise recursively declare ./model as an output.
  • I can attach arbitrary key=value metadata to models: If I write code like ds.model("x","y", foo="bar"), the library will attach a label of the form model:x={"files":{"main":"y"}, "metadata":{"foo": "bar"}}, and declare y as an output.

Metadata

Metadata

Assignees

No one assigned

    Labels

    taskNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions