Real-time structural validation for material extrusion additive manufacturing