Skip to content

params() should throw when parameters aren't known yet #185

@tomayac

Description

@tomayac

Current implementations makes it impossible to know the actual values of the parameters reported on via params() before the model is downloaded. This means UI that would, for example, set a slider to the defaultTopK can only reliably do so after the model is downloaded.

The current implementation, however, returns made-up values that change after the true values are known, so UI would jump, which is against developer expectations. Instead, the params() function should throw (maybe an InvalidStateError) if the reported values can't be accurate yet to set developer expectations.

(Action item following crbug/441711146.)

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