🤖 AI Summary
In marine-domain multi-task anomaly detection, existing MLOps systems suffer from low reusability and high maintenance overhead. Method: This paper proposes a Ports-and-Adapters architectural approach tailored for Machine Learning-Enhanced Systems (MLES), deeply integrating the Hexagonal Architecture into MLOps practice. It decouples core business logic—including feature engineering and model inference—from external dependencies such as data sources, deployment environments, and monitoring services, thereby enabling highly cohesive, loosely coupled component reuse across microservices. The design supports flexible derivation of multiple domain-specific microservices from a single codebase and seamlessly integrates with ML pipelines and Domain-Driven Design. Contribution/Results: Evaluated in the Ocean Guard system, the architecture significantly improves code reuse, system portability, and team development velocity, while reducing deployment and iterative development complexity for marine AI systems across heterogeneous environments.
📝 Abstract
ML-Enabled Systems (MLES) are inherently complex since they require multiple components to achieve their business goal. This experience report showcases the software architecture reusability techniques applied while building Ocean Guard, an MLES for anomaly detection in the maritime domain. In particular, it highlights the challenges and lessons learned to reuse the Ports and Adapters pattern to support building multiple microservices from a single codebase. This experience report hopes to inspire software engineers, machine learning engineers, and data scientists to apply the Hexagonal Architecture pattern to build their MLES.