In this study, a farm-scale mathematical programming model for sheep and goat farms is proposed to simulate economic performance, including new resilience sheep traits that allow animals to counteract the presence of infectious and noninfectious diseases. The model was developed in the Small Ruminants Breeding for Efficiency and Resilience (SMARTER) Horizon 2020 project. The SMARTER model is a comprehensive and adaptable linear programming model that enables the assessment of hypothetical scenarios/challenges related to animal traits that prevent infectious and noninfectious diseases. The optimal performance and the structure of the farm are modeled under the presence of infectious and noninfectious diseases (disease plan) and under conditions where no diseases occur (future plan). A comparison of the model solutions, between presence and absence of diseases, provides suggested adjustments to the farming system and insights into the potential shape of new sustainable farm system profiles for the sheep and goat sector. Technical and economic data from five different sheep farms and one goat farm in Greece and France were used in this empirical application to assess different scenarios in the presence of mastitis, parasitism, and lameness in the flocks. The results showed that the profitability and sustainability of the farms are significantly improved when the resilience of animals reduces the impact of the diseases (the highest increase in gross margin was 23.5%). However, although there is substantial improvement in the economic performance of the farms that rear healthy animals, this does not affect the production and management plan of the farmer and does not alter the farm’s structure.