Skip to content

Enhancement idea: default to latest model version when running jobs #37

@bmunday3

Description

@bmunday3

Checklist

Please review first that the issue is fully related with this SDK by checking the relevant checkboxes ([x]).

  • I have a Modzy API Key active and have the entitlements to perform the desired action.
  • I review that have access to Modzy API host.
  • I think that is a error specific to the SDK.
  • I review the documentation and existing issues in order to not duplicate existing ones.
  • I am willing to follow-up on comments in a timely manner.

Info

  • Modzy SDK version: 0.6.0
  • Python version: 3.9.7
  • Operating System: Windows

Description

When submitting a job to any model, one of the parameters is the model version. There are ways to extract the latest version programmatically, but it would be great if the SDK defaulted to the latest version in the case a version is not supplied.

Steps to reproduce

You can get the latest model version this way in the SDK:

for model in models:
    model_info = client.models.get(models[model]['id'])
    if models[model].get('version', None) == None: #let set a version explicitly above
        models[model]['version'] = model_info.latestActiveVersion
    models[model]['name'] = model_info.name

Expected results: Default latest version extracted by SDK automatically if user does not pass version through

Actual results: Requires manual work on user currently

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions