The Tenebrio molitor has become the first insect added to the catalogue of novel foods by the European Food Safety Authority due to its rich nutritional value and the low carbon footprint produced during its breeding. The large scale of Tenebrio molitor breeding makes automation of the process, which is supported by a monitoring system, essential. Present research involves the development of a 3-module system for monitoring Tenebrio molitor breeding. The instance segmentation module (ISM) detected individual growth stages (larvae, pupae, beetles) of Tenebrio molitor, and also identified anomalies: dead larvae and pests. The semantic segmentation module (SSM) extracted feed, chitin, and frass from the obtained image. The larvae phenotyping module (LPM) calculated features for both individual larvae (length, curvature, mass, division into segments, and their classification) and the whole population (length distribution). The modules were developed using machine learning models (Mask R-CNN, U-Net, LDA), and were validated on different samples of real data. Synthetic image generation using a collection of labelled objects was used, which significantly reduced the development time of the models and reduced the problems of dense scenes and the imbalance of the considered classes. The obtained results (average $$F1>0.88$$ for ISM and average $$F1>0.95$$ for SSM) confirm the great potential of the proposed system.
2 November 2023 in Engineering Applications of Artificial Intelligence
Automatic dimensioning of mealworms based on computer vision is challenging due to occlusions. Amodal instance segmentation (AIS) could be a viable solution, but the acquisition of annotated training data is difficult and time-consuming. This work proposes a new method to prepare data for training AIS models that reduces the human annotation effort significantly. Instead of acquiring the occluded images directly, only images of fully visible larvae are acquired and processed, allowing obtaining their contours via automatic segmentation. Next, synthetic images with occlusions are generated from the database of automatically extracted instances. The generation procedure uses simple computer graphics tools and is computationally inexpensive, yet yields images that allow training off-the-shelf AIS models. Since those models need to be tested on real data, which requires manual annotation, a data acquisition method that significantly simplifies the test set annotation process is demonstrated. Results are reported in terms of the amodal segmentation quality as well as the accuracy of larvae dimensioning, measured using the histogram intersection metric. The best-performing model achieves a mean average precision of 0.41 and a histogram intersection of 0.77, confirming the effectiveness of the proposed method of data acquisition and generation. The method is not specific to mealworm detection and could be applied to other similar problems where object occlusions pose a challenge.
3 January 2023 in Computers and Electronics in Agriculture
LLMs (Large Language Models) have become increasingly important, with chatbots being widely used in commercial settings to assist employees and answer customer questions. To protect a company’s reputation and ensure compliance, it’s crucial that chatbots do not generate harmful content, even in the face of deliberate jailbreak attacks. Researchers propose various methods to secure LLMs, known as guardrails, to prevent harmful content generation and jailbreak attacks. This article aims to comprehensively analyze existing guardrail solutions and provide guidelines for selecting the optimal solution for specific scenarios. The study compared six different guardrail methods across three versions of LLMs (Mistral Large 24.02, Meta Llama 3-8B Instruct, Anthropic Claude 3.5 Sonnet), including two baseline approaches, two cloud-based solutions (AWS Guardrails, Azure AI Content Safety), and two other popular non-cloud solutions (NeMo by Nvidia and Llama Guard by Meta). Thirteen datasets were used for evaluation: ten representing harmful questions in jailbreak attacks and three with neutral prompts similar to harmful questions to check for excessive blocking. The best results were achieved by AWS Guardrails (averaged accuracy across models 96.8%) and NeMo (93.9%) The results clearly showed that using guardrails is essential when building commercial applications based on LLMs due to advancements in effective jailbreak attacks.