Document conversion service stability optimization method and system based on artificial intelligence
By acquiring real-time operational status data of the document conversion service for feature extraction and fusion, calling a pre-trained anomaly tracing module for pattern recognition, and generating stability control strategies, the problem of insufficient human experience in existing technologies is solved, thereby improving the stability and reliability of the document conversion service.
Patent Information
- Application Number
- CN202511693414.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-18
- Publication Date
- 2025-12-16
- Estimated Expiration
- 2045-11-18
AI Technical Summary
Existing methods for ensuring the stability of document conversion services rely on insufficient human experience, resulting in untimely anomaly handling and a lack of intelligent identification and control. This makes it impossible to accurately identify anomaly types and associated characteristics, thus affecting the stability and reliability of the service.
By acquiring real-time operational status data of the document conversion service, feature extraction and fusion are performed. The pre-trained service anomaly tracing module is then invoked to perform anomaly pattern recognition, generating service anomaly pattern recognition results. Based on the recognition results, the service adaptation model is invoked to adjust parameters, generating service stability control strategies. Finally, the training sample set of the adaptation model is updated for iterative optimization.
It improved the accuracy and efficiency of anomaly identification, enabled targeted resource allocation and task scheduling, and significantly enhanced the stability and reliability of document conversion services.
Smart Images

Figure CN121144274A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of digital office and information processing, and in particular, to a document conversion service stability optimization method and system based on artificial intelligence. BACKGROUND
[0002] In the field of digital office and information processing, document conversion services play a crucial role. They can convert documents of different formats to meet diverse business needs. However, as the application scenarios of document conversion services continue to expand and the processing tasks become increasingly complex, their stability faces many challenges.
[0003] Existing methods for ensuring the stability of document conversion services have obvious shortcomings. On the one hand, some methods mainly rely on manual experience for monitoring and adjustment. When the service is abnormal, the operation and maintenance personnel need to manually analyze a large amount of running data, which is not only inefficient but also prone to missing key problems due to the limitations of individual experience and judgment, leading to delayed abnormal handling and affecting the stability of the service. On the other hand, some automated monitoring methods can collect service running data in real time, but lack intelligent abnormal identification and control mechanisms, and can only perform simple threshold alarms, which cannot accurately identify abnormal types and associated features, and therefore cannot develop targeted stability control strategies to fundamentally solve service stability problems. In addition, existing methods do not effectively feedback and optimize the abnormal handling process after handling service abnormalities, which may lead to the repeated occurrence of the same or similar problems, further reducing the stability and reliability of the service. The format and attributes are comprehensively fused and optimized, which affects the quality and efficiency of electronic file printing. SUMMARY
[0004] In view of the above-mentioned problems, in combination with the first aspect of the present application, the embodiments of the present application provide a document conversion service stability optimization method based on artificial intelligence, which comprises: Obtaining a set of real-time running state data of the document conversion service, performing feature extraction processing on the set of real-time running state data to obtain a set of service running state features, the set of real-time running state data including service process running data, resource occupation data and conversion task processing data; Calling a pre-trained service abnormality tracing module to perform abnormal pattern recognition processing on the set of service running state features to generate a service abnormality pattern recognition result, the service abnormality pattern recognition result including an abnormal type identifier and an abnormal associated feature; Based on the service abnormality pattern recognition result, calling a corresponding service adaptation model, performing parameter adjustment processing on the service adaptation model to generate a service stability control strategy, the service stability control strategy including a resource allocation scheme and a task scheduling rule; inputting the service stability regulation strategy into an execution control module of the document conversion service, executing the service stability regulation strategy, and obtaining a service running parameter adjustment result; updating a training sample set of the service adaptation model based on the service running parameter adjustment result, performing iterative optimization processing on the service adaptation model, and generating an optimized service adaptation model.
[0005] In another aspect, the embodiment of the present application also provides a document conversion service stability optimization system based on artificial intelligence, which comprises a processor and a machine readable storage medium, the machine readable storage medium is connected with the processor, the machine readable storage medium is used for storing programs, instructions or codes, and the processor is used for executing the programs, instructions or codes in the machine readable storage medium to realize the above method.
[0006] Based on the above aspects, the embodiment of the present application can accurately identify the abnormal type and the associated features by acquiring the real-time running state data set of the document conversion service and performing feature extraction, and calling the pre-trained service abnormality tracing module to perform abnormal pattern recognition, avoiding the subjectivity and limitation of manual judgment, and improving the accuracy and efficiency of abnormal identification. Based on the identification result, the corresponding service adaptation model is called and the service stability regulation strategy is generated, which can formulate a targeted resource allocation scheme and task scheduling rule according to different abnormal types, realize accurate regulation, and effectively improve the stability of the service. The regulation strategy is input into the execution control module and the running parameter adjustment result is obtained, finally, the training sample set of the service adaptation model is updated based on the running parameter adjustment result and iterative optimization is performed, so that the model can continuously learn and adapt to the changes of service running, further improve the accuracy of abnormal identification and regulation, and significantly improve the stability and reliability of the document conversion service. BRIEF DESCRIPTION OF DRAWINGS
[0007] Figure 1 is an execution flow diagram of the document conversion service stability optimization method based on artificial intelligence provided by the embodiment of the present application.
[0008] Figure 2 is a schematic diagram of exemplary hardware and software components of the document conversion service stability optimization system based on artificial intelligence provided by the embodiment of the present application. DETAILED DESCRIPTION
[0009] The present application will be described in detail below with reference to the accompanying drawings, Figure 1 is a flow diagram of the document conversion service stability optimization method based on artificial intelligence provided by an embodiment of the present application, and the document conversion service stability optimization method based on artificial intelligence will be described in detail below.
[0010] Step S110: Obtain a real-time running state data set of the document conversion service, perform feature extraction processing on the real-time running state data set, and obtain a service running state feature set. The real-time running state data set includes service process running data, resource occupation data, and conversion task processing data.
[0011] In this embodiment, an enterprise internal document conversion service system is taken as an application scenario, which is deployed on an enterprise private cloud server and used to process various document format conversion requirements generated in daily work of employees, support mutual conversion between multiple document types, and perform format conversion operations on different types of documents such as text documents, table documents, and presentation documents.
[0012] Step S111: Collect service process running data generated in the running process of the document conversion service. The service process running data includes process startup duration data, process response delay data, and process interaction data.
[0013] For the enterprise document conversion service system, multiple independent service processes are running, and each service process corresponds to a specific type of document conversion function, such as a process that specializes in processing text document conversion and a process that specializes in processing table document conversion. Process startup duration data refers to the time interval experienced by each service process from the issuance of a system startup instruction to the process being fully ready and able to receive a conversion task. Through this data, the startup efficiency of the process can be understood. Process response delay data refers to the time interval between when a service process receives a document conversion request sent by a client and when the process starts performing a conversion operation. This process response delay data is directly related to the user's perception of service response speed. Process interaction data covers communication information between the service process and other components inside the system (such as a task scheduling module and a resource management module), including the initiation time of an interaction request, the type of interaction data, the result state of an interaction operation, and other content.
[0014] Step S112: Collect resource occupation data during the running of the document conversion service. The resource occupation data includes memory occupation data, processor occupation data, and network bandwidth occupation data.
[0015] The enterprise document conversion service system runs in a cluster environment composed of multiple servers, and the collection of resource occupation data is carried out for each server and the service process running therein. The memory occupation data includes the size of the memory space currently allocated to each service process and the actual amount of memory used. Different types of document conversion tasks have different memory requirements. For example, when processing a presentation document containing a large number of pictures, the memory occupation amount is usually higher than when processing a pure text document. The processor occupation data reflects the utilization of the server CPU resources by the service process, including the processor usage ratio and the processor time slice allocation between different service processes. When multiple high-complexity conversion tasks are executed concurrently, the processor occupation rate will increase significantly. The network bandwidth occupation data relates to the network resources occupied by the service process in receiving the document data uploaded by the client for conversion and returning the converted document data to the client, including the data transmission rate, the number of network connections, the packet loss rate during data transmission, and other indicators. In an enterprise internal network environment, the allocation of network bandwidth resources will affect the overall processing efficiency of the document conversion service.
[0016] Step S113: Collect conversion task processing data when the document conversion service processing task is processed, and the conversion task processing data includes task reception quantity data, task processing progress data, and task completion time consumption data.
[0017] Employees in the enterprise submit various conversion tasks to the document conversion service system through the client. The task reception quantity data records the total number of conversion tasks received by the service system in a unit of time, as well as the proportion of each type of document conversion task. The trend of this task reception quantity data can reflect the load of the service. The task processing progress data refers to the real-time progress of each conversion task during execution, such as the proportion of completed document pages to total pages, the current processing document paragraph, etc. Through this data, the execution status of the task can be monitored in real time. The task completion time consumption data refers to the total time consumed from when the conversion task is received and started to be processed by the service process to when the task is completely executed. This task completion time consumption data is related to factors such as the size, complexity, and format type of the document. By analyzing this data, the processing efficiency of different types of conversion tasks can be evaluated.
[0018] Step S114: Integrate the service process running data, the resource occupation data, and the conversion task processing data according to the time sequence to form a real-time running state data set. Perform feature extraction processing on the real-time running state data set, extract process running features, resource occupation features, and task processing features through feature extraction algorithms. The process running features correspond to the key attributes of the service process running data, the resource occupation features correspond to the key attributes of the resource occupation data, and the task processing features correspond to the key attributes of the conversion task processing data.
[0019] In the data integration stage, the collected service process running data, resource occupation data and conversion task processing data are associated and combined according to the time stamp to form a real-time running state data set with time as the axis. For example, the process response delay data at a certain time point, the memory occupation data corresponding to the time point and the task completion time consumption data of the conversion task being processed at that time are associated and stored. The feature extraction process adopts a combination of multiple feature extraction algorithms. For process running data, the process running features reflecting the process running stability, response timeliness and collaborative working ability are extracted by analyzing the change law of process startup duration data, the distribution characteristics of process response delay data and the key events in process interaction data. For resource occupation data, the resource occupation features reflecting the resource utilization efficiency and resource allocation rationality are extracted by analyzing the fluctuation of memory occupation data, the peak and valley changes of processor occupation data and the transmission efficiency of network bandwidth occupation data. For conversion task processing data, the task processing features reflecting the task load pressure and task processing efficiency are extracted by analyzing the time distribution characteristics of task receiving quantity data, the advancing rate of task processing progress data and the statistical law of task completion time consumption data.
[0020] Step S115: After the process running features, the resource occupation features and the task processing features are input into the feature fusion module for standardization processing, the fusion processing is performed by combining feature splicing and weight distribution to generate a service running state feature set with unified dimensions.
[0021] Firstly, the extracted process running features, resource occupation features and task processing features are input into the feature fusion module for standardization processing. In the standardization processing, for different types of features, the feature values are converted into a unified numerical interval according to their data distribution range and feature attributes to eliminate the influence of dimension difference between different features. For example, the process response delay features and the memory occupation rate features are standardized respectively to make their numerical ranges in the same interval. After the standardization processing, the feature fusion operation is performed. Feature splicing is to combine the process running features, the resource occupation features and the task processing features into a high-dimensional feature vector according to the preset order. Weight distribution is to assign corresponding weight values to each feature according to the importance of different features in reflecting the stability of service running state. The importance evaluation is based on the contribution degree analysis results of each feature to the occurrence of abnormality in historical service abnormal cases. In the fusion process, each feature is multiplied by the corresponding weight value, and then all the features adjusted by weight are combined according to the splicing order to finally generate a service running state feature set with unified dimensions.
[0022] Step S120: calling the pre-trained service exception tracing module to perform abnormal pattern recognition processing on the service running state feature set, and generating a service exception pattern recognition result, which contains an exception type identifier and an exception associated feature.
[0023] After obtaining the service running state feature set, it needs to be subjected to abnormal pattern recognition to determine whether there is an exception in the service currently and the specific type and related features of the exception. The pre-trained service exception tracing module is trained based on a large amount of historical service running data and exception cases, and has the ability to perform deep analysis and pattern recognition on the service running state features. By calling the service exception tracing module, the input service running state feature set can be processed to accurately identify the possible abnormal patterns in the service running process.
[0024] Step S121: inputting the service running state feature set into the feature layering unit of the service exception tracing module, performing layering processing on the service running state feature set according to the data source and the association relationship, obtaining a basic feature layer and an associated feature layer, the basic feature layer contains features corresponding to single type data, i.e., independent features corresponding to service process running data, resource occupation data, and conversion task processing data, and the associated feature layer contains associated features between different types of data, i.e., associated features between service process running data and resource occupation data, associated features between resource occupation data and conversion task processing data, and associated features between service process running data and conversion task processing data.
[0025] The feature layering unit of the service anomaly tracing module first analyzes the input service running state feature set, and divides the features into different basic feature sub-layers according to the data sources of the features. For example, features related to service process running (such as process response delay features, process startup time features, etc.) are divided into a process basic feature sub-layer; features related to resource occupation (such as memory occupation features, processor occupation features, etc.) are divided into a resource basic feature sub-layer; features related to conversion task processing (such as task completion time-consuming features, task receiving quantity features, etc.) are divided into a task basic feature sub-layer, and these sub-layers together constitute a basic feature layer. The construction of the correlation feature layer is achieved by analyzing the internal correlation between the features in different basic feature sub-layers. For example, the relationship between the process response delay feature in the process basic feature sub-layer and the processor occupation feature in the resource basic feature sub-layer is analyzed. When the processor occupation rate is high, whether the process response delay shows an increasing trend, thereby constructing the correlation feature between the two; the relationship between the memory occupation feature in the resource basic feature sub-layer and the task completion time-consuming feature in the task basic feature sub-layer is analyzed. When the memory occupation reaches a certain degree, whether the task completion time-consuming will change significantly, and the corresponding correlation feature is formed; the relationship between the process interaction data feature in the process basic feature sub-layer and the task processing progress feature in the task basic feature sub-layer is analyzed. Whether the smoothness of process interaction has an impact on the advancement of task processing progress, and then the correlation feature is constructed.
[0026] Step S122: performing abnormal threshold comparison processing on each feature in the basic feature layer, filtering out the features that exceed the normal range of the feature as basic abnormal features through the preset feature normal range interval, performing correlation degree analysis processing on each correlation feature in the correlation feature layer, filtering out the features whose standardized correlation strength value exceeds the normal correlation range as correlation abnormal features through the calculation of the standardized correlation strength value of the correlation feature.
[0027] For each feature in the basic feature layer, a feature normal range interval is preset according to the value range of the feature in the historical normal operation state. In the abnormal threshold comparison process, the value of the current feature is compared with the preset normal range interval, and if the feature value exceeds the interval, the feature is marked as a basic abnormal feature. For example, for the process response delay feature, a normal range interval is preset, and when the value of the feature at a certain time exceeds the upper limit of the interval, the feature is determined to be a basic abnormal feature. For each correlation feature in the correlation feature layer, the strength of the correlation relationship is evaluated by calculating the standardized correlation strength value. The calculation of the standardized correlation strength value is based on the correlation strength distribution of the correlation feature in the historical data under the normal operation state, and the correlation strength value of the current correlation feature is converted into a standardized value. A normal correlation range is preset, and when the standardized correlation strength value exceeds the range, it indicates that the correlation relationship between the corresponding features is abnormal, and the correlation feature is marked as a correlation abnormal feature. For example, for the correlation feature between the processor occupancy feature and the task completion time feature, when the calculated standardized correlation strength value exceeds the normal correlation range, it indicates that the relationship between the processor occupancy and the task completion time is abnormal, and the correlation feature is screened as a correlation abnormal feature.
[0028] Step S123: input the basic abnormal features and the correlation abnormal features into the pattern matching unit of the service abnormality tracing module, call the preset abnormal pattern library, compare the basic abnormal features with the standard basic abnormal features one by one, and compare the correlation abnormal features with the standard correlation abnormal features one by one. The abnormal pattern library stores a plurality of standard abnormal feature sets corresponding to historical service abnormalities, and each standard abnormal feature set includes standard basic abnormal features and standard correlation abnormal features.
[0029] Step S1231: call the preset abnormal pattern library, read all standard abnormal feature sets stored in the abnormal pattern library, and identify each standard abnormal feature set.
[0030] In the embodiment, the abnormal pattern library adopts a distributed storage architecture and is deployed on multiple nodes of an enterprise private cloud and accessed through a unified interface. When a preset abnormal pattern library is called, a query request is first sent through the interface, and the request contains an instruction to obtain all standard abnormal feature sets. After receiving the request, the abnormal pattern library performs identity authentication and permission check on the request, and after verification, reads the metadata information of all standard abnormal feature sets from the distributed storage nodes, including set name, corresponding abnormal type description, creation time, update time, etc. Then, according to the metadata information, each standard abnormal feature set is uniquely identified, and the identification adopts the form of combination of letters and numbers, wherein the letter part represents the major category of the abnormal type, and the number part represents the specific abnormal subclass and version information under the major category. For example, the identification starting with "MEM" represents the abnormal type related to the memory resource, and the subsequent numbers represent the specific abnormal subclass and the update version of the standard feature set of the subclass. After completing the identification, the identification and the corresponding metadata information of all standard abnormal feature sets are returned to the pattern matching unit, and the pattern matching unit stores the above information in the local cache for subsequent fast access.
[0031] Step S1232: For each standard abnormal feature in the standard abnormal feature set, compare each feature in the standard basic abnormal feature with the corresponding standard basic abnormal feature, normalize all feature values before comparison, calculate the normalized difference value in the attribute dimension, and the normalized difference value is negatively correlated with the matching degree. The matching degree corresponding to the normalized difference value conforms to the preset correlation relationship, and the similarity between the numerical distribution of the normalized basic abnormal feature and the numerical distribution of the normalized standard basic abnormal feature is calculated to obtain the basic feature similarity.
[0032] For each standard abnormal feature set, the pattern matching unit reads its corresponding standard basic abnormal feature list from the local cache. For each feature in the basic abnormal feature, according to the feature name and attribute description, find the corresponding standard basic abnormal feature in the standard basic abnormal feature list. After finding the corresponding feature, first normalize the feature values of the two. The normalization process is to map the feature value to a pre-set standard numerical interval, and the mapping method is determined based on the maximum and minimum values of the feature in the historical normal running state. The standardized feature value is obtained by subtracting the historical minimum value from the current feature value and dividing by the difference between the historical maximum value and the historical minimum value. After the normalization is completed, the attribute comparison is carried out, and the attribute comparison includes the data type, dimension (mainly checks the dimension consistency identification on the basis of the unified dimension in the early stage), physical meaning description of the feature, etc. For numerical attribute, calculate the standardized difference value of the two in the attribute dimension, the calculation method is to subtract the standardized value of the basic abnormal feature from the standardized value of the standard basic abnormal feature and take the absolute value. The smaller the standardized difference value, the higher the matching degree of the two features in the numerical attribute, that is, the standardized difference value and the matching degree are negatively correlated. The pre-set association is determined by looking up the pre-set mapping table, which stores the matching degree level corresponding to different standardized difference value intervals, for example, the standardized difference value in a certain interval corresponds to the matching degree level "high", and in another interval corresponds to the level "medium", etc. At the same time, the similarity of the numerical distribution of the standardized basic abnormal feature and the numerical distribution of the standard basic abnormal feature is calculated. The similarity of the numerical distribution is calculated by using statistical methods. First, the probability density functions of the two features are calculated respectively. The calculation of the probability density function is based on the kernel density estimation method, which is obtained by selecting appropriate kernel function and bandwidth parameter to fit the standardized feature value sample. Then, the integral probability distance between the two probability density functions is calculated. The smaller the integral probability distance, the more similar the numerical distribution of the two features. Convert the integral probability distance into a similarity index, that is, get the basic feature similarity. The basic feature similarity considers the matching degree level of the feature attribute comparison and the similarity index of the numerical distribution, and is obtained by weighted summation, the weight is determined according to the importance of the feature attribute, for example, the matching weight of the physical meaning description of the feature is higher than that of the numerical attribute.
[0033] Step S1233: for each standard associated abnormal feature in each standard abnormal feature set, compare the association relationship between each feature in the associated abnormal feature and the corresponding standard associated abnormal feature, analyze the consistency of the two in the association direction and the change trend of the association strength, calculate the coincidence degree of the association relationship, and calculate the similarity of the time series change rule of the associated features to obtain the associated feature similarity.
[0034] For each standard associated abnormal feature in each standard abnormal feature set, the pattern matching unit also finds the corresponding associated abnormal feature in the associated abnormal feature according to the feature name and the association description. The association comparison first analyzes the association direction of the two, which is divided into three types of positive correlation, negative correlation and no correlation. By comparing the association direction identifiers of the basic abnormal feature and the standard basic abnormal feature, it is judged whether they are consistent. Then the consistency of the change trend of the association strength is analyzed. The change trend of the association strength is described by the change curve of the association strength value with time. The change curve of the association strength of the associated abnormal feature is compared with the change curve of the association strength of the standard associated abnormal feature, and the appearance order and duration of the rising section, the falling section and the stable section of the curve are analyzed. The consistency of the change trend of the association strength is measured by calculating the dynamic time warping distance of the two curves. The smaller the dynamic time warping distance, the higher the consistency of the trend. The distance is converted into a consistency index between 0 and 1. The consistency of the association relationship is the product of the consistency of the association direction and the trend consistency index. At the same time, the similarity of the time series variation law of the associated feature is calculated. The time series variation law includes periodicity, trend, mutation point distribution, etc. The periodicity analysis converts the time series to the frequency domain through Fourier transform, and compares whether the distribution of the main frequency components is consistent. The trend analysis compares whether the slope and intercept of the fitted straight line are within the preset error range. The mutation point distribution analysis finds the points whose first-order difference absolute value exceeds the preset threshold as the mutation points, and compares the number and appearance time distribution of the mutation points. The similarity calculation of the time series variation law weights and averages the periodicity similarity, trend similarity and mutation point distribution similarity to obtain the associated feature similarity. The weights of each part are determined according to the importance of the association relationship in the historical data.
[0035] Step S1234: The basic feature similarity and the associated feature similarity are weighted and summed according to the preset weight to obtain the comprehensive matching degree of the current abnormal feature and the standard abnormal feature set. The preset weight is adjusted according to the historical abnormal recognition accuracy.
[0036] The preset weights are stored in the configuration file of the pattern matching unit, and the initial preset weights are set based on expert experience, wherein the sum of the weight of the basic feature similarity and the weight of the associated feature similarity is 1. During the operation of the system, the preset weights are dynamically adjusted according to the historical abnormality identification accuracy. The adjustment process is to periodically (such as every week) statistics the accuracy of abnormality identification when using the current weight setting, that is, the ratio of the number of correctly identified abnormal cases to the total number of identified abnormal cases. When the accuracy is lower than the preset threshold, the weight adjustment mechanism is started. The adjustment mechanism uses the gradient ascent method to adjust the weights of the basic feature similarity and the associated feature similarity by a small amount, calculate the change of the adjusted accuracy, if the accuracy is improved, keep the adjustment direction and continue to adjust, if the accuracy is reduced, adjust in the opposite direction, until the weight combination that makes the accuracy the highest is found, and the weight combination is updated to the configuration file. When calculating the comprehensive matching degree, the pattern matching unit reads the current preset weight from the configuration file, then multiplies the basic feature similarity by the basic feature weight and multiplies the associated feature similarity by the associated feature weight, and the sum of the two is the comprehensive matching degree of the current abnormal feature and the standard abnormal feature set.
[0037] Step S1235: If there are multiple standard abnormal feature sets with the same comprehensive matching degree and the highest value, further extract the key features in the basic abnormal feature and the associated abnormal feature, compare the key features with the key standard features in each standard abnormal feature set for a second time, and determine a unique standard abnormal feature set according to the second comparison result, wherein the key features are the features with the greatest impact on service abnormality.
[0038] After calculating the comprehensive matching degrees of all standard abnormal feature sets, the pattern matching unit sorts the comprehensive matching degrees and finds the maximum value. If only one standard abnormal feature set has the maximum comprehensive matching degree, it is directly taken as the matching result. If there are multiple standard abnormal feature sets with the same maximum comprehensive matching degree, secondary comparison is needed. The core of the secondary comparison is to extract key features, and the extraction of the key features is based on a feature importance evaluation algorithm. The feature importance is determined according to the contribution of each feature in the historical abnormal cases to the occurrence of the abnormality. The contribution is measured by calculating the appearance frequency of the feature when the abnormality occurs and the mutual information value with the abnormal result. The higher the appearance frequency and the larger the mutual information value, the higher the importance of the feature. The top several features in importance are selected from the basic abnormal features and the associated abnormal features as the key features. The number of selected features is determined according to the complexity of the abnormal type, and usually 3 to 5 features are selected. For each standard abnormal feature set with the highest comprehensive matching degree, the corresponding key standard features are extracted from the standard basic abnormal features and the standard associated abnormal features. Then, the extracted key features are compared with each key standard feature for secondary comparison. The method of secondary comparison is similar to the basic feature comparison and the associated feature comparison, but the comparison process is more detailed. For example, higher-order statistics (such as skewness and kurtosis) are used for comparison in the numerical distribution similarity calculation, and the lag analysis of the associated features is added in the associated relationship comparison. According to the secondary comparison result, the matching score of the key features is calculated, and the standard abnormal feature set with the highest score is determined as the unique matching result.
[0039] Step S124: Based on the comparison result, the matching degree of the current abnormal feature and each standard abnormal feature set is calculated, the corresponding abnormal type identifier is determined according to the standard abnormal feature set with the highest matching degree, the abnormal type identifier is used to distinguish different types of service abnormalities, and the features directly related to the abnormal type identifier are extracted from the basic abnormal features and the associated abnormal features as abnormal associated features.
[0040] In the comparison process, for each standard abnormal feature set, the matching degree of the basic abnormal feature and the standard basic abnormal feature and the matching degree of the associated abnormal feature and the standard associated abnormal feature are calculated respectively. The calculation of the basic abnormal feature matching degree considers factors such as the type of the feature and the value deviation degree; the calculation of the associated abnormal feature matching degree considers factors such as the type of the association, the deviation degree of the standardized association strength value, etc. The basic abnormal feature matching degree and the associated abnormal feature matching degree are integrated according to a certain weight ratio to obtain the overall matching degree of the current abnormal feature and the standard abnormal feature set. All standard abnormal feature sets in the abnormal pattern library are traversed, and the standard abnormal feature set with the highest overall matching degree is found. The abnormal type corresponding to the standard abnormal feature set is the abnormal type that the current service may have, and the identifier corresponding to the abnormal type is the abnormal type identifier. For example, if the standard abnormal feature set corresponding to the "insufficient memory resource causes service response delay abnormality" has the highest matching degree, the abnormal type identifier is this type. The extraction of the abnormal association feature is to filter out the features directly related to the determined abnormal type identifier from the basic abnormal feature and the associated abnormal feature. For example, for the "insufficient memory resource causes service response delay abnormality" type, the memory occupation related basic abnormal feature is extracted from the basic abnormal feature, and the association abnormal feature between memory occupation and process response delay is extracted from the associated abnormal feature, which together constitute the abnormal association feature.
[0041] Step S125: The abnormal type identifier and the abnormal association feature are integrated according to a preset format to generate a service abnormal pattern recognition result.
[0042] The preset format specifies the structure and content organization method of the service abnormal pattern recognition result, including the field name and data type of the abnormal type identifier, the arrangement order and feature description information of the abnormal association feature, etc. In the integration process, the determined abnormal type identifier and the extracted abnormal association feature are filled and organized according to the preset format to form a structured service abnormal pattern recognition result. For example, the abnormal type identifier field is explicitly labeled as "insufficient memory resource causes service response delay abnormality", and the abnormal association feature part lists the specific description of the memory occupation basic abnormal feature, the specific description of the memory occupation and process response delay association abnormal feature, etc. in turn. The generated service abnormal pattern recognition result will be used as the basis for subsequent service adaptation model parameter adjustment.
[0043] Step S130: Based on the service abnormal pattern recognition result, the corresponding service adaptation model is called to perform parameter adjustment processing on the service adaptation model, and a service stability control strategy is generated, which contains a resource allocation scheme and a task scheduling rule.
[0044] According to the determined abnormal type in the service abnormal pattern recognition result, a service adaptation model specially for the abnormal type is called from the model library. The service adaptation model is trained based on historical optimization experience and machine learning algorithm, can adjust the model parameters according to the input abnormal associated features, and then generate effective service stability regulation strategies to solve the current service abnormal problems and ensure the stable operation of the service.
[0045] Step S131: The abnormal type identifier in the service abnormal pattern recognition result is parsed, and according to the preset corresponding relationship between the abnormal type and the service adaptation model, a service adaptation model matched with the abnormal type identifier is called from the model library. Different abnormal type identifiers correspond to different service adaptation models, and each service adaptation model has optimization and regulation capability for a specific type of service abnormality.
[0046] The preset corresponding relationship between the abnormal type and the service adaptation model is stored in the model management module, which clearly shows the name, version number, storage path and other information of the service adaptation model corresponding to each abnormal type identifier. After parsing the abnormal type identifier in the service abnormal pattern recognition result, the model management module finds the corresponding service adaptation model information according to the identifier, and then calls the corresponding service adaptation model from the model library according to the storage path. For example, when the abnormal type identifier is "service response delay abnormality caused by insufficient memory resources", the "memory resource optimization adaptation model" is called according to the corresponding relationship.
[0047] Step S132: Extract the abnormal associated features in the service abnormal pattern recognition result, classify the abnormal associated features by attributes, determine the features reflecting resource problems, process problems and task problems, and input the classified abnormal associated features into the called service adaptation model as the core basis for service adaptation model parameter adjustment.
[0048] The abnormal associated features include multiple features with different attributes, and the attribute classification is to more clearly analyze the causes of the abnormality. The features reflecting resource problems include abnormal features related to resource occupation such as memory, processor and network bandwidth, such as features of memory occupation exceeding the normal range, features of high processor occupation rate, etc.; the features reflecting process problems include abnormal features related to service process running state, such as features of process response delay abnormality, features of process interaction failure, etc.; the features reflecting task problems include abnormal features related to conversion task processing, such as features of long task completion time, features of sudden increase in task receiving quantity, etc. After classification, the above different categories of abnormal associated features are arranged according to the input format required by the service adaptation model, and then input into the called service adaptation model. After receiving these features, the service adaptation model takes them as the core basis for analyzing the current abnormal condition and adjusting the model parameters.
[0049] Step S133: After the service adaptation model receives the classified abnormal association features, it reads its initial parameter configuration, which includes resource allocation parameters, task scheduling parameters, and process control parameters. According to the influence degree of different types of features in the abnormal association features, the corresponding initial parameters are adjusted.
[0050] The initial parameter configuration of the service adaptation model is a set of parameter values preset after the model training is completed. These parameter values control the behavior of the model when the model is not adjusted. The resource allocation parameters include memory allocation proportion coefficient, processor time slice allocation weight, network bandwidth allocation priority, etc.; the task scheduling parameters include task priority determination coefficient, task allocation strategy parameter, task queue management parameter, etc.; the process control parameters include process start threshold, process restart condition parameter, process resource limit parameter, etc. After receiving the classified abnormal association features, the service adaptation model analyzes the influence degree of different types of abnormal association features on service abnormalities through the built-in feature influence evaluation algorithm. For example, for "memory resource shortage leads to service response delay abnormality", the abnormal association features reflecting resource problems (such as memory occupation abnormal features) have the highest influence degree. According to the influence degree of each type of feature, the model adjusts the corresponding parameters in the initial parameter configuration. For example, for memory resource problems, increase the weight value corresponding to high-priority conversion tasks in the memory allocation proportion coefficient, and adjust the resource allocation parameters related to memory allocation.
[0051] Step S134: Run the service adaptation model after adjusting the parameters. The service adaptation model analyzes the current running bottleneck of the document conversion service, generates a resource allocation scheme based on the adjusted parameters, and the resource allocation scheme includes the memory allocation proportion, processor allocation proportion, and network bandwidth allocation proportion of different service processes. At the same time, the service adaptation model analyzes the priority of the current conversion task to be processed, and generates a task scheduling rule, which includes the task priority sorting method and the method of assigning tasks to different service processes.
[0052] Step S1341: Run the service adaptation model after adjusting the parameters. Through the data interface, obtain the current system resource total data of the document conversion service, which includes total memory capacity, total processor core number, and total network bandwidth. At the same time, obtain the current resource occupation data of each service process. Compare the system resource total data with the current resource occupation data to determine the resource remaining amount. Combine the adjusted resource allocation parameters to analyze the bottleneck of the current resource allocation.
[0053] After the service adaptation model is started after adjusting the parameters, first, the internal data buffer and calculation module are initialized. A connection is established with the resource monitoring module of the document conversion service through a preset data interface. The connection uses the TCP / IP protocol, and the interface communication format is JSON format. The service adaptation model sends a resource data request instruction to the resource monitoring module. The instruction includes the requested resource type (total memory capacity, total processor core number, and total network bandwidth) and timestamp. After receiving the request, the resource monitoring module collects the current total system resource data. The total memory capacity is obtained by reading the memory management interface of the server operating system. The memory management interface returns the total available memory after subtracting the system kernel reserved memory from the total physical memory. The total processor core number is obtained by reading the hardware information of the CPU, including the physical core number and the logical core number. Here, the logical core number is used as the total processor core number. The total network bandwidth is determined by testing the maximum transmission rate of the server network card and combining the bandwidth limit in the current network topology. At the same time, the resource monitoring module collects the current resource occupation data of each service process, including the memory usage, processor usage (in core number), and network bandwidth usage of each process. The total system resource data and current resource occupation data are sent to the service adaptation model, which stores them in the data buffer after receiving them. Then, the remaining resources are calculated. The remaining resources are equal to the total system resources minus the current total resource occupation, and the remaining memory capacity, remaining processor core number, and remaining network bandwidth are obtained. In combination with the adjusted resource allocation parameters, such as the elasticity coefficient of memory allocation, the priority weight of processor allocation, and the guarantee threshold of network bandwidth allocation, the resource remaining amount and the resource demand of each process are analyzed. The analysis process uses a decision tree algorithm, taking the resource remaining amount, the historical resource demand of each process, and the adjusted resource allocation parameters as input features. Through the branch judgment of the decision tree, the current resource allocation bottleneck is determined. For example, when the remaining memory capacity is lower than the product of the adjusted memory allocation elasticity coefficient and the basic memory demand of each process, the memory resource is determined as the bottleneck. When the remaining processor core number cannot meet the processor demand of the high-priority process, the processor resource is determined as the bottleneck. When the remaining network bandwidth is lower than the guarantee threshold, the network bandwidth resource is determined as the bottleneck.
[0054] Step S1342: Based on the resource bottleneck analysis result, the service adaptation model calculates the resource demand priority of each service process according to the pre-defined service process weight coefficient and the real-time monitored task urgency index after standardization. The service process weight coefficient is determined based on its pre-set importance level, and the task urgency index is determined based on the delay threshold and deadline of the task queue and is standardized.
[0055] The service adaptation model predefines a service process weight coefficient table, in which each service process is assigned a weight coefficient, and the value of the weight coefficient ranges from 0 to 1. The importance level of a service process is determined according to the impact degree of the task type it processes on the enterprise business, and the impact degree is jointly evaluated by the enterprise business department and the IT department, and is divided into three levels of core, important and general, and the core level corresponds to the highest weight coefficient, and the general level corresponds to the lowest weight coefficient. The weight coefficient table is stored in the configuration file of the service adaptation model and can be manually updated according to business adjustment. The task urgency index monitored in real time is provided by the task scheduling module, and the task urgency index is calculated for the task queue currently being processed by each service process. The calculation of the task urgency index is based on the delay threshold and the deadline of all tasks in the task queue. The delay threshold refers to the maximum waiting processing time allowed by the task, and the deadline refers to the final time at which the task must be completed. For each task, the ratio of its remaining time (deadline minus current time) to delay threshold is calculated. The smaller the ratio, the higher the task urgency. The urgency indexes of all tasks in the task queue are weighted and averaged to obtain the task urgency index of the service process, and the weight is the proportion of the data volume of the task to the total data volume of the queue. The obtained task urgency index is standardized by dividing the index value by the historical maximum task urgency index value to obtain the standardized task urgency index, and the value range is between 0 and 1. When calculating the resource demand priority of each service process, the service adaptation model multiplies the service process weight coefficient and the standardized task urgency index to obtain a preliminary priority score. Then, according to the resource bottleneck type, the preliminary priority score is adjusted, for example, if the bottleneck is the memory resource, an adjustment factor is added to the preliminary priority score of the memory-intensive service process, and the adjustment factor is determined according to the memory demand coefficient of the process. The higher the memory demand coefficient, the larger the adjustment factor. The adjusted score is the resource demand priority of each service process.
[0056] Step S1343: According to the high and low order of the resource demand priority, the remaining resources are allocated to each service process in proportion to generate a resource allocation scheme containing the memory allocation proportion, processor allocation proportion and network bandwidth allocation proportion of different service processes.
[0057] The service adaptation model ranks the resource demand priorities of the service processes from high to low to form a resource allocation sequence. For the remaining memory capacity, the memory resources are allocated to each service process in turn according to the resource allocation sequence. When allocating, the basic memory demand of each service process is first met, and the basic memory demand is determined according to the type and historical minimum memory occupation of the process and is stored in the service process configuration table. After the basic memory demand is met, the remaining memory resources are allocated according to the proportion of the resource demand priority score of each service process to the total priority score (the sum of the priority scores of all processes). For example, the priority score of a service process is P, and the total priority score is SumP, then the additional memory that can be allocated to the process is the remaining memory capacity multiplied by P / SumP, and the total memory allocation of the process is the basic memory demand plus the additional memory allocation, and then the memory allocation proportion (total memory allocation divided by the total memory capacity of the system) is calculated. For the allocation of the remaining number of processor cores, the basic processor core demand of each service process is first met, and the basic processor core demand is determined according to the concurrent processing capability of the process, for example, the basic demand of a text conversion process is 1 core, and the basic demand of a table conversion process is 2 cores. After the basic demand is met, the remaining processor cores are allocated according to the resource demand priority proportion, and the calculation method is similar to the memory allocation, and the processor allocation proportion (the number of allocated cores divided by the total number of processor cores) of each process is obtained. The network bandwidth allocation first guarantees the basic network bandwidth demand of each service process, and the basic network bandwidth demand is determined according to the average data transmission rate when the process handles the task, and then the remaining network bandwidth is allocated according to the priority proportion to obtain the network bandwidth allocation proportion (the allocated bandwidth divided by the total network bandwidth) of each process. The memory allocation proportion, processor allocation proportion and network bandwidth allocation proportion calculated are organized according to the service process name to form a resource allocation scheme, and the scheme format is XML format, which includes process identification, resource allocation proportion and allocation basis description.
[0058] Step S1344: The service adaptation model simultaneously obtains the task information of all conversion tasks to be processed at present, and the task information includes the document type corresponding to the task, the document data volume, the task submission time and the task receiver demand. The processing difficulty is determined according to the document type in the task information, the processing time consumption is determined according to the document data volume, and the urgency is determined according to the task submission time and the receiver demand.
[0059] The service adaptation model obtains the task information of all conversion tasks to be processed currently through a data interface with the task queue management module. The data interface adopts the RESTful style, the service adaptation model sends an HTTP GET request, and the request parameters include the identification and state (to be processed) of the task queue. The task queue management module returns a task list in JSON format, and each task object in the task list includes a task ID, a document type (such as.docx,.xlsx,.pptx, etc.), a document data volume (expressed in bytes), a task submission time (in timestamp format), and task receiver requirements (including whether it is urgent, output format requirements, whether encryption is required, etc.). The service adaptation model parses the task list, extracts the task information of each task, and stores it in the task information table. When determining the processing difficulty according to the document type, a preset document type difficulty coefficient table is queried, in which each document type is assigned a difficulty coefficient. The difficulty coefficient is determined based on factors such as the number of calculation steps required in the conversion process of the document type, the algorithm complexity, and the degree of dependence on external libraries. For example, the difficulty coefficient of a presentation document (.pptx) is higher than that of a pure text document (.docx) because it contains pictures and animations. The processing time is determined according to the document data volume, and a mapping relationship model of the document data volume and the processing time is established. The mapping relationship model is obtained by training historical task data, the input is the document data volume and the document type difficulty coefficient, and the output is the predicted processing time. The model uses a multiple linear regression algorithm, in which the coefficient of the document data volume is positive, indicating that the larger the data volume, the longer the processing time, and the coefficient of the difficulty coefficient is also positive, indicating that the higher the difficulty, the longer the processing time. The urgency is determined according to the task submission time and the receiver requirements. The later the task submission time (the closer to the current time), the higher the urgency; the task marked as “urgent” in the receiver requirements has an increased urgency coefficient by a preset value, which is determined according to the task priority rules within the enterprise, for example, the urgency coefficient of an urgent task is increased by 0.3 (the urgency coefficient value range is 0 to 1).
[0060] Step S1345: Based on the processing difficulty, processing time and urgency, the service adaptation model establishes a task priority evaluation system to score the priority of each conversion task to be processed, determines the task priority ordering mode from high to low according to the score, and forms the priority ordering part of the task scheduling rule.
[0061] The task priority evaluation system includes evaluation indexes, index weights, and score calculation methods. The evaluation indexes include processing difficulty, processing time consumption, and urgency level, and the value of each index is standardized to 0 to 1. The index weights are determined by the analytic hierarchy process, and an evaluation group composed of enterprise IT operation experts and business department representatives is invited to compare the importance of each index, build a judgment matrix, calculate the maximum eigenvalue of the judgment matrix and the corresponding eigenvector, and obtain the weight of each index. The weight of the urgency level is usually higher than that of the processing difficulty and the processing time consumption. The score calculation method is to multiply the processing difficulty index value by its weight, the processing time consumption index value by its weight, and the urgency level index value by its weight, and then take the sum of the three as the task priority score. For example, the processing difficulty index value of a certain task is D, the weight is Wd; the processing time consumption index value is T, the weight is Wt; the urgency level index value is U, and the weight is Wu, then the priority score is The service adaptation model calculates the priority score of all the conversion tasks to be processed one by one, and then sorts the tasks in descending order of the score. The sorting result is the task priority sorting method, which is recorded in the task scheduling rule in the form of a task ID list as the priority sorting part.
[0062] Step S1346: According to the historical processing efficiency, real-time resource occupation rate, and supported document types of each service process, the comprehensive processing capacity score of each service process is calculated.
[0063] The service adaptation model retrieves the historical processing efficiency data of each service process from the historical task processing database. The historical processing efficiency is measured by the number of tasks processed per unit time and the average task processing accuracy. The number of tasks processed per unit time is the average value of the recent period (such as the past 24 hours), and the average task processing accuracy is obtained by dividing the number of successfully processed tasks in the historical tasks by the total number of processed tasks. The real-time resource occupancy rate is obtained from the resource monitoring module, including the current memory occupancy rate (used memory / allocated memory), processor occupancy rate (used core number / allocated core number), and network bandwidth occupancy rate (used bandwidth / allocated bandwidth). The average of the three is taken as the comprehensive real-time resource occupancy rate. The document types supported by the service process are recorded in the service process capability table. Each process supports multiple document types, which are represented by a binary vector. The supported document types correspond to bits of 1, and the unsupported ones correspond to bits of 0. When calculating the comprehensive processing capacity score, first convert the historical processing efficiency into an efficiency score: Efficiency score = (number of tasks processed per unit time / historical maximum number of tasks processed per unit time) 0.6 + average task processing accuracy 0.4. The weights are set according to the degree of influence on processing capacity. Then, calculate the resource adequacy score: Resource adequacy score = 1 - comprehensive real-time resource occupancy rate. The lower the resource occupancy rate, the higher the resource adequacy score. Next, calculate the document type matching degree score. For a document type in the current to-be-processed task, if the service process supports this type, the matching degree is 1, otherwise it is 0. If there are multiple to-be-processed tasks, take the average matching degree. Comprehensive processing capacity score = efficiency score 0.5 + resource adequacy score 0.3 + document type matching degree score The weights can be adjusted according to the current optimization goal of the system. For example, when the system focuses on processing speed, the efficiency score weight can be increased.
[0064] Step S1347: Set resource availability threshold and processing capacity score threshold.
[0065] The resource availability threshold includes a memory availability threshold, a processor availability threshold, and a network bandwidth availability threshold, which respectively represent the minimum available proportion of memory, processor, and network bandwidth resources when the service process can receive a new task. The above thresholds are determined according to the type of the service process and the historical resource availability during stable operation. For example, the text conversion process has low dependence on memory, and the memory availability threshold can be set to a low value, while the memory availability threshold of the table conversion process is set to a high value. The processing capacity score threshold is the minimum score standard for judging whether the service process has the processing capacity for a new task. This threshold is determined by statistical analysis of the comprehensive processing capacity score of the service process when it can stably process tasks in history. The lower limit value of the historical score is taken as the threshold, and the service process below the threshold is not assigned a new task. The resource availability threshold and the processing capacity score threshold are stored in the parameter configuration file of the service adaptation model, which can be manually adjusted by the system administrator according to the actual operation, and the adjustment record is automatically saved to the audit log.
[0066] Step S1348: Assign tasks with priority meeting the preset sorting standard to service processes with a comprehensive processing capacity score higher than the processing capacity score threshold and a real-time resource occupancy rate lower than the resource availability threshold, to form the task allocation mode part of the task scheduling rule, and complete the generation of the resource allocation scheme and the task scheduling rule.
[0067] The preset sorting standard means that the task priority score is higher than a certain preset value, which is determined according to the length of the current task queue and the average priority score. When the task queue is longer, the preset value can be appropriately increased to prioritize more urgent tasks. The service adaptation model traverses the task list sorted by priority, and for tasks with priority meeting the preset sorting standard, obtains their document types. Then, all service processes are traversed to filter out service processes with a comprehensive processing capacity score higher than the processing capacity score threshold and a real-time resource occupancy rate lower than the resource availability threshold, to form a candidate service process list. In the candidate service process list, the most suitable service process is selected according to the matching degree of the document types supported by the service process and the current task document type, the comprehensive processing capacity score of the service process, and the matching degree of the task priority (high priority tasks are assigned to processes with high scores). The selection method uses weighted voting, assigns weights to the matching degree, score, and priority matching degree of each candidate process, calculates the comprehensive score, and the process with the highest score is selected. The task is assigned to the selected service process, and the correspondence between the task ID and the service process ID is recorded to form the task allocation mode part. The resource allocation scheme and the task scheduling rule (including the priority sorting part and the task allocation mode part) are integrated into a JSON format document, a scheme generation timestamp and a version number are added, and the generation of the service stability control strategy is completed.
[0068] Step S135: Compatibility verification is performed on the generated resource allocation scheme and task scheduling rule to ensure that the sum of the resource occupation ratios of each process in the resource allocation scheme meets the system resource total quantity limit and that the task allocation manner in the task scheduling rule matches the processing capacity of the service process. After the verification passes, the two are integrated to generate a service stability regulation strategy.
[0069] Compatibility verification is an important link to ensure that the resource allocation scheme and the task scheduling rule can be effectively executed in the actual system. For the resource allocation scheme, it is verified whether the sum of the memory allocation ratios of each service process is equal to the total system memory allocatable ratio, whether the sum of the processor allocation ratios is equal to the total system processor resource allocatable ratio, and whether the sum of the network bandwidth allocation ratios is equal to the total system network bandwidth allocatable ratio, to ensure that the resource allocation scheme meets the system resource total quantity limit and avoids resource allocation conflicts. For the task scheduling rule, it is verified whether the task allocation manner matches the processing capacity of the service process, for example, whether the number and type of tasks allocated to a service process in the task scheduling rule are within the processing capacity range of the process, to avoid task failure or service crash due to task allocation exceeding the processing capacity of the process. If it is found in the verification process that the resource allocation scheme or the task scheduling rule has incompatibility problems, the service adaptation model is returned to adjust the parameters and generate the scheme again until the compatibility verification passes. After the verification passes, the resource allocation scheme and the task scheduling rule are integrated according to the preset format to form a complete service stability regulation strategy, which contains various resource allocation and task scheduling instructions required to achieve stable service operation.
[0070] Step S140: The service stability regulation strategy is input into the execution control module of the document conversion service, and the service stability regulation strategy is executed to obtain a service running parameter adjustment result.
[0071] After the service stability regulation strategy is generated, it needs to be passed to the execution control module of the document conversion service, which is responsible for adjusting the running parameters of the service according to the instructions in the strategy. The execution control module is a bridge connecting strategy generation and actual service running adjustment, which improves the running state of the service by executing the regulation strategy and solves the previous abnormal problems.
[0072] Step S141: The service stability regulation strategy is input into the execution control module of the document conversion service through a data transmission channel, and the execution control module has a strategy analysis unit. The strategy analysis unit performs structured analysis on the service stability regulation strategy and extracts the resource allocation scheme and the task scheduling rule therein.
[0073] The data transmission channel adopts an encrypted transmission mode to ensure the security and integrity of the service stability control strategy during the transmission process. After receiving the control strategy, the execution control module transmits it to the built-in strategy analysis unit. The strategy analysis unit analyzes the control strategy according to the preset format and separates the resource allocation scheme and the task scheduling rule. In analyzing the resource allocation scheme, the specific parameters such as the memory allocation ratio, processor allocation ratio, and network bandwidth allocation ratio corresponding to each service process are extracted. In analyzing the task scheduling rule, the specific rules of task priority ordering (such as ordering priority according to factors such as task submission time, urgency, and document type) and the specific method of task allocation to different service processes (such as allocation based on process load, processing capacity, and historical success rate) are extracted. After the analysis is completed, the extracted information is stored in the temporary data storage area of the execution control module.
[0074] Step S142: According to the resource allocation scheme obtained by analysis, the execution control module sends resource adjustment instructions to the resource allocation module of the document conversion service. The resource adjustment instructions contain the target memory occupation, target processor occupation, and target network bandwidth occupation of each service process. After receiving the instructions, the resource allocation module gradually adjusts the resource occupation of each service process to make the final resource allocation ratio comply with the resource allocation scheme.
[0075] The execution control module calculates the target memory occupation, target processor occupation, and target network bandwidth occupation of each service process according to the resource allocation scheme obtained by analysis and the current total amount of resources of the system. For example, the target memory occupation of each process is calculated according to the memory allocation ratio and the total memory capacity of the system. Then, resource adjustment instructions containing these target occupations are generated and sent to the resource allocation module. The resource allocation module is a component responsible for managing the allocation of server hardware resources. After receiving the resource adjustment instructions, it adjusts the resource occupation of each service process in a gradual manner. During the gradual adjustment process, the resource allocation module monitors the resource usage and service running state of each process in real time to avoid service process interruption or task failure caused by too fast resource adjustment. For example, for a service process that needs to increase memory allocation, its memory allocation is gradually increased in multiple times. After each adjustment, the process running is observed to ensure stability until the target memory occupation is reached. For a service process that needs to reduce memory allocation, part of the memory resources is gradually released on the premise that its current processing task is not affected. Through the above method, the resource occupation ratio of each service process is finally consistent with the provisions in the resource allocation scheme.
[0076] Step S143: According to the parsed task scheduling rule, the execution control module sends a task adjustment instruction to the task scheduling module of the document conversion service, which contains a task priority ranking list and the target service process identifier corresponding to each task.
[0077] The execution control module reorders the current conversion task queue to be processed according to the parsed task scheduling rule, and generates a task priority ranking list. The task priority ranking list sorts all tasks to be processed from high to low according to the sorting method specified in the task scheduling rule. At the same time, according to the task allocation method in the task scheduling rule and the current state of each service process (such as resource occupation, processing capacity, current task quantity, etc.), a target service process is allocated to each task, and a corresponding target service process identifier is generated. Then, the execution control module integrates the task priority ranking list and the target service process identifier corresponding to each task into the task adjustment instruction and sends it to the task scheduling module.
[0078] Step S144: After receiving the task adjustment instruction, the task scheduling module reorders the current task queue to be processed, and assigns tasks to the corresponding service process according to the sorting result.
[0079] After receiving the task adjustment instruction, the task scheduling module first reorganizes the current task queue to be processed according to the task priority ranking list, and adjusts the execution order of the tasks so that high-priority tasks are placed at the front of the queue and have priority to obtain processing resources. Then, according to the target service process identifier corresponding to each task, the task is assigned to the task processing queue of the corresponding service process. During the task allocation process, the task scheduling module communicates with each service process to obtain the task processing queue state of the service process in real time, ensuring the accuracy and timeliness of task allocation. For example, the high-urgency text document conversion task ranked first in the task priority ranking list is assigned to the service process corresponding to the target service process identifier, which is specifically responsible for processing text document conversion.
[0080] Step S145: During the process of resource adjustment by the resource allocation module and task adjustment by the task scheduling module, the execution control module collects service running parameter change data through the real-time monitoring unit, which includes resource occupation change data, task processing efficiency change data, and process response change data. The collection frequency is adapted to the change rate of the service running parameter.
[0081] Step S1451: The real-time monitoring unit of the execution control module determines the collection frequency, which is determined according to the historical change rate of the service running parameter. Parameters with a fast change rate require more frequent collection, while parameters with a slow change rate require relatively gentle collection, so that the collection frequency is adapted to the change rate of the parameter.
[0082] When the real-time monitoring unit is started, first, the historical change records of various service running parameters are called from the historical monitoring database, and the historical change records include parameter name, sampling timestamp and parameter value. For each parameter, its historical change rate is calculated, and the change rate is measured by calculating the average absolute change amount of the parameter value per unit time, and the unit time is 10 times the parameter sampling period. For example, the sampling period of a certain parameter is T, and in the time window 10T, the parameter value changes from V1 to V2, and the change rate is |V2-V1| / 10T. According to the size of the historical change rate, the parameters are divided into three categories: fast-changing parameters, medium-changing parameters and slow-changing parameters. Fast-changing parameters include processor occupancy rate, network bandwidth occupancy rate, etc., and their change rates are high; medium-changing parameters include memory occupancy rate, task processing progress, etc.; slow-changing parameters include process startup time, total task completion time, etc. Different basic collection frequency ranges are preset for different types of parameters, and the basic collection frequency range of fast-changing parameters is higher than that of medium-changing parameters, and the basic collection frequency range of medium-changing parameters is higher than that of slow-changing parameters. The real-time monitoring unit dynamically adjusts the actual collection frequency in the corresponding type of basic collection frequency range according to the historical change rate of the current parameter. The adjustment method is to compare the current change rate with the average value of the historical change rate of the parameter, if the current change rate is higher than the average value, the collection frequency is increased in the basic range; if it is lower than the average value, the collection frequency is reduced. The adjustment range of the collection frequency is determined according to the deviation degree of the change rate, the greater the deviation degree, the greater the adjustment range, but not exceeding the basic collection frequency range. The determined collection frequency is stored in the collection configuration table of the real-time monitoring unit, and each parameter corresponds to a configuration record, including parameter ID, current collection frequency, next evaluation and adjustment time.
[0083] Step S1452: In the process of resource allocation module performing resource adjustment, the real-time monitoring unit collects resource occupation data of each service process according to the determined collection frequency, calculates the difference between the current resource occupation data of the service process and the resource occupation data collected last time after each collection, associates the difference with the collection timestamp, and standardizes the change values of different types of resources to form resource occupation change data. The resource occupation change data includes standardized memory occupation change value, processor occupation change value and network bandwidth occupation change value.
[0084] The real-time monitoring unit sends a resource occupation data collection request to the resource allocation module at a regular time according to the parameter ID and collection frequency in the collection configuration table. The request contains the target service process ID and the resource type (memory, processor, network bandwidth) to be collected. After receiving the request, the resource allocation module collects the current resource occupation data of the specified service process through the system call interface provided by the operating system. The memory occupation data is obtained by reading the virtual memory size and physical memory size of the process, and the physical memory size is taken as the current memory occupation data. The processor occupation data is obtained by reading the CPU time slice usage of the process, calculating the CPU usage rate in the collection interval, and multiplying the allocated processor core number. The network bandwidth occupation data is obtained by listening to the network socket of the process and counting the total number of bytes sent and received in a unit of time. After the collection is completed, the resource allocation module returns the current resource occupation data and the collection timestamp to the real-time monitoring unit. The real-time monitoring unit calculates the difference between the current resource occupation data and the last collected resource occupation data (stored in the local cache, with the service process ID and resource type as the key) to obtain the original change value (current value - last value). The original change value is standardized by dividing it by the maximum change amplitude of the resource type in the historical adjustment process. The maximum change amplitude is determined by statistical maximum absolute change value of the resource type in the historical resource adjustment. The standardized change value ranges from -1 to 1, with a positive value indicating an increase in resource occupation and a negative value indicating a decrease. The standardized memory occupation change value, processor occupation change value, and network bandwidth occupation change value are associated with the collection timestamp and service process ID and stored in the resource occupation change data buffer to form resource occupation change data.
[0085] Step S1453: During the task scheduling module executes the task adjustment, the real-time monitoring unit collects the number of tasks completed by each service process in a unit of time, calculates the difference between the current unit of time processing capacity and the last unit of time processing capacity to obtain the task processing efficiency change data. At the same time, the real-time monitoring unit collects the response time of each service process from receiving a request to returning a processing result, calculates the difference between the current response time and the last response time to obtain the process response change data.
[0086] The real-time monitoring unit establishes a long connection with the task scheduling module and receives task processing state update events through a subscription mechanism. The unit time is determined according to the average duration of task processing, for example, for short tasks (average processing time less than 1 minute), the unit time is set to 1 minute; for long tasks (average processing time greater than 10 minutes), the unit time is set to 5 minutes. The real-time monitoring unit sends a task completion quantity query request to the task scheduling module at the end of each unit time, and the request includes the service process ID and the time window (the current unit time). The task scheduling module queries the number of tasks marked as “completed” in the specified time window for the service process and returns it to the real-time monitoring unit. The real-time monitoring unit calculates the difference between the current unit time processing capacity and the last unit time processing capacity (read from the local cache, key is service process ID and unit time identifier) to obtain task processing efficiency change data (current processing capacity - last processing capacity). For process response time collection, the real-time monitoring unit achieves this by intercepting communication messages between the service process and the task scheduling module. When the service process receives a task request message, it records the reception timestamp, and when the service process sends a task processing result message, it records the sending timestamp. The response time is the sending timestamp minus the reception timestamp. The real-time monitoring unit extracts the latest response time of each service process from the message log at a regular interval (the collection frequency is consistent with the preset frequency of process response change data) and calculates the difference between the current response time and the last collected response time (stored in the local cache) to obtain process response change data (current response time - last response time). The task processing efficiency change data and the process response change data are associated with the service process ID, unit time identifier / collection timestamp, respectively, and stored in the corresponding data buffer.
[0087] Step S1454: The real-time monitoring unit performs real-time verification on the collected resource occupation change data, task processing efficiency change data and process response change data, and stores the resource occupation change data, task processing efficiency change data and process response change data that pass the verification according to the service process. Each service process corresponds to a complete set of change data.
[0088] The verification module of the real-time monitoring unit first verifies the resource occupation change data, and the verification content includes data integrity (whether to contain service process ID, timestamp, and three resource change values), data rationality (whether the standardized change value is between -1 and 1), and timestamp continuity (whether the current timestamp is later than the last timestamp and the interval is within a reasonable range, which is determined according to the collection frequency). For task processing efficiency change data, the verification content includes whether the task quantity is a non-negative integer, whether the unit time identifier is correct, and whether the change value is within a preset reasonable range (determined based on the maximum and minimum values of historical task processing efficiency changes). For process response change data, the verification content includes whether the response time is a non-negative value and whether the change value is within a preset range (to avoid false judgments caused by abnormal values). During the verification process, if the data is found to be incomplete or unreasonable, the real-time monitoring unit sends a re-collection request to the resource allocation module or the task scheduling module, retries a maximum of a preset number of times (such as 3 times), and if the verification fails after retrying, marks the data as invalid and records an error log. The verified data is sent to the classified storage module, which creates a data directory according to the service process ID, and creates three subdirectories of "resource occupation change", "task processing efficiency change", and "process response change" under each directory. The corresponding data is stored in the corresponding subdirectory in the form of a JSON file, and the file name contains the timestamp of data generation, which facilitates subsequent retrieval in chronological order. Under the directory of each service process, the three change data files form the complete service running parameter change data record of the process.
[0089] Step S146: The execution control module performs time sequence arrangement on the collected service running parameter change data, sorts the service running parameter change data according to the collection time sequence, attributes the valid data, marks the corresponding service process, data type, and collection time, and forms a service running parameter adjustment result after the arrangement, which reflects the change of the service running state after the execution of the service stability control strategy.
[0090] After the execution control module collects the service running parameter change data, it sorts the data according to the time sequence of data collection and constructs time series data. Then, the validity of each data point in the time series is judged, and invalid data caused by collection errors or interference factors is removed. For valid data, attribute annotation is performed to clearly indicate the corresponding service process (such as "text document conversion process", "table document conversion process", etc.), data type (such as "memory occupation change data", "processor occupation change data", etc.), and specific collection time. After time sequence arrangement and attribute annotation, the data set forms a service running parameter adjustment result.
[0091] Step S150: updating the training sample set of the service adaptation model based on the service running parameter adjustment result, iteratively optimizing the service adaptation model, and generating an optimized service adaptation model.
[0092] The service running parameter adjustment result reflects the effect of the control strategy generated by the service adaptation model in actual application. By feeding back the result to the training process of the service adaptation model, the model is iteratively optimized, which can continuously improve the control ability of the model for service exceptions, so that the service adaptation model can better adapt to various complex situations in the service running process.
[0093] Step S151: analyzing the service running parameter adjustment result, extracting resource occupation change data, task processing efficiency change data, and process response change data, simultaneously calling the corresponding service exception mode recognition result and service stability control strategy in this stability control process, associating the resource occupation change data, the task processing efficiency change data, the process response change data, the service exception mode recognition result, and the service stability control strategy, and the association basis is the timestamp of the control process.
[0094] First, the service running parameter adjustment result is analyzed, and the resource occupation change data (such as the change sequence of the memory occupation of each service process, the change sequence of the processor occupation, etc.), the task processing efficiency change data (such as the change sequence of the number of tasks processed per unit time, the change sequence of the task processing progress rate, etc.), and the process response change data (such as the change sequence of the process response delay time, the change sequence of the process interaction success rate, etc.) are extracted from the sorted time series data. Then, through the control process timestamp recorded by the system log, the corresponding service exception mode recognition result (including exception type identification and exception associated features) and service stability control strategy (including resource allocation scheme and task scheduling rule) in this stability control process are called. With the timestamp of the control process as the common identifier, the extracted various change data are associated with the service exception mode recognition result and the service stability control strategy, and a complete data chain of “abnormality recognition-strategy generation-execution effect” is established. For example, the resource occupation change data in a certain time period is associated with the abnormality associated features in the service exception mode recognition result corresponding to the time period, and the executed resource allocation scheme part, forming a complete control case data set.
[0095] Step S152: marking the associated data set as a new training sample, the new training sample including input features and output labels, the input features being the abnormality associated features in the service exception mode recognition result, and the output labels being the service stability control strategy and the corresponding service running parameter adjustment result, adding the new training sample to the training sample set of the service adaptation model, and updating the content of the training sample set.
[0096] The associated data set is labeled with training samples, and the input features and output labels are determined. The input features are set as the abnormal association features in the service anomaly pattern recognition result, which describe the specific manifestations and related factors of service anomalies; the output labels are set as the service stability control strategies generated in this control process and the service running parameter adjustment results obtained after executing the strategies, which reflect the control measures taken for specific abnormal association features and their actual effects. The labeled data set is used as a new training sample and added to the training sample set of the service adaptation model. The training sample set is a database that stores a large number of historical control case data, and the addition of new samples expands the size and coverage of the training sample set, including more up-to-date service anomaly situations and control experience.
[0097] Step S153: Select samples from the updated training sample set as validation samples according to a preset proportion, and the remaining samples as training samples, wherein the preset proportion is determined according to the total number of the training sample set, so that the validation samples can cover samples corresponding to different types of service anomalies.
[0098] The determination of the preset proportion considers the total number of the training sample set. When the total number of samples is large, the preset proportion can be appropriately reduced to ensure that there are sufficient training samples for model training; when the total number of samples is small, the preset proportion can be appropriately increased to ensure that the validation samples can fully reflect different types of service anomaly situations. When selecting validation samples, a stratified sampling method is used to stratify the training sample set according to service anomaly types, and a certain number of samples are selected from the samples corresponding to each anomaly type as validation samples according to the preset proportion, and the remaining samples are used as training samples. Through the above method, the validation samples can cover all samples corresponding to different types of service anomalies, ensuring that the model's processing capability for various anomalies can be fully evaluated during model validation. For example, for a training sample set containing multiple anomaly types, samples of the same proportion are selected from the samples of each anomaly type to form validation samples, to ensure the representativeness of the validation samples.
[0099] Step S154: Divide the training samples into batches, each batch containing a preset number of training samples, and input the training samples in batch order into the service adaptation model, and the service adaptation model processes the input features in each training sample and outputs the predicted service stability control strategy.
[0100] The determination of the preset number takes into account factors such as the computing power of the service adaptation model, the memory resource limit, and the training efficiency requirement, and the number of samples in each batch should enable the model to be efficiently processed in memory. The training samples are divided into batches, and each batch contains a preset number of continuous training samples. During the model training process, the training samples are input into the service adaptation model in sequence according to the batch order. After receiving the input features (abnormal association features) of the training samples, the service adaptation model processes the input features through its internal neural network structure. The layers of the neural network perform layer-by-layer transformation and abstraction on the features according to the preset connection relationship and weight parameters, for example, the input layer receives the abnormal association features, performs convolution, pooling, full connection, and other operations on the features through multiple hidden layers, and finally outputs the predicted service stability regulation strategy through the output layer, which includes the predicted resource allocation scheme and task scheduling rule.
[0101] Step S155: Compare the predicted regulation strategy output by the service adaptation model with the actual service stability regulation strategy in the training sample, calculate the difference between the two in terms of resource allocation proportion and task scheduling rule, and generate a strategy difference value. At the same time, compare the parameter change results simulated by the service adaptation model based on the predicted regulation strategy with the actual service running parameter adjustment results in the training sample, and calculate the difference between the two in terms of standardized resource occupancy change, task processing efficiency change, and process response change, and generate a parameter difference value.
[0102] The calculation of the strategy difference value is performed for the resource allocation proportion and the task scheduling rule in the predicted regulation strategy and the actual service stability regulation strategy. For the resource allocation proportion, compare the differences between the predicted memory allocation proportion, processor allocation proportion, and network bandwidth allocation proportion of each service process and the corresponding proportions in the actual strategy; for the task scheduling rule, compare the differences between the predicted task priority ordering method and the method of assigning tasks to service processes and the actual rule, and generate a strategy difference value by synthesizing these differences, with a larger difference value indicating a larger deviation between the predicted strategy and the actual strategy. The calculation of the parameter difference value first requires standardizing the parameter change results (such as simulated resource occupancy change, task processing efficiency change, and process response change data) simulated by the service adaptation model based on the predicted regulation strategy and the actual service running parameter adjustment results in the training sample to eliminate the influence of dimensional differences. The standardization process uses the same method as the previous feature standardization to convert the data to a unified numerical interval. Then, compare the differences between the standardized simulated parameter change results and the actual parameter change results in each dimension, such as the similarity of the standardized memory occupancy change curve and the consistency of the task processing efficiency change trend, and generate a parameter difference value by synthesizing these differences.
[0103] Step S156: Construct a loss function based on the policy difference value and the parameter difference value, calculate the partial derivative of the loss function with respect to each parameter of the service adaptation model by the gradient descent algorithm, adjust the parameters of the service adaptation model according to the direction of the partial derivative, adjust the loss function value to a preset range, complete the training of one batch of samples, and repeat the process until all training sample batches are processed, completing one round of training.
[0104] The construction of the loss function combines the policy difference value and the parameter difference value according to certain weights to form a function that comprehensively reflects the prediction error of the model. The size of the weight is determined according to the degree of influence of the policy difference and the parameter difference on the performance of the model. For example, if the policy difference has a greater impact on the service regulation effect, a higher weight is assigned to the policy difference value. The partial derivative of the loss function with respect to each parameter of the service adaptation model (such as the connection weight and bias value in a neural network) is calculated by the gradient descent algorithm. The partial derivative reflects the direction and degree of influence of parameter changes on the loss function value. According to the direction of the partial derivative, the parameters of the service adaptation model are adjusted according to the preset learning rate, so that the loss function value changes in the direction of decreasing. The size of the learning rate affects the step size of parameter adjustment and needs to be dynamically adjusted according to the change of the loss function during training. In the training process of one batch of samples, the model parameters are constantly adjusted until the loss function value decreases to a preset range or reaches the upper limit of the number of iterations, completing the training of this batch of samples. According to the same method, all training sample batches are processed in turn. When all batches are processed, one round of training of the service adaptation model is completed.
[0105] Step S157: After completing one round of training, input the verification sample into the currently trained service adaptation model, and the service adaptation model outputs the predicted regulation policy and the predicted parameter change result for the input features of the verification sample, calculates the policy difference value between the predicted regulation policy and the actual service stability regulation policy in the verification sample, and calculates the parameter difference value between the predicted parameter change result and the actual service running parameter adjustment result in the verification sample.
[0106] After each round of training is completed, the verification sample is used to verify the model to evaluate the generalization ability and training effect of the service adaptation model. The verification sample is input into the currently trained service adaptation model in the same input format as the training sample. The model processes the input features (abnormal correlation features) of the verification sample and outputs the predicted regulation policy and the predicted parameter change result simulated based on the policy. Then, the policy difference value between the predicted regulation policy and the actual service stability regulation policy in the verification sample is calculated, and the parameter difference value between the predicted parameter change result and the actual service running parameter adjustment result in the verification sample is calculated. The above difference values reflect the prediction performance of the model on the verification sample that did not participate in the training.
[0107] Step S158: Calculate the verification accuracy of the service adaptation model based on the policy difference value and the parameter difference value of the verification sample. The verification accuracy reflects the degree of agreement between the prediction result and the actual result of the service adaptation model. If the verification accuracy does not reach the preset standard, adjust the training parameters and retrain the training sample in batches until the verification accuracy of the service adaptation model reaches the preset standard, and complete the training optimization of the service adaptation model.
[0108] The calculation of the verification accuracy is based on the policy difference value and the parameter difference value of the verification sample. By converting the above difference values into accuracy indicators, the degree of agreement between the model prediction result and the actual result is measured. For example, when the policy difference value and the parameter difference value are both less than the preset threshold, it is considered that the verification sample is predicted correctly, and the verification accuracy is the ratio of the number of verification samples predicted correctly to the total number of verification samples. The preset standard is a verification accuracy threshold set according to the actual demand of service stability regulation. This verification accuracy threshold reflects the minimum requirement for model prediction performance. If the calculated verification accuracy does not reach the preset standard, it means that the model has insufficient generalization ability or insufficient training, and the training parameters (such as learning rate, batch size, upper limit of training rounds, etc.) need to be adjusted. Then, start from dividing the training sample batches, and train the service adaptation model according to the above training process. Repeat the adjustment of the training parameters and the training process until the verification accuracy of the service adaptation model on the verification sample reaches the preset standard. At this time, it is considered that the model training optimization is completed, and the optimized service adaptation model is generated. The optimized service adaptation model can more accurately generate effective service stability regulation strategies according to the service anomaly pattern recognition result, and improve the stability of the document conversion service.
[0109] Figure 2 A schematic diagram of exemplary hardware and software components of an artificial intelligence-based document conversion service stability optimization system 100 that can implement the idea of the present application is shown. For example, the processor 120 can be used in the artificial intelligence-based document conversion service stability optimization system 100 and used to perform the functions in the present application.
[0110] For example, the artificial intelligence based document conversion service stability optimization system 100 can include a network port 110 connected to a network, one or more processors 120 for executing program instructions, a communication bus 130, and different forms of storage media 140, such as a disk, a ROM, or a RAM, or any combination thereof. Illustratively, the artificial intelligence based document conversion service stability optimization system 100 can also include program instructions stored in a ROM, a RAM, or other types of non-transitory storage media, or any combination thereof. The methods of the present application can be implemented according to these program instructions. The artificial intelligence based document conversion service stability optimization system 100 also includes an I / O interface 150 between the computer and other input and output devices.
[0111] In addition, the embodiments of the present application also provide a readable storage medium, wherein computer executable instructions are preset in the readable storage medium, and when a processor executes the computer executable instructions, the artificial intelligence based document conversion service stability optimization method is realized.
[0112] It should be noted that, in order to simplify the expression of the present application and to help the understanding of one or more embodiments of the present application, in the foregoing description of the embodiments of the present application, various features are sometimes combined into one embodiment, figure or description thereof.
Claims
1. A method for optimizing the stability of document conversion services based on artificial intelligence, characterized in that, The method includes: Obtain a real-time running status data set of the document conversion service, perform feature extraction processing on the real-time running status data set to obtain a service running status feature set, wherein the real-time running status data set includes service process running data, resource usage data and conversion task processing data; The pre-trained service anomaly tracing module is invoked to perform anomaly pattern recognition processing on the service running status feature set, generating service anomaly pattern recognition results, which include anomaly type identifiers and anomaly association features. Based on the service anomaly pattern recognition result, the corresponding service adaptation model is invoked, the parameters of the service adaptation model are adjusted, and a service stability control strategy is generated. The service stability control strategy includes a resource allocation scheme and task scheduling rules. The service stability control strategy is input into the execution control module of the document conversion service, and the service stability control strategy is executed to obtain the service operation parameter adjustment results; The training sample set of the service adaptation model is updated based on the adjustment results of the service operation parameters, and the service adaptation model is iteratively optimized to generate an optimized service adaptation model.
2. The method for optimizing the stability of document conversion services based on artificial intelligence according to claim 1, characterized in that, The process involves acquiring a real-time operational status data set of the document conversion service, performing feature extraction on the real-time operational status data set to obtain a service operational status feature set, including: Collect service process running data generated during the operation of the document conversion service. The service process running data includes process startup time data, process response delay data, and process interaction data. Collect resource usage data during the operation of the document conversion service, including memory usage data, processor usage data, and network bandwidth usage data; Collect conversion task processing data when the document conversion service processes tasks. The conversion task processing data includes task received quantity data, task processing progress data, and task completion time data. The service process running data, the resource usage data, and the conversion task processing data are integrated according to the time series to form a real-time running status data set. Feature extraction processing is performed on the real-time running status data set. The process running features, resource usage features, and task processing features are extracted by the feature extraction algorithm. The process running features correspond to the key attributes of the service process running data, the resource usage features correspond to the key attributes of the resource usage data, and the task processing features correspond to the key attributes of the conversion task processing data. After the process running characteristics, resource usage characteristics, and task processing characteristics are input into the feature fusion module for standardized processing, a combination of feature splicing and weight allocation is used for fusion processing to generate a service running status feature set with a unified dimension.
3. The method for optimizing the stability of document conversion services based on artificial intelligence according to claim 1, characterized in that, The pre-trained service anomaly tracing module is invoked to perform anomaly pattern recognition processing on the service runtime state feature set, generating service anomaly pattern recognition results, including: The service operation status feature set is input into the feature layering unit of the service anomaly tracing module. The service operation status feature set is layered according to the data source and correlation to obtain a basic feature layer and a related feature layer. The basic feature layer contains features corresponding to a single type of data, namely, independent features corresponding to service process operation data, resource consumption data, and conversion task processing data respectively. The related feature layer contains correlation features between different types of data, namely, correlation features between service process operation data and resource consumption data, correlation features between resource consumption data and conversion task processing data, and correlation features between service process operation data and conversion task processing data. For each feature in the basic feature layer, an anomaly threshold comparison is performed. By using a preset normal range for the feature, features that exceed the normal range are selected as basic abnormal features. For each associated feature in the associated feature layer, a correlation degree analysis is performed. By calculating the standardized correlation strength value of the associated features, features whose standardized correlation strength value exceeds the normal correlation range are selected as associated abnormal features. The basic anomaly features and the associated anomaly features are input into the pattern matching unit of the service anomaly tracing module. The preset anomaly pattern library is called to compare the basic anomaly features with the standard basic anomaly features one by one, and the associated anomaly features with the standard associated anomaly features one by one. The anomaly pattern library stores a set of standard anomaly features corresponding to various historical service anomalies. Each set of standard anomaly features includes standard basic anomaly features and standard associated anomaly features. Based on the comparison results, the degree of matching between the current abnormal feature and each set of standard abnormal features is calculated. The corresponding abnormal type identifier is determined according to the set of standard abnormal features with the highest degree of matching. The abnormal type identifier is used to distinguish different types of service abnormalities. At the same time, features directly related to the abnormal type identifier are extracted from the basic abnormal features and the associated abnormal features as abnormal association features. The anomaly type identifier and the anomaly association features are integrated according to a preset format to generate a service anomaly pattern recognition result.
4. The method for optimizing the stability of document conversion services based on artificial intelligence according to claim 3, characterized in that, The step of inputting the basic anomaly features and the associated anomaly features into the pattern matching unit of the service anomaly tracing module, calling the preset anomaly pattern library, and comparing the basic anomaly features with standard basic anomaly features one by one, and comparing the associated anomaly features with standard associated anomaly features one by one, includes: Call the preset abnormal pattern library, read all standard abnormal feature sets stored in the abnormal pattern library, and identify each standard abnormal feature set; For each set of standard anomaly features, each feature in the set of standard anomaly features is compared with the corresponding standard basic anomaly feature in terms of feature attributes. Before the comparison, all feature values are standardized, and the standardized difference value between the two in the attribute dimension is calculated. The standardized difference value is negatively correlated with the degree of matching. The degree of matching corresponding to the standardized difference value conforms to a preset association relationship. At the same time, the similarity between the numerical distribution of the standardized basic anomaly features and the numerical distribution of the standardized standard basic anomaly features is calculated to obtain the basic feature similarity. For each set of standard anomaly features, the association relationship between each feature in the set of standard anomaly features and the corresponding standard association anomaly features is compared. The consistency between the two in terms of association direction and association strength change trend is analyzed, the degree of agreement of association relationship is calculated, and the similarity of the time series change pattern of the association features is calculated to obtain the association feature similarity. The basic feature similarity and the associated feature similarity are weighted and summed according to a preset weight to obtain the comprehensive matching degree between the current abnormal feature and the standard abnormal feature set. The preset weight is adjusted according to the historical anomaly identification accuracy. If multiple sets of standard anomaly features have the same overall matching degree and all have the highest value, then the key features in the basic anomaly features and the associated anomaly features are further extracted. The key features are then compared with the key standard features in each set of standard anomaly features. Based on the results of the second comparison, a unique set of standard anomaly features is determined. The key features are those that have the greatest impact on service anomalies.
5. The method for optimizing the stability of document conversion services based on artificial intelligence according to claim 1, characterized in that, The step of invoking the corresponding service adaptation model based on the service anomaly pattern recognition result, adjusting the parameters of the service adaptation model, and generating a service stability control strategy includes: The abnormal type identifier in the service abnormality pattern recognition result is parsed. According to the preset correspondence between abnormal type and service adaptation model, the service adaptation model matching the abnormal type identifier is called from the model library. Different abnormal type identifiers correspond to different service adaptation models. Each service adaptation model has optimization and control capabilities for specific types of service abnormalities. Extract the abnormal association features from the service abnormality pattern recognition results, classify the abnormal association features by attributes, determine the features that reflect resource problems, process problems, and task problems, and input the classified abnormal association features into the called service adaptation model as the core basis for adjusting the service adaptation model parameters. After receiving the classified anomaly correlation features, the service adaptation model reads its own initial parameter configuration, which includes resource allocation parameters, task scheduling parameters, and process control parameters. Based on the influence of different types of features in the anomaly correlation features, the corresponding initial parameters are adjusted. The service adaptation model with adjusted parameters is run. The service adaptation model analyzes the current operational bottleneck of the document conversion service and generates a resource allocation scheme based on the adjusted parameters. The resource allocation scheme includes the memory allocation ratio, processor allocation ratio, and network bandwidth allocation ratio of different service processes. At the same time, the service adaptation model performs priority analysis on the conversion tasks to be processed and generates task scheduling rules. The task scheduling rules include the task priority sorting method and the method of assigning tasks to different service processes. The generated resource allocation scheme and task scheduling rules are subjected to compatibility verification to ensure that the total resource ratio of each process in the resource allocation scheme meets the system's total resource limit, and that the task allocation method in the task scheduling rules matches the processing capacity of the service process. After the verification is passed, the two are integrated to generate a service stability control strategy.
6. The method for optimizing the stability of document conversion services based on artificial intelligence according to claim 5, characterized in that, The service adaptation model, after adjusting the parameters, analyzes the current operational bottlenecks of the document conversion service and generates a resource allocation scheme based on the adjusted parameters. This resource allocation scheme includes memory allocation ratios, processor allocation ratios, and network bandwidth allocation ratios for different service processes. Simultaneously, the service adaptation model performs priority analysis on currently pending conversion tasks and generates task scheduling rules, including: Run the service adaptation model with adjusted parameters, obtain the current total system resource data of the document conversion service through the data interface. The total system resource data includes the total memory capacity, the total number of processor cores and the total network bandwidth. At the same time, obtain the current resource usage data of each service process, compare the total system resource data with the current resource usage data, determine the remaining resources, and analyze the bottleneck of the current resource allocation in combination with the adjusted resource allocation parameters. Based on the resource bottleneck analysis results, the adjusted service adaptation model calculates the resource requirement priority of each service process according to the predefined service process weight coefficient and the standardized real-time monitoring task urgency index. The service process weight coefficient is determined based on its preset importance level, and the task urgency index is determined based on the delay threshold and deadline of the task queue and has been standardized. Based on the priority of the resource requirements, the remaining resources are allocated proportionally to each service process to generate a resource allocation scheme that includes the memory allocation ratio, processor allocation ratio, and network bandwidth allocation ratio for different service processes. The service adaptation model simultaneously obtains task information for all currently pending transformation tasks. The task information includes the document type, document data volume, task submission time, and task recipient requirements. The processing difficulty is determined based on the document type in the task information, the processing time is determined based on the document data volume, and the urgency is determined based on the task submission time and recipient requirements. Based on processing difficulty, processing time and urgency, the service adaptation model establishes a task priority evaluation system, scores the priority of each conversion task to be processed, and determines the task priority sorting method according to the score from high to low, forming the priority sorting part in the task scheduling rules. The overall processing capability score of each service process is calculated based on its historical processing efficiency, real-time resource utilization, and the types of documents it supports. Set resource availability thresholds and processing capacity scoring thresholds; Tasks whose priority meets the preset sorting criteria are assigned to service processes whose comprehensive processing capability score is higher than the processing capability score threshold and whose real-time resource occupancy rate is lower than the resource availability rate threshold, forming the task allocation method part of the task scheduling rule, thus completing the generation of the resource allocation scheme and task scheduling rule.
7. The method for optimizing the stability of document conversion services based on artificial intelligence according to claim 1, characterized in that, The step of inputting the service stability control strategy into the execution control module of the document conversion service, executing the service stability control strategy, and obtaining the service operation parameter adjustment results includes: The service stability control strategy is input into the execution control module of the document conversion service through the data transmission channel. The execution control module has a built-in strategy parsing unit, which performs structured parsing on the service stability control strategy and extracts the resource allocation scheme and task scheduling rules. Based on the parsed resource allocation scheme, the execution control module sends a resource adjustment instruction to the resource allocation module of the document conversion service. The resource adjustment instruction includes the target memory usage, target processor usage, and target network bandwidth usage of each service process. After receiving the instruction, the resource allocation module gradually adjusts the resource usage of each service process so that the final resource allocation ratio conforms to the resource allocation scheme. Based on the parsed task scheduling rules, the execution control module sends a task adjustment instruction to the task scheduling module of the document conversion service. The task adjustment instruction contains a task priority sorting list and the target service process identifier corresponding to each task. After receiving the task adjustment instruction, the task scheduling module reorders the current queue of tasks to be processed and assigns the tasks to the corresponding service processes according to the sorting result. During the process of resource adjustment by the resource allocation module and task adjustment by the task scheduling module, the execution control module collects service operation parameter change data through the real-time monitoring unit. The service operation parameter change data includes resource usage change data, task processing efficiency change data, and process response change data. The collection frequency is adapted to the change rate of the service operation parameters. The execution control module performs time-series processing on the collected service operation parameter change data, sorts the service operation parameter change data according to the collection time order, and labels the attributes of the valid data, including the corresponding service process, data type and collection time. After processing, the service operation parameter adjustment result is generated, which reflects the change in service operation status after the service stability control strategy is implemented.
8. The method for optimizing the stability of document conversion services based on artificial intelligence according to claim 7, characterized in that, During the process of resource adjustment by the resource allocation module and task adjustment by the task scheduling module, the execution control module collects change data of service operation parameters through the real-time monitoring unit. This change data includes changes in resource usage, task processing efficiency, and process response. The collection frequency is adapted to the rate of change of the service operation parameters, including: The real-time monitoring unit of the execution control module determines the sampling frequency. The sampling frequency is determined based on the rate of change of historical service operation parameters. Parameters with a fast rate of change use a more frequent sampling frequency, while parameters with a slow rate of change use a relatively gentle sampling frequency, so that the sampling frequency is adapted to the rate of change of the parameters. During the resource allocation module's resource adjustment process, the real-time monitoring unit collects resource usage data for each service process at a determined collection frequency. After each collection, it calculates the difference between the current resource usage data and the previously collected resource usage data for that service process, associates the difference with the collection timestamp, and standardizes the change values of different types of resources to form resource usage change data. The resource usage change data includes standardized memory usage change values, processor usage change values, and network bandwidth usage change values. During the task scheduling module's task adjustment process, the real-time monitoring unit collects the number of tasks completed by each service process within a unit of time, calculates the difference between the current unit of time and the previous unit of time, and obtains task processing efficiency change data. At the same time, the real-time monitoring unit collects the response time from receiving a request to returning a processing result for each service process, calculates the difference between the current response time and the previous response time, and obtains process response change data. The real-time monitoring unit verifies the collected data on changes in resource usage, task processing efficiency, and process response in real time. The verified data are then stored according to the service process, with each service process corresponding to a complete set of change data.
9. The method for optimizing the stability of document conversion services based on artificial intelligence according to claim 1, characterized in that, The step of updating the training sample set of the service adaptation model based on the service operation parameter adjustment results, and iteratively optimizing the service adaptation model to generate an optimized service adaptation model includes: The service operation parameter adjustment results are analyzed, and the resource usage change data, task processing efficiency change data, and process response change data are extracted. At the same time, the service anomaly pattern identification results and service stability control strategies corresponding to this stability control process are retrieved. The resource usage change data, task processing efficiency change data, process response change data, service anomaly pattern identification results, and service stability control strategies are associated with each other, based on the timestamp of the control process. The associated dataset is labeled as a new training sample. The new training sample contains input features and output labels. The input features are the abnormal association features in the service anomaly pattern recognition results. The output labels are the service stability control strategy and the corresponding service operation parameter adjustment results. The new training sample is added to the training sample set of the service adaptation model, and the contents of the training sample set are updated. From the updated training sample set, samples are selected as verification samples according to a preset ratio, and the remaining samples are used as training samples. The preset ratio is determined according to the total number of training samples, so that the verification samples can cover samples corresponding to different types of service anomalies. The training samples are divided into batches, each batch containing a preset number of training samples. After the training samples are input into the service adaptation model in the order of the batches, the service adaptation model processes the input features in each training sample and outputs a predicted service stability control strategy. The predictive control strategy output by the service adaptation model is compared with the actual service stability control strategy in the training samples. The differences between the two in terms of resource allocation ratio and task scheduling rules are calculated to generate a strategy difference value. At the same time, the parameter change results simulated by the service adaptation model based on the predictive control strategy are compared with the actual service operation parameter adjustment results in the training samples. Before the comparison, the parameter change results are standardized, and the differences between the two in terms of standardized resource consumption change, task processing efficiency change, and process response change are calculated to generate a parameter difference value. A loss function is constructed based on the strategy difference value and the parameter difference value. The partial derivatives of the loss function with respect to each parameter of the service adaptation model are calculated using the gradient descent algorithm. The parameters of the service adaptation model are adjusted according to the direction of the partial derivatives. The loss function value is adjusted to a preset range to complete the training of one batch of samples. This process is repeated until all training sample batches are processed to complete one round of training. After each round of training, the validation samples are input into the currently trained service adaptation model. The service adaptation model outputs the prediction and control strategy and the prediction parameter change results for the input features of the validation samples. The strategy difference between the prediction and control strategy and the actual service stability control strategy in the validation samples is calculated, and the parameter difference between the prediction parameter change results and the actual service operation parameter adjustment results in the validation samples is calculated. The validation accuracy of the service adaptation model is calculated based on the policy difference value and parameter difference value of the validation samples. The validation accuracy reflects the degree of agreement between the prediction results of the service adaptation model and the actual results. If the validation accuracy does not reach the preset standard, the training parameters are adjusted and the training samples are retrained according to the batch processing until the validation accuracy of the service adaptation model reaches the preset standard, thus completing the training optimization of the service adaptation model.
10. A document conversion service stability optimization system based on artificial intelligence, characterized in that, The AI-based document conversion service stability optimization system includes a processor and a memory, the memory and the processor being connected. The memory is used to store programs, instructions, or code, and the processor is used to execute the programs, instructions, or code in the memory to implement the AI-based document conversion service stability optimization method according to any one of claims 1-9.
Citation Information
Patent Citations
Printer document cloud conversion method and system, medium and program product
CN118502693A
Supercomputing center emergency response method and system based on data fusion analysis
CN120353635A
Big data-combined bus system full-data comprehensive management analysis method and system
CN120430587A
Adaptive data processing optimization method and device, equipment and medium
CN120743705A
Intelligent operation and maintenance processing method and system for thermoelectric unit
CN120875828A
Cited By
Network security protection method and system applied to cloud data monitoring
CN121644209A