vios_app 0.1.1

Small JSON vaults: Argon2id + AES-GCM, with optional AAD binding.
Documentation
// 🎭 congruence.rs — Facial-Tone Emotional Congruence Checker

/// Calculates congruence score between tone and face emotion
/// Returns score (0.0 - 1.0) and human label like "MATCH: HIGH"
pub fn calculate_congruence(tone: &str, face: &str) -> (f32, String) {
    let tone = tone.to_lowercase();
    let face = face.to_lowercase();

    if tone == face {
        return (1.0, "MATCH: PERFECT".to_string());
    }

    let close_match = matches!(
        (tone.as_str(), face.as_str()),
        ("calm", "neutral")
            | ("neutral", "calm")
            | ("happy", "surprise")
            | ("surprise", "happy")
            | ("sad", "fear")
            | ("fear", "sad")
            | ("angry", "disgust")
            | ("disgust", "angry")
    );

    if close_match {
        (0.8, "MATCH: CLOSE".to_string())
    } else {
        (0.3, "MISMATCH: DIVERGENT".to_string())
    }
}