//! Type definitions for TGGN implementation - Using canonical types from lib.rs

use serde::{Deserialize, Serialize};
use std::collections::HashMap;

// NO RE-EXPORTS - Use explicit imports: crate::{InferenceResult, ModelMetadata, ModelType}

/// Training metrics for model performance tracking
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct TrainingMetrics {
    pub loss: f64,
    pub accuracy: f64,
    pub precision: f64,
    pub recall: f64,
    pub f1_score: f64,
    pub training_time_seconds: f64,
    pub epochs_trained: u32,
    pub convergence_achieved: bool,
    pub additional_metrics: HashMap<String, f64>,
}

impl Default for TrainingMetrics {
    fn default() -> Self {
        Self::new()
    }
}

impl TrainingMetrics {
    pub fn new() -> Self {
        Self {
            loss: 0.0,
            accuracy: 0.0,
            precision: 0.0,
            recall: 0.0,
            f1_score: 0.0,
            training_time_seconds: 0.0,
            epochs_trained: 0,
            convergence_achieved: false,
            additional_metrics: HashMap::new(),
        }
    }
}

/// Validation metrics for model performance evaluation
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct ValidationMetrics {
    pub validation_loss: f64,
    pub validation_accuracy: f64,
    pub validation_precision: f64,
    pub validation_recall: f64,
    pub validation_f1_score: f64,
    pub samples_validated: usize,
    pub additional_metrics: HashMap<String, f64>,
}

// NO RE-EXPORTS - Use explicit imports: crate::MLError
