easy_ml 0.2.0.pre.rc48 → 0.2.0.pre.rc49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 528284a7ca2b0c4aa7370104e5d3e6206b6ada6785da1f76274bb8ce01e74145
4
- data.tar.gz: c9aa88ad10369733a124142ed47d1595a06986be06c49817c1b08142992d7146
3
+ metadata.gz: e342ccd144abd65ab937bace40c11524e76a82aef6a6c5eb16d3ba0b3eae1e84
4
+ data.tar.gz: f90fc476542773a25d4f8e1995f68b5ceb733d5a9b03e39f687d9a157aade66d
5
5
  SHA512:
6
- metadata.gz: 8c37ec1e30a93c91594f305078d7282d0aa5e51cddce120d983e32ff34a04633aad0fd388538314d724d2ae7cb2adb5da58bd65b881aa10a5b94c07f2faca32a
7
- data.tar.gz: abe7ad4855b7cae96535cd828e47886ed25553b2a7d396811e6846857ccf31c402e5f9536ddd60577ab91bfcc7b538810a05db6622bd1c81e2ba20390c506fb6
6
+ metadata.gz: 638190fdf3351bb87f44c6276c9159abeb4a1a12cf135942c888a365aba76b21a0a6b5f43e5adfd44908fec1c2ef3cfe5fa7010c4ba964052de8c6948601d959
7
+ data.tar.gz: 36a4b4d3a34fc51f7283a9d1d2d517e0c09f040286070abda480181ebdf012c5ae158f4f6e9f79d6da53b22692fe675094e899bb32a21da1f4b1f6f307332455
@@ -44,16 +44,16 @@ interface ScheduleModalProps {
44
44
 
45
45
  const METRICS = {
46
46
  classification: [
47
- { value: 'accuracy_score', label: 'Accuracy', description: 'Overall prediction accuracy' },
48
- { value: 'precision_score', label: 'Precision', description: 'Ratio of true positives to predicted positives' },
49
- { value: 'recall_score', label: 'Recall', description: 'Ratio of true positives to actual positives' },
50
- { value: 'f1_score', label: 'F1 Score', description: 'Harmonic mean of precision and recall' }
47
+ { value: 'accuracy_score', label: 'Accuracy', description: 'Overall prediction accuracy', direction: 'maximize' },
48
+ { value: 'precision_score', label: 'Precision', description: 'Ratio of true positives to predicted positives', direction: 'maximize' },
49
+ { value: 'recall_score', label: 'Recall', description: 'Ratio of true positives to actual positives', direction: 'maximize' },
50
+ { value: 'f1_score', label: 'F1 Score', description: 'Harmonic mean of precision and recall', direction: 'maximize' }
51
51
  ],
52
52
  regression: [
53
- { value: 'mean_absolute_error', label: 'Mean Absolute Error', description: 'Average absolute differences between predicted and actual values' },
54
- { value: 'mean_squared_error', label: 'Mean Squared Error', description: 'Average squared differences between predicted and actual values' },
55
- { value: 'root_mean_squared_error', label: 'Root Mean Squared Error', description: 'Square root of mean squared error' },
56
- { value: 'r2_score', label: 'R² Score', description: 'Proportion of variance in the target that is predictable' }
53
+ { value: 'mean_absolute_error', label: 'Mean Absolute Error', description: 'Average absolute differences between predicted and actual values', direction: 'minimize' },
54
+ { value: 'mean_squared_error', label: 'Mean Squared Error', description: 'Average squared differences between predicted and actual values', direction: 'minimize' },
55
+ { value: 'root_mean_squared_error', label: 'Root Mean Squared Error', description: 'Square root of mean squared error', direction: 'minimize' },
56
+ { value: 'r2_score', label: 'R² Score', description: 'Proportion of variance in the target that is predictable', direction: 'maximize' }
57
57
  ]
58
58
  };
59
59
 
@@ -609,8 +609,13 @@ export function ScheduleModal({ isOpen, onClose, onSave, initialData, tunerJobCo
609
609
  <div className="ml-3">
610
610
  <h3 className="text-sm font-medium text-blue-800">Deployment Criteria</h3>
611
611
  <p className="mt-2 text-sm text-blue-700">
612
- The model will be automatically deployed when the {formData.retraining_job_attributes.metric} is{' '}
613
- {formData.retraining_job_attributes.direction === 'minimize' ? 'below' : 'above'} {formData.retraining_job_attributes.threshold}.
612
+ {(() => {
613
+ const metricsList = METRICS[initialData.task === 'classification' ? 'classification' : 'regression'];
614
+ const selectedMetric = metricsList.find(m => m.value === formData.retraining_job_attributes.metric);
615
+ const direction = selectedMetric?.direction === 'minimize' ? 'below' : 'above';
616
+
617
+ return `The model will be automatically deployed when the ${selectedMetric?.label} is ${direction} ${formData.retraining_job_attributes.threshold}.`;
618
+ })()}
614
619
  </p>
615
620
  </div>
616
621
  </div>
@@ -10,13 +10,13 @@ module EasyML
10
10
 
11
11
  @last_activity = Time.current
12
12
  setup_signal_traps
13
- # @monitor_thread = start_monitor_thread
13
+ @monitor_thread = start_monitor_thread
14
14
 
15
15
  @model.actually_train do |iteration_info|
16
16
  @last_activity = Time.current
17
17
  end
18
18
  ensure
19
- # @monitor_thread&.exit
19
+ @monitor_thread&.exit
20
20
  end
21
21
 
22
22
  private
@@ -42,6 +42,7 @@ module EasyML
42
42
  @cleaned_up = true
43
43
  @model.last_run.update(status: "failed", error_message: error_message, completed_at: Time.current)
44
44
  @model.update(is_training: false)
45
+ @model.unlock!
45
46
  end
46
47
 
47
48
  def start_monitor_thread
@@ -46,7 +46,6 @@ module EasyML
46
46
  validates :name, presence: true
47
47
  validates :datasource_type, presence: true
48
48
  validates :datasource_type, inclusion: { in: DATASOURCE_NAMES }
49
- # validate :validate_datasource_exists
50
49
 
51
50
  before_save :set_root_dir
52
51
  after_initialize :read_adapter_from_configuration, if: :persisted?
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module EasyML
4
- VERSION = "0.2.0-rc48"
4
+ VERSION = "0.2.0-rc49"
5
5
 
6
6
  module Version
7
7
  end
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "entrypoints/Application.tsx": {
3
- "file": "assets/entrypoints/Application.tsx-KJwHDm3F.js",
3
+ "file": "assets/entrypoints/Application.tsx-u6L4jkNy.js",
4
4
  "name": "entrypoints/Application.tsx",
5
5
  "src": "entrypoints/Application.tsx",
6
6
  "isEntry": true,