Show Candidate data in Model Version
What does this MR do and why?
Adds candidate info to the model version, and updates the candidate detail presenter to use camelCase instead of snake_case since that has become the default on model registry. This MR does not change the UI.
Screenshots
Before | After | |
---|---|---|
Model Detail | ||
Model Version Detail |
How to set up and validate locally
-
Enable the feature flag
Feature.enable("model_registry")
-
Create the data (in rails console):
p = Project.find_by(id: 20) # or whatever project you want to use for testing model = Ml::FindOrCreateModelService.new(p, "model_1").execute model_version = Ml::FindOrCreateModelVersionService.new(p, { model_name: "model_1", version: "1.0.#{i}" }).execute c = model_version.candidate c.metrics.create(name: "AUC", value: 0.1, step: 0) c.metrics.create(name: "Accuracy", value: 0.2, step: 2) c.metrics.create(name: "Accuracy", value: 0.5, step: 3) c.metadata.create(name: "some name", value: "some data") c.params.create(name: "max-depth", value: "3")
-
Navigate to
<your_project>/-/ml/models
. Verify that metadata, params and metrics now appear in theDetails
section -
Select the version in the versions tab. . Verify that metadata, params and metrics now appear
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #428905 (closed)
Edited by Eduardo Bonet