Real-time cost control method and system for pig raising enterprises

By real-time collection and analysis of full-cycle structured data from pig farming enterprises, combined with theoretical standard values ​​from experimental fields and machine learning prediction thresholds, and automated adjustment operations, we can solve the problems of data fragmentation, lagging cost accounting, and insufficient accuracy in anomaly detection in traditional pig farming enterprises, achieve real-time and accurate cost control, and reduce resource waste.

CN120598588APending Publication Date: 2025-09-05WENS FOODSTUFF GROUP CO LTD
View PDF 0 Cites 5 Cited by

Patent Information

Application Number
CN202510592499.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-08
Publication Date
2025-09-05

AI Technical Summary

Technical Problem

The cost control system of traditional pig farming enterprises has a data collection and processing mechanism that is unable to support the dynamic management needs of the entire process, resulting in data fragmentation, delayed cost accounting, insufficient accuracy of anomaly detection and inefficient manual response. It is unable to integrate the complete structured data of the entire life cycle of breeding pigs, piglets and meat pigs in real time, and is unable to dynamically reflect market price fluctuations and differences in pig growth stages. It is difficult to accurately identify hidden waste links and potential risk points.

Method used

By collecting structured data from the entire breeding cycle of breeding pigs, piglets and meat pigs in real time, real-time cost indicators are calculated based on preset algorithms. These data are compared with the theoretical standard values ​​of experimental field data and future cost thresholds predicted by machine learning, abnormal costs are determined, and corresponding automated adjustment operations are performed, including feed formula optimization, medication plan revision, equipment parameter adjustment, etc.

Benefits of technology

It realizes minute-level dynamic update of cost data and full-dimensional transparent management, accurately identifies abnormal costs, shortens problem discovery cycle, reduces manual investigation costs, improves exception handling efficiency, reduces resource waste, and promotes enterprise cost control from passive response to active intervention, significantly reducing controllable costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120598588A_ABST
    Figure CN120598588A_ABST
Patent Text Reader

Abstract

The invention discloses a real-time cost management and control method and system for a pig raising enterprise. The method comprises the following steps: collecting structured data of a whole breeding period of boars, piglets and pork pigs in real time; based on the structured data, real-time cost indexes of the boars, the piglets and the pork pigs are calculated through a preset algorithm; comparing the real-time cost index with a theoretical standard value based on experimental field data; comparing the real-time cost index with a future cost threshold predicted by machine learning; when the real-time cost index exceeds the theoretical standard value or the future cost threshold value, it is judged that the cost is abnormal; and executing a corresponding exception adjustment operation according to the type of the exception cost. According to the invention, the technical problems of fragmentization of data acquisition, lagging of cost accounting, insufficient anomaly detection precision and low manual response efficiency in the prior art are solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of livestock and poultry breeding technology, and in particular to a real-time cost control method, system, computer equipment and storage medium for a pig farming enterprise. Background Art

[0002] Cost control systems in traditional pig farming operations have long been constrained by extensive management models. The core issue lies in the inability of data collection and processing mechanisms to support dynamic management across the entire process. Existing technologies rely on manual record-keeping and periodic accounting within financial systems. Data sources are scattered across independent processes, such as feed collection, water and electricity metering, low-consumables, and drug consumption. This fragments key cost information and prevents real-time integration of a complete, structured data chain covering the entire lifecycle of breeding pigs, piglets, and hogs, from entry to exit. Cost calculations significantly lag behind actual production activity. Traditional accounting allocation models, based on static unit prices and fixed cycles, fail to dynamically reflect the impact of market price fluctuations on resource costs, nor can they promptly capture changes in consumption patterns caused by differences in pig growth stages. This leads to significant discrepancies between cost accounting results and actual resource inputs. In terms of anomaly detection, due to the lack of a scientific benchmarking system and predictive models, managers can only rely on historical experience or simple thresholds, making it difficult to accurately identify hidden waste and potential risk points. For example, abnormal behaviors such as overfeeding and unproductive water and electricity losses are often overlooked due to delayed data feedback. Furthermore, the existing system still relies on manual intervention to investigate and adjust the solution after discovering cost anomalies. This creates a window of several days or even weeks between problem identification and intervention, leading to a continuous accumulation of wasted resources. This "after-the-fact accounting, passive response" mechanism not only limits the timeliness of cost control but also makes it difficult for companies to build cost advantages through refined operations amidst fierce market competition.

[0003] To address the above-mentioned problems, no effective solutions have been proposed so far. Summary of the Invention

[0004] The main purpose of the present invention is to provide a real-time cost control method and system for pig farming enterprises, aiming to solve the technical problems of data collection fragmentation, delayed cost accounting, insufficient anomaly detection accuracy and low manual response efficiency in the background technology.

[0005] To achieve the above objectives, the present invention provides a first aspect of a real-time cost control method for a pig farming enterprise, comprising: Step S100: collecting structured data of the entire breeding cycle of sows, piglets and meat pigs in real time; Step S200: Calculating real-time cost indicators of sows, piglets, and meat pigs using a preset algorithm based on the structured data; Step S300: Comparing the real-time cost indicator with a theoretical standard value based on experimental field data; comparing the real-time cost indicator with a future cost threshold predicted by machine learning; when the real-time cost indicator exceeds the theoretical standard value or the future cost threshold, determining it as an abnormal cost; Step S400: performing corresponding abnormal adjustment operations according to the type of the abnormal cost.

[0006] Preferably, in step S300, determining the theoretical standard value includes the following steps: Step S311: collecting daily benchmark data of sows, piglets, and meat pigs at different production stages in the experimental farm, wherein the daily benchmark data includes feed consumption benchmark data, drug and vaccine usage benchmark data, low-consumables benchmark data, and water and electricity consumption benchmark data; Step S312: Clean the single-day benchmark data, remove outliers and establish a standardized data set; Step S313: Based on the standardized data set, a standard consumption model corresponding to the production stage is established through association analysis; Step S314: Outputting confidence intervals of theoretical standard values ​​including feed, medicines and vaccines, low-consumption products, and water and electricity according to the standard consumption model.

[0007] Preferably, in step S300, determining the future cost threshold predicted by machine learning includes the following steps: Step S321: Collecting historical production data of breeding pig batches, piglet breeding batches, and hog breeding batches from the breeding farm and the breeder, wherein the historical production data includes feed consumption, water and electricity consumption, drug and vaccine usage, low-consumables consumption, number of breedings, number of farrowings, pig mortality rate, and disease monitoring records; Step S322: extracting time series features from the historical production data to generate standardized training samples; Step S323: Modeling the standardized training samples through a long short-term memory neural network to learn the correlation between resource consumption and cost indicators; Step S324: Evaluate the model prediction accuracy based on the validation set and adjust the model parameters until the prediction error meets the preset requirements; Step S325: Input the current production data into the trained model and output the confidence interval of the cost indicator threshold in the future period.

[0008] Preferably, in step S300, the step of determining abnormal costs includes: Step S331: Performing a horizontal comparative analysis of the real-time cost indicators of the breeding batches of sows, piglets, and hogs of the sow farms and farmers. When the real-time cost indicator of any breeding batch exceeds the upper or lower limit of the corresponding theoretical standard value confidence interval, it is determined to be an abnormal cost; Step S332: Compare the real-time cost indicator with the cost threshold confidence interval output by the machine learning prediction model. If the real-time cost indicator continues to exceed the cost threshold confidence interval for multiple consecutive monitoring cycles, it is determined to be a persistent abnormal cost. Step S333: Based on the real-time cost indicator type corresponding to the abnormal cost, the type of abnormal cost is determined, and the type of abnormal cost includes at least one of abnormal feed consumption cost, abnormal drug and vaccine consumption cost, abnormal low-consumables consumption cost, abnormal water and electricity consumption cost, abnormal feeding schedule cost or abnormal market procurement cost.

[0009] Preferably, in step S400, the step of performing a corresponding abnormal adjustment operation according to the type of the abnormal cost includes: When abnormal feed consumption costs are detected, automatic feed formula optimization is performed; When abnormal drug and vaccine consumption costs are detected, the medication plan revision operation is executed; When abnormal consumption costs of low-consumable items are detected, the use authority control operation is executed; When abnormal water and electricity consumption costs are detected, automatic adjustment of equipment operating parameters is performed; When abnormal feeding progress cost is detected, the nutrient ratio adjustment operation is performed; When abnormalities in the raw material market procurement costs are detected, a procurement strategy update operation is executed.

[0010] Preferably, the real-time cost control method for a pig farming enterprise further includes: The automatic feed formula optimization operation includes mining the correlation data between historical feed formulas and pig growth rates through a big data analysis platform to generate alternative raw material ratio plans, and screening the most cost-effective supplier based on the feed demand threshold predicted by machine learning; The medication plan revision operation includes generating disease screening plans based on mortality monitoring data and disease positive records, and dynamically adjusting vaccination doses; The aforementioned permission management and control operations include activating a dynamic permission control strategy based on the cost threshold of low-value consumables per unit, triggered by benchmarked parameters of the experimental field, implementing category-based application restrictions for non-essential production positions, and forcibly linking multi-level electronic approval processes with production task traceability. The automatic adjustment of equipment operating parameters includes generating ventilation equipment start-stop strategies based on pig house environmental data, executing intelligent start-stop rules for high-power equipment, dynamic control of sensor lighting, and linkage water and electricity cut-offs for empty pen identification to limit non-production energy consumption; The nutrient ratio adjustment operation includes comparing the production data of the pig breeding batches collected in real time with the standard growth curve, increasing the feeding ratio of key nutrients for batches with lagging growth progress, and adjusting the energy density of the feed according to the ambient temperature; The procurement strategy update operation includes real-time access to market data to generate cross-regional procurement plans, triggering emergency reserves in conjunction with disaster warnings, and optimizing supplier priorities.

[0011] Preferably, the real-time cost control method for pig farming enterprises also includes a traffic light early warning mechanism, specifically: When the type and source of abnormal costs are detected, a traffic light warning sign is generated based on the comparison result of the key parameter exceeding the standard and the preset threshold value, where a red sign indicates that authority control or automated operation instructions need to be triggered immediately, a yellow sign indicates that manual review and optimization suggestions need to be generated, and a green sign indicates that the indicators have returned to normal and the authority restrictions have been lifted; the traffic light warning sign is linked to at least one automated adjustment operation among the feed formula automatic optimization operation, medication plan revision operation, permission control operation, equipment operating parameter automatic adjustment operation, nutrient ratio adjustment operation and procurement strategy update operation, and automatically updates the sign status according to the actual cost data after the automated adjustment operation is completed.

[0012] A second aspect of the present invention provides a real-time cost control system for a pig farming enterprise, comprising: The collection module is used to collect structured data of the entire breeding cycle of breeding pigs, piglets and meat pigs in real time; A calculation module, which calculates the real-time cost indicators of breeding pigs, piglets and meat pigs based on the structured data using a preset algorithm; a determination module, configured to compare the real-time cost indicator with a theoretical standard value based on experimental field data; compare the real-time cost indicator with a future cost threshold predicted by machine learning; and determine that the real-time cost indicator is abnormal when it exceeds the theoretical standard value or the future cost threshold; The processing module is used to perform corresponding abnormal adjustment operations according to the type of the abnormal cost.

[0013] A third aspect of the present invention provides a computer device, characterized in that it includes a processor and a memory, the memory is used to store executable instructions, and the instructions are used to control the processor to execute any method described in the first aspect.

[0014] A fourth aspect of the present invention provides a computer-readable storage medium, characterized in that a computer program is stored thereon, and when the computer program is executed by a processor, it implements the method as described in any one of the first aspects.

[0015] The present invention provides a real-time cost control method and system for pig farming enterprises. By collecting structured data of the entire breeding cycle of breeding pigs, piglets and meat pigs in real time, the system effectively integrates fragmented information scattered in feed, medicine, water, electricity, low-consumption products and other links, and builds a complete data chain covering the entry and exit of pigs. This method completely solves the problems of data islands and manual record lags in the traditional model, and realizes minute-level dynamic update of cost data and full-dimensional transparent management. Through two-dimensional dynamic benchmark comparison, dual verification of experimental standard values ​​and machine learning prediction thresholds, combined with differentiated tolerance rules, the system realizes intelligent identification and classification of abnormal costs. It shortens the problem discovery cycle, reduces the cost of manual investigation, can identify hidden cost problems such as feed waste, drug overconsumption, and equipment abnormalities, and avoids the ambiguity of traditional experience judgment; automatically triggers adjustment operations based on the abnormality type, and realizes closed-loop control of the entire process from data collection, abnormality judgment to execution intervention. Through automated operations such as formula optimization, medication revision, and equipment parameter adjustment, it quickly blocks resource waste, improves abnormality handling efficiency, and promotes enterprise cost control from passive response to active intervention, reducing unnecessary resource consumption from the source, and significantly reducing the ineffective investment in controllable costs such as feed, water and electricity, drugs, and low-consumption products. The present invention solves the technical problems of data collection fragmentation, cost accounting lag, insufficient abnormality detection accuracy, and low manual response efficiency in the existing technology. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following will briefly introduce the drawings required for the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on the structures shown in these drawings without creative work. The purpose of the present invention, the functional features and advantages will be further explained in conjunction with the embodiments and with reference to the drawings. In the drawings: Figure 1 A flowchart of a real-time cost control method for a pig farming enterprise provided by an embodiment of the present invention; Figure 2 A flow chart of a method for determining a theoretical standard value provided in an embodiment of the present invention; Figure 3 A flowchart of a method for determining a future cost threshold value predicted by machine learning provided in an embodiment of the present invention; Figure 4 A flowchart of a method for determining abnormal costs provided by an embodiment of the present invention; Figure 5A schematic diagram of a real-time cost control system for a pig farming enterprise provided by an embodiment of the present invention; Figure 6 A schematic diagram of a real-time cost control computer device for a pig farming enterprise provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0017] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.

[0018] It should be noted that if the embodiments of the present invention involve directional indications (such as up, down, left, right, front, back, etc.), such directional indications are only used to explain the relative position relationship, movement status, etc. between the various components under a certain specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indication will also change accordingly.

[0019] In addition, if there are descriptions involving "first", "second", etc. in the embodiments of the present invention, the descriptions of "first", "second", etc. are only for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of such features. In addition, the meaning of "and / or" appearing throughout the text includes three parallel schemes. Taking "A and / or B" as an example, it includes scheme A, or scheme B, or a scheme in which A and B are satisfied at the same time. In addition, the technical solutions between the various embodiments can be combined with each other, but it must be based on the ability of ordinary technicians in this field to implement. When the combination of technical solutions is mutually contradictory or cannot be implemented, it should be deemed that such a combination of technical solutions does not exist and is not within the scope of protection required by the present invention.

[0020] In view of this, the main purpose of the present invention is to provide a real-time cost control method and system for pig farming enterprises, aiming to solve the technical problems of data collection fragmentation, delayed cost accounting, insufficient anomaly detection accuracy and low manual response efficiency in the background technology.

[0021] like Figures 1 to 4 As shown, the first aspect of the present invention provides a real-time cost control method for a pig farming enterprise, comprising: Step S100: collecting structured data of the entire breeding cycle of sows, piglets and meat pigs in real time; Step S200: Calculating real-time cost indicators of sows, piglets, and meat pigs using a preset algorithm based on the structured data; Step S300: Comparing the real-time cost indicator with a theoretical standard value based on experimental field data; comparing the real-time cost indicator with a future cost threshold predicted by machine learning; when the real-time cost indicator exceeds the theoretical standard value or the future cost threshold, determining it as an abnormal cost; Step S400: performing corresponding abnormal adjustment operations according to the type of the abnormal cost.

[0022] Specifically, in one embodiment of the present invention, in a breeding pig farm scenario, feed tower weighing equipment, smart water meters and electricity meters are deployed in key production links such as reserve houses, breeding houses, and farrowing houses. The feed consumption, water and electricity usage and other data of each functional house are collected in real time through the Internet of Things gateway, and automatically connected with the enterprise ERP system and human resources management system to synchronously obtain the drug collection records, low-value consumables consumption lists and labor cost details of each production line, forming a full-dimensional data set covering feed, medicines, water, electricity, manpower, low-consumables and manufacturing costs. Data on various cost items are collected and integrated in the following ways: feed consumption uses feed tower weighing equipment to collect feeding data of different feed varieties in real time; drug and vaccine usage is obtained from the drug receipt record to obtain vaccine injection volume and therapeutic drug consumption details; water and electricity consumption are automatically collected through smart water meters and electricity meters for each shed; low-value consumables receipt records cover the receipt quantity and category of office supplies, labor protection materials, etc.; labor costs are connected to the human resources management system to obtain real-time salary and benefit details of breeders and managers; common expenses are imported from the financial system every month, and facility depreciation and maintenance costs are evenly distributed according to the number of livestock on hand.

[0023] In the pig farming scenario, farmers use the COM port direct connection technology of the scale to automatically collect data for piglet admission, feed collection, and pig sales. When piglet transport vehicles are weighed, the average piglet arrival weight is automatically calculated and uploaded to the system. Each time feed transport vehicles collect feed, the net amount collected is recorded in real time by the difference between the gross weight and the tare weight on the scale. When pigs are sold, the average weight and number of pigs sold are automatically captured. The system also integrates the drug collection registration, death records, and sales receipts from the breeding management system, dynamically linking the pig's age, feeding stage, and cost data. It also automatically calculates the estimated average weight before sale using a standard feed quantity model, building a data chain covering the entire pig life cycle from admission, feeding, death, and sale.

[0024] Data for each cost item is collected and integrated using the following methods: Piglet collection data includes collection date, collection type, collection quantity, piglet age in days, average piglet weight, and unit cost. Average piglet weight is automatically collected via a direct connection to the weighbridge's COM port. When the piglet transport vehicle is weighed, the system calculates the average piglet weight in real time based on the difference between the tare and gross weights and uploads the data. The unit cost is automatically calculated by the system. Feed collection data includes collection date, collection type, collection weight, and unit cost. Collection weight is automatically collected via a direct connection to the weighbridge's COM port. Each time the feed transport vehicle is weighed, the system calculates the net weight in real time based on the difference between the tare and gross weights and uploads the data. The unit cost is automatically calculated by the system. Feed collection adheres to the "use up, then re-collect" rule to ensure data continuity. Medication collection data includes collection date, medication name, collection quantity, and unit cost. Medication collection data is entered into the computer system by the operator, and the unit cost is automatically calculated by the system. Pig mortality data includes the date of death, number of pigs killed, age at death in days, age at death in days, and unit cost. Age at death is calculated by adding the piglet age in days and the piglet age in days, and the unit cost is automatically calculated by the system. Pig sales data includes the date of sale, number of pigs sold, age at sale in days, age at sale in days, average sales weight, and unit cost. Average sales weight is automatically collected via direct connection to the COM port of the scale: When a pig transport vehicle is weighed, the system calculates the average sales weight in real time based on the difference between the tare weight and the gross weight and uploads the data. Age at sale is calculated by adding the piglet age in days and the piglet age in days, and the unit cost is automatically calculated by the system. Estimated average weight data before sale includes the estimated date and the estimated average weight of the herd. The system automatically calculates the estimated average weight based on an experimentally verified standard feed quantity model and historical feed collection data. Simultaneously, sales staff manually estimate the average weight at the breeding site and enter it into the system, creating a double verification mechanism.

[0025] After completing the structured data collection for the entire pig breeding cycle, the system calculates the real-time cost indicators of the pigs using a preset algorithm. The specific implementation process is as follows: In the breeding pig farm scenario, the monthly real-time cost indicators of breeding pigs are calculated by analyzing the resource consumption data and corresponding cost unit prices of each production line and functional shed, adding labor costs and manufacturing expenses, calculating the total input cost of breeding pigs, and evenly distributing it to the monthly inventory number, thereby obtaining the monthly real-time cost of breeding pigs. The data consumption data includes feed, medicine, sundries, water and electricity consumption.

[0026] Specifically, the cost of a single breeding pig = (feed consumption cost + drug consumption cost + vaccine consumption cost + labor cost + electricity cost + water cost + low-consumables collection cost + common area cost) / average daily number of pigs on hand.

[0027] The meanings of various real-time cost indicators are as follows: Feed consumption cost: refers to the cost of all feed consumed by breeding pigs over a period of time. The total cost of feed is calculated by the consumption and unit price of each type of feed.

[0028] Drug consumption cost: includes all drug costs related to the health management of breeding pigs, calculated by usage quantity and unit price.

[0029] Vaccine consumption cost: refers to the relevant costs used for vaccination of breeding pigs, calculated based on the quantity used and unit price.

[0030] Labor costs: covers the labor costs related to breeding and management of breeding pigs, including the wages and benefits of breeders, team leaders, district heads, farm heads and other staff.

[0031] Electricity costs: The electricity consumption costs incurred to maintain the normal operation of the breeding pig production facilities, such as the electricity costs of the heating and ventilation system, lighting equipment and environmental protection system, calculated based on the smart meter reading and local electricity prices.

[0032] Water Fee: This includes all water consumption costs related to pig drinking water, environmental management, living area water use, etc. The water fee is calculated by recording the water meter reading and the local water price.

[0033] Cost of obtaining low-value consumables: refers to the expenditure on low-value consumables required for the daily management of breeding pigs, specifically including office supplies, daily necessities, environmental protection materials and labor protection supplies.

[0034] Common expenses: refers to other shared costs involved in maintaining the overall breeding production operation, such as facility depreciation, maintenance, reception, travel expenses, etc., which are allocated to each breeding pig based on the total number of the farm, and are not allocated separately to each production line and functional house.

[0035] Similarly, in the breeding farm scenario, real-time cost indicators are set for piglets. By analyzing resource consumption data and unit costs in the farrowing house, the total input cost of the piglets is calculated and evenly distributed across the monthly inventory to arrive at the monthly real-time cost of the piglets. Specifically, the cost per piglet = (feed consumption cost + medication consumption cost + vaccine consumption cost) / average daily number of piglets in stock. The meaning of each indicator is as follows: Feed consumption cost: refers to the cost of all feed consumed by piglets over a period of time. The total cost of feed is calculated by the consumption and unit price of each type of feed.

[0036] Medication consumption cost: includes all medication costs related to piglet health management, calculated by usage quantity and unit price.

[0037] Vaccine consumption cost: refers to the relevant expenses for piglet vaccination, calculated based on the quantity used and unit price.

[0038] In the pig farming scenario, a real-time cost indicator for pigs is set. The total cost is calculated based on the resource consumption data and unit cost of each pig batch during the farming process. The resource consumption data includes piglets, feed, and medicine. By evenly distributing the total cost to the pig inventory and excluding the cost of deaths, the real-time inventory cost of the pig batch during the farming cycle is calculated. The specific calculation formula is as follows: Real-time cost per piglet = total cost of piglets received / total number of piglets received Real-time feed cost per pig = (total feed cost - feed cost of dead pigs - feed cost of marketed pigs) / number of pigs on hand Real-time drug cost per pig = (total feed cost - drug cost of dead pigs - drug cost of marketed pigs) / number of pigs on hand Real-time total cost per pig = real-time piglet cost per pig + real-time feed cost per pig + real-time drug cost per pig Real-time piglet cost per pound = Real-time piglet cost per head / estimated average weight Real-time feed cost per pound = Real-time feed cost per head / estimated average weight Real-time drug cost per kilogram = Real-time drug cost per head / estimated average weight Real-time total cost per pound = real-time total cost per head / estimated average weight After completing the calculation of real-time cost indicators, the system uses a two-dimensional dynamic benchmark comparison mechanism to accurately determine abnormal costs. Based on the historical data of the experimental field, a standardized cost model for different production stages is established, quantifiable cost thresholds are set for different production stages, and abnormality determination is achieved through dynamic deviation rate calculation. The real-time cost indicators of the current breeding pigs or piglets are compared with the experimental benchmarks of the corresponding stages. Differentiated tolerance ranges are set according to the sensitivity and business impact of different cost items. For example: feed consumption has reasonable fluctuations due to formula adjustments, and a wider threshold (±15%-20%) is allowed; drugs and vaccines need to be strictly controlled due to epidemic risks, and a narrower threshold (±10%) is set; water and electricity consumption is significantly affected by seasonal temperature changes, and there are occasional fluctuations in the use of low-consumption items, so a higher tolerance is allowed, set to the theoretical standard value ± (20%-30%). At the same time, historical data modeling is used to predict future cost fluctuations. Using an LSTM neural network, time-series modeling is performed on historical data (feed price fluctuations, disease incidence, and seasonal water and electricity consumption) to predict cost fluctuations over the next three days and generate confidence intervals. For example, the feed cost per kilogram threshold at a 95% confidence level is 0.48-0.52 yuan / catties. When a real-time cost indicator (e.g., feed cost per kilogram of 0.58 yuan) exceeds the predicted range for two consecutive monitoring periods, it is marked as a "persistent anomaly." Based on the identified anomaly type, the system performs corresponding adjustment actions. For example, automated control commands trigger key anomaly types (e.g., drug cost exceeding standards, increased disease risk), automatically adjusting equipment parameters and restricting access permissions. Optimization suggestions are intelligently pushed, generating specific action suggestions for anomalies requiring manual intervention (e.g., feed formula adjustments, procurement plan changes) and sending them to management terminals. Cross-system collaboration integrates with external systems such as the supply chain management system and environmental control equipment to achieve closed-loop operations such as automatic price comparison for purchase orders and dynamic optimization of energy-consuming equipment parameters.

[0039] It can be understood that, through the implementation of the above technical solutions, this embodiment can achieve the following significant beneficial effects compared with traditional cost control methods: breaking through the lag of traditional accounting on a monthly basis, realizing minute-level collection, dynamic calculation and visualization of cost data, so that managers can grasp the cost dynamics of each production link in real time; through two-dimensional dynamic benchmark comparison, double verification of experimental standard values ​​and machine learning prediction thresholds, combined with differentiated tolerance rules, intelligent identification and classification of abnormal costs can be achieved, shortening the problem discovery cycle, reducing manual investigation costs, and being able to identify hidden cost problems such as feed waste, drug overconsumption, and equipment abnormalities, avoiding the ambiguity of traditional experience judgment; automated adjustment strategies and cross-system linkage control, transforming resource waste control from passive response to active intervention, improving the efficiency of exception handling, reducing unnecessary resource consumption from the source, and significantly reducing the ineffective investment in controllable costs such as feed, water, electricity, and drugs.

[0040] Preferably, in step S300, determining the theoretical standard value includes the following steps: Step S311: collecting daily benchmark data of sows, piglets, and meat pigs at different production stages in the experimental farm, wherein the daily benchmark data includes feed consumption benchmark data, drug and vaccine usage benchmark data, low-consumables benchmark data, and water and electricity consumption benchmark data; Step S312: Clean the single-day benchmark data, remove outliers and establish a standardized data set; Step S313: Based on the standardized data set, a standard consumption model corresponding to the production stage is established through association analysis; Step S314: Outputting confidence intervals of theoretical standard values ​​including feed, medicines and vaccines, low-consumption products, and water and electricity according to the standard consumption model.

[0041] Specifically, in one embodiment of the present invention, first, sows, piglets, and hogs at different production stages were selected as experimental subjects within a standardized experimental field. A high-precision sensor network, including silo weighing equipment, smart water meters, smart electricity meters, and environmental monitoring devices, was deployed to collect real-time baseline data on feed consumption, drug and vaccine usage, water and electricity consumption, low-consumables, and environmental parameter data. The data collection cycle covered the entire production cycle, with complete growth data collected for a sample size of no less than 100 pigs at each production stage. The feed consumption baseline data recorded actual feed consumption by the pigs at each production stage on a daily basis, distinguishing between different feed types. The drug and vaccine usage baseline data tracked vaccination records and treatment medication use, correlating them with the corresponding pig health status. The low-consumables baseline data used records of low-value consumables. The water and electricity consumption baseline data monitored water and electricity usage directly related to pig farming within the piggery, excluding consumption in the living area. The environmental parameter data continuously collected environmental indicators such as temperature, humidity, and ammonia concentration.

[0042] After collecting the daily baseline data of breeding pigs and meat pigs at different production stages in the experimental field, the system will pre-process the original daily baseline data: first, it will automatically identify and delete abnormal data that exceeds the reasonable range. For example, if the feed consumption of a single sow suddenly increases to three times the normal value on a certain day, the system will determine that it is a sensor failure or human error and mark it as invalid data; then the data in different units will be standardized and converted into a unified dimension. For example, the feed consumption will be unified into "kg / head·day", and the water and electricity consumption will be converted into "cubic meters / head·day" and "kilowatt-hours / head·day"; secondly, the data needs to be aligned in time series. According to the growth age of the pigs, the pig herd data of the same breeding batch are aligned along the time axis to ensure the consistency of the time series of data comparison and finally generate a standardized data set.

[0043] Based on the cleaned, standardized dataset, the system constructs a standard consumption model through correlation analysis. Specifically, the system analyzes feed consumption data by analyzing the correlation between age, feed type, ambient temperature, and feed consumption at different production stages to establish theoretical feed consumption curves for each stage. For medication and vaccine data, the system combines herd health status, disease positivity history, and immunization schedule to construct a baseline medication model for different disease risk levels. For water and electricity consumption data, the system correlates pen type, seasonal variations, and equipment operating time to establish a dynamic water and electricity consumption reference model. The system further uses statistical methods to calculate historical data distributions and generate confidence intervals for theoretical standard values ​​for feed, medications, vaccines, water, and electricity. For example, the confidence interval for daily feed consumption for gestating sows is set at 2.3-3.2 kg / head, and the confidence interval for a single vaccine dose for lactating piglets is set at 1.8-2.2 ml / head. These confidence intervals are dynamically optimized based on the accumulation of experimental field data. When feed efficiency improves in new batches of pigs due to breed improvements or environmental manipulation, the system automatically narrows the confidence interval to improve the accuracy of the standard.

[0044] It is understandable that by collecting the full-cycle production data of the experimental field through a high-precision sensor network, and combining it with automated cleaning and standardized processing, manual recording errors and abnormal interference can be effectively eliminated; the standard consumption model constructed based on correlation analysis can dynamically respond to environmental changes and differences in production conditions. For example, in high temperature seasons, the confidence interval of electricity consumption in the farrowing house is automatically relaxed to avoid misjudgment due to ambient temperature fluctuations, while maintaining the rationality of cost monitoring; through the confidence interval comparison mechanism, the system can accurately locate abnormal links that deviate from the theoretical standard value. For example, the daily water consumption of the farrowing house of a pig farm exceeds the upper limit of the confidence interval by 15%. The system automatically triggers an early warning and associates the equipment operation records to help managers quickly discover flushing valve failures, avoid waste of water and electricity resources and save costs; the theoretical standard value based on the experimental field data can provide a unified management benchmark for different pig farms and production lines, and promote the standardization process of large-scale breeding.

[0045] Preferably, in step S300, determining the future cost threshold predicted by machine learning includes the following steps: Step S321: Collecting historical production data of breeding pig batches, piglet breeding batches, and hog breeding batches from the breeding farm and the breeder, wherein the historical production data includes feed consumption, water and electricity consumption, drug and vaccine usage, low-consumables consumption, number of breedings, number of farrowings, pig mortality rate, and disease monitoring records; Step S322: extracting time series features from the historical production data to generate standardized training samples; Step S323: Modeling the standardized training samples through a long short-term memory neural network to learn the correlation between resource consumption and cost indicators; Step S324: Evaluate the model prediction accuracy based on the validation set and adjust the model parameters until the prediction error meets the preset requirements; Step S325: Input the current production data into the trained model and output the confidence interval of the cost indicator threshold in the future period.

[0046] Specifically, in one embodiment of the present invention, in the scenario of breeding pig farms and pig farmers raising pigs, the steps of predicting future cost thresholds through machine learning technology are as follows: First, the system obtains multi-dimensional production data by integrating historical data collection modules of breeding pig batches, piglet breeding batches and pig breeding batches of breeding pig farms and farmers. Historical data covers feed consumption, water and electricity consumption, drug and vaccine usage, low-consumables consumption, number of matings, number of farrowings, pig mortality rate and disease monitoring records. The specific collection method includes real-time reading of material tower weighing data and smart water and electricity meter readings from IoT sensors, exporting vaccination records and treatment drug details from the breeding management system, and synchronizing parameters such as temperature, humidity, and ammonia concentration with environmental monitoring equipment. The data covers the entire production cycle to ensure temporal consistency and data integrity.

[0047] The system then extracts and standardizes time series features from historical production data. The system aligns the raw data by breeding batch and age in days to generate a time series dataset. Key features are extracted using sliding window statistical methods, such as calculating average feed consumption and mortality trends over the past seven days, and marking seasonal fluctuations and unexpected events. Data is then normalized to a uniform dimension, eliminating magnitude differences between indicators, and generating standardized training samples.

[0048] Next, a long-short-term memory neural network (LSTM) was used to model the standardized training samples. The model input layer receives time-aligned data on feed consumption, water and electricity consumption, consumables consumption, disease records, and environmental parameters, with a time step set to cover the typical growth stages of the pig herd. The network structure consists of multiple layers of LSTM units and dropout layers. Training is performed using a mean squared error loss function and an Adam optimizer to learn the dynamic correlation between resource consumption and cost indicators. The training objective is to predict the threshold range for feed, drug, consumables, and water and electricity costs in the future cycle. Historical data is divided into training, validation, and test sets, preserving the temporal characteristics of the data in chronological order. The model's prediction accuracy is evaluated using the validation set, and the number of network layers, number of neurons, and learning rate are dynamically adjusted until the prediction error meets the preset requirements. The model is fine-tuned monthly with newly added production data to adapt to changes in farm management strategies or environmental conditions, ensuring that the prediction thresholds are consistent with actual production trends.

[0049] Finally, the current production data is input into the trained LSTM long short-term memory neural network model, which outputs the predicted value of the cost indicator in the future period and its confidence interval. The system dynamically sets the cost threshold based on the prediction results. For example, it combines the feed market price fluctuations and the growth stage of the pig herd to generate a reasonable range of feed costs per head in the next 30 days. The confidence interval is automatically adjusted as the actual production data is updated. When it is monitored that the cost data continues to deviate from the threshold, an early warning is triggered and optimization suggestions are generated.

[0050] It can be understood that this embodiment realizes the dynamic prediction of future cost thresholds through machine learning models, which significantly improves the foresight and accuracy of cost control of pig farming enterprises; the system is based on the long-short-term memory neural network trained based on historical data, which can capture the temporal patterns of feed, water, electricity, low-consumables and drug consumption, and predict future cost fluctuation trends in combination with environmental and production events; by setting dynamic confidence intervals, managers can identify abnormal cost risks in advance, such as adjusting procurement plans and epidemic prevention measures before feed prices rise or the peak of epidemics, effectively reducing resource waste; the model's adaptive learning mechanism ensures that the prediction threshold continues to fit the actual changes in production, such as the efficiency improvement caused by pig breed improvement or environmental regulation can be automatically reflected in the threshold adjustment; the linkage analysis of prediction results and real-time cost data provides decision makers with full-cycle support from short-term intervention to long-term planning, and promotes enterprises to achieve refined and intelligent management.

[0051] Preferably, in step S300, the step of determining abnormal costs includes: Step S331: Performing a horizontal comparative analysis of the real-time cost indicators of the breeding batches of sows, piglets, and hogs of the sow farms and farmers. When the real-time cost indicator of any breeding batch exceeds the upper or lower limit of the corresponding theoretical standard value confidence interval, it is determined to be an abnormal cost; Step S332: Compare the real-time cost indicator with the cost threshold confidence interval output by the machine learning prediction model. If the real-time cost indicator continues to exceed the cost threshold confidence interval for multiple consecutive monitoring cycles, it is determined to be a persistent abnormal cost. Step S333: Based on the real-time cost indicator type corresponding to the abnormal cost, the type of abnormal cost is determined, and the type of abnormal cost includes at least one of abnormal feed consumption cost, abnormal drug and vaccine consumption cost, abnormal low-consumables consumption cost, abnormal water and electricity consumption cost, abnormal feeding schedule cost or abnormal market procurement cost.

[0052] Specifically, in one embodiment of the present invention, the system first dynamically compares the real-time cost data of the breeding pig batches, piglet breeding batches and meat pig breeding batches of the breeding pig farms and farmers based on the confidence interval of the theoretical standard value constructed by the experimental field. The real-time cost indicators of each breeding batch, such as feed consumption cost, drug and vaccine cost, low-consumables cost, water and electricity cost, are matched with the confidence interval of the theoretical standard value of the corresponding production stage; for example, if the daily feed consumption of a batch of lactating piglets exceeds the upper limit of the confidence interval set by the experimental field, the system immediately marks it as an abnormal feed consumption cost; during the comparison process, the system automatically eliminates temporary fluctuations caused by environmental mutations or equipment failures to ensure the accuracy of the judgment results.

[0053] Secondly, the system uses the confidence interval of future cost thresholds predicted by machine learning models to track and analyze real-time cost indicators across multiple monitoring periods. If a batch's real-time cost data consistently exceeds the predicted threshold for multiple consecutive monitoring periods (e.g., three days), it is identified as a persistently abnormal cost. For example, if the feed costs of a particular pig batch exceed the upper limit of the predicted range for three consecutive days, the system, combined with the pig herd's growth curve and environmental data, will confirm this abnormality and trigger an upgraded warning.

[0054] Finally, the system automatically classifies the causes of abnormalities based on the indicator types and associated data corresponding to the abnormal costs: if the real-time feed cost exceeds the standard and the feed quantity difference analysis shows that the feeding amount exceeds the standard value, the feed consumption cost is determined to be abnormal; when the indicators related to the health of the pig herd continue to be stable or decline and at the same time the drug cost continues to exceed the limit, the drug and vaccine consumption cost is determined to be abnormal; when the cost per head of low-consumables continues to exceed the standard value of the experimental field and the frequency / amount of use deviates from the work order requirements, the low-consumables consumption cost is determined to be abnormal; when the water and electricity cost anomaly is associated with the pig house equipment operation log and equipment failure or energy waste is identified, the water and electricity consumption cost is determined to be abnormal; when the deviation between the planned feed amount and the real-time consumption is compared and it is found that the pig herd is lagging in growth or nutritionally unbalanced, the feeding progress cost is determined to be abnormal; combined with the external market price fluctuation data, the cost surge caused by improper procurement timing or supplier selection is identified, and the market procurement cost is determined to be abnormal.

[0055] Understandably, based on the dual-reset confidence intervals of experimental field standards and machine learning predictions, the system can distinguish temporary fluctuations from real anomalies, reducing the misjudgment rate; through automatic classification of anomaly types, managers can quickly locate the root cause of the problem and provide a basis for formulating targeted measures; the full process automation from data collection, anomaly determination to type attribution promotes enterprise cost management from passive response to active control.

[0056] Preferably, in step S400, the step of performing a corresponding abnormal adjustment operation according to the type of the abnormal cost includes: When abnormal feed consumption costs are detected, automatic feed formula optimization is performed; When abnormal drug and vaccine consumption costs are detected, the medication plan revision operation is executed; When abnormal consumption costs of low-consumable items are detected, the use authority control operation is executed; When abnormal water and electricity consumption costs are detected, automatic adjustment of equipment operating parameters is performed; When abnormal feeding progress cost is detected, the nutrient ratio adjustment operation is performed; When an abnormality in market procurement costs is detected, a procurement strategy update operation is performed.

[0057] Specifically, in one embodiment of the present invention, the steps of performing corresponding adjustment operations according to the abnormal cost type are as follows: When anomalies in feed consumption costs are detected, the system automatically triggers the feed formula optimization process. Using a big data analytics platform, it mines historical feed formulas and pig growth rate correlations, combines them with real-time feed ingredient market price fluctuations, and generates alternative raw material ratios. For example, if the cost of a batch of breeding pig feed exceeds the theoretical standard, the system uses a multi-objective optimization algorithm based on raw material price fluctuations and nutritional model constraints to generate alternative ratios within the constraints of core nutritional parameters such as feed-to-meat ratio, lysine, and metabolic energy, ensuring nutritional balance and optimal cost. The optimized formula is automatically executed by intelligent feed mixing equipment, and a list of suppliers with the best price-performance ratio is pushed to the procurement module, guiding the feed factory to adjust its production plan.

[0058] When abnormal drug and vaccine consumption costs are detected, the system initiates a dynamic revision mechanism for medication plans. Combining mortality monitoring data with disease positivity records, it generates disease screening plans and adjusts vaccination dosages. For example, if medication costs for a particular production line consistently exceed limits, the system correlates this with the rising disease positivity rate of the pigs in that line and automatically increases the frequency of vaccinations. It also limits overages through internal approval processes, triggers drug procurement alerts, and recommends alternative treatment options. The revised medication plan is then simultaneously pushed to the veterinary workstation and inventory management system.

[0059] When abnormal consumption costs for low-value consumables are detected, the system performs the following actions: Using the field-verified single-unit low-value consumable cost standard as a benchmark, if actual production costs consistently exceed the standard, the system automatically implements access restrictions within the low-value consumables requisition platform, prohibiting employees in non-essential positions from directly claiming core consumables. If urgent requisitions are truly necessary for production, the applicant must submit an electronic approval work order. Only after approval by the on-site supervisor, cost control specialist, and biosafety officer at each level can access to the specified consumable category and quantity be unlocked. The system simultaneously records the approval process and requisition details, forming a traceable closed-loop control system.

[0060] When abnormal water and electricity consumption costs are detected, the system automatically adjusts the equipment operating parameters and adjusts the ventilation equipment start and stop strategies in real time based on the pig house environmental sensor data. For example, the fan operating frequency is increased during high temperature periods in summer. At the same time, combined with the peak and valley electricity price periods monitored by the smart meter, the operating time of non-essential equipment (such as the flushing system) is automatically delayed. If the water consumption of a certain pen is abnormal, the system immediately starts the water leakage detection program and restricts non-production water use, and simultaneously sends a maintenance work order to the maintenance team.

[0061] When the system detects abnormal feeding progress and costs, it dynamically adjusts the nutrient ratio, comparing real-time herd growth data with the standard growth curve and increasing the feeding ratio of key nutrients for the lagging herds. For example, if a herd's average daily weight gain decreases due to low ambient temperature, the system automatically increases the energy density of the feed, adjusts the feeding time and frequency through the intelligent feeder, and simultaneously activates the environmental control equipment to raise the pig house temperature to the set threshold.

[0062] When abnormal market procurement costs are detected, the system updates procurement strategies and generates cross-regional optimization plans. The system integrates real-time feed and pharmaceutical price data from commodity trading platforms, combines inventory levels with future demand forecasts, and automatically generates procurement window recommendations. For example, if soybean meal price fluctuations cause feed costs to exceed a threshold, the system recommends urgent purchases from suppliers in lower-price regions, initiates futures contracts to hedge price risks, and reassesses supplier credit ratings to prioritize partnerships.

[0063] Preferably, the real-time cost control method for a pig farming enterprise further includes: The automatic feed formula optimization operation includes mining the correlation data between historical feed formulas and pig growth rates through a big data analysis platform to generate alternative raw material ratio plans, and screening the most cost-effective supplier based on the feed demand threshold predicted by machine learning; The medication plan revision operation includes generating disease screening plans based on mortality monitoring data and disease positive records, and dynamically adjusting vaccination doses; The aforementioned permission management and control operations include activating a dynamic permission control strategy based on the cost threshold of low-value consumables per unit, triggered by benchmarked parameters of the experimental field, implementing category-based application restrictions for non-essential production positions, and forcibly linking multi-level electronic approval processes with production task traceability. The automatic adjustment of equipment operating parameters includes generating ventilation equipment start-stop strategies based on pig house environmental data, executing intelligent start-stop rules for high-power equipment, dynamic control of sensor lighting, and linkage water and electricity cut-offs for empty pen identification to limit non-production energy consumption; The nutrient ratio adjustment operation includes comparing the production data of the pig breeding batches collected in real time with the standard growth curve, increasing the feeding ratio of key nutrients for batches with lagging growth progress, and adjusting the energy density of the feed according to the ambient temperature; The procurement strategy update operation includes real-time access to market data to generate cross-regional procurement plans, triggering emergency reserves in conjunction with disaster warnings, and optimizing supplier priorities.

[0064] Specifically, in one embodiment of the present invention, the steps of performing corresponding adjustment operations according to the abnormal cost type are as follows: The automated feed formula optimization process involves integrating historical feed formula data with pig growth rate records through a big data analytics platform to establish a correlation model between raw material ratios and growth efficiency. When abnormal feed consumption costs are detected, the platform automatically analyzes the current feed ingredient ratios and market price fluctuations to generate alternative raw material ratios. For example, if corn prices rise significantly, the system recommends increasing the proportion of rice bran or wheat bran. Using machine learning, it predicts feed demand thresholds for the next 30 days, identifies suppliers with the best price-performance ratio, and directly distributes the optimized formula instructions to the intelligent feed mixing equipment, which then simultaneously adjusts the feed mill's production plan and raw material purchase orders to ensure nutritional balance and manageable costs.

[0065] Medication plan revisions include: Based on real-time mortality monitoring data and disease positivity records, the system dynamically adjusts medication strategies. If a batch of pigs experiences abnormal drug and vaccine consumption costs, the platform automatically links historical disease data with the batch's current health status to generate a disease screening plan and revise vaccination dosages. For example, for a herd with an increasing disease positivity rate, the system increases vaccination frequency to once every two weeks and restricts overdose through an approval process. The revised medication plan is then pushed to veterinary workstations to guide on-site operations, triggering drug inventory alerts and recommending alternative treatment options.

[0066] The specific operations of the authority control for obtaining the materials include: when the cost of a single low-value consumable exceeds the standard, the system automatically triggers a dynamic authority control strategy based on the benchmark value of the laboratory, and restricts the authority to apply for core consumables for non-essential production positions on the obtaining platform, such as protective clothing, syringes, etc. Emergency obtaining requires the submission of an electronic work order, which is unlocked after multi-level approval by the on-site supervisor, cost accountant, and biosafety manager, and is forcibly bound to the corresponding production task code, such as "Hill B Disinfection-2024-07 Work Order". The system records the approval link and obtaining details in real time, generates a traceable electronic ledger, marks abnormal losses for unmatched production tasks or excessive obtaining behaviors, and simultaneously pushes them to the management terminal of the responsible department to avoid hidden waste and achieve transparent management and control.

[0067] Automatic adjustment of equipment operating parameters involves generating ventilation equipment start / stop strategies based on temperature, humidity, and ammonia concentration data collected by environmental sensors in the piggery. For example, during high summer temperatures, the system automatically increases fan frequency. In conjunction with peak and off-peak electricity prices monitored by smart meters, the system delays the operation of non-essential equipment (such as flushing systems) until nighttime, when prices are lower. If a water meter reading in a particular pen rises abnormally, the system immediately initiates a leak detection program, restricts non-production water use, sends a repair instruction to the maintenance team, and simultaneously updates the baseline water and electricity consumption model.

[0068] The nutrient ratio adjustment process involves comparing real-time pig batch production data, such as average daily weight gain and feed consumption, with a standard growth curve. The system then identifies batches with lagging growth progress. For these batches, the system automatically increases the feed ratio of key nutrients and adjusts feed energy density based on ambient temperature. For example, in winter, during low temperatures, the system increases the fat content in the feed to enhance the pigs' resistance to cold. It also coordinates with environmental control equipment to adjust the pig house temperature to the optimal threshold to ensure efficient nutrient absorption.

[0069] Procurement strategy updates include: The system leverages real-time access to commodity market data and disaster warning information to dynamically generate cross-regional procurement plans. For example, when a typhoon warning is triggered, the system automatically increases emergency feed reserves and prioritizes sourcing from suppliers in non-affected areas. By combining historical partnership data and price fluctuation trends, the system optimizes the supplier priority list, identifying cost-effective and reliable partners. Furthermore, futures contracts are used to lock in forward raw material prices to hedge market risks.

[0070] It can be understood that the present invention achieves the following technical effects through a multi-dimensional automated adjustment mechanism: dynamic optimization of feed formula combined with intelligent screening of suppliers can reduce raw material costs; revision of medication plans based on real-time data can improve vaccine coverage and reduce drug waste; dynamic control of low-value consumables use authority and a multi-level approval and traceability mechanism can realize explicit management and control of hidden losses and reduce non-productive waste; equipment operation strategies are linked with peak and valley electricity prices to save water and electricity costs; dynamic adjustment of nutrient ratios is linked with environmental control equipment to solve the problem of growth lag caused by environmental factors; emergency reserves driven by disaster warnings and supplier priority optimization ensure production continuity; closed-loop control from data collection to decision execution reduces manual intervention, and the decision response speed is greatly improved compared with the pure manual mode.

[0071] Preferably, the real-time cost control method for pig farming enterprises also includes a traffic light warning mechanism, specifically: When the type and source of abnormal costs are detected, a traffic light warning sign is generated based on the comparison result of the key parameter exceeding the standard and the preset threshold value, where a red sign indicates that authority control or automated operation instructions need to be triggered immediately, a yellow sign indicates that manual review and optimization suggestions need to be generated, and a green sign indicates that the indicators have returned to normal and the authority restrictions have been lifted; the traffic light warning sign is linked to at least one automated adjustment operation among the feed formula automatic optimization operation, medication plan revision operation, permission control operation, equipment operating parameter automatic adjustment operation, nutrient ratio adjustment operation and procurement strategy update operation, and automatically updates the sign status according to the actual cost data after the automated adjustment operation is completed.

[0072] Specifically, in one embodiment of the present invention, the system monitors in real time the cost indicators of pig breeding farms and pig farmers' pig breeding batches, including feed consumption, drug and vaccine usage, water and electricity consumption, low-consumables consumption, breeding progress deviations, and market procurement cost fluctuations. Traffic light indicators are dynamically generated based on preset threshold rules and the extent of the excess. When key parameters exceed the confidence interval of the theoretical standard value or the future cost threshold predicted by machine learning, the system determines the warning level according to the following rules: Red flag: Triggered when a key parameter exceeds the preset upper threshold for at least two monitoring cycles. For example, if the cost of a batch of feed exceeds the upper limit of the forecast range for two consecutive days, the system will determine a red alert, immediately triggering automatic feed formula optimization and freezing current feed collection permissions.

[0073] Yellow flag: Triggered when a parameter deviates from the standard value but does not reach the red threshold, or when the limit is exceeded for only a single period. For example, if a production line's drug or vaccine consumption exceeds the limit on a single day but recovers the next day, the system will mark it as a yellow alert, generate a revised medication plan, and send it to the veterinary workstation for manual review and implementation.

[0074] Green indicator: This is triggered when a real-time cost metric returns to the threshold range or an automated adjustment is executed effectively. For example, after adjusting the device's operating parameters and returning water and electricity consumption to a reasonable range, the red indicator turns green and the device's permissions are automatically unlocked.

[0075] It is understandable that traffic light warning signs can be linked with automated adjustment operations, as illustrated below: The specific linkage of automatic optimization operation of feed formula is as follows: when the red mark is triggered, the system immediately starts the formula optimization process, generates alternative ratio plans based on real-time raw material prices, and links the intelligent feeding equipment to execute the new formula; when the yellow mark is triggered, the system generates optimization suggestions for manual confirmation and execution.

[0076] The specific linkage of the medication plan revision operation is as follows: when the red mark is triggered, the system automatically increases the vaccination dosage of batches with high disease risk and suspends the authority to obtain abnormal drugs; when the yellow mark is triggered, a medication adjustment suggestion is generated and needs to be approved by a veterinarian before implementation.

[0077] The specific linkage of access control operations is as follows: when the consumption cost of low-consumables triggers a red flag, the system immediately freezes access to core consumables for non-essential positions and enforces a multi-level electronic approval process. All emergency requests require dual approval from both the biosafety supervisor and the cost control specialist, and must be linked to a production task traceability code, such as "Pen A Disinfection-2024-07 Work Order." For example, if the cost of disinfectant for a single head on a production line exceeds the standard by 20% for two consecutive days, the system automatically restricts the line's employees' access to protective clothing and disinfectant, authorizing only veterinary specialists to receive limited quantities after approval. When a yellow flag is triggered, suggestions for optimizing consumable usage are generated and pushed to the on-site supervisor's workstation. These suggestions require manual review and implementation of some access restrictions. Consumption data for the next three days is also monitored to determine whether to upgrade the warning level.

[0078] The automatic adjustment operation linkage of equipment operating parameters is as follows: the red mark triggers the forced energy-saving mode of the ventilation equipment and shuts down non-essential power loads; when the yellow mark is triggered, the system recommends a staggered power consumption plan and allows managers to adjust it manually.

[0079] The specific linkage of the nutritional ratio adjustment operation is as follows: when the abnormal feeding progress cost triggers the red mark, the system automatically increases the energy density of the lagging batch feed and adjusts the feeding frequency; when the yellow mark is triggered, the system generates a nutritional optimization plan that needs to be reviewed by a nutritionist to take effect.

[0080] The specific linkage of procurement strategy update operations is as follows: when the red mark of market procurement cost is triggered, the system immediately initiates cross-regional emergency procurement and locks low-price futures contracts; when the yellow mark is triggered, the system generates a supplier price comparison list that requires approval and execution by the procurement supervisor.

[0081] After automated adjustments are executed, the system tracks actual cost data changes in real time and dynamically updates warning status based on the latest indicators. For example, if the consumption of a batch of feed returns to the standard range after formula optimization, the red indicator will automatically turn green the next day. Simultaneously, an operational effectiveness analysis report will be generated to verify the effectiveness of the optimization measures. If costs still exceed the standard after adjustments, the system will upgrade the warning level and trigger stricter control measures.

[0082] It can be understood that this embodiment achieves precise graded response through the deep linkage of the traffic light warning mechanism and the automated adjustment operation. The red mark directly triggers the automated operation, the yellow mark guides the manual review, and the green mark confirms the restoration of normality, forming a hierarchical management and control system, which significantly improves the efficiency compared with traditional manual decision-making.

[0083] like Figure 5 As shown, the second aspect of the present invention provides a real-time cost control system for a pig farming enterprise, comprising: The collection module is used to collect structured data of the entire breeding cycle of breeding pigs, piglets and meat pigs in real time; A calculation module, which calculates the real-time cost indicators of breeding pigs, piglets and meat pigs based on the structured data using a preset algorithm; a determination module, configured to compare the real-time cost indicator with a theoretical standard value based on experimental field data; compare the real-time cost indicator with a future cost threshold predicted by machine learning; and determine that the real-time cost indicator is abnormal when it exceeds the theoretical standard value or the future cost threshold; The processing module is used to perform corresponding abnormal adjustment operations according to the type of the abnormal cost.

[0084] like Figure 6 As shown, the third aspect of the present invention provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that when the processor executes the computer program, the real-time cost control method for pig farming enterprises as described in the first aspect is implemented.

[0085] The fourth aspect of the present invention also provides a computer-readable storage medium, on which a real-time cost control processing program for pig farming enterprises is stored. When the real-time cost control program for pig farming enterprises is executed by a processor, the steps of the real-time cost control method for pig farming enterprises as described in any of the above embodiments are implemented.

[0086] The processor can be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor, etc. The processor is the control center of the pig farming enterprise real-time cost control system, and uses various interfaces and lines to connect the various parts of the pig farming enterprise real-time cost control system to process the operational devices.

[0087] The memory can be used to store the computer programs and / or modules. The processor implements the various functions of the pig farming enterprise real-time cost control system by running or executing the computer programs and / or modules stored in the memory and accessing the data stored in the memory. The memory can mainly include a program storage area and a data storage area. The program storage area can store an operating system and at least one application required for a function (such as a sound playback function, an image playback function, etc.); the data storage area can store data created based on the use of the mobile phone (such as audio data, a phone book, etc.). In addition, the memory can include high-speed random access memory and non-volatile memory, such as a hard disk, internal memory, a plug-in hard disk, a smart memory card (SmartMediaCard, SMC), a secure digital (SecureDigital, SD) card, a flash card (FlashCard), at least one disk storage device, a flash memory device, or other volatile solid-state storage device.

[0088] Compared with the prior art, the beneficial effects of the present invention include at least: The real-time cost control method and system for pig farming enterprises provided by the present invention collects structured data of the entire breeding cycle of breeding pigs, piglets and meat pigs in real time, effectively integrates fragmented information scattered in feed, medicine, low-consumption products, water and electricity, etc., and builds a complete data chain covering the entry and exit of pigs. It completely solves the problems of data islands and manual record lags in the traditional model, and realizes minute-level dynamic update of cost data and full-dimensional transparent management; through two-dimensional dynamic benchmark comparison, dual verification of experimental standard values ​​and machine learning prediction thresholds, combined with differentiated tolerance rules, it realizes intelligent identification and classification of abnormal costs, shortens problem The discovery cycle reduces the cost of manual investigation and can identify hidden cost issues such as feed waste, drug overconsumption, low-consumable product overconsumption, and equipment anomalies, avoiding the ambiguity of traditional experience judgment; based on the type of anomaly, adjustment operations are automatically triggered to achieve closed-loop control of the entire process from data collection, anomaly judgment to execution intervention. Through automated operations such as formula optimization, medication revision, and equipment parameter adjustment, resource waste is quickly blocked, the efficiency of anomaly handling is improved, and the enterprise cost control is promoted from passive response to active intervention, reducing unnecessary resource consumption from the source, and significantly reducing the ineffective investment in controllable costs such as feed, water and electricity, low-consumable products, and drugs. The present invention solves the technical problems of data collection fragmentation, cost accounting lag, insufficient anomaly detection accuracy, and low manual response efficiency in the existing technology.

[0089] The above-described embodiments merely represent several implementation methods of the present invention, and their descriptions are relatively specific and detailed, but they should not be construed as limiting the scope of the present invention. It should be noted that, for those skilled in the art, without departing from the concept of the present invention, several variations and improvements can be made, and equivalent structural transformations made using the contents of the present invention's description and drawings, or direct / indirect application in other related technical fields are all included within the scope of the present invention's patent protection. Therefore, the scope of protection of the present invention's patent shall be based on the appended claims.

[0090] It should be noted that, in the present invention, the embodiments implemented by the real-time cost control system of the pig farming enterprise can be referenced with the embodiments implemented by the real-time cost control method of the pig farming enterprise, and the present invention will not elaborate on them one by one.

[0091] The above are only preferred embodiments of the present invention and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention description and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A real-time cost control method for a pig farming enterprise, characterized in that: include: Step S100: collecting structured data of the entire breeding cycle of sows, piglets and meat pigs in real time; Step S200: Calculating real-time cost indicators of sows, piglets, and meat pigs using a preset algorithm based on the structured data; Step S300: comparing the real-time cost indicator with a theoretical standard value based on experimental field data; Comparing the real-time cost indicator with the future cost threshold predicted by machine learning; when the real-time cost indicator exceeds the theoretical standard value or the future cost threshold, determining it as an abnormal cost; Step S400: performing corresponding abnormal adjustment operations according to the type of the abnormal cost.

2. The real-time cost control method for a pig farming enterprise according to claim 1, characterized in that: In step S300, determining the theoretical standard value includes the following steps: Step S311: collecting daily benchmark data of sows, piglets, and meat pigs at different production stages in the experimental farm, wherein the daily benchmark data includes feed consumption benchmark data, drug and vaccine usage benchmark data, low-consumables benchmark data, and water and electricity consumption benchmark data; Step S312: Clean the single-day benchmark data, remove outliers and establish a standardized data set; Step S313: Based on the standardized data set, a standard consumption model corresponding to the production stage is established through association analysis; Step S314: Outputting confidence intervals of theoretical standard values ​​including feed, medicines and vaccines, low-consumption products, and water and electricity according to the standard consumption model.

3. The real-time cost control method for a pig farming enterprise according to claim 1, characterized in that: In step S300, determining the future cost threshold predicted by machine learning includes the following steps: Step S321: Collecting historical production data of breeding pig batches, piglet breeding batches, and hog breeding batches from the breeding farm and the breeder, wherein the historical production data includes feed consumption, water and electricity consumption, drug and vaccine usage, low-consumables consumption, number of breedings, number of farrowings, pig mortality rate, and disease monitoring records; Step S322: extracting time series features from the historical production data to generate standardized training samples; Step S323: Modeling the standardized training samples through a long short-term memory neural network to learn the correlation between resource consumption and cost indicators; Step S324: Evaluate the model prediction accuracy based on the validation set and adjust the model parameters until the prediction error meets the preset requirements; Step S325: Input the current production data into the trained model and output the confidence interval of the cost indicator threshold in the future period.

4. The real-time cost control method for a pig farming enterprise according to any one of claims 1 to 3, characterized in that: In step S300, the step of determining abnormal costs includes: Step S331: Performing a horizontal comparative analysis of the real-time cost indicators of the breeding batches of sows, piglets, and hogs of the sow farms and farmers. When the real-time cost indicator of any breeding batch exceeds the upper or lower limit of the corresponding theoretical standard value confidence interval, it is determined to be an abnormal cost; Step S332: Compare the real-time cost indicator with the cost threshold confidence interval output by the machine learning prediction model. If the real-time cost indicator continues to exceed the cost threshold confidence interval for multiple consecutive monitoring cycles, it is determined to be a persistent abnormal cost. Step S333: Based on the real-time cost indicator type corresponding to the abnormal cost, the type of abnormal cost is determined, and the type of abnormal cost includes at least one of abnormal feed consumption cost, abnormal drug and vaccine consumption cost, abnormal low-consumables consumption cost, abnormal water and electricity consumption cost, abnormal feeding schedule cost or abnormal market procurement cost.

5. The real-time cost control method for a pig farming enterprise according to claim 4, characterized in that: In step S400, the step of performing a corresponding abnormal adjustment operation according to the type of the abnormal cost includes: When abnormal feed consumption costs are detected, automatic feed formula optimization is performed; When abnormal drug and vaccine consumption costs are detected, the medication plan revision operation is executed; When abnormal consumption costs of low-consumable items are detected, the use authority control operation is executed; When abnormal water and electricity consumption costs are detected, automatic adjustment of equipment operating parameters is performed; When abnormal feeding progress cost is detected, the nutrient ratio adjustment operation is performed; When abnormalities in the raw material market procurement costs are detected, a procurement strategy update operation is executed.

6. The real-time cost control method for a pig farming enterprise according to claim 5, characterized in that: The automatic feed formula optimization operation includes mining the correlation data between historical feed formulas and pig growth rates through a big data analysis platform to generate alternative raw material ratio plans, and screening the most cost-effective supplier based on the feed demand threshold predicted by machine learning; The medication plan revision operation includes generating disease screening plans based on mortality monitoring data and disease positive records, and dynamically adjusting vaccination doses; The aforementioned permission management and control operations include activating a dynamic permission control strategy based on the cost threshold of low-value consumables per unit, triggered by benchmarked parameters of the experimental field, implementing category-based application restrictions for non-essential production positions, and forcibly linking multi-level electronic approval processes with production task traceability. The automatic adjustment of equipment operating parameters includes generating ventilation equipment start-stop strategies based on pig house environmental data, executing intelligent start-stop rules for high-power equipment, dynamic control of sensor lighting, and linkage water and electricity cut-offs for empty pen identification to limit non-production energy consumption; The nutrient ratio adjustment operation includes comparing the production data of the pig breeding batches collected in real time with the standard growth curve, increasing the feeding ratio of key nutrients for batches with lagging growth progress, and adjusting the energy density of the feed according to the ambient temperature; The procurement strategy update operation includes real-time access to market data to generate cross-regional procurement plans, triggering emergency reserves in conjunction with disaster warnings, and optimizing supplier priorities.

7. The real-time cost control method for a pig farming enterprise according to claim 6, characterized in that: It also includes a traffic light warning mechanism, specifically: When the type and source of abnormal costs are detected, a traffic light warning sign is generated based on the comparison result of the key parameter exceeding the standard and the preset threshold value, where a red sign indicates that authority control or automated operation instructions need to be triggered immediately, a yellow sign indicates that manual review and optimization suggestions need to be generated, and a green sign indicates that the indicators have returned to normal and the authority restrictions have been lifted; the traffic light warning sign is linked to at least one automated adjustment operation among the feed formula automatic optimization operation, medication plan revision operation, permission control operation, equipment operating parameter automatic adjustment operation, nutrient ratio adjustment operation and procurement strategy update operation, and automatically updates the sign status according to the actual cost data after the automated adjustment operation is completed.

8. A real-time cost control system for pig farming enterprises, characterized in that: include: The collection module is used to collect structured data of the entire breeding cycle of breeding pigs, piglets and meat pigs in real time; A calculation module, which calculates the real-time cost indicators of breeding pigs, piglets and meat pigs based on the structured data using a preset algorithm; a determination module, configured to compare the real-time cost indicator with a theoretical standard value based on experimental field data; compare the real-time cost indicator with a future cost threshold predicted by machine learning; and determine that the real-time cost indicator is abnormal when it exceeds the theoretical standard value or the future cost threshold; The processing module is used to perform corresponding abnormal adjustment operations according to the type of the abnormal cost.

9. A computer device, characterized in that: The system comprises a processor and a memory, wherein the memory is used to store executable instructions, and the instructions are used to control the processor to execute the method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that A computer program is stored thereon, which implements the method according to any one of claims 1 to 7 when executed by a processor.

Citation Information

Cited By

  • Feeding cost control method and system based on goose growth performance

    CN120833052A

  • Multi-pig farm reserve scheduling control method and device and storage medium

    CN121119312A

  • Method, device and storage medium for multi-farm reserve scheduling control

    CN121119312B

  • Agricultural and pastoral whole chain main data and cost management and control method and system

    CN121684491A

  • Intelligent live pig inspection optimization method and system based on resource constraint

    CN122133876A