Resource hierarchy comparison and processing method, apparatus, device, and medium

CN123011511APending Publication Date: 2026-10-30PING AN TECH (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

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

AI Technical Summary

Technical Problem

[0005]本发明的主要目的在于提供一种资源层级比对与处理方法、装置、设备及存储介质,旨在解决现有技术在多个资源均可用于同一资源使用请求时,难以结合请求参数、资源属性数据和层级处理配置生成准确的资源使用序列,导致资源使用对象选择与后续资源使用处理不一致的技术问题

Benefits of technology

[0010]有益效果:本发明涉及数据分析技术领域,公开了一种资源层级比对与处理方法、装置、设备及介质,包括:获取资源使用请求,基于请求参数读取用户资源账户中的资源记录并生成初始资源集合;对初始资源集合进行可用性筛查,生成候选资源集合;基于请求参数和资源属性数据生成资源比较信息;结合层级处理配置对候选资源集合进行层级比对,生成资源使用序列;基于资源使用序列生成待使用资源记录和备用资源记录;对待使用资源记录或备用资源记录进行资源使用处理,生成资源处理日志,并更新用户资源账户和写入资源调度记录。本发明可应用于金融科技等业务场景中,通过可用性筛查形成候选资源集合,再结合资源比较信息和层级处理配置生成资源使用序列,使资源使用对象能够按层级比对结果确定,并通过备用资源记录和资源处理日志完成替换处理及账户更新,从而减少多个可用资源并存时资源使用顺序不准确和账户记录更新不一致的情况。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123011511A_ABST
    Figure CN123011511A_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of data analysis, and discloses a resource level comparison and processing method, device, equipment and medium, comprising: obtaining a resource use request and generating an initial resource set; performing availability screening on the initial resource set to generate a candidate resource set; generating resource comparison information and combining level processing configuration to form a resource use sequence; generating a to-be-used resource record and a standby resource record based on the resource use sequence; performing resource use processing to generate a resource processing log, and updating a user resource account and writing a resource scheduling record. The present application can be applied to financial technology and other business scenarios, determines a resource use sequence through availability screening, resource comparison information and level processing configuration, and completes resource use processing and account updating in combination with the standby resource record and the resource processing log, thereby reducing the situation that the use order is inaccurate and the account updating is inconsistent when multiple available resources coexist.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data analysis technology, and in particular to a method, apparatus, equipment and medium for resource hierarchy comparison and processing. Background Technology

[0002] In scenarios involving combined service resource processing, existing resource allocation methods typically determine the resource usage order based on a single factor, such as expiration time, manual selection, or a preset fixed order. Since multiple available resources may exist simultaneously for the same resource usage request, and these resources differ in service type, service location, resource attributes, and account status, existing methods struggle to create a resource usage sequence that matches the current request from among the available resources. This can easily lead to a mismatch between the resource usage order and the actual service requirements.

[0003] In the fintech business, customers may simultaneously hold account service resources, payment discount resources, policy value-added resources, claims assistance resources, and membership value-added resources. Existing financial service platforms, when processing service requests such as payments, insurance, consumer finance, or wealth management, typically rely on resource expiration dates or manual selection to determine the appropriate resource, failing to combine request parameters and resource attribute data for hierarchical judgment. Consequently, when multiple resources satisfy the current service request, inaccurate usage order can easily occur, affecting the consistency of resource deduction, account updates, and resource processing records.

[0004] In the healthcare sector, users may simultaneously hold access to consultation services, physical examination services, health management resources, medication delivery services, and nursing care services. Existing healthcare platforms, when processing appointments, consultations, deliveries, or health service requests, typically focus on the availability of individual resources, lacking a hierarchical comparison process that considers a set of candidate resources. Consequently, when multiple health service resources are available for the same service request, inaccurate determination of the resource usage sequence can easily occur, affecting subsequent resource allocation, resource usage processing, and account record updates. Summary of the Invention

[0005] The main objective of this invention is to provide a resource hierarchy comparison and processing method, apparatus, device, and storage medium, aiming to solve the technical problem in the prior art that when multiple resources can be used for the same resource usage request, it is difficult to combine request parameters, resource attribute data, and hierarchy processing configuration to generate an accurate resource usage sequence, resulting in inconsistencies between the selection of resource usage objects and subsequent resource usage processing.

[0006] To achieve the above objectives, the present invention provides a resource hierarchy comparison and processing method, comprising: Obtain resource usage requests, and based on the request parameters in the resource usage requests, read the resource records in the user's resource account to generate an initial resource set; Based on the request parameters, the initial resource set is subjected to availability screening, and the resource records that pass the availability screening are used as candidate resource records to generate a candidate resource set. Resource comparison information is generated based on the request parameters and the resource attribute data of the candidate resource records, and the resource comparison information is bound to the candidate resource records; Obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison on the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence; The candidate resource record with the highest sorting from the resource usage sequence is selected for temporary occupation to generate a resource record to be used, and the remaining candidate resource records in the resource usage sequence are determined as backup resource records. The resource record to be used is matched and verified with the resource usage request. Based on the matching and verification results, the resource record to be used or the backup resource record is processed for resource usage, a resource processing log is generated, and the user resource account is updated and written to the resource scheduling record based on the resource processing log.

[0007] Furthermore, to achieve the above objectives, the present invention provides a resource hierarchy comparison and processing apparatus, comprising: The request parsing and resource reading module is used to obtain resource usage requests, read resource records in the user's resource account based on the request parameters in the resource usage requests, and generate an initial resource set. The resource availability screening module is used to perform availability screening on the initial resource set based on the request parameters, and to use the resource records that pass the availability screening as candidate resource records and generate a candidate resource set. The resource comparison information generation module is used to generate resource comparison information based on the request parameters and the resource attribute data of the candidate resource record, and bind the resource comparison information to the candidate resource record; The hierarchical comparison and sorting module is used to obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison on the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence. The temporary occupancy processing module is used to select the candidate resource record with the highest sorting from the resource usage sequence for temporary occupancy processing, generate a resource record to be used, and determine the remaining candidate resource records in the resource usage sequence as backup resource records. The resource usage settlement module is used to match and verify the resource records to be used with the resource usage requests, process the resource records to be used or the backup resource records based on the matching and verification results, generate a resource processing log, update the user resource account based on the resource processing log, and write it into the resource scheduling record.

[0008] Furthermore, to achieve the above objectives, the present invention also provides a computer device, the computer device including a memory, a processor, and a resource hierarchy comparison and processing program stored in the memory and executable on the processor, wherein when the resource hierarchy comparison and processing program is executed by the processor, it implements the steps of the resource hierarchy comparison and processing method as described above.

[0009] Furthermore, to achieve the above objectives, the present invention also provides a computer-readable storage medium storing a resource hierarchy comparison and processing program, wherein when the resource hierarchy comparison and processing program is executed by a processor, it implements the steps of the resource hierarchy comparison and processing method described above.

[0010] Beneficial Effects: This invention relates to the field of data analysis technology and discloses a resource hierarchy comparison and processing method, apparatus, device, and medium, comprising: acquiring a resource usage request; reading resource records in a user's resource account based on request parameters and generating an initial resource set; performing availability screening on the initial resource set to generate a candidate resource set; generating resource comparison information based on request parameters and resource attribute data; performing hierarchical comparison on the candidate resource set in conjunction with hierarchical processing configuration to generate a resource usage sequence; generating pending resource records and standby resource records based on the resource usage sequence; performing resource usage processing on the pending resource records or standby resource records, generating a resource processing log, and updating the user's resource account and writing it to the resource scheduling record. This invention can be applied to business scenarios such as fintech. By forming a candidate resource set through availability screening and then generating a resource usage sequence by combining resource comparison information and hierarchical processing configuration, the resource user can be determined according to the hierarchical comparison results. Replacement processing and account updates are completed through standby resource records and resource processing logs, thereby reducing the situation of inaccurate resource usage order and inconsistent account record updates when multiple available resources coexist. Attached Figure Description

[0011] The present invention will be further described below with reference to the accompanying drawings and embodiments. In the accompanying drawings: Figure 1 This is a schematic diagram of an application environment for a resource hierarchy comparison and processing method according to an embodiment of the present invention; Figure 2 This is a flowchart illustrating an embodiment of the resource hierarchy comparison and processing method of the present invention; Figure 3This is a schematic diagram of the functional modules of a preferred embodiment of the resource hierarchy comparison and processing device of the present invention; Figure 4 This is a schematic diagram of the structure of a computer device according to an embodiment of the present invention; Figure 5 This is another structural schematic diagram of a computer device according to one embodiment of the present invention. Detailed Implementation

[0012] It should be understood that the specific embodiments described herein are for illustrative purposes only and are not intended to limit the scope of the invention.

[0013] The resource hierarchy comparison and processing method provided in this embodiment of the invention can be applied to, for example, Figure 1 In this application environment, the client communicates with the server via a network. The server can obtain resource usage requests from the client, read resource records from the user's resource account based on the request parameters, and generate an initial resource set; perform availability screening on the initial resource set to generate a candidate resource set; generate resource comparison information based on the request parameters and resource attribute data; perform hierarchical comparison of the candidate resource set in conjunction with hierarchical processing configuration to generate a resource usage sequence; generate pending resource records and backup resource records based on the resource usage sequence; process the pending resource records or backup resource records, generate a resource processing log, and update the user's resource account and write it to the resource scheduling record. This invention can be applied to business scenarios such as fintech. By forming a candidate resource set through availability screening, and then generating a resource usage sequence by combining resource comparison information and hierarchical processing configuration, the resource usage object can be determined according to the hierarchical comparison results. Replacement processing and account updates are completed through backup resource records and resource processing logs, thereby reducing the situation of inaccurate resource usage order and inconsistent account record updates when multiple available resources coexist. The client can be, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices. The server can be implemented using a standalone server or a server cluster composed of multiple servers. The present invention will now be described in detail through specific embodiments.

[0014] Please see Figure 2 , Figure 2 This is a flowchart illustrating an embodiment of the resource hierarchy comparison and processing method provided by the present invention. It should be noted that although the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than that shown here.

[0015] like Figure 2 As shown, the resource hierarchy comparison and processing method proposed in this invention includes the following steps: S10, Obtain a resource usage request, and based on the request parameters in the resource usage request, read the resource records in the user's resource account to generate an initial resource set; In this embodiment, resource usage requests can be passed in from the business frontend, service interface, message queue, or scheduled task, carrying the request parameters required for this resource call. The request parameters are used to distinguish the resource call object, service category, service location, request time, and business source, and can be obtained through field mapping, message parsing, object attribute reading, or message body parsing. User resource accounts are used to centrally store service resource data under the same username. Account location can be completed based on user ID, member ID, account ID, customer ID, or business transaction number. Resource records are readable single-item resource data in user resource accounts, which can include resource identifier, resource type, resource status, resource expiration data, resource area data, and resource remaining data. When reading resource records, the user resource account is located based on the request parameters, and then the resource record corresponding to this resource usage request is read from the user resource account. The read resource records are then aggregated into an initial resource set. The initial resource set is used to store resource records obtained under the same resource usage request, ensuring a unified data scope for subsequent processing.

[0016] This can be implemented using an API read method. After receiving a resource usage request, the business interface parses the request parameters from the request message, accesses the account directory based on the account location information in the request parameters, obtains the user resource account's primary key, then queries the resource data table according to the account primary key, reads the resource records, and writes them to a temporary collection object to form the initial resource collection. Alternatively, a cache read method can be used. After receiving a resource usage request, the service interface accesses the user resource account cache based on the request parameters. If the cached version meets the read requirements, it directly reads the resource records and generates the initial resource collection; if the cached version does not meet the read requirements, it calls the account resource service to supplement the read resource records, and then merges the cached records and the supplemented records to generate the initial resource collection. In fintech businesses, request parameters can come from payment discount requests, policy value-added service requests, claims assistance service requests, or membership resource access requests; in healthcare businesses, request parameters can come from physical examination appointment requests, consultation service requests, drug delivery requests, or health management service requests.

[0017] In the fintech business, when a customer initiates a request for policy value-added services, the request parameters include the customer ID, service category, and request time. The system uses the customer ID to locate the user's resource account, reads resource records such as policy service resources, membership value-added resources, and payment discount resources, and generates an initial resource set. This set corresponds to the same policy value-added service request, facilitating the subsequent identification of available resources within the same data range.

[0018] In the healthcare business, after a user initiates a physical examination appointment request, the request parameters include the member number, service location, and appointment time. The system locates the user's resource account based on the member number, reads resource records such as physical examination service resources, consultation service resources, and drug delivery resources, and generates an initial resource set to avoid inconsistent resource usage due to scattered reading.

[0019] This embodiment locates the user resource account by requesting parameters, then reads resource records from the user resource account and generates an initial resource set, so that resource data corresponding to the same resource usage request can be stored in the same set. Since the initial resource set retains the correspondence between request parameters and resource records, subsequent resource screening and sorting can be performed based on the same data range, thereby reducing resource omissions and inconsistencies in account resource records caused by unclear resource reading range.

[0020] S20, based on the request parameters, perform availability screening on the initial resource set, take the resource records that pass the availability screening as candidate resource records, and generate a candidate resource set; In this embodiment, request parameters are used to provide screening criteria and may include service category, service location, request time, and request source identifier. The service category determines whether the resource record supports the current resource usage request; the service location determines whether the resource record's coverage includes the current service location; and the request time determines whether the resource record is still within its usable time range. Request parameters can be obtained from parsing interface messages, message bodies, or task records, or they can be written as fixed fields by upstream business nodes when generating the request. After parsing, the request parameters can be converted into a unified field format. For example, service names from different business entry points can be converted into a unified service category, addresses, branches, and service areas can be converted into a unified service location, and transaction time, appointment time, or submission time can be converted into a unified request time.

[0021] The initial resource set stores resource records read from user resource accounts. During availability screening, resource records in the initial resource set can be read item by item, and resource status data, resource type data, resource region data, and resource expiration data can be extracted from them. Resource status data is used to determine whether a resource record is allowed to participate in use; resource type data is used to match with service categories; resource region data is used to determine coverage with service locations; and resource expiration data is used to determine time based on the request time. Resource records can be associated with the above data using resource identifiers, allowing screening results to be written back to the corresponding resource records.

[0022] Availability screening can be performed by merging multiple verification results. Resource status data is verified for availability to generate a status verification result; resource type data is matched with service category to generate a type verification result; resource region data is matched with service location to generate a region coverage verification result; and resource validity data is matched with request time to generate a time verification result. When the status, type, region coverage, and time verification results all meet the screening criteria, the corresponding resource record is marked as a candidate resource record. Candidate resource records retain their original resource identifier, resource attribute data, and screening pass flag, and are then aggregated to form a candidate resource set. Resource records that fail the screening retain their failure verification results to prevent them from being included in the candidate resource set.

[0023] In the fintech business, when a customer initiates a request to use payment discount resources, the service category is "payment discount," the service location is the transaction location, and the request time is the transaction submission time. The initial resource set may include payment discount resources, membership value-added resources, and insurance policy service resources. During the screening process, if the resource type data of the payment discount resource matches the service category, the resource location data covers the transaction location, the resource validity data covers the transaction submission time, and the resource status data meets the availability conditions, then the resource record is added to the candidate resource set. Resource records that do not match the payment scenario or have exceeded the valid time range are not added to the candidate resource set.

[0024] In the healthcare sector, when a user initiates a physical examination appointment request, the service category is "physical examination service," the service location is the appointment service area, and the request time is the appointment submission time. The initial resource set may include physical examination service resources, consultation service resources, and medication delivery resources. During the screening process, if the resource type data of the physical examination service resource matches the service category, the resource area data covers the appointment service area, the resource timeliness data covers the appointment submission time, and the resource status data meets the availability conditions, then the resource record is considered a candidate resource record and added to the candidate resource set, preventing consultation or delivery resources from entering the subsequent selection range for physical examination services.

[0025] This embodiment uses request parameters to screen resource records in the initial resource set by status, type, region, and time. It can separate candidate resource records that meet the current resource usage request from the resource records read from the user's resource account and form a candidate resource set. Since the candidate resource set is determined by multiple verification results, subsequent resource sorting and resource user selection can be based on the data range of invalid records that have been filtered out, thereby reducing the resource selection bias caused by resource records that do not meet the request conditions participating in subsequent processing.

[0026] S30, Generate resource comparison information based on the request parameters and the resource attribute data of the candidate resource record, and bind the resource comparison information to the candidate resource record; In this embodiment, the request parameters are used to provide a comparison benchmark and may include service location, request time, and service category. Service location can be represented by a region code, branch code, or service area identifier; request time can be represented by transaction submission time, appointment submission time, or resource call time. Candidate resource records carry resource attribute data, which may include resource timeliness data, resource region data, and resource availability data. The resource timeliness data is compared with the request time by performing time difference processing; the resource region data is compared with the service location by coverage level determination; and the resource availability data is compared with the resource call request by availability status determination, thereby generating resource comparison information. Resource comparison information can be bound to the corresponding candidate resource record through field writing, association table records, or object attribute mounting.

[0027] This can be implemented using in-memory objects. After candidate resource records are converted into resource objects, resource attribute data is read from the resource objects, and then combined with request parameters to generate resource comparison information, which is then written to the comparison field of the resource objects. Alternatively, it can be implemented using an association table. Candidate resource records are stored in a temporary resource table, and resource comparison information is written to a comparison result table, which is then associated with the candidate resource records through resource identifiers. In fintech businesses, payment discount resources, policy value-added resources, and membership service resources can form resource comparison information based on timeliness, region, and remaining capacity; in healthcare businesses, physical examination service resources, consultation service resources, and delivery service resources can form resource comparison information in the same way.

[0028] In the fintech business, after a customer initiates a request for policy value-added services, the resource timeliness data, resource region data, and resource balance data in the candidate resource record are processed in accordance with the request parameters to generate resource comparison information and bind it to the candidate resource record.

[0029] In the healthcare business, after a user initiates a physical examination appointment request, physical examination service resources, consultation service resources, and drug delivery resources can also form resource comparison information in the same way, so that the subsequent determination of the order of resources has a corresponding comparative basis.

[0030] This embodiment generates resource comparison information by request parameters and resource attribute data, and binds the resource comparison information to candidate resource records, so that each candidate resource record carries the comparison basis corresponding to the current resource usage request, thereby reducing the deviation caused by determining the resource usage order based on only a single field.

[0031] S40, obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison on the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence; In this embodiment, the request parameters are used to retrieve the hierarchical processing configuration and may carry fields such as service category, service location, request time, business source, and resource usage scenario. The hierarchical processing configuration can be stored in a configuration table, configuration cache, configuration service interface, or tenant-level parameter file. Its content may include the hierarchical comparison order, hierarchical comparison direction, and peer-to-peer comparison method. The hierarchical comparison order is used to determine the sequential reading relationship between timeliness comparison information, regional comparison information, and remaining capacity comparison information. The hierarchical comparison direction is used to determine the arrangement of the same type of comparison information according to urgency, coverage, or remaining capacity status. The peer-to-peer comparison method is used to handle situations where multiple candidate resource records have the same comparison result at the same level.

[0032] Resource comparison information is bound to candidate resource records and can be read item by item according to resource identifier during hierarchical comparison. After each candidate resource record in the candidate resource set is retrieved, its corresponding resource comparison information is read, and hierarchical comparison is performed according to the hierarchical processing configuration. The comparison process can first read the first type of comparison information according to the hierarchical comparison order to form the first-level ranking result, and then continue to read the next type of comparison information for candidate resource records with the same comparison result in the first-level ranking result. After each level of comparison, the candidate resource records form a resource usage sequence according to their final ranking position. The resource usage sequence can include candidate resource records, ranking position, information categories involved in the comparison, and comparison result markers, which facilitates the direct selection of the candidate resource record ranked first in subsequent comparisons.

[0033] This can be achieved using a configuration table. The configuration table stores hierarchical processing configurations based on service category, service location, and business origin. Upon receiving a resource usage request, the configuration table is queried based on the request parameters to obtain the hierarchical comparison order, comparison direction, and peer comparison method. Then, the resource comparison information for each candidate resource record in the candidate resource set is read, and the resources are arranged according to the configuration content. This method is suitable for scenarios in fintech businesses where payment discount resources, policy value-added resources, and membership service resources have different sorting requirements.

[0034] Alternatively, a configuration caching approach can be used. The hierarchical processing configuration is preloaded into the cache, and the configuration content is directly read after the request parameters are converted into cache keys. The candidate resource set is compared hierarchically in memory, and a resource usage sequence is generated. This method is suitable for scenarios with high request concurrency and a moderate number of candidate resource records. In healthcare services, physical examination service resources, consultation service resources, and delivery service resources can read different hierarchical processing configurations according to service category, allowing the arrangement of service resources to change with the service scenario.

[0035] In the fintech business, when a customer initiates a request for policy value-added services, the request parameters are matched to a hierarchical processing configuration that prioritizes timeliness comparison information, followed by remaining capacity comparison information, and then regional comparison information. Policy service resources, membership value-added resources, and payment discount resources in the candidate resource set are compared hierarchically according to this configuration to generate a resource usage sequence, enabling the subsequent resource usage targets to be determined based on the current request scenario.

[0036] In the healthcare business, after a user initiates a physical examination appointment request, the request parameters are matched to a hierarchical processing configuration that prioritizes regional comparison information, followed by timeliness comparison information, and then availability comparison information. Physical examination service resources, consultation service resources, and delivery service resources in the candidate resource set are compared hierarchically according to this configuration to generate a resource usage sequence that matches the appointment service region and appointment time.

[0037] This embodiment obtains the hierarchical processing configuration by requesting parameters, and uses the hierarchical processing configuration and resource comparison information to perform hierarchical comparison of the candidate resource set. This allows the candidate resource records to form a resource usage sequence according to the comparison order that matches the current resource usage request. Since the resource usage sequence comes from the hierarchical processing of multiple types of comparison information, it can reduce the usage order deviation caused by arranging multiple candidate resource records based on a single attribute when multiple candidate resource records coexist.

[0038] S50, Select the candidate resource record with the highest sorting from the resource usage sequence for temporary occupation processing, generate a resource record to be used, and determine the remaining candidate resource records in the resource usage sequence as backup resource records; In this embodiment, the resource usage sequence stores candidate resource records that have undergone hierarchical comparison. Each candidate resource record can include its ranking position, resource identifier, resource availability data, and resource occupancy status. The candidate resource record at the top of the ranking can be obtained through its ranking position, queue index, or priority flag, and is used to determine the resource object that the current resource usage request will attempt to occupy first. Temporary occupancy processing can be achieved by writing a temporary occupancy flag, recording the temporary occupancy amount, and setting the occupancy validity period. The temporary occupancy flag is used to distinguish that the resource record has been reserved for the current resource usage request. The temporary occupancy amount can be determined based on the resource availability data and the requested usage amount. The occupancy validity period is used to limit the duration of the reservation. The resource record to be used can store the resource identifier, temporary occupancy amount, temporary occupancy flag, occupancy validity period, and ranking position, so that the selected candidate resource record can enter the subsequent verification as an independent record. Candidate resource records in the resource usage sequence that are ranked after the selected candidate resource record are retained as backup resource records according to their original ranking order, and are used to provide alternative objects when the priority record can no longer be used.

[0039] This can be implemented using a queue index. The resource usage sequence is stored in an ordered list. After the first candidate resource record in the list is read, the remaining resource data and occupancy status are queried based on the resource identifier, and then a temporary occupancy flag and the validity period of the occupancy are written to generate a resource record to be used. The candidate resource records after the first one in the list maintain their original order, generating a list of standby resource records.

[0040] Alternatively, a priority field approach can be used. The resource usage sequence is stored in a data table, with each candidate resource record having a priority field. The candidate resource record with the highest priority field is read and used to generate a resource record to be used. The remaining candidate resource records are sorted according to their priority fields to form a backup resource record. In fintech businesses, payment discount resources, policy value-added resources, and membership service resources can be temporarily occupied using a queue index. In healthcare businesses, physical examination service resources, consultation service resources, and delivery service resources can be reserved for backup using a priority field approach.

[0041] In the fintech business, when a customer initiates a request to use membership service resources, the resource usage sequence includes membership value-added resources, payment discount resources, and policy value-added resources. The membership value-added resources listed first are marked with a temporary occupancy flag and a record of resources to be used is generated. The remaining payment discount resources and policy value-added resources are listed in their original order to form a reserve resource record.

[0042] In the healthcare business, when a user initiates a request for a physical examination appointment, the resource usage sequence includes physical examination service resources, consultation service resources, and delivery service resources. The physical examination service resources listed first are temporarily occupied and recorded as pending resources, while the subsequent consultation service resources and delivery service resources are reserved as backup resources.

[0043] This embodiment selects the candidate resource record with the highest order from the resource usage sequence and temporarily occupies it, so that the priority resource object can be reserved before formal use, reducing the situation where the same resource is occupied by multiple requests at the same time; by determining the remaining candidate resource records as backup resource records, the subsequent replacement objects and the original order can be preserved, thereby reducing the processing delay caused by re-selecting resources when the priority resource object cannot be used.

[0044] S60, the resource record to be used is matched and verified with the resource use request, and the resource use is processed based on the matching and verification result. A resource processing log is generated, and the user resource account is updated and written to the resource scheduling record based on the resource processing log.

[0045] In this embodiment, the resource record to be used is used to take over the candidate resource record that has been temporarily occupied. It may include resource identifier, temporary occupation amount, effective occupation time, temporary occupation flag, and sorting position data. The matching verification revolves around the consistency between the resource record to be used and the resource usage request. It can read the service category, service location, request time, and request usage amount from the request parameters, and then read the resource status data, resource area data, resource validity data, and resource remaining data of the corresponding resource record in the user resource account. The matching verification result can be divided into pass, fail, occupation timeout, or usage incomplete. When the matching verification result is pass, the resource remaining data is deducted according to the temporary occupation amount, and a resource processing log is formed. When the matching verification result is fail, the effective occupation time expires, or the usage is incomplete, the temporary occupation flag corresponding to the resource record to be used is released, and a backup resource record is called to participate in the resource usage processing. The resource processing log can record the resource identifier, resource usage processing result, deduction result, replacement status, and account update result. The user resource account updates the resource record according to the resource processing log, and the resource scheduling record saves the log data, comparison basis, sorting basis, and replacement basis during the resource usage processing.

[0046] In the fintech business, after a customer initiates a request for policy value-added services, the policy service resources corresponding to the resource record to be used need to be matched and verified against the service category, service location, and request time. If the matching and verification result is successful, the remaining resource data in the user's resource account is deducted according to the temporary usage amount, and a resource processing log is generated; if the matching and verification result is unsuccessful, the member service resources or payment discount resources in the backup resource record are called to continue participating in the resource usage processing.

[0047] In the healthcare business, after a user initiates a physical examination appointment request, the physical examination service resources corresponding to the pending resource record need to be matched and verified against the appointment area, appointment time, and requested usage. If the valid time expires or the physical examination service resources cannot be used, the temporary occupancy marker can be released and the consultation service resources or delivery service resources in the backup resource record can be called. The resource processing log synchronously records the resource usage processing results and account update results.

[0048] This embodiment limits the inconsistency between the resource record to be used and the resource usage request by matching and verifying. Then, based on the matching and verification results, it selects the resource record to be used or the backup resource record to participate in the resource usage process. It also uses the resource processing log to update the user resource account and write the resource scheduling record, which can reduce the situation of resources being deducted incorrectly, temporary occupation without release, and inconsistency between account records and resource usage results.

[0049] In one embodiment, step S10 includes: S101, Receive a resource usage request, parse the resource usage request, and obtain request parameters; S102, extract account location parameters, service constraint parameters and time constraint parameters from the request parameters, perform integrity verification on the account location parameters, the service constraint parameters and the time constraint parameters, and obtain the request parameter verification result; S103, when the verification result of the request parameters is passed, query the user resource account directory based on the account location parameters to determine the user resource account; S104, Based on the account positioning parameters, read the resource records in the user resource account and generate an account resource snapshot; S105, associate the service constraint parameters and the time constraint parameters with the account resource snapshot, and generate an initial resource set based on the associated account resource snapshot.

[0050] In this embodiment, resource usage requests can be generated through interface calls, message reception, task triggering, or page submission. Upon receipt, the requests are parsed according to pre-configured message paths, field mapping relationships, or object attribute reading methods to obtain request parameters. These request parameters carry three types of information: account location, service constraints, and time constraints. Account location parameters can be represented by user ID, account ID, member ID, or business transaction number. Service constraint parameters can be represented by service category, resource usage scenario, or service scope identifier. Time constraint parameters can be represented by request time, appointment time, submission time, or trigger time. During the parsing process, fields from different sources can be converted to a unified data format. For example, string timestamps can be converted to standard time objects, service names in business entry points can be converted to service category codes, and account identifiers can be converted to query keys recognizable by the account directory.

[0051] Integrity verification can be completed before account reading. Account location parameters determine whether a user resource account can be located, service constraint parameters preserve service association conditions after resource reading, and time constraint parameters preserve time association conditions after resource reading. Integrity verification can include null value validation, format validation, field length validation, enumeration value validation, and time format validation. Upon successful verification, a request parameter verification result is generated, indicating that the account location parameters, service constraint parameters, and time constraint parameters can participate in subsequent reading. If any parameter is missing or its format does not meet the reading requirements, a failed request parameter verification result can be generated, and account reading can be stopped or the process can be initiated into the exception logging phase.

[0052] The user resource account directory can be implemented using an account index table, account directory cache, account routing table, or account service interface. After verification, the account location parameters are used as the query key to access the user resource account directory, retrieving the account primary key, account partition identifier, account storage address, or account service access identifier. Once the user resource account is identified, resource records within the user resource account are read based on the account location parameters. Resource records may include resource identifier, resource type, resource status, resource expiration data, resource region data, resource remaining data, and resource source category. Reading methods can include database query, cache read, service interface fetch, or partition data access, and resource records obtained in the same read can be written to the account resource snapshot.

[0053] Account resource snapshots are used to save the resource records read in this operation, along with the read time, account location parameters, and read batch information. By associating service constraint parameters and time constraint parameters with the account resource snapshot, the resource records in the snapshot retain the service and time conditions of the current resource usage request. The association method can be either writing a request association marker into the account resource snapshot or establishing a mapping record between the account resource snapshot and the request parameters. The associated account resource snapshot is then converted into an initial resource set. Each resource record in the initial resource set retains the account source and request association information, facilitating subsequent processing within the same data scope.

[0054] This embodiment obtains request parameters by parsing resource usage requests and performs integrity verification on account location parameters, service constraint parameters, and time constraint parameters, which can reduce parameter omissions and format errors before account reading. By querying the user resource account directory and reading resource records in the user resource account through account location parameters, the resource reading range can be kept consistent with the account location results. After generating an initial resource set by associating service constraint parameters and time constraint parameters with account resource snapshots, the read resource records can be kept at the same data level as the current resource usage request, thereby reducing unclear resource record reading range, repeated reading, and inconsistencies in subsequent account data.

[0055] In one embodiment, step S20 above includes: S201, extract the service category, service location, and request time from the request parameters; S202, Read the resource records in the initial resource set item by item, and extract resource status data, resource type data, resource area data and resource timeliness data from the resource records; S203, perform status availability verification based on the resource status data, and generate status verification result; S204, Perform type matching verification based on the service category and the resource type data, and generate a type verification result; S205, Perform regional coverage verification based on the service location and the resource area data, and generate regional coverage verification result; S206, Perform time validity verification based on the request time point and the resource timeliness data, and generate a time verification result; S207, the resource records that pass the status verification result, the type verification result, the area coverage verification result, and the time verification result are taken as candidate resource records, and the candidate resource records are aggregated to generate a candidate resource set; S208, at least one of the status verification result, the type verification result, the area coverage verification result, and the time verification result that represents a failed resource record is used as an excluded resource record, and an excluded resource set is generated based on the excluded resource record and the corresponding failed verification result.

[0056] In this embodiment, the service category, service location, and request time point in the request parameters each serve different screening functions. The service category is used to match the resource type data in the resource records, preventing resource records that do not match the current service request from entering the candidate range. The service location is used to determine coverage against resource area data, which can be represented by a region code, service range identifier, network location identifier, or hierarchical region identifier. The request time point is used to determine timeliness against resource validity data, which can be represented by an effective start time, effective end time, cycle end time, or expiration time. Before screening, the above data can be formatted uniformly; for example, the service category can be converted to a unified category code, the service location to a region code, and the request time point to a unified time format, enabling request parameters generated by different business entry points to participate in the same screening process.

[0057] Resource records in the initial resource set are read item by item according to their resource identifiers. Resource status data, resource type data, resource region data, and resource expiration data are obtained from the same resource record. Resource status data is used for availability verification, distinguishing between states such as available for use, frozen, disabled, occupied, or expired. Resource type data is used for type matching verification, determining whether the service scope supported by the resource record includes the service category. Resource region data is used for region coverage verification, determining whether the service location falls within the serviceable region corresponding to the resource record. Resource expiration data is used for time validity verification, determining whether the request time falls within the allowed time range of the resource record.

[0058] The status verification result, type verification result, area coverage verification result, and time verification result each correspond to a screening conclusion. When all four verification results meet the screening criteria, the corresponding resource record is marked as a candidate resource record and aggregated to form a candidate resource set. When at least one verification result fails to meet the screening criteria, the corresponding resource record is marked as an excluded resource record, and together with the failed verification results, forms an excluded resource set. The candidate resource set retains only resource records that can participate in subsequent selections, while the excluded resource set retains the excluded resource records and their corresponding reasons, ensuring that the resource screening results have a traceable data source.

[0059] This embodiment extracts service category, service location, and request time point through request parameters, and performs multiple screenings by combining resource status data, resource type data, resource region data, and resource timeliness data in resource records. This can exclude resource records in the initial resource set that do not meet the current resource usage request, and form a candidate resource set of resource records that meet the screening conditions. Since the candidate resource set is determined by the four types of verification results of status, type, region, and time, the range of data involved in subsequent processing is clearer, thereby reducing the deviation of resource usage objects caused by invalid resource records participating in subsequent selections.

[0060] In one embodiment, step S30 above includes: S301, extract the service location and request time point from the request parameters; S302, Read the candidate resource records in the candidate resource set item by item, and read the resource attribute data of the candidate resource records; S303, extract resource timeliness data, resource area data, resource balance data, and balance clearing time point from the resource attribute data; S304, Based on the resource timeliness data and the request time point, perform timeliness difference processing to generate timeliness comparison information; S305, Based on the resource area data and the service location, perform regional coverage level identification and generate regional comparison information; S306, Based on the resource remaining data, the remaining time point when the remaining amount is cleared, and the request time point, the remaining amount consumption status is identified, and remaining amount comparison information is generated; S307, the timeliness comparison information, the regional comparison information and the remaining capacity comparison information are combined into resource comparison information; S308, establish a binding relationship between the resource comparison information and the corresponding candidate resource record, and write the resource comparison information into the corresponding candidate resource record based on the binding relationship.

[0061] In this embodiment, the service location and request time point are extracted from the request parameters to provide a unified reference for subsequent comparisons. The service location can be represented by a region code, service outlet code, service range identifier, or location hierarchy code. After extraction, the format can be converted and the hierarchy can be split to ensure that the service location corresponds to the resource region data. The request time point can be represented by the request submission time, service trigger time, or resource call time. After extraction, it can be converted to a unified time format to determine the time relationship between the request time point and resource validity data and the time point when the remaining balance is cleared.

[0062] Candidate resource records in the candidate resource set are read item by item according to their resource identifiers. During the reading process, the independence between candidate resource records is preserved to avoid mixing attribute data from different records. Resource attribute data is obtained from the candidate resource records and may include resource expiration data, resource region data, resource remaining data, and the time point when the remaining data is cleared. Resource expiration data indicates the allowed time range or expiration time of the resource; resource region data indicates the resource coverage area or region level; resource remaining data indicates the remaining uses, remaining quota, or available quantity; and the time point when the remaining data is cleared indicates the time when the resource remaining data is reset or expires.

[0063] Timeliness discrepancy processing compares resource timeliness data with the request time, generating timeliness comparison information. This information records the urgency of resource failure, whether the request time is close to the failure boundary, and the time priority attribute of the resource timeliness data. Regional coverage level identification compares resource region data with service locations, generating region comparison information. This information records whether the service location falls within the corresponding range of the resource region data, whether the resource region hierarchy is more concentrated, and the relative size of the resource coverage area. Remaining resource consumption status identification combines resource remaining data, the time point of resetting the remaining resource to zero, and the request time to generate remaining resource comparison information. This information records the remaining status of the resource remaining resource, its time relationship to zeroing, and the necessity of continuing to retain the remaining resource.

[0064] When timeliness comparison information, regional comparison information, and remaining capacity comparison information are combined into resource comparison information, they can be aggregated according to resource identifiers, making each candidate resource record an independent comparison data group. A binding relationship is established between resource comparison information and the corresponding candidate resource record, which can be accomplished through writing extended fields of candidate resource records, mapping resource identifier records, cached key-value pairs, or mounting in-memory object attributes. The written candidate resource record carries the resource comparison information, maintaining the correspondence between resource attribute data, request parameters, and comparison results.

[0065] This embodiment extracts the service location and request time from the request parameters, and combines them with the resource timeliness data, resource region data, resource balance data, and balance clearing time from the candidate resource records to generate timeliness comparison information, region comparison information, and balance comparison information, respectively. This allows the resource comparison information to reflect the three dimensions of time, region, and balance simultaneously. After the resource comparison information is further bound to the corresponding candidate resource records, each candidate resource record carries a comparison basis that matches the current request, thereby reducing the selection bias caused by relying on a single attribute to form the resource usage order.

[0066] In one embodiment, step S40 above includes: S401, extract configuration retrieval parameters from the request parameters, and query the hierarchical configuration library based on the configuration retrieval parameters to obtain the hierarchical processing configuration; S402, extract the hierarchical comparison order, hierarchical comparison direction and peer comparison method from the hierarchical processing configuration; S403, Read the candidate resource records in the candidate resource set item by item, and read the resource comparison information from the candidate resource records; S404, Read the timeliness comparison information, regional comparison information and remaining capacity comparison information from the resource comparison information according to the hierarchical comparison order, and generate candidate resource comparison items; S405, perform a first-level comparison on the candidate resource comparison items based on the hierarchical comparison direction, and generate a first-level comparison result; S406, Based on the hierarchical comparison order and the hierarchical comparison direction, perform subsequent hierarchical comparisons on the candidate resource records at the same level in the first hierarchical comparison results to generate hierarchical comparison results; S407, Based on the same-level comparison method, the candidate resource records at the same level in the hierarchical comparison results are processed in order to generate a resource usage sequence.

[0067] In this embodiment, the request parameters are used to obtain configuration retrieval parameters that match the current resource usage scenario. These parameters can consist of one or more of the following: service category, service location, request time point, business source identifier, and resource call scenario identifier. After field normalization, null value removal, hierarchical splitting, and priority mapping, the configuration retrieval parameters are used to query the hierarchical configuration library. The hierarchical configuration library can use data tables, cached key-value pairs, configuration files, or configuration service interfaces to store hierarchical processing configurations for different scenarios. The hierarchical processing configuration stores the hierarchical comparison order, hierarchical comparison direction, and peer-to-peer comparison method. The hierarchical comparison order determines the order in which timeliness comparison information, regional comparison information, and remaining capacity comparison information participate in the comparison; the hierarchical comparison direction determines the direction in which each type of comparison information is arranged; and the peer-to-peer comparison method handles situations where multiple candidate resource records at the same level have the same comparison result.

[0068] Candidate resource records in the candidate resource set can be read item by item according to their resource identifiers. Resource comparison information has been written to the candidate resource records and can be retrieved from extended fields, associated records, cached objects, or memory objects during reading. Resource comparison information may include timeliness comparison information, regional comparison information, and remaining capacity comparison information. After reading the above comparison information in hierarchical comparison order, candidate resource comparison items can be generated. Candidate resource comparison items are used to combine candidate resource records and the data participating in the ranking into the same data unit, avoiding the loss of the correspondence between candidate resource records and comparison information during the comparison process.

[0069] Hierarchical comparison can be performed layer by layer according to the hierarchical processing configuration. The comparison information ranked first in the hierarchical comparison order is used to form the input for the first-level comparison, and the hierarchical comparison direction is used to determine the arrangement relationship in the first-level comparison results. After the first-level comparison, candidate resource records with the same comparison result continue to the subsequent hierarchical comparison, and the subsequent hierarchical comparison continues to read the next type of comparison information according to the hierarchical comparison order and hierarchical comparison direction. After each level of comparison, candidate resource records that are still at the same level can be processed in order according to the same-level comparison method. The same-level comparison method can be implemented by resource identifier order, account registration time, most recent usage time, fixed fallback sorting field, or random seed sorting field. The resource usage sequence can save candidate resource records, their arrangement positions, the information categories involved in the comparison, and the comparison result markers, so that subsequent resource selection can directly read the candidate resource records ranked first.

[0070] This embodiment obtains the hierarchical processing configuration by requesting parameters and uses the hierarchical processing configuration to perform hierarchical comparison of resource comparison information in the candidate resource set. This allows candidate resource records to form a resource usage sequence according to multiple comparison criteria such as timeliness, region, and remaining capacity. Since each level of comparison is controlled by the hierarchical comparison order and hierarchical comparison direction, and candidate resource records at the same level can continue to form an order through the same level comparison method, when multiple candidate resource records simultaneously meet the resource usage request, the deviation in resource usage order caused by arranging based on only a single attribute can be reduced.

[0071] In one embodiment, step S50 above includes: S501, Select the candidate resource record with the highest sorting order from the resource usage sequence, and determine the sorting position data of the candidate resource record with the highest sorting order in the resource usage sequence; S502, read the resource identifier and resource balance data from the candidate resource record at the top of the sort, and extract the request usage from the request parameters; S503, generate a temporary occupancy amount based on the resource remaining data and the request usage amount, and perform temporary occupancy processing on the top-ranked candidate resource record based on the temporary occupancy amount to generate a temporary occupancy mark and an effective occupancy time; S504, the resource identifier, the temporary occupancy amount, the temporary occupancy flag, the occupancy validity time, and the sorting position data are written into the resource to be used record; S505, when multiple resource usage requests simultaneously point to the candidate resource record with the highest sorting, generate duplicate occupation restriction information based on the temporary occupation amount in the resource record to be used, and write the duplicate occupation restriction information into the resource record to be used; S506, the candidate resource records following the first candidate resource record in the resource usage sequence are determined as backup resource records according to the sorting order in the resource usage sequence.

[0072] In this embodiment, the resource usage sequence stores the relative positions of candidate resource records after sorting. This can be implemented using an ordered list, a queue object, a set of sorting fields, or a temporary data table. Each candidate resource record can carry a resource identifier, resource remaining data, and sorting position data. The sorting position data indicates the position of the candidate resource record in the resource usage sequence and can be a sequence number field, a priority field, a queue index value, or a sorting result marker. When reading the resource usage sequence, the candidate resource record at the front of the sorted list is located according to the sorting position data. This ensures that subsequent temporary occupancy only applies to the candidate resource record with the highest current priority, preventing multiple candidate resource records from entering an occupied state simultaneously.

[0073] Once the top-ranked candidate resource record is determined, its resource identifier and remaining resource data are retrieved. The resource identifier distinguishes the selected resource and ensures traceability of its origin when generating subsequent resource records. The remaining resource data indicates the quantity, frequency, or amount of the resource still available for use. The requested usage amount, obtained from the request parameters, indicates the quantity, frequency, or amount required for this resource usage request. The temporary occupancy amount is formed based on the remaining resource data and the requested usage amount. It can be used when the requested usage amount is less than or equal to the remaining resource data, or it can be combined with the remaining resource data and the requested usage amount to determine the available occupancy amount when there are single-use limits, account-level occupancy limits, or resource-level occupancy limits. Therefore, the temporary occupancy amount corresponds to the current request demand and is also constrained by the actual remaining resource quantity.

[0074] Temporary occupancy can be handled by writing a temporary occupancy flag and an effective occupancy time. The temporary occupancy flag can be written to a candidate resource record, occupancy register, cached object, or pending resource record, indicating that the top-ranked candidate resource record has been reserved by the current resource usage request. The effective occupancy time limits the duration of the reservation state and can be set based on request processing time limits, resource usage confirmation time limits, or service response time limits. The pending resource record can store resource identifier, temporary occupancy amount, temporary occupancy flag, effective occupancy time, and ranking position data, transforming the selected candidate resource record into an independent pending object. When multiple resource usage requests simultaneously target the top-ranked candidate resource record, duplicate occupancy restriction information is formed based on the temporary occupancy amount in the pending resource record, recording the occupied amount, remaining available amount, request source identifier, and occupancy time, preventing the same resource remaining capacity from being repeatedly reserved by multiple requests. Candidate resource records following the top-ranked candidate resource record in the resource usage sequence are determined as backup resource records according to their original ranking order. Backup resource records retain their corresponding resource identifier and ranking position for subsequent calls in the original order.

[0075] This embodiment locates the top-ranked candidate resource record in the resource usage sequence and generates a temporary occupancy based on resource availability data and request usage. This allows priority resource objects to be reserved in a controlled manner before formal use, reducing the possibility of resources being preempted by other requests after selection. By recording the reservation status through temporary occupancy markers and valid occupancy time, the reservation scope and duration can be limited, reducing the risk of resource unavailability caused by long-term temporary occupancy. By recording the occupancy changes under concurrent requests through duplicate occupancy restriction information, the duplicate occupancy of the same resource availability can be reduced. By determining the remaining candidate resource records as backup resource records according to the sorting order in the resource usage sequence, the calling order of alternative resources can be preserved, thereby reducing the processing delay caused by re-selecting resources when priority resources can no longer be used.

[0076] In one embodiment, step S60 above includes: S601, matching and verifying the resource record to be used with the resource usage request, processing the resource record to be used or the backup resource record based on the matching and verification result, generating a resource processing log, updating the user resource account based on the resource processing log and writing it into the resource scheduling record, including: S602, read the resource identifier, temporary occupancy amount, temporary occupancy mark, occupancy validity time and sorting position data from the resource record to be used, and read the current resource record from the user resource account based on the resource identifier; S603, read request parameters from the resource usage request, and perform matching and verification on the resource record to be used based on the request parameters, the temporary occupancy amount, the occupancy validity time, and the resource status data, resource area data, resource timeliness data, and resource remaining data in the current resource record, and generate a matching and verification result; S604, when the matching verification result is passed, resource usage processing is performed based on the resource record to be used, and the remaining resource data of the resource record corresponding to the resource identifier in the user resource account is deducted according to the temporary occupation amount, and a usage completion log is generated; S605, when the matching verification result fails, the valid time for occupation expires, or the resource usage processing is not completed, the temporary occupation mark in the resource to be used record is removed, and the backup resource record is called again for matching verification and resource usage processing according to the sorting order of the backup resource record in the resource usage sequence, and a replacement processing log and replacement reason are generated. S606, the usage completion log or the replacement processing log is determined as the resource processing log, a resource usage update result is generated based on the resource processing log, and the resource usage update result is written into the resource record in the user resource account; S607, the resource processing log, the resource comparison information, the hierarchical processing configuration, the resource record to be used, the backup resource record, the sorting position data, and the resource usage processing result extracted from the resource processing log are written into the resource scheduling record, and when the resource processing log includes the replacement processing log, the replacement reason is written into the resource scheduling record.

[0077] In this embodiment, the resource record to be used stores resource identifier, temporary occupancy amount, temporary occupancy flag, occupancy validity time, and sorting position data. The resource identifier is used to locate the current resource record from the user's resource account. The current resource record retains resource status data, resource region data, resource validity data, and resource remaining data. The temporary occupancy amount indicates the quantity, frequency, or quota of resources reserved for this resource usage request. The occupancy validity time is used to determine whether the reservation status is still valid, and the temporary occupancy flag is used to determine whether the resource record to be used is still in a reserved state. The sorting position data records the source position of the resource record to be used in the resource usage sequence, facilitating the reconstruction of the resource selection process when subsequently written into the resource scheduling record.

[0078] Matching and validation can be performed based on request parameters, temporary occupancy, valid occupancy time, and resource data in the current resource record. Request parameters can include service category, service location, request time, and requested usage. Resource status data is used to determine whether the current resource record is still allowed to be used; resource region data is used to determine whether the service location is still within coverage; resource validity data is used to determine whether the request time is within the available time range; and resource remaining data is used to determine whether the current remaining quantity can cover the temporary occupancy. When the valid occupancy time expires, even if other data meets the requirements, it is necessary to enter the exception branch to prevent expired reservations from continuing to participate in resource usage processing.

[0079] When the matching verification result is successful, the resource record to be used participates in resource usage processing, and the resource balance data of the corresponding resource record in the user's resource account is deducted according to the temporary occupation amount. After the deduction is completed, a usage completion log is generated, which can record the resource identifier, the resource balance data before deduction, the temporary occupation amount, the resource balance data after deduction, the resource usage time, and the account update status. When the matching verification result is unsuccessful, the valid occupation time expires, or the resource usage processing is not completed, the temporary occupation mark in the resource record to be used is removed, and the reserved resource is restored to a state that can be reassessed; the standby resource record is called according to the sorting order in the resource usage sequence, and matching verification and resource usage processing are performed again, generating a replacement processing log and the replacement reason. The replacement reason can come from status failure, region mismatch, timeout, insufficient balance, occupation timeout, or usage processing incomplete.

[0080] Once the completion log or replacement processing log is identified as a resource processing log, it is used to generate resource usage update results. These results can include changes in resource availability, resource status, last usage time, and occupancy flags, and are written to the resource record in the user's resource account. The resource scheduling record stores the resource processing log, resource comparison information, hierarchical processing configuration, records of resources to be used, records of standby resources, sorting position data, and resource usage processing results extracted from the resource processing log. When the resource processing log contains a replacement processing log, the replacement reason is written to the resource scheduling record, ensuring that both the normal usage path and the replacement usage path have corresponding records.

[0081] This embodiment locates the current resource record by resource identifier and performs matching and verification using request parameters, temporary occupancy, valid occupancy time, and status, region, timeliness, and remaining data in the current resource record. This reduces the possibility of continued deduction when reserved resources are inconsistent with the current request. After a successful match, the remaining resource data is deducted according to the temporary occupancy. If the match fails, occupancy times out, or processing is incomplete, the temporary occupancy mark is removed and a backup resource record is called, which reduces the possibility of resources being incorrectly occupied and processing interruptions. The resource processing log further generates resource usage update results and writes them to the user's resource account. At the same time, the resource usage processing results and replacement reasons are written to the resource scheduling record, which improves the consistency between the account resource record and the actual resource usage results.

[0082] In one embodiment, in a fintech business scenario, a customer initiates a request to use insurance value-added service resources through a service platform. The request corresponds to high-end customer health management services. After receiving the resource usage request, the service platform parses it to obtain request parameters. These parameters include account positioning parameters derived from the customer's ID, service constraint parameters derived from the health management service, and time constraint parameters derived from the time the customer submits the service application. The service platform performs integrity verification on the account positioning parameters, service constraint parameters, and time constraint parameters. If the verification result is satisfactory, it queries the user resource account directory based on the account positioning parameters to determine the customer's corresponding user resource account. Based on the account positioning parameters, it reads the resource records in the user resource account and generates an account resource snapshot. The account resource snapshot can include various resource records such as annual physical examination resources, expert consultation resources, drug delivery resources, policy value-added service resources, payment discount resources, and membership service resources. The service platform associates the service constraint parameters and time constraint parameters with the account resource snapshot and generates an initial resource set based on the associated snapshot, ensuring that resource records corresponding to the same resource usage request are uniformly included in the same processing scope.

[0083] The service platform performs availability screening on the initial resource set based on request parameters, extracting service category, service location, and request time from the parameters. The service category is health management service, the service location is the service city selected by the customer, and the request time is the time the customer submitted the service request. The service platform reads each resource record in the initial resource set, extracting resource status data, resource type data, resource region data, and resource expiration data. For resource records whose status data indicates the resource is disabled or frozen, the status verification result fails. For resource records whose resource type data does not match the health management service, the type verification result fails. For resource records whose region data does not cover the service city selected by the customer, the region coverage verification result fails. For resource records whose expiration data exceeds the request time, the time verification result fails. The service platform selects resource records that pass all four verification results as candidate resource records and aggregates them to generate a candidate resource set. Resource records that fail at least one verification result are excluded resource records, and an excluded resource set is generated based on these excluded resource records and their corresponding failed verification results. Therefore, discontinued membership service resources, drug delivery resources not covered by the service city, and payment discount resources that have expired will not be included in the candidate resource set. Annual physical examination resources, expert consultation resources, and policy value-added service resources can be recorded as candidate resources and continue to participate in subsequent processing.

[0084] The service platform further generates resource comparison information based on request parameters and resource attribute data of candidate resource records. The platform extracts service location and request time from the request parameters, reads candidate resource records from the candidate resource set item by item, and reads the resource attribute data of each candidate resource record. From the resource attribute data, it extracts resource expiration data, resource region data, resource remaining data, and the remaining data reset time. For annual physical examination resources, resource expiration data represents the annual service expiration date, resource region data represents the available city range, resource remaining data represents the remaining number of physical examinations, and the remaining data reset time represents the time when the annual number of examinations is reset to zero. For expert consultation resources, resource expiration data represents the service package validity period, resource region data represents the online or designated area availability range, and resource remaining data represents the remaining number of consultations. For policy value-added service resources, resource expiration data represents the policy's annual benefit validity period, resource region data represents the service provider's coverage area, and resource remaining data represents the remaining number of value-added service visits. The service platform processes timeliness differences based on resource timeliness data and request time to generate timeliness comparison information; it identifies regional coverage levels based on resource region data and service location to generate regional comparison information; and it identifies remaining resource consumption status based on resource balance data, remaining balance clearing time, and request time to generate remaining balance comparison information. The service platform combines timeliness comparison information, regional comparison information, and remaining balance comparison information into resource comparison information, establishes a binding relationship between resource comparison information and corresponding candidate resource records, and writes the resource comparison information into the corresponding candidate resource records based on this binding relationship. Therefore, annual physical examination resources can carry comparison information such as nearing expiration, narrow service city coverage, and few remaining sessions; expert consultation resources and policy value-added service resources also carry corresponding comparison information.

[0085] The service platform obtains the hierarchical processing configuration based on the request parameters and extracts the configuration retrieval parameters from them. These parameters can be formed by combining service category, service location, customer level, and business source. The platform then queries the hierarchical configuration library based on these parameters to obtain the hierarchical processing configuration and extracts the hierarchical comparison order, comparison direction, and peer comparison method. In health management service scenarios, the hierarchical comparison order can prioritize regional comparison information, followed by timeliness comparison information, and then remaining balance comparison information. Similarly, in time-limited policy value-added service scenarios, timeliness comparison information can be prioritized. The platform reads candidate resource records from the candidate resource set item by item and retrieves resource comparison information from these records. Following the hierarchical comparison order, it reads timeliness comparison information, regional comparison information, and remaining balance comparison information from the resource comparison information to generate candidate resource comparison items. The service platform performs a first-level comparison of candidate resource comparison items based on hierarchical comparison direction, generating a first-level comparison result. For candidate resource records at the same level in the first-level comparison result, subsequent hierarchical comparisons are performed based on the hierarchical comparison order and direction, generating hierarchical comparison results. For candidate resource records still at the same level in the hierarchical comparison results, the order is processed based on the same-level comparison method to generate a resource usage sequence. In the resource usage sequence, annual physical examination resources with more precise service city coverage, those about to expire, and with fewer remaining sessions can be prioritized, while policy value-added service resources with broader coverage and longer validity periods can be prioritized, so that the resource usage order matches the current financial service scenario.

[0086] After the resource usage sequence is formed, the service platform selects the top-ranked candidate resource record from the sequence for temporary allocation. If the top-ranked candidate resource record is an annual health checkup resource, the service platform determines its ranking position in the resource usage sequence, reads the resource identifier and remaining resource data from the annual health checkup resource, and extracts the requested usage from the request parameters. If the customer only requests a health checkup service once, the service platform generates a temporary allocation based on the remaining resource data and the requested usage, and temporarily allocates the top-ranked candidate resource record based on this temporary allocation, generating a temporary allocation marker and an effective allocation time. The service platform writes the resource identifier, temporary allocation, temporary allocation marker, effective allocation time, and ranking position data into the resource record to be used. When multiple resource usage requests simultaneously target the same annual health checkup resource, the service platform generates duplicate allocation restriction information based on the temporary allocation in the resource record to be used, and writes this restriction information into the resource record to prevent the same resource remaining space from being reserved repeatedly. The service platform will designate expert consultation resources and policy value-added service resources that are located after the annual physical examination resources in the resource usage sequence as reserve resource records according to the sorting order in the resource usage sequence.

[0087] The service platform matches and verifies the records of resources to be used with resource usage requests. It reads the resource identifier, temporary occupancy, temporary occupancy flag, effective occupancy time, and sorting position data from the records of resources to be used, and reads the current resource record from the user's resource account based on the resource identifier. The service platform reads request parameters from the resource usage request. Based on the request parameters, temporary occupancy, effective occupancy time, and resource status data, resource area data, resource validity data, and resource remaining data in the current resource record, it matches and verifies the records of resources to be used, generating a matching and verification result. If the matching and verification result is successful, the service platform processes the resource usage based on the records of resources to be used, deducting the resource remaining data from the resource record corresponding to the resource identifier in the user's resource account according to the temporary occupancy, and generating a usage completion log. If the matching and verification result is unsuccessful, the effective occupancy time expires, or the resource usage processing is incomplete, the service platform removes the temporary occupancy flag from the records of resources to be used, and calls the backup resource records according to their sorting order in the resource usage sequence to re-match and verify and re-process the resource usage, generating a replacement processing log and the replacement reason. The service platform identifies completion logs or replacement processing logs as resource processing logs, generates resource usage update results based on these logs, and writes these results to the resource records in the user's resource account. The service platform also writes the resource processing logs, resource comparison information, hierarchical processing configurations, records of resources to be used, records of backup resources, sorting position data, and resource usage processing results extracted from the resource processing logs into the resource scheduling record. When the resource processing logs include replacement processing logs, the reason for the replacement is written into the resource scheduling record. Therefore, when an insurance customer holds multiple service resources simultaneously, the service platform can determine the resource usage order according to request parameters, resource attribute data, and hierarchical processing configurations, and maintain data consistency between temporary resource occupation, backup replacement, account updates, and scheduling record writing.

[0088] In one embodiment, a resource level comparison and processing apparatus is provided, which corresponds one-to-one with the resource level comparison and processing method in the above embodiments. (Refer to...) Figure 3 , Figure 3 This is a schematic diagram of the functional modules of a preferred embodiment of the resource hierarchy comparison and processing device of the present invention. The modules include a request parsing and resource reading module 10, a resource availability screening module 20, a resource comparison information generation module 30, a hierarchy comparison and sorting module 40, a temporary occupancy processing module 50, and a resource usage settlement module 60. Detailed descriptions of each functional module are as follows: The request parsing and resource reading module 10 is used to obtain resource usage requests, read resource records in the user's resource account based on the request parameters in the resource usage requests, and generate an initial resource set. The resource availability screening module 20 is used to perform availability screening on the initial resource set based on the request parameters, take the resource records that pass the availability screening as candidate resource records, and generate a candidate resource set. The resource comparison information generation module 30 is used to generate resource comparison information based on the request parameters and the resource attribute data of the candidate resource record, and bind the resource comparison information to the candidate resource record; The hierarchical comparison and sorting module 40 is used to obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison on the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence. The temporary occupancy processing module 50 is used to select the candidate resource record with the highest sorting from the resource usage sequence for temporary occupancy processing, generate a resource record to be used, and determine the remaining candidate resource records in the resource usage sequence as backup resource records. The resource usage settlement module 60 is used to match and verify the resource record to be used with the resource usage request, process the resource record to be used or the backup resource record based on the matching and verification result, generate a resource processing log, update the user resource account based on the resource processing log and write it into the resource scheduling record.

[0089] In one embodiment, the request parsing and resource reading module 10 is specifically used for: Receive a resource usage request, parse the resource usage request, and obtain the request parameters; The account location parameter, service constraint parameter, and time constraint parameter are extracted from the request parameters. The integrity of the account location parameter, service constraint parameter, and time constraint parameter is verified to obtain the request parameter verification result. When the verification result of the request parameters is passed, the user resource account directory is queried based on the account location parameters to determine the user resource account; Based on the account positioning parameters, read the resource records in the user's resource account and generate an account resource snapshot; The service constraint parameters and the time constraint parameters are associated with the account resource snapshot, and an initial resource set is generated based on the associated account resource snapshot.

[0090] In one embodiment, the resource availability screening module 20 is specifically used for: Extract the service category, service location, and request time from the request parameters; Read the resource records in the initial resource set one by one, and extract resource status data, resource type data, resource region data and resource timeliness data from the resource records; Based on the resource status data, a status availability verification is performed, and a status verification result is generated. Based on the service category and resource type data, perform type matching verification to generate type verification results; Based on the service location and the resource area data, perform regional coverage verification and generate regional coverage verification results; Based on the request time and the resource validity data, a time validity verification is performed to generate a time verification result. Resource records that pass the status verification result, type verification result, area coverage verification result, and time verification result are selected as candidate resource records, and these candidate resource records are aggregated to generate a candidate resource set. At least one of the status verification result, the type verification result, the area coverage verification result, and the time verification result is used to identify the failed resource record as the excluded resource record, and an excluded resource set is generated based on the excluded resource record and the corresponding failed verification result.

[0091] In one embodiment, the resource comparison information generation module 30 is specifically used for: Extract the service location and request time from the request parameters; Read the candidate resource records in the candidate resource set one by one, and read the resource attribute data of the candidate resource records; Extract resource timeliness data, resource region data, resource balance data, and balance clearing time from the resource attribute data; Based on the resource timeliness data and the request time point, timeliness difference processing is performed to generate timeliness comparison information; Based on the resource area data and the service location, regional coverage level identification is performed to generate regional comparison information; Based on the resource balance data, the balance clearing time point, and the request time point, the balance consumption status is identified, and balance comparison information is generated. The timeliness comparison information, the regional comparison information, and the remaining capacity comparison information are combined into resource comparison information; Establish a binding relationship between the resource comparison information and the corresponding candidate resource record, and write the resource comparison information into the corresponding candidate resource record based on the binding relationship.

[0092] In one embodiment, the hierarchical comparison and sorting module 40 is specifically used for: Extract configuration retrieval parameters from the request parameters, and query the hierarchical configuration library based on the configuration retrieval parameters to obtain the hierarchical processing configuration; Extract the hierarchical comparison order, hierarchical comparison direction, and peer comparison method from the hierarchical processing configuration; Read the candidate resource records in the candidate resource set item by item, and read the resource comparison information from the candidate resource records; According to the hierarchical comparison order, read the timeliness comparison information, regional comparison information and remaining capacity comparison information from the resource comparison information to generate candidate resource comparison items; Based on the hierarchical comparison direction, the candidate resource comparison items are compared at the first level to generate the first level comparison result. Based on the hierarchical comparison order and the hierarchical comparison direction, subsequent hierarchical comparisons are performed on candidate resource records at the same level in the first hierarchical comparison results to generate hierarchical comparison results; Based on the peer comparison method, the candidate resource records at the same level in the hierarchical comparison results are processed in order to generate a resource usage sequence.

[0093] In one embodiment, the temporary occupancy processing module 50 is specifically used for: Select the candidate resource record that is ranked first from the resource usage sequence, and determine the ranking position data of the candidate resource record that is ranked first in the resource usage sequence; Read the resource identifier and resource balance data from the top-ranked candidate resource record, and extract the request usage from the request parameters; A temporary occupancy is generated based on the resource availability data and the request usage, and the top-ranked candidate resource record is temporarily occupied based on the temporary occupancy, generating a temporary occupancy flag and an effective occupancy time. Write the resource identifier, the temporary occupancy amount, the temporary occupancy flag, the occupancy validity time, and the sorting position data into the resource to be used record; When multiple resource usage requests simultaneously point to the top-ranked candidate resource record, duplicate usage restriction information is generated based on the temporary occupancy in the resource record to be used, and the duplicate usage restriction information is written into the resource record to be used. Candidate resource records that are located after the first candidate resource record in the resource usage sequence are determined as backup resource records according to the sorting order in the resource usage sequence.

[0094] In one embodiment, the resource usage settlement module 60 is specifically used for: Read the resource identifier, temporary occupancy, temporary occupancy flag, occupancy validity time and sorting position data from the resource record to be used, and read the current resource record from the user's resource account based on the resource identifier; Read request parameters from the resource usage request, and perform matching and verification on the resource record to be used based on the request parameters, the temporary occupancy amount, the occupancy validity time, and the resource status data, resource area data, resource timeliness data, and resource remaining data in the current resource record, and generate a matching and verification result. When the matching verification result is successful, resource usage processing is performed based on the resource record to be used, and the remaining resource data of the resource record corresponding to the resource identifier in the user's resource account is deducted according to the temporary occupancy amount to generate a usage completion log; When the matching verification result fails, the valid time for occupation expires, or the resource usage processing is not completed, the temporary occupation mark in the resource to be used record is removed, and the backup resource record is called again for matching verification and resource usage processing according to the sorting order of the backup resource record in the resource usage sequence, generating a replacement processing log and replacement reason; The usage completion log or the replacement processing log is identified as the resource processing log. Based on the resource processing log, a resource usage update result is generated and written into the resource record in the user's resource account. Write the resource processing log, the resource comparison information, the hierarchical processing configuration, the resource record to be used, the backup resource record, the sorting position data, and the resource usage processing result extracted from the resource processing log into the resource scheduling record. When the resource processing log includes the replacement processing log, write the replacement reason into the resource scheduling record.

[0095] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 4 As shown, the computer device includes a processor, memory, network interface, and database connected via a system bus. The processor provides determination and control capabilities. The memory includes non-volatile and / or volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface is used to communicate with external clients via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a resource hierarchy comparison and processing method on the server side.

[0096] In one embodiment, a computer device is provided, which may be a client, and its internal structure diagram may be as follows: Figure 5As shown, the computer device includes a processor, memory, network interface, display screen, and input devices connected via a system bus. The processor provides determination and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface is used to communicate with an external server via a network connection. When executed by the processor, the computer program implements client-side functions or steps of a resource hierarchy comparison and processing method.

[0097] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to perform the following steps: Obtain resource usage requests, and based on the request parameters in the resource usage requests, read the resource records in the user's resource account to generate an initial resource set; Based on the request parameters, the initial resource set is subjected to availability screening, and the resource records that pass the availability screening are used as candidate resource records to generate a candidate resource set. Resource comparison information is generated based on the request parameters and the resource attribute data of the candidate resource records, and the resource comparison information is bound to the candidate resource records; Obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison on the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence; The candidate resource record with the highest sorting from the resource usage sequence is selected for temporary occupation to generate a resource record to be used, and the remaining candidate resource records in the resource usage sequence are determined as backup resource records. The resource record to be used is matched and verified with the resource usage request. Based on the matching and verification results, the resource record to be used or the backup resource record is processed for resource usage, a resource processing log is generated, and the user resource account is updated and written to the resource scheduling record based on the resource processing log.

[0098] In one embodiment, a computer-readable storage medium is provided, which may be non-volatile or volatile, and a computer program is stored thereon, which, when executed by a processor, performs the following steps: Obtain resource usage requests, and based on the request parameters in the resource usage requests, read the resource records in the user's resource account to generate an initial resource set; Based on the request parameters, the initial resource set is subjected to availability screening, and the resource records that pass the availability screening are used as candidate resource records to generate a candidate resource set. Resource comparison information is generated based on the request parameters and the resource attribute data of the candidate resource records, and the resource comparison information is bound to the candidate resource records; Obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison on the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence; The candidate resource record with the highest sorting from the resource usage sequence is selected for temporary occupation to generate a resource record to be used, and the remaining candidate resource records in the resource usage sequence are determined as backup resource records. The resource record to be used is matched and verified with the resource usage request. Based on the matching and verification results, the resource record to be used or the backup resource record is processed for resource usage, a resource processing log is generated, and the user resource account is updated and written to the resource scheduling record based on the resource processing log.

[0099] It should be noted that the functions or steps that can be implemented by the computer-readable storage medium or computer device described above can be referred to the relevant descriptions on the server side and client side in the foregoing method embodiments. To avoid repetition, they will not be described one by one here.

[0100] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0101] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is used as an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0102] It should be noted that any AI models, software tools, or components not belonging to this company appearing in the embodiments of this application are merely illustrative examples and do not represent actual use. All user personal information involved in the embodiments of this application has been authorized (with the knowledge and consent) by the relevant parties or has been fully authorized by all parties, and the executing entity may obtain it through various legal and compliant means. The collection, storage, use, processing, transmission, provision, and disclosure of the information, data, and signals involved all comply with relevant laws and regulations and do not violate public order and good morals.

[0103] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included within the protection scope of the present invention.

Claims

1. A method for comparing and processing resource levels, characterized in that, Includes the following steps: Obtain resource usage requests, and based on the request parameters in the resource usage requests, read the resource records in the user's resource account to generate an initial resource set; Based on the request parameters, the initial resource set is subjected to availability screening, and the resource records that pass the availability screening are used as candidate resource records to generate a candidate resource set. Resource comparison information is generated based on the request parameters and the resource attribute data of the candidate resource records, and the resource comparison information is bound to the candidate resource records; Obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison on the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence; The candidate resource record with the highest sorting order is selected from the resource usage sequence for temporary occupation, generating a resource record to be used, and the remaining candidate resource records in the resource usage sequence are determined as backup resource records. The resource record to be used is matched and verified with the resource usage request. Based on the matching and verification results, the resource record to be used or the backup resource record is processed for resource usage, a resource processing log is generated, and the user resource account is updated and written to the resource scheduling record based on the resource processing log.

2. The resource hierarchy comparison and processing method as described in claim 1, characterized in that, Obtain resource usage requests, read resource records from the user's resource account based on the request parameters in the resource usage requests, and generate an initial resource set, including: Receive a resource usage request, parse the resource usage request, and obtain the request parameters; The account location parameter, service constraint parameter, and time constraint parameter are extracted from the request parameters. The integrity of the account location parameter, service constraint parameter, and time constraint parameter is verified to obtain the request parameter verification result. When the verification result of the request parameters is passed, the user resource account directory is queried based on the account location parameters to determine the user resource account; Based on the account positioning parameters, read the resource records in the user's resource account and generate an account resource snapshot; The service constraint parameters and the time constraint parameters are associated with the account resource snapshot, and an initial resource set is generated based on the associated account resource snapshot.

3. The resource hierarchy comparison and processing method as described in claim 1, characterized in that, Based on the request parameters, the initial resource set is subjected to availability screening. Resource records that pass the availability screening are used as candidate resource records, and a candidate resource set is generated, including: Extract the service category, service location, and request time from the request parameters; Read the resource records in the initial resource set one by one, and extract resource status data, resource type data, resource region data and resource timeliness data from the resource records; Based on the resource status data, a status availability verification is performed, and a status verification result is generated. Based on the service category and resource type data, perform type matching verification to generate type verification results; Based on the service location and the resource area data, perform regional coverage verification and generate regional coverage verification results; Based on the request time and the resource validity data, a time validity verification is performed to generate a time verification result. Resource records that pass the status verification result, type verification result, area coverage verification result, and time verification result are selected as candidate resource records, and these candidate resource records are aggregated to generate a candidate resource set. At least one of the status verification result, the type verification result, the area coverage verification result, and the time verification result is used to identify the failed resource record as the excluded resource record, and an excluded resource set is generated based on the excluded resource record and the corresponding failed verification result.

4. The resource hierarchy comparison and processing method as described in claim 1, characterized in that, Resource comparison information is generated based on the request parameters and the resource attribute data of the candidate resource records, and the resource comparison information is bound to the candidate resource records, including: Extract the service location and request time from the request parameters; Read the candidate resource records in the candidate resource set one by one, and read the resource attribute data of the candidate resource records; Extract resource timeliness data, resource region data, resource balance data, and balance clearing time from the resource attribute data; Based on the resource timeliness data and the request time point, timeliness difference processing is performed to generate timeliness comparison information; Based on the resource area data and the service location, regional coverage level identification is performed to generate regional comparison information; Based on the resource balance data, the balance clearing time point, and the request time point, the balance consumption status is identified, and balance comparison information is generated. The timeliness comparison information, the regional comparison information, and the remaining capacity comparison information are combined into resource comparison information; Establish a binding relationship between the resource comparison information and the corresponding candidate resource record, and write the resource comparison information into the corresponding candidate resource record based on the binding relationship.

5. The resource hierarchy comparison and processing method as described in claim 1, characterized in that, Obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison of the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence, including: Extract configuration retrieval parameters from the request parameters, and query the hierarchical configuration library based on the configuration retrieval parameters to obtain the hierarchical processing configuration; Extract the hierarchical comparison order, hierarchical comparison direction, and peer comparison method from the hierarchical processing configuration; Read the candidate resource records in the candidate resource set item by item, and read the resource comparison information from the candidate resource records; According to the hierarchical comparison order, read the timeliness comparison information, regional comparison information and remaining capacity comparison information from the resource comparison information to generate candidate resource comparison items; Based on the hierarchical comparison direction, the candidate resource comparison items are compared at the first level to generate the first level comparison result. Based on the hierarchical comparison order and the hierarchical comparison direction, subsequent hierarchical comparisons are performed on candidate resource records at the same level in the first hierarchical comparison results to generate hierarchical comparison results; Based on the peer comparison method, the candidate resource records at the same level in the hierarchical comparison results are processed in order to generate a resource usage sequence.

6. The resource hierarchy comparison and processing method as described in claim 1, characterized in that, The resource record with the highest ranking in the resource usage sequence is selected for temporary allocation to generate a resource record to be used. The remaining candidate resource records in the resource usage sequence are designated as backup resource records, including: Select the candidate resource record that is ranked first from the resource usage sequence, and determine the ranking position data of the candidate resource record that is ranked first in the resource usage sequence; Read the resource identifier and resource balance data from the top-ranked candidate resource record, and extract the request usage from the request parameters; A temporary occupancy is generated based on the resource availability data and the request usage, and the top-ranked candidate resource record is temporarily occupied based on the temporary occupancy, generating a temporary occupancy flag and an effective occupancy time. Write the resource identifier, the temporary occupancy amount, the temporary occupancy flag, the occupancy validity time, and the sorting position data into the resource to be used record; When multiple resource usage requests simultaneously point to the top-ranked candidate resource record, duplicate usage restriction information is generated based on the temporary occupancy in the resource record to be used, and the duplicate usage restriction information is written into the resource record to be used. Candidate resource records that are located after the first candidate resource record in the resource usage sequence are determined as backup resource records according to the sorting order in the resource usage sequence.

7. The resource hierarchy comparison and processing method as described in claim 1, characterized in that, The process involves matching and verifying the resource records to be used with the resource usage requests, processing the resource usage of the resource records to be used or the backup resource records based on the matching and verification results, generating a resource processing log, updating the user resource account based on the resource processing log, and writing it into the resource scheduling record. Read the resource identifier, temporary occupancy, temporary occupancy flag, occupancy validity time and sorting position data from the resource record to be used, and read the current resource record from the user's resource account based on the resource identifier; Read request parameters from the resource usage request, and perform matching and verification on the resource record to be used based on the request parameters, the temporary occupancy amount, the occupancy validity time, and the resource status data, resource area data, resource timeliness data, and resource remaining data in the current resource record, and generate a matching and verification result. When the matching verification result is successful, resource usage processing is performed based on the resource record to be used, and the remaining resource data of the resource record corresponding to the resource identifier in the user's resource account is deducted according to the temporary occupancy amount to generate a usage completion log; When the matching verification result fails, the valid time for occupation expires, or the resource usage processing is not completed, the temporary occupation mark in the resource to be used record is removed, and the backup resource record is called again for matching verification and resource usage processing according to the sorting order of the backup resource record in the resource usage sequence, generating a replacement processing log and replacement reason; The usage completion log or the replacement processing log is identified as the resource processing log. Based on the resource processing log, a resource usage update result is generated and written into the resource record in the user's resource account. Write the resource processing log, the resource comparison information, the hierarchical processing configuration, the resource record to be used, the backup resource record, the sorting position data, and the resource usage processing result extracted from the resource processing log into the resource scheduling record. When the resource processing log includes the replacement processing log, write the replacement reason into the resource scheduling record.

8. A resource hierarchy comparison and processing device, characterized in that, The resource hierarchy comparison and processing device includes: The request parsing and resource reading module is used to obtain resource usage requests, read resource records in the user's resource account based on the request parameters in the resource usage requests, and generate an initial resource set. The resource availability screening module is used to perform availability screening on the initial resource set based on the request parameters, and to use the resource records that pass the availability screening as candidate resource records and generate a candidate resource set. The resource comparison information generation module is used to generate resource comparison information based on the request parameters and the resource attribute data of the candidate resource record, and bind the resource comparison information to the candidate resource record; The hierarchical comparison and sorting module is used to obtain the hierarchical processing configuration corresponding to the request parameters, perform hierarchical comparison on the candidate resource set based on the hierarchical processing configuration and the resource comparison information, and generate a resource usage sequence. The temporary occupancy processing module is used to select the candidate resource record with the highest sorting from the resource usage sequence for temporary occupancy processing, generate a resource record to be used, and determine the remaining candidate resource records in the resource usage sequence as backup resource records. The resource usage settlement module is used to match and verify the resource records to be used with the resource usage requests, process the resource records to be used or the backup resource records based on the matching and verification results, generate a resource processing log, update the user resource account based on the resource processing log and write it into the resource scheduling record.

9. A computer device, characterized in that, The computer device includes a memory, a processor, and a resource hierarchy comparison and processing program stored in the memory and executable on the processor. When the resource hierarchy comparison and processing program is executed by the processor, it implements the steps of the resource hierarchy comparison and processing method as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The storage medium stores a resource hierarchy comparison and processing program, which, when executed by a processor, implements the steps of the resource hierarchy comparison and processing method as described in any one of claims 1-7.