//! Product entity type utilities.
//!
//! Product-specific classification and hierarchy building is now handled by
//! the semantic resolution engine (semantic.rs). This module retains the
//! entity type guard used by the worker pipeline and API layer.

/// Returns true if the entity type is a product type.
/// Used by the worker pipeline to determine if semantic subtype/hierarchy
/// metadata should be considered for relationship edge persistence.
pub fn is_product_entity_type(t: &str) -> bool {
    matches!(t, "product" | "product_catalog")
}

#[cfg(test)]
mod tests {
    #[test]
    fn is_product_entity_type_check() {
        assert!(super::is_product_entity_type("product"));
        assert!(super::is_product_entity_type("product_catalog"));
        assert!(!super::is_product_entity_type("person"));
        assert!(!super::is_product_entity_type("company"));
        assert!(!super::is_product_entity_type(""));
    }
}
