Optical character recognition model optimization method and device based on MaaS platform

CN123016445APending Publication Date: 2026-10-30SHANGHAI ENFLAME INTELLIGENCE TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611011380.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-08
Publication Date
2026-10-30

AI Technical Summary

Technical Problem

[0004]本发明提供了一种基于MaaS平台的光学字符识别模型优化方法及装置,解决了依赖人工采集及标注的训练数据,优化光学字符识别模型的现有技术,成本较高,且模型优化效果较差的问题,降低了模型优化成本,改善了模型优化效果,保证了各类图片识别结果的准确性

Benefits of technology

[0009]本发明的技术方案,通过获取用户向MaaS平台提交的光学字符识别请求,并从光学字符识别请求中提取待识别图片;调用部署于MaaS平台的光学字符识别模型,对各待识别图片进行识别,得到与各待识别图片分别的图片识别结果;基于各图片识别结果,将各待识别图片划分为识别成功图片和识别失败图片;根据各识别失败图片生成增量训练集,并采用增量训练集,对光学字符识别模型进行微调;当微调后光学字符识别模型满足预设性能要求时,返回执行获取用户向MaaS平台提交的光学字符识别请求的操作,直至达到预先定义的微调终止条件的技术手段,解决了依赖人工采集及标注的训练数据,优化光学字符识别模型的现有技术,成本较高,且模型优化效果较差的问题,降低了模型优化成本,改善了模型优化效果,保证了各类图片识别结果的准确性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123016445A_ABST
    Figure CN123016445A_ABST
Patent Text Reader

Abstract

The embodiment of the application discloses a kind of based on MaaS platform's optical character recognition model optimization method and device, comprising: obtaining the optical character recognition request that user submits to MaaS platform, and extracting to be identified picture from optical character recognition request;Call the optical character recognition model deployed in MaaS platform, identify each to-be-recognized picture, obtain the picture recognition result respectively with each to-be-recognized picture;Based on each picture recognition result, each to-be-recognized picture is divided into recognition success picture and recognition failure picture;According to each recognition failure picture, generate incremental training set, and using incremental training set, fine-tune the optical character recognition model;When fine-tuned optical character recognition model meets preset performance requirement, return the operation of obtaining the optical character recognition request that user submits to MaaS platform, until reaching the fine-tuning termination condition defined in advance, reduce model optimization cost, improve model optimization effect.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of model optimization, and in particular to a method and apparatus for optimizing optical character recognition models based on the MaaS platform. Background Technology

[0002] With the deepening of enterprise digital transformation, optical character recognition (OCR) technology is widely used in areas such as invoice verification, document archiving, and information extraction. An OCR model built on a Model as a Service (MaaS) platform provides invoice recognition and invoice parsing capabilities through an open Application Programming Interface (API). However, due to factors such as updated invoice styles and interference from complex invoice designs, this OCR model requires long-term iterative optimization to continuously adapt to new business scenarios.

[0003] Currently, optical character recognition (OCR) models often rely on manually collected and labeled training data. However, manually collected training data often fails to cover various edge cases in real-world business scenarios (such as different lighting conditions, shooting angles, and document wear), resulting in unsatisfactory recognition performance after actual deployment. Secondly, relying on manually labeled training data requires personnel to manually mark text regions and content in images, consuming significant manpower and resources. Finally, iteratively optimizing OCR models using training data that integrates positive and negative samples often struggles to selectively identify the most valuable challenging examples for model optimization, leading to poor optimization results. Summary of the Invention

[0004] This invention provides a method and apparatus for optimizing optical character recognition models based on a MaaS platform. It solves the problems of high cost and poor model optimization effect of existing technologies that rely on manually collected and labeled training data to optimize optical character recognition models. This invention reduces the model optimization cost, improves the model optimization effect, and ensures the accuracy of recognition results for various types of images.

[0005] In a first aspect, embodiments of the present invention provide an optical character recognition model optimization method based on a MaaS platform, comprising: acquiring an optical character recognition request submitted by a user to the MaaS platform, and extracting images to be recognized from the optical character recognition request; calling an optical character recognition model deployed on the MaaS platform to recognize each image to be recognized, and obtaining image recognition results for each image to be recognized; based on the image recognition results, dividing each image to be recognized into successfully recognized images and unrecognized images; generating an incremental training set based on each unrecognized image, and using the incremental training set to fine-tune the optical character recognition model; when the fine-tuned optical character recognition model meets preset performance requirements, returning to the operation of acquiring the optical character recognition request submitted by the user to the MaaS platform, until a predefined fine-tuning termination condition is reached.

[0006] Secondly, embodiments of the present invention also provide an optical character recognition model optimization device based on a MaaS platform, comprising: an image acquisition module, used to acquire optical character recognition requests submitted by users to the MaaS platform and extract images to be recognized from the optical character recognition requests; an image recognition module, used to call the optical character recognition model deployed on the MaaS platform to recognize each image to be recognized and obtain image recognition results for each image to be recognized; an image classification module, used to classify each image to be recognized into successfully recognized images and unrecognized images based on the image recognition results; a model fine-tuning module, used to generate an incremental training set based on each unrecognized image and use the incremental training set to fine-tune the optical character recognition model; and a flywheel optimization module, used to return to the operation of acquiring optical character recognition requests submitted by users to the MaaS platform when the fine-tuned optical character recognition model meets preset performance requirements, until a predefined fine-tuning termination condition is reached.

[0007] Thirdly, embodiments of the present invention also provide an electronic device, the electronic device comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores a computer program executable by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to execute the optical character recognition model optimization method based on the MaaS platform provided in any embodiment of the present invention.

[0008] Fourthly, embodiments of the present invention also provide a computer-readable storage medium storing computer instructions for causing a processor to execute and implement the optical character recognition model optimization method based on the MaaS platform provided in any embodiment of the present invention.

[0009] The technical solution of this invention obtains optical character recognition requests submitted by users to the MaaS platform and extracts images to be recognized from these requests; it then calls the optical character recognition model deployed on the MaaS platform to recognize each image, obtaining separate image recognition results for each image; based on these recognition results, each image is divided into successfully recognized images and unrecognized images; an incremental training set is generated based on each unrecognized image, and the optical character recognition model is fine-tuned using this incremental training set; when the fine-tuned optical character recognition model meets preset performance requirements, the process of obtaining the optical character recognition requests submitted by users to the MaaS platform is resumed until a predefined fine-tuning termination condition is met. This approach solves the problems of high cost and poor model optimization effects associated with existing technologies that rely on manually collected and labeled training data to optimize optical character recognition models. It reduces model optimization costs, improves model optimization effects, and ensures the accuracy of various image recognition results.

[0010] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of the present invention, nor is it intended to limit the scope of the invention. Other features of the invention will become readily apparent from the following description. Attached Figure Description

[0011] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0012] Figure 1 This is a flowchart of an optical character recognition model optimization method based on a MaaS platform according to Embodiment 1 of the present invention; Figure 2 This is a flowchart of another optical character recognition model optimization method based on the MaaS platform provided in Embodiment 2 of the present invention; Figure 3 This is a schematic diagram of the structure of an optical character recognition model optimization device based on the MaaS platform according to Embodiment 3 of the present invention; Figure 4 This is a schematic diagram of the structure of an electronic device provided in Embodiment 4 of the present invention. Detailed Implementation

[0013] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0014] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0015] Example 1 Figure 1 This is a flowchart of an optical character recognition model optimization method based on a MaaS platform according to Embodiment 1 of the present invention. This embodiment is applicable to the optimization of optical character recognition models based on a MaaS platform. The method can be executed by an optical character recognition model optimization device based on a MaaS platform. The optical character recognition model optimization device based on a MaaS platform can be implemented in hardware and / or software and can be configured in an electronic device such as a computer.

[0016] like Figure 1 As shown in this embodiment, an optical character recognition model optimization method based on the MaaS platform is disclosed, including: S110: Obtain the optical character recognition request submitted by the user to the MaaS platform, and extract the image to be recognized from the optical character recognition request.

[0017] In this embodiment, the MaaS platform can be used to receive optical character recognition requests submitted by users in real time, and continuously optimize the trained optical character recognition model based on each optical character recognition request.

[0018] Specifically, this step involves obtaining optical character recognition (OCR) requests submitted by users through the MaaS platform's API. Users can submit OCR requests in various ways, such as direct file upload, downloading a remote Uniform Resource Locator (URL), or embedding an image within a radix-64 encoded string.

[0019] Then, when the optical character recognition request only includes the image to be recognized, the image to be recognized can be extracted directly from the optical character recognition request. When the optical character recognition request includes both the image to be recognized and the authentication token, the authentication token is extracted from the optical character recognition request first, and the image to be recognized is extracted from the optical character recognition request only when the authentication token is verified.

[0020] The advantage of this setup is that by extracting the image to be recognized from the optical character recognition request submitted by the user to the MaaS platform, the independent data acquisition process in traditional model optimization can be eliminated, and training data can be automatically accumulated as business calls occur.

[0021] S120. Call the optical character recognition model deployed on the MaaS platform to recognize each image to be recognized, and obtain the image recognition result for each image to be recognized.

[0022] In this embodiment, the optical character recognition model can be understood as a recognition model that has completed basic training and requires continuous iterative optimization. The image recognition results can be used to reflect various field information extracted from the image to be recognized.

[0023] In this step, specifically, each image to be recognized can be encapsulated, and the encapsulated images can be input into an optical character recognition model. The optical character recognition model can then recognize each image to obtain a separate image recognition result.

[0024] S130. Based on the recognition results of each image, divide each image to be recognized into images that were successfully recognized and images that were not recognized.

[0025] In this step, specifically, all fields in each image recognition result can be iterated to obtain the number of non-empty fields and the total number of fields corresponding to each image recognition result. Then, based on the number of non-empty fields and the total number of fields corresponding to each image recognition result, the proportion of non-empty fields corresponding to each image recognition result can be determined, and each image to be recognized can be divided into successfully recognized images and unrecognized images based on the proportion of non-empty fields corresponding to each image recognition result. Alternatively, each image to be recognized can be directly divided into successfully recognized images and unrecognized images based on the number of non-empty fields corresponding to each image recognition result.

[0026] S140. Generate an incremental training set based on each failed recognition image, and use the incremental training set to fine-tune the optical character recognition model.

[0027] In this step, specifically, each failed recognition image can be labeled, resulting in labeled failed recognition images. Then, these labeled failed recognition images can be merged into the existing training set to obtain an incremental training set. Finally, the incremental training set can be used to fine-tune the optical character recognition model, enabling it to maintain its original recognition capabilities while specifically improving the recognition accuracy of difficult samples.

[0028] The advantage of this setup is that by generating incremental training sets from each failed recognition image, and using these incremental training sets to fine-tune the optical character recognition model, the most valuable difficult examples can be selectively chosen for model optimization when the optical character recognition model experiences performance degradation or when faced with images belonging to new business types. This effectively improves the model optimization effect.

[0029] S150. When the fine-tuned optical character recognition model meets the preset performance requirements, return to the operation of obtaining the optical character recognition request submitted by the user to the MaaS platform, until the predefined fine-tuning termination condition is reached.

[0030] In this step, specifically, after fine-tuning the optical character recognition model, a reserved test dataset can be used to evaluate the performance of the fine-tuned model. Performance evaluation metrics can include overall recognition accuracy, classification accuracy, and inference latency. Then, if the fine-tuned model performs worse than the un-fine-tuned model on any performance evaluation metric, the process of extracting the image to be recognized from the optical character recognition request can be repeated until the fine-tuned model performs no worse than the un-fine-tuned model on all performance evaluation metrics.

[0031] When the fine-tuned optical character recognition (OCR) model performs no worse than the untuned OCR model in all performance evaluation metrics, the fine-tuned OCR model is hot-deployed, and the process of retrieving the OCR request submitted by the user to the MaaS platform is resumed until a predefined fine-tuning termination condition is met. This fine-tuning termination condition can be varied, such as the model reaching a predefined iteration limit or manual interruption.

[0032] The advantage of this setup is that by performing multiple rounds of optimization on the optical character recognition model, the recognition accuracy of the optical character recognition model can be continuously improved, the amount of manual annotation required for each round of optimization can be reduced, and the optimization of the optical character recognition model can enter the flywheel self-acceleration stage.

[0033] The technical solution of this embodiment obtains optical character recognition requests submitted by users to the MaaS platform and extracts images to be recognized from these requests; it calls the optical character recognition model deployed on the MaaS platform to recognize each image to be recognized, obtaining image recognition results for each image; based on the recognition results, each image to be recognized is divided into successfully recognized images and unrecognized images; an incremental training set is generated based on each unrecognized image, and the optical character recognition model is fine-tuned using the incremental training set; when the fine-tuned optical character recognition model meets preset performance requirements, the operation of obtaining optical character recognition requests submitted by users to the MaaS platform is returned, until the predefined fine-tuning termination condition is reached. This technical approach solves the problems of high cost and poor model optimization effect of existing technologies that rely on manually collected and labeled training data to optimize optical character recognition models, thereby reducing model optimization costs, improving model optimization effect, and ensuring the accuracy of various image recognition results.

[0034] Example 2 Figure 2 This is a flowchart of another optical character recognition model optimization method based on the MaaS platform provided by Embodiment 2 of the present invention. This embodiment is a further optimization and extension of the above embodiments and can be combined with various optional technical solutions in the above embodiments.

[0035] like Figure 2 As shown in this embodiment, an optical character recognition model optimization method based on the MaaS platform is disclosed, including: S210. Obtain the optical character recognition request submitted by the user to the MaaS platform, and extract the image to be recognized from the optical character recognition request.

[0036] The optical character recognition request includes the image to be recognized, the authentication token, and the business type.

[0037] Optionally, extracting the image to be recognized from the optical character recognition request includes: extracting an authentication token from the optical character recognition request, and extracting user identifier, application identifier, and timestamp information from the authentication token; using the user identifier, application identifier, and timestamp information to authenticate the user; when the user passes authentication, verifying payment based on the user identifier, application identifier, and timestamp information; when the user passes payment verification, determining whether the number of concurrent recognition requests corresponding to the user exceeds a preset request threshold; if not, extracting the image to be recognized from the optical character recognition request.

[0038] Specifically, when a user passes authentication, the payment method can be determined based on the user's identifier. If the user's payment method is prepaid, check if the remaining number of calls in their service package is greater than or equal to 1. If so, decrement the remaining number of calls by 1 and confirm the user has passed payment verification. If not, confirm the user has failed payment verification and return the corresponding error message. If the user's payment method is postpaid, check if their account balance is greater than or equal to the single payment fee. If so, decrement the single payment fee from their account balance and confirm the user has passed payment verification. If not, confirm the user has failed payment verification and return the corresponding error message.

[0039] When a user passes the payment verification, if the number of concurrent recognition requests corresponding to that user exceeds a preset request threshold, an error message indicating that the concurrency limit has been exceeded is returned. If the number of concurrent recognition requests corresponding to that user does not exceed the preset request threshold, the number of concurrent recognition requests corresponding to that user is incremented by 1, and the image to be recognized is extracted from the optical character recognition request.

[0040] S220: Call the optical character recognition model deployed on the MaaS platform to recognize each image to be recognized, and obtain the image recognition result for each image to be recognized.

[0041] In this step, specifically, to ensure the accuracy of the number of concurrent recognition requests corresponding to each user, after obtaining the image recognition results for each image to be recognized, the user corresponding to each image to be recognized can be obtained, and the number of concurrent recognition requests for each user can be decremented by one.

[0042] S230. Count the number of non-empty fields and the total number of fields in each image recognition result, and determine the proportion of non-empty fields corresponding to each image recognition result based on the number of non-empty fields and the total number of fields corresponding to each image recognition result.

[0043] S240. Based on the proportion of non-empty fields corresponding to the recognition results of each image, divide each image to be recognized into successfully recognized images and unrecognized images.

[0044] In this step, specifically, when the proportion of non-empty fields in the image recognition result is greater than a preset threshold, it is considered that sufficient valid information has been identified, and the image to be recognized has been effectively identified. In this case, the image to be recognized corresponding to this image recognition result can be regarded as a successfully recognized image. When the proportion of non-empty fields in the image recognition result is less than or equal to the preset threshold, it is considered that insufficient valid information has been identified, and the image to be recognized has not been effectively recognized. In this case, the image to be recognized corresponding to this image recognition result can be regarded as a failed recognition image. The preset threshold can be understood as a threshold set according to user needs and historical experience; for example, the preset threshold can be set to 50%.

[0045] After dividing the images to be recognized into successfully recognized images and unrecognized images, a first structured data file can be generated based on each successfully recognized image and its corresponding image recognition result. A second structured data file can be generated based on each unrecognized image and its corresponding image recognition result. To ensure the uniqueness of the structured data filenames and the traceability of the time sequence, each structured data file can be named with a timestamp in the format "month-day-hour-minute-second.microsecond".

[0046] Then, since the Hypertext Transfer Protocol (HTTP) status code for each successfully recognized image is 201, and the HTTP status code for each failed image is 400, a first subdirectory with the directory structure "root directory / current timestamp / 201" and a second subdirectory with the directory structure "root directory / current timestamp / 400" can be built in the file system. Finally, the first structured data file can be stored in the first subdirectory, and the second structured data file can be stored in the second subdirectory, so as to quickly optimize the optical character recognition model based on each failed image.

[0047] S250. Obtain the call log records corresponding to each failed recognition image; the call log records include user identifier, business type and call time.

[0048] In this step, specifically, the call log records corresponding to each failed recognition image can be obtained from the call log record table of the preset relational database.

[0049] It's worth noting that the call log can also include information such as the caller's Internet Protocol (IP) address, the name of the image to be recognized, the content of the image to be recognized, request parameters, recognition response, response time, recognition result flag, and billing status. The caller's IP address can be understood as the IP address of the client that initiated the optical character recognition request. The name of the image to be recognized can be understood as the name of the image submitted by the user. The content of the image to be recognized can be understood as the binary content or reference path of the image to be recognized. Request parameters can be understood as other parameter data carried in the optical character recognition request, such as the API interface type. The recognition response can be understood as the complete response content returned by the optical character recognition model. The response time can be understood as the timestamp when the image recognition result was returned. The recognition result flag can be a Boolean value used to indicate whether the recognition was successful. The billing status can be used to indicate whether the call log has been billed.

[0050] S260. Based on the call log records corresponding to each failed recognition image, determine the labeling priority of each failed recognition image; the labeling priority is divided into first priority and second priority, with the first priority having a higher priority than the second priority.

[0051] In this step, specifically, based on the call log records of each failed image, images exhibiting concentrated anomalies within a given time period, key user images, and newly added business type images can be identified from among the failed images. Then, the labeling priority for images exhibiting concentrated anomalies within a given time period, key user images, and newly added business type images can be determined as first priority, while the labeling priority for other failed images can be determined as second priority.

[0052] Optionally, based on the call log records corresponding to each failed image, the labeling priority of each failed image is determined, including: based on the user identifier, business type, and call time of each failed image, identifying time-concentrated abnormal images, key user images, and newly added business type images among the failed images; determining the labeling priority of time-concentrated abnormal images, key user images, and newly added business type images as the first priority; and determining the labeling priority of other failed images besides time-concentrated abnormal images, key user images, and newly added business type images as the second priority.

[0053] Specifically, based on the access time of each failed image, images with concentrated abnormalities within a given time period can be identified. Based on the user identifier of each failed image, images representing key users can be identified. Based on the business type of each failed image, images representing newly added business types can be identified.

[0054] By setting up the above, fluctuations in model performance during specific time periods or scenarios can be detected in a timely manner, thereby quickly determining the annotation priority of each failed recognition image.

[0055] Optionally, based on the user identifier, business type, and call time of each failed identification image, identify time-concentrated abnormal images, key user images, and newly added business type images from among the failed identification images. This includes: identifying time-concentrated abnormal images from among the failed identification images based on the call time of each failed identification image; identifying key user images from among the failed identification images other than time-concentrated abnormal images based on the user identifier of each failed identification image; and identifying newly added business type images from among the failed identification images other than time-concentrated abnormal images and key user images based on the business type of each failed identification image.

[0056] Specifically, the following technical methods can be used to identify time-concentrated abnormal images: Based on the call time of each failed image, the number of successful and failed recognitions per hour is counted to form time-series trend data. Based on this time-series trend data, time-concentrated abnormal images are identified among the failed images. These time-concentrated abnormal images can be understood as images that failed to be recognized due to overload during peak periods.

[0057] Key user images are identified using the following specific technical means: The call log records corresponding to each successfully identified image are obtained, and the user identifier for each successfully identified image is determined based on these records. Then, based on the user identifiers of each failed image and each successful image, the number of successful and failed identifications for each user can be counted. Finally, based on the number of successful and failed identifications for each user, key users can be identified among all users, and key user images can be identified from the failed identification images excluding those with concentrated anomalies within a specific time period. Here, key users can be understood as users whose failed identification counts account for more than a preset percentage of the total identification counts, where the total identification count is the sum of the successful and failed identification counts.

[0058] The following specific technical methods are used to determine the new business type images: Based on the call time of each failed image, the number of successful and failed recognitions per day is counted, and dates with more than a preset failure threshold are designated as frequently occurring anomaly days. Then, the business type of each failed image on the frequently occurring anomaly day can be obtained, and the business type with the most failed images is designated as the abnormal business type. Finally, among the failed images excluding time-concentrated abnormal images and key user images, images belonging to the abnormal business type can be obtained, and these images are designated as new business type images.

[0059] S270. When the optimization efficiency requirement of the optical character recognition model is non-instantaneous optimization, each failed recognition image is labeled according to its labeling priority, and an incremental training set is generated based on the labeled failed recognition images.

[0060] S280. When the optimization efficiency requirement of the optical character recognition model is real-time optimization, the recognition failure images with the first priority are taken as images to be processed, each image to be processed is labeled, and an incremental training set is generated based on the labeled images to be processed.

[0061] The advantage of this setup is that by recording the call logs of each failed image, the labeling priority of each failed image can be determined. When the optimization efficiency requirement of the optical character recognition model is immediate optimization, an incremental training set is generated only based on the failed images with the highest labeling priority. This can realize the transformation from the call log to usable training data, thereby shortening the model optimization cycle and improving the model optimization efficiency.

[0062] S290. Use an incremental training set to fine-tune the optical character recognition model. When the fine-tuned optical character recognition model meets the preset performance requirements, return to execute the operation of obtaining the optical character recognition request submitted by the user to the MaaS platform, until the predefined fine-tuning termination condition is reached.

[0063] Optionally, if the fine-tuned optical character recognition model does not meet the preset performance requirements, the model optimization process can be traced back according to the call log records corresponding to each failed recognition image in the incremental training set, so as to re-optimize the fine-tuned optical character recognition model and make it meet the preset performance requirements.

[0064] The technical solution of this embodiment determines the annotation priority of each failed recognition image by using the call pipeline records corresponding to each failed recognition image. The annotation priority is divided into a first priority and a second priority, with the first priority having a higher priority than the second priority. When the optimization efficiency requirement of the optical character recognition model is real-time optimization, the failed recognition images with the first priority are used as images to be processed. Each image to be processed is annotated, and an incremental training set is generated based on the annotated images to be processed. By using the incremental training set to fine-tune the optical character recognition model, the conversion from call pipeline to usable training data can be realized, thereby shortening the model optimization cycle and improving the model optimization efficiency.

[0065] Example 3 Figure 3 This is a schematic diagram of the structure of an optical character recognition model optimization device based on a MaaS platform according to Embodiment 3 of the present invention. This embodiment can be applied to the situation of optimizing an optical character recognition model based on a MaaS platform. The optical character recognition model optimization device based on a MaaS platform can be implemented in hardware and / or software and can be configured in electronic devices such as computers.

[0066] like Figure 3 As shown, the optical character recognition model optimization device based on the MaaS platform disclosed in this embodiment includes: Image acquisition module 31 is used to acquire optical character recognition requests submitted by users to the MaaS platform and extract the images to be recognized from the optical character recognition requests; Image recognition module 32 is used to call the optical character recognition model deployed on the MaaS platform to recognize each image to be recognized and obtain the image recognition result for each image to be recognized. Image classification module 33 is used to classify each image to be identified into successfully identified images and unrecognized images based on the recognition results of each image; The model fine-tuning module 34 is used to generate an incremental training set based on each failed recognition image, and to fine-tune the optical character recognition model using the incremental training set. The flywheel optimization module 35 is used to return to the operation of obtaining the optical character recognition request submitted by the user to the MaaS platform when the fine-tuned optical character recognition model meets the preset performance requirements, until the predefined fine-tuning termination condition is reached.

[0067] The technical solution in this embodiment, through the cooperation of the image acquisition module 31, image recognition module 32, image classification module 33, model fine-tuning module 34, and flywheel optimization module 35, solves the problems of high cost and poor model optimization effect of existing technologies that rely on manually collected and labeled training data to optimize optical character recognition models. It reduces the model optimization cost, improves the model optimization effect, and ensures the accuracy of various image recognition results.

[0068] Optionally, the image acquisition module 31 is specifically used for: extracting an authentication token from the optical character recognition request, and extracting user identifier, application identifier, and timestamp information from the authentication token; using the user identifier, application identifier, and timestamp information to authenticate the user; when the user passes authentication, verifying payment based on the user identifier, application identifier, and timestamp information; when the user passes payment verification, determining whether the number of concurrent recognition requests corresponding to the user exceeds a preset request threshold; if not, extracting the image to be recognized from the optical character recognition request.

[0069] Optionally, the image classification module 33 is specifically used for: counting the number of non-empty fields and the total number of fields in each image recognition result; determining the proportion of non-empty fields corresponding to each image recognition result based on the number of non-empty fields and the total number of fields corresponding to each image recognition result; and dividing each image to be recognized into successfully recognized images and unrecognized images according to the proportion of non-empty fields corresponding to each image recognition result.

[0070] Optionally, the model fine-tuning module 34 includes: The call log acquisition unit is used to obtain the call log records corresponding to each failed recognition image; the call log records include user identifier, application identifier, business type, and call time. The labeling priority determination unit is used to determine the labeling priority of each failed image based on the call log record corresponding to each failed image. The labeling priority is divided into first priority and second priority, with the first priority having a higher priority than the second priority. The image annotation unit is used to annotate each failed recognition image according to the annotation priority of each failed recognition image when the optimization efficiency requirement of the optical character recognition model is not real-time optimization. The first training set generation unit is used to generate an incremental training set based on the labeled images that failed to be identified. The image to be processed determination unit is used to identify images that failed to be recognized and have a priority of first priority as images to be processed when the optimization efficiency requirement of the optical character recognition model is immediate optimization. The second training set generation unit is used to annotate each image to be processed and generate an incremental training set based on the annotated images to be processed.

[0071] Optionally, the annotation priority determination unit includes: The key image determination subunit is used to identify time-concentrated abnormal images, key user images, and newly added business type images from each failed image based on the user identifier, application identifier, business type, and call time of each failed image. The first priority determination sub-unit is used to determine the labeling priority of concentrated abnormal images, key user images, and newly added business type images as the first priority; The second priority determination subunit is used to determine the labeling priority of failed recognition images other than time-concentrated abnormal images, key user images, and newly added business type images as the second priority.

[0072] Optionally, the key image determination subunit is specifically used for: determining time-concentrated abnormal images among the failed images based on the user identifier, application identifier, and call time of each failed image; determining key user images among the failed images other than time-concentrated abnormal images based on the user identifier of each failed image; and determining newly added business type images among the failed images other than time-concentrated abnormal images and key user images based on the business type of each failed image.

[0073] The optical character recognition model optimization device based on the MaaS platform provided in this embodiment of the invention can execute the optical character recognition model optimization method based on the MaaS platform provided in any embodiment of the invention, and has the corresponding functional modules and beneficial effects of the method execution. Content not described in detail in this embodiment can be referred to the description in any method embodiment of this application.

[0074] Example 4 Figure 4 A schematic diagram of the structure of an electronic device 10 that can be used to implement embodiments of the present invention is shown. For example... Figure 4 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded into the RAM 13 from storage unit 18. The RAM 13 can also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0075] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0076] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as the optical character recognition model optimization method based on a MaaS platform.

[0077] In some embodiments, the MaaS-based optical character recognition model optimization method can be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program can be loaded and / or installed on electronic device 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the MaaS-based optical character recognition model optimization method described above can be performed. Alternatively, in other embodiments, processor 11 can be configured to execute the MaaS-based optical character recognition model optimization method by any other suitable means (e.g., by means of firmware).

[0078] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0079] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, or as a standalone software package, partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0080] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.

[0081] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0082] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or middleware components (e.g., application servers), or frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.

[0083] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.

[0084] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.

[0085] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.

Claims

1. A method for optimizing an optical character recognition model based on a MaaS platform, characterized in that, The method includes: Obtain the optical character recognition request submitted by the user to the MaaS platform, and extract the image to be recognized from the optical character recognition request; The optical character recognition model deployed on the MaaS platform is invoked to recognize each of the images to be recognized, and the image recognition results are obtained for each of the images to be recognized. Based on the image recognition results, the images to be recognized are divided into successfully recognized images and unrecognized images. An incremental training set is generated based on each of the images that failed to be recognized, and the optical character recognition model is fine-tuned using the incremental training set. When the fine-tuned optical character recognition model meets the preset performance requirements, it returns to the operation of obtaining the optical character recognition request submitted by the user to the MaaS platform, until the predefined fine-tuning termination condition is reached.

2. The method according to claim 1, characterized in that, The optical character recognition request includes the image to be recognized and the authentication token; Extracting the image to be recognized from the optical character recognition request includes: Extract the authentication token from the optical character recognition request, and extract the user identifier, application identifier, and timestamp information from the authentication token; The user is authenticated using the user identifier, application identifier, and timestamp information; When the user passes authentication, payment verification is performed on the user based on the user identifier, application identifier, and timestamp information; When the user passes the payment verification, it is determined whether the number of concurrent identification requests corresponding to the user exceeds a preset request threshold. If not, then extract the image to be recognized from the optical character recognition request.

3. The method according to claim 1, characterized in that, Based on the image recognition results, each of the images to be recognized is divided into successfully recognized images and unrecognized images, including: Count the number of non-empty fields and the total number of fields in each of the image recognition results; Based on the number of non-empty fields and the total number of fields corresponding to each of the image recognition results, the proportion of non-empty fields corresponding to each of the image recognition results is determined. Based on the proportion of non-empty fields corresponding to the recognition results of each image, the images to be recognized are divided into successfully recognized images and unrecognized images.

4. The method according to claim 1, characterized in that, An incremental training set is generated based on the images that failed to be identified, including: Obtain the call log record corresponding to each of the aforementioned failed recognition images; the call log record includes user identifier, service type, and call time; Based on the call log records corresponding to each of the failed recognition images, the labeling priority of each of the failed recognition images is determined; the labeling priority is divided into a first priority and a second priority, with the first priority having a higher priority than the second priority; When the optimization efficiency requirement of the optical character recognition model is non-instantaneous optimization, each of the failed recognition images is labeled according to the labeling priority of each image. An incremental training set is generated based on the labeled images that failed to be identified.

5. The method according to claim 4, characterized in that, After determining the labeling priority of each of the aforementioned failed recognition images, the process also includes: When the optimization efficiency requirement of the optical character recognition model is real-time optimization, the recognition failure images marked with the first priority are taken as images to be processed. Each of the images to be processed is labeled, and an incremental training set is generated based on the labeled images.

6. The method according to claim 4, characterized in that, Based on the call log records corresponding to each of the aforementioned failed recognition images, the annotation priority of each of the aforementioned failed recognition images is determined, including: Based on the user identifier, business type, and call time of each of the failed identification images, images of concentrated abnormalities during a specific time period, images of key users, and images of newly added business types are identified among the failed identification images. The priority for labeling concentrated abnormal images, key user images, and newly added business type images during the aforementioned time period is determined as the first priority; Images that failed to be identified, excluding those exhibiting concentrated abnormalities within a specific time period, images of key users, and images representing newly added business types, are designated as the second priority for labeling.

7. The method according to claim 6, characterized in that, Based on the user identifier, business type, and call time of each of the failed identification images, images with concentrated time periods, key user images, and newly added business type images are identified from among the failed identification images, including: Based on the call time of each of the failed identification images, identify the abnormal images with concentrated time periods among the failed identification images; Based on the user identifiers of each of the failed identification images, key user images are identified from the failed identification images excluding those with concentrated abnormality over a specific time period. Based on the business type of each of the aforementioned failed identification images, new business type images are identified from the failed identification images other than time-concentrated abnormal images and key user images.

8. An optical character recognition model optimization device based on a MaaS platform, characterized in that, The device includes: The image acquisition module is used to acquire optical character recognition requests submitted by users to the MaaS platform and extract the images to be recognized from the optical character recognition requests. The image recognition module is used to call the optical character recognition model deployed on the MaaS platform to recognize each of the images to be recognized, and obtain the image recognition results for each of the images to be recognized. The image classification module is used to classify each image to be identified into successfully identified images and unrecognized images based on the image recognition results. The model fine-tuning module is used to generate an incremental training set based on each of the failed recognition images, and to fine-tune the optical character recognition model using the incremental training set. The flywheel optimization module is used to return to the operation of obtaining the optical character recognition request submitted by the user to the MaaS platform when the fine-tuned optical character recognition model meets the preset performance requirements, until the predefined fine-tuning termination condition is reached.

9. An electronic device, characterized in that, The electronic device includes: At least one processor; and a memory communicatively connected to said at least one processor; The memory stores a computer program that can be executed by the at least one processor, which is then executed by the at least one processor to enable the at least one processor to perform the optical character recognition model optimization method based on the MaaS platform as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that cause a processor to execute the optical character recognition model optimization method based on the MaaS platform as described in any one of claims 1-7.