Settlement difference event alarm method, device and equipment and storage medium
Patent Information
- Application Number
- CN202610872210.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-16
- Publication Date
- 2026-10-09
AI Technical Summary
[0003]在凭证解析环节,承运商提供的结算凭证涵盖Excel、PDF、扫描件、手机拍摄照片等多种格式,且不同承运商的账单排版差异较大,传统基于固定模板或正则表达式的解析工具鲁棒性较差,一旦承运商微调表格列宽、字体或页面布局,解析便容易失效,导致较多凭证无法实现自动化入库,需人工手动录入,增加了结算前期的工作量
[0018]本发明公开的结算差异事件告警方法,通过差异化的凭证预处理机制,解决了不同格式账单无法统一自动化解析的难题,提升了凭证入库效率;通过合同规则匹配与多维差异判定,实现了结算差异的精准初筛,过滤了无意义的微小误差;通过因果分析机制,突破了传统规则比对的局限性,能够自动推导差异产生的深层业务原因;通过多视角智能体交叉验证机制,有效降低了模型幻觉风险,提升了归因结果的准确性与可信度;所述方法实现了多源数据解析、智能归因和主动告警,有效提升异常排查效率,可帮助企业及时发现结算异常,挽回不必要的经济损失,同时满足透明度要求,实现了物流结算业务的升级。
Smart Images

Figure CN122887620A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data processing technology, and in particular to a method, apparatus, device, and storage medium for alarming settlement discrepancy events. Background Technology
[0002] Logistics companies need to connect with dozens or even hundreds of carriers of different sizes. Settlement business is characterized by a surge in data volume, diverse voucher formats, and complex billing rules, and the limitations of traditional logistics settlement models are gradually becoming apparent.
[0003] In the document parsing stage, the settlement documents provided by carriers cover a variety of formats, including Excel, PDF, scanned copies, and photos taken by mobile phones. Moreover, the billing layouts of different carriers vary greatly. Traditional parsing tools based on fixed templates or regular expressions are not robust. Once the carrier makes minor adjustments to the table column width, font, or page layout, the parsing is prone to failure. As a result, many documents cannot be automatically entered into the database and need to be manually entered, which increases the workload in the early stages of settlement.
[0004] In the reconciliation and matching process, existing transportation management systems and financial systems generally only support hard rule comparisons of three documents: orders, waybills, and invoices. They can only output whether the amounts are consistent, and cannot effectively explain the reasons for the discrepancies. This keeps the reconciliation work at a superficial stage of problem discovery, making it difficult to advance subsequent problem-solving.
[0005] In the discrepancy attribution stage, logistics settlement discrepancies often involve multiple cost types such as freight, surcharges, and compensation payments. Finance and dispatch personnel need to manually investigate semi-structured and unstructured data such as chat logs, emails, GPS tracks, and on-site photos across systems. This not only takes several days or even weeks, resulting in low efficiency, but also easily leads to the loss of accumulated discrepancy investigation experience due to staff turnover. In addition, manual investigation is highly subjective and has a high rate of missed and incorrect judgments, making it difficult to meet the company's requirements for settlement accuracy and audit transparency.
[0006] It is evident that existing technologies still need improvement and enhancement. Summary of the Invention
[0007] To overcome the shortcomings of existing technologies, the present invention aims to provide a settlement discrepancy event alarm method, which realizes multi-source data parsing, intelligent attribution and proactive alarm, effectively improves the efficiency of anomaly investigation, and can help logistics companies to discover settlement anomaly events in a timely manner and reduce economic losses.
[0008] The first aspect of this invention provides a method for alarming settlement discrepancy events, comprising: acquiring multi-source settlement voucher data of an order to be settled, and parsing the file type and structure level of each voucher included in the multi-source settlement voucher data; preprocessing each voucher based on the file type and structure level, integrating the preprocessing results of each voucher to construct preprocessed billing data, wherein the preprocessed billing data includes the actual settlement amount of the order to be settled; determining the original order node of the order to be settled based on the preprocessed billing data to match the contract pricing rules, and calculating the settlement amount to be settled according to the preprocessed billing data and the contract pricing rules. Calculate the theoretical payable amount for the order; determine the difference threshold; based on the actual settlement amount, the theoretical payable amount, and the difference threshold, determine whether the order to be settled is a settlement difference event; if the order to be settled is determined to be a settlement difference event, generate a graph probe based on the preprocessed billing data, and perform causal analysis based on the preprocessed billing data and the graph probe to generate preliminary root cause results of the difference for the order to be settled; call a pre-trained multi-view agent to cross-validate the preliminary root cause results of the difference to determine the final attribution information, and generate settlement difference alarm information based on the final attribution information and the preprocessed billing data.
[0009] Optionally, in the first implementation of the first aspect of the present invention, the step of preprocessing each voucher based on file type and degree of structuring, and integrating the preprocessing results of each voucher to construct preprocessed billing data, includes: classifying vouchers into structured spreadsheets, semi-structured documents, and unstructured images based on the file type and degree of structuring of each voucher; if the voucher is a structured spreadsheet, extracting core billing fields through fuzzy field matching, and performing data type conversion, null value filling, and outlier marking on the core billing fields to obtain structured billing fields; if the voucher is a semi-structured document or an unstructured image, using a large visual model to perform multimodal document understanding on the voucher to extract text blocks with layout attributes and reorganize them into a continuous text stream, and extracting structured billing fields based on the continuous text stream; separating unstructured remarks information from the text content of all vouchers, extracting event type, participating entities, time, location, and impact factors, and converting them into standardized semantic triples; and integrating the structured billing fields and standardized semantic triples to construct preprocessed billing data.
[0010] Optionally, in a second implementation of the first aspect of the present invention, the step of determining the original order node of the order to be settled based on the preprocessed billing data to match the contract pricing rules, and calculating the theoretical payable amount of the order to be settled according to the preprocessed billing data and the contract pricing rules includes: extracting the billing context features of the order to be settled from the preprocessed billing data and encoding the billing context features into a billing context vector; calculating the cosine similarity between the billing context vector and each high-dimensional vector in the pre-constructed contract rule vector library, and determining the contract pricing rules of the order to be settled based on the cosine similarity calculation results; and calculating the theoretical payable amount of the order to be settled on a per-item basis according to the contract pricing rules and the billing base in the preprocessed billing data.
[0011] Optionally, in a third implementation of the first aspect of the present invention, determining the difference threshold, based on the actual settlement amount, the theoretical payable amount, and the difference threshold, to determine whether the order to be settled is a settlement difference event includes: statistically analyzing the amount difference data of all settlement orders within a preset historical period, and calculating the difference threshold corresponding to different expense items using the 3-Sigma principle; comparing the actual settlement amount and the theoretical payable amount of the order to be settled item by item, calculating the amount difference value and difference ratio of each expense item, and generating a multidimensional difference matrix; for each expense item, if the amount difference value exceeds the corresponding difference threshold and the difference ratio is greater than a preset ratio threshold, then the expense item is marked as an abnormal item; if the order to be settled has at least one abnormal item, then the order to be settled is determined to be a settlement difference event.
[0012] Optionally, in the fourth implementation of the first aspect of the present invention, the step of generating a graph probe based on the preprocessed billing data and performing causal analysis based on the preprocessed billing data and the graph probe to generate preliminary root cause results of discrepancies for orders to be settled includes: extracting core features of settlement discrepancy events from the preprocessed billing data to generate a discrepancy feature vector, wherein the core features include the discrepancy amount, abnormal expense item, occurrence time, transportation route, and associated semantic evidence; inputting the discrepancy feature vector into a pre-trained classification model to output multiple preliminary root cause categories, wherein the multiple preliminary root cause categories serve as graph probes for locating corresponding subgraph entries in a pre-constructed settlement causal graph; calling a pre-trained language model with external tool calling capabilities to retrieve and verify cross-system data related to the multiple preliminary root cause categories to generate first evidence information; concurrently calling the pre-constructed settlement causal graph and performing a directional depth-first search based on the graph probe to generate second evidence information; integrating the first evidence information and the second evidence information to generate preliminary root cause results, wherein the preliminary root cause results include root cause categories, evidence sources, and logical deduction processes.
[0013] Optionally, in a fifth implementation of the first aspect of the present invention, the step of calling a pre-trained multi-perspective agent to cross-validate the preliminary root cause results to determine the final attribution information includes: initializing three pre-trained agents with different perspectives, namely a financial compliance perspective agent, a field operation perspective agent, and a data system perspective agent; inputting the preliminary root cause results into the three agents respectively to generate multiple inference branches; quantitatively evaluating the explanatory power of each inference branch, dynamically pruning inference branches with explanatory power lower than a preset power threshold, and further validating the retained inference branches; when a preset verification stop condition is met, obtaining the inference branch with the optimal explanatory power, and determining the root cause conclusion corresponding to the inference branch as the final attribution information.
[0014] Optionally, in the sixth implementation of the first aspect of the present invention, after generating settlement discrepancy alarm information based on the final attribution information and preprocessed billing data, the method further includes: acquiring relevant data of all settlement discrepancy events within a preset historical settlement period to construct a standardized time-series dataset; performing multiple rounds of iterative training on a model pre-built based on a long short-term memory network based on the standardized time-series dataset to obtain a time-series prediction model; acquiring settlement data within the current settlement period and inputting the settlement data into the time-series prediction model to predict the probability and range of discrepancy events for each carrier and each transportation route in the current settlement period; determining whether there is a risk of settlement discrepancy events based on the predicted probability and range of discrepancy events; and generating settlement discrepancy risk warning information and pushing it to relevant management personnel if a risk of discrepancy events is determined to exist.
[0015] A second aspect of the present invention provides a settlement discrepancy event alarm device, comprising: a parsing module, configured to acquire multi-source settlement voucher data of an order to be settled, and parse the file type and structuring level of each voucher included in the multi-source settlement voucher data; a construction module, configured to preprocess each voucher based on the file type and structuring level, and integrate the preprocessing results of each voucher to construct preprocessed billing data, wherein the preprocessed billing data includes the actual settlement amount of the order to be settled; and a calculation module, configured to determine the original order node of the order to be settled based on the preprocessed billing data to match the contract pricing rules, and calculate the amount to be settled according to the preprocessed billing data and the contract pricing rules. The system calculates the theoretical payable amount for each order; a judgment module determines a difference threshold and, based on the actual settlement amount, the theoretical payable amount, and the difference threshold, determines whether the order to be settled is a settlement difference event; an analysis module, if the order to be settled is determined to be a settlement difference event, generates a graph probe based on the preprocessed billing data and performs causal analysis based on the preprocessed billing data and the graph probe to generate preliminary root cause results for the order to be settled; and a verification module, which calls a pre-trained multi-view agent to cross-validate the preliminary root cause results to determine the final attribution information and generates settlement difference alarm information based on the final attribution information and the preprocessed billing data.
[0016] A third aspect of the present invention provides a settlement discrepancy event alarm device, the settlement discrepancy event alarm device comprising: a memory and at least one processor, the memory storing instructions; at least one processor calling the instructions in the memory to cause the settlement discrepancy event alarm device to execute each step of the settlement discrepancy event alarm method described in any of the preceding claims.
[0017] A fourth aspect of the present invention provides a computer-readable storage medium storing instructions that, when executed by a processor, implement the steps of the settlement difference event alarm method described in any of the preceding claims.
[0018] This invention discloses a settlement discrepancy event alarm method that solves the problem of inconsistent automated parsing of invoices of different formats through a differentiated voucher preprocessing mechanism, thereby improving voucher entry efficiency. Through contract rule matching and multi-dimensional discrepancy judgment, it achieves accurate initial screening of settlement discrepancies, filtering out meaningless minor errors. Through a causal analysis mechanism, it overcomes the limitations of traditional rule comparison, automatically deriving the underlying business reasons for discrepancies. Through a multi-perspective intelligent agent cross-validation mechanism, it effectively reduces the risk of model illusion and improves the accuracy and credibility of attribution results. The method realizes multi-source data parsing, intelligent attribution, and proactive alarms, effectively improving anomaly detection efficiency. It can help enterprises promptly discover settlement anomalies, recover unnecessary economic losses, and meet transparency requirements, thus upgrading logistics settlement operations. Attached Figure Description
[0019] Figure 1 This is a first logic flowchart of the settlement difference event alarm method provided in an embodiment of the present invention; Figure 2 This is a second logic flowchart of the settlement difference event alarm method provided in an embodiment of the present invention; Figure 3 This is a third logic flowchart of the settlement difference event alarm method provided in an embodiment of the present invention; Figure 4 The fourth logic flowchart of the settlement difference event alarm method provided in the embodiment of the present invention; Figure 5 This is the fifth logic flowchart of the settlement difference event alarm method provided in the embodiment of the present invention; Figure 6 The sixth logic flowchart of the settlement difference event alarm method provided in the embodiment of the present invention; Figure 7 The seventh logic flowchart of the settlement difference event alarm method provided in the embodiment of the present invention; Figure 8 This is a schematic diagram of the settlement discrepancy event alarm device provided in an embodiment of the present invention; Figure 9 This is a schematic diagram of the structure of the settlement difference event alarm device provided in an embodiment of the present invention. Detailed Implementation
[0020] This invention provides a method, apparatus, device, and storage medium for alarming settlement discrepancies. In this invention, the terms "first," "second," "third," "fourth," etc. (if present)," in the specification, claims, and accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in a sequence other than that illustrated or described herein. Furthermore, the terms "comprising" or "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or device that includes a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or devices.
[0021] This application discloses a method for alarming settlement discrepancy events. For ease of understanding, the specific process of the embodiments of the present invention is described below, such as... Figure 1 As shown, one embodiment of the settlement difference event alarm method in this invention includes: 101. Obtain multi-source settlement voucher data for orders pending settlement, and parse the file type and structure of each voucher included in the multi-source settlement voucher data; In this embodiment, the multi-source settlement voucher data originates from the logistics company's internal transportation management system, enterprise resource planning system, customer relationship management system, as well as various settlement-related documents submitted by external carriers through channels such as email, file transfer protocol servers, and online reconciliation platforms. Logistics settlement is usually processed in batches according to fixed cycles, so it is necessary to obtain all settlement vouchers for all orders within the settlement period. A single order to be settled may correspond to multiple vouchers from different sources, including master invoices, surcharge details, VAT invoices, goods receipt slips, and exception situation explanation slips. By identifying the file extension of each voucher to determine the file type, and by analyzing the structural characteristics of the file content, three types of vouchers are distinguished: fully structured, semi-structured, and unstructured. This achieves unified access and automatic classification of multi-source and multi-format vouchers, laying the foundation for subsequent differentiated preprocessing and avoiding the inefficiency and classification errors caused by manual classification.
[0022] 102. Based on the file type and degree of structure, each voucher is preprocessed separately, and the preprocessing results of each voucher are integrated to construct preprocessed billing data, which includes the actual settlement amount of the order to be settled; In traditional settlement models, vouchers of different formats need to be processed manually, and the lack of uniform data formats makes it impossible to directly conduct subsequent reconciliation analysis. This embodiment adopts an adaptive preprocessing method for different types of vouchers, which can extract data scattered in different format files and convert it into a unified structured format. This not only improves the efficiency of data processing, but also reduces errors that may occur during manual data entry. The integrated preprocessed billing data includes all the information required to complete the settlement, providing a unified and complete data foundation for subsequent order matching, theoretical amount calculation, and discrepancy analysis.
[0023] 103. Based on the pre-processed billing data, determine the original order node of the order to be settled in order to match the contract pricing rules, and calculate the theoretical payable amount of the order to be settled according to the pre-processed billing data and the contract pricing rules; In traditional reconciliation processes, finance personnel need to manually search for corresponding order information and contract terms in multiple systems, and then calculate the theoretical amount one by one according to the contract rules. This process is tedious and prone to errors. This embodiment achieves automatic association between billing data, order data, and contract data by automatically matching the original order nodes. Based on the specific contract terms corresponding to the order to be settled, it automatically extracts the applicable pricing rules and calculates the theoretical amount payable. This not only shortens the time for calculating the theoretical amount, but also ensures that the calculation results comply with the contract agreement. It provides an objective and accurate comparison benchmark for subsequent difference determination and avoids disputes caused by human calculation errors.
[0024] 104. Determine the difference threshold: Based on the actual settlement amount, the theoretical payable amount, and the difference threshold, determine whether the order to be settled is a settlement difference event; During the logistics settlement process, numerous minor discrepancies without business significance arise due to system floating-point errors, rounding differences, and reasonable business fluctuations. Manually investigating all discrepancies would waste significant human and material resources. This embodiment effectively distinguishes between normal business fluctuations and abnormal discrepancies requiring attention by dynamically determining the discrepancy threshold. Specifically, only significant discrepancies exceeding the threshold are identified as settlement discrepancy events, triggering subsequent root cause analysis processes. This filters out meaningless minor discrepancies, reduces the workload of analysis, and improves the efficiency of the entire settlement process.
[0025] 105. If the order to be settled is determined to be a settlement discrepancy event, a graph probe is generated based on the preprocessed billing data, and causal analysis is performed based on the preprocessed billing data and the graph probe to generate preliminary root cause results of the discrepancy of the order to be settled. Traditional settlement systems can only detect discrepancies in amounts but cannot explain the reasons for these discrepancies, and discrepancy investigation relies on human experience. Finance personnel need to consult a large amount of data across systems, including chat logs, emails, GPS tracks, etc., resulting in long investigation cycles and the loss of experience due to staff turnover. This embodiment, by integrating causal analysis mechanisms of causal graphs and large language models, can deduce the deep-seated business reasons for discrepancies, breaking through the limitations of traditional rule comparison, shortening the discrepancy investigation time, reducing reliance on human experience, and preserving the complete reasoning process for subsequent auditing and traceability.
[0026] 106. Call the pre-trained multi-view agent to cross-validate the preliminary root cause results of the differences to determine the final attribution information, and generate settlement difference alarm information based on the final attribution information and pre-processed billing data; The inference results of a single model may contain illusions or biases, leading to attribution errors. This embodiment calls multiple intelligent agents with different professional perspectives to cross-validate the preliminary root cause results from multiple dimensions such as financial compliance, on-site operations, and data systems. The generated settlement discrepancy alarm information includes discrepancy details, root cause conclusions, evidence chains, and suggested handling measures, which can help relevant personnel quickly understand the discrepancy situation and take corresponding handling measures, improving the response speed and handling efficiency of settlement anomalies, while ensuring the accuracy and reliability of attribution results and meeting the transparency requirements of audit level.
[0027] The settlement discrepancy event alarm method disclosed in this application solves the problem of inconsistent automated parsing of invoices of different formats through a differentiated voucher preprocessing mechanism, thereby improving voucher entry efficiency. Through contract rule matching and multi-dimensional discrepancy judgment, it achieves accurate initial screening of settlement discrepancies, filtering out meaningless minor errors. Through a causal analysis mechanism, it overcomes the limitations of traditional rule comparison, automatically deriving the underlying business reasons for discrepancies. Through a multi-perspective intelligent agent cross-validation mechanism, it effectively reduces the risk of model illusion and improves the accuracy and credibility of attribution results. The method achieves multi-source data parsing, intelligent attribution, and proactive alarming, effectively improving anomaly detection efficiency. It can help enterprises promptly discover settlement anomalies, recover unnecessary economic losses, and meet transparency requirements, thus upgrading logistics settlement operations.
[0028] Furthermore, such as Figure 2 As shown in this embodiment of the invention, the preprocessing of each voucher based on file type and degree of structure, and the integration of the preprocessing results of each voucher to construct preprocessed billing data, includes: 201. Based on the file type and degree of structuring of each voucher, vouchers are divided into structured spreadsheets, semi-structured documents, and unstructured images. In this embodiment, vouchers with file extensions of .xls or .xlsx and a standardized row and column structure are classified as structured spreadsheets; vouchers with file extensions of .pdf and including editable text content are classified as semi-structured documents; and vouchers with file extensions of .jpg, .png, .bmp, .tiff, and other image formats, as well as .pdf vouchers including non-editable scanned content, are classified as unstructured images. This classification of vouchers provides a basis for subsequent adoption of targeted preprocessing methods.
[0029] 202. If the voucher is a structured spreadsheet, the core billing fields are extracted by fuzzy matching of fields, and the core billing fields are processed by data type conversion, null value filling and outlier marking to obtain the structured billing fields. In this embodiment, fuzzy matching and mapping of fields are achieved by calculating the text similarity between table column names and predefined field names. The predefined set of field names includes waybill number, shipper name, shipper phone number, consignee name, consignee phone number, origin, destination, cargo weight, cargo volume, expense item, unit price, quantity, amount, invoice number, invoice date, carrier name, etc., determined based on the actual needs of logistics settlement business, national logistics industry standards, and internal financial regulations of the enterprise. The thesaurus is constructed based on common logistics industry terms and internal enterprise idioms. For example, synonyms for volumetric weight include volumetric weight and volumetric weight. The definition of core billing fields is also included. Then, the extracted core billing fields are converted into their corresponding data types. For null fields, default values or values derived from related fields are used to fill them. Field values that exceed the reasonable range are marked as abnormal. This achieves automatic parsing and data cleaning of structured spreadsheet vouchers, adapting to the differences in field names of different carriers' tables, and improving the accuracy and completeness of data extraction.
[0030] 203. If the voucher is a semi-structured document or an unstructured image, a large visual model is used to perform multimodal document understanding on the voucher to extract text blocks with layout attributes and reorganize them into a continuous text stream, and extract structured billing fields based on the continuous text stream. In this embodiment, the large-scale visual model is pre-trained based on large-scale general document image and corresponding text pairing data, and then fine-tuned using a large amount of professional document data such as bills, invoices, waybills, and receipts from the logistics field. For semi-structured document vouchers, the text embedding information of the document and the pixel information after converting the document into an image are extracted simultaneously. For unstructured image vouchers, the text content is first extracted using optical character recognition technology to generate text embedding information, while the pixel information of the original image is input. The pre-trained large-scale visual model fuses the text embedding information and pixel information through a multimodal encoder, and outputs text blocks with layout attributes such as titles, paragraphs, tables, lists, headers, and footers. Then, according to the reading order from left to right and top to bottom, the discrete text blocks are reassembled into a continuous text stream, and the core billing fields are extracted from the reassembled text stream through semantic analysis. This step solves the problem of the difficulty in automatically parsing semi-structured documents and unstructured image vouchers, and can accurately identify the table structure and text content in the document, improving the parsing accuracy of non-standard format vouchers.
[0031] 204. Separate unstructured remarks from the text content of all vouchers, extract the event type, participating entities, time, location and impact factors, and transform them into standardized semantic triples; In this embodiment, semantic segmentation technology is first used to classify text blocks into two categories: bill body and remarks. The semantic segmentation technology combines rules and models. Rule-based segmentation locates the remarks area through keyword matching, such as matching text blocks containing keywords such as remarks, explanations, messages, special cases, and exception explanations. Model-based segmentation uses a fine-tuned text classification model, which is based on a pre-trained text classification base model and is fine-tuned using a logistics settlement document annotation dataset. The training dataset includes real logistics bill text samples, covering multiple scenarios such as regular bill body, various remarks and exception explanations, customer service messages, and driver annotation text, and is uniformly labeled as bill body and remarks. The training process adopts adaptive learning rate, batch iterative training, and early stopping mechanism to optimize the model's feature extraction capability for logistics document text scenarios. The trained text classification model can distinguish between structured bill body and scattered, non-standardized remarks text. Secondly, a named entity recognition model is used to extract key elements from the notes information and transform them into standardized semantic triples in the form of subject-verb-object according to a preset ontology structure. The preset ontology structure is a logistics-specific ontology, including three major categories: event, entity, and relation. The event category includes subcategories such as delay, detour, waiting to unload, waiting to load, forwarding, damaged goods, and loss. The entity category includes subcategories such as vehicle, driver, warehouse, customer, carrier, and goods. The relation category includes subcategories such as cause, occur, participate, location, and duration. By mining the business clues contained in the unstructured notes information, the implicit text information is transformed into computable structured data, providing evidence for subsequent causal analysis.
[0032] 205. Integrate the structured bill fields with the standardized semantic triples to construct preprocessed bill data; In this embodiment, the waybill number is used as a unique identifier to associate the extracted structured bill fields with the corresponding standardized semantic triples, thereby establishing a unified data view of the waybill dimension, i.e., preprocessed bill data, which realizes the organic integration of different types of data; and the preprocessed bill data is stored in a graph database to ensure that subsequent reconciliation and attribution analysis can be based on complete and consistent data.
[0033] Furthermore, such as Figure 3 As shown in this embodiment of the invention, the step of determining the original order node of the order to be settled based on the preprocessed billing data to match the contract pricing rules, and calculating the theoretical payable amount of the order to be settled according to the preprocessed billing data and the contract pricing rules, includes: 301. Extract the billing context features of the orders to be settled from the preprocessed billing data, and encode the billing context features into a billing context vector; In this embodiment, billing context features such as cargo weight, cargo volume, transportation route, transportation mode, cargo type, transportation time, and carrier name are extracted from preprocessed billing data. These features are concatenated into natural language text and then input into the Sentence-BERT model for encoding into a fixed-dimensional high-dimensional vector, resulting in a billing context vector. The pre-trained sentence encoder is the Sentence-BERT model, which is pre-trained based on general natural language corpora and then fine-tuned using professional corpora such as contract texts, billing texts, and customer service records from the logistics field. By transforming discrete billing context features into continuous vector representations, subsequent rapid matching of contract rules can be achieved through vector similarity calculation, improving the efficiency and flexibility of rule matching.
[0034] 302. Calculate the cosine similarity between the billing context vector and each high-dimensional vector in the pre-built contract rule vector library, and determine the contract pricing rules for the order to be settled based on the cosine similarity calculation results; In this embodiment, the pricing rule text in all effective contracts in the ERP system is pre-segmented into atomic conditions. The segmentation rule is to divide according to punctuation marks and logical connectors, and to break down complex compound rules into multiple independent atomic condition statements. Each atomic condition statement includes a judgment condition and a corresponding billing rule. For example, the rule that the first weight in Jiangsu, Zhejiang and Shanghai is 10 yuan and the additional weight is 5 yuan per kilogram, and that if the volume weight is greater than the actual weight, it is billed according to the volume weight, is split into three atomic conditions. Then, using the Sentence-BERT model from step 301, each atomic condition is encoded into a high-dimensional vector to construct a contract rule vector library. The system calculates the cosine similarity between the billing context vector and each vector in the vector library, and selects the contract rule with the highest similarity that exceeds a preset similarity threshold as the applicable pricing rule for the order. The preset similarity threshold is 0.8. By replacing traditional hard rule matching with vectorized similarity matching, the pricing rule applicable to the current order can be automatically identified without the need for manual configuration of a large number of rule conditions, thus reducing the system's maintenance costs.
[0035] 303. Based on the contract pricing rules and the billing base in the pre-processed billing data, calculate the theoretical payable amount for each expense item of the order to be settled; In this embodiment, the fee items include basic freight, remote area surcharge, overweight fee, waiting fee, forwarding fee, door-to-door delivery fee, insurance premium, and compensation payment. By parsing the selected contract pricing rules, the calculation logic and parameters of each fee item are extracted. Then, the corresponding billing base is obtained from the preprocessed billing data, and the calculation is performed item by item according to the calculation logic. For example, the basic freight equals the chargeable weight × the basic rate, and the overweight fee equals the overweight portion weight × the overweight rate. Since the calculation of the theoretical payable amount is adapted to the logistics pricing rules, it has the advantages of flexible calculation and high calculation accuracy, and provides an accurate benchmark for difference determination.
[0036] Furthermore, such as Figure 4 As shown in this embodiment of the invention, determining the difference threshold, based on the actual settlement amount, the theoretical payable amount, and the difference threshold, to determine whether the order to be settled is a settlement difference event includes: 401. Statistically analyze the amount difference data of all settlement orders within the preset historical period, and calculate the difference threshold corresponding to different expense items using the 3-Sigma principle; In this embodiment, the preset historical period is the past three months, that is, to collect the difference data between the actual amount and the theoretical amount of each expense item of all completed settlement orders in the past three months; calculate the mean and standard deviation of the difference data for each expense item, and use the mean ± three times the standard deviation as the difference threshold for the expense item according to the 3-Sigma principle. The difference threshold is different for different expense items. The system dynamically calculates the difference threshold based on the statistical characteristics of historical data, which can adapt to the difference distribution characteristics of different expense items, effectively filter business fluctuations within a reasonable range, and improve the scientific nature of difference determination.
[0037] 402. Compare the actual settlement amount of the order to be settled with the theoretical payable amount item by item, calculate the amount difference value and difference percentage of each expense item, and generate a multi-dimensional difference matrix; In this embodiment, the amount difference value = actual settlement amount of each expense item in the order to be settled - theoretical payable amount; the difference ratio = amount difference value ÷ theoretical payable amount; with the order as the row, the expense item as the column, and the amount difference value and the difference ratio as the elements, a multidimensional difference matrix is generated; by comparing each expense item, the specific expense item where the difference occurred can be accurately located, and the generated multidimensional difference matrix shows the full picture of the differences in the order, providing data support for subsequent analysis.
[0038] 403. For each expense item, if the amount difference exceeds the corresponding difference threshold and the difference ratio is greater than the preset ratio threshold, then the expense item is marked as an abnormal item. In this embodiment, for each expense item, it is simultaneously checked whether the amount difference exceeds the corresponding difference threshold and whether the difference percentage is greater than a preset percentage threshold, where the preset percentage threshold is 1 / 1000. Only when both conditions are met is the expense item marked as an abnormal item. If the amount difference is less than the corresponding difference threshold or the difference percentage is less than or equal to the preset percentage threshold, the expense item is marked as a normal item and does not proceed to the subsequent root cause analysis process. By using dual conditions to determine abnormal items, the probability of false positive differences is further reduced, ensuring that only significant differences with business significance can proceed to the subsequent root cause analysis stage.
[0039] 404. If an order pending settlement has at least one abnormal account, the order pending settlement is determined to be a settlement discrepancy event; In this embodiment, all expense items of the pending settlement order are traversed to check if there are any items marked as abnormal. If one or more abnormal items are found, the pending settlement order is determined to be a settlement discrepancy event, and the subsequent root cause analysis process is triggered. If the pending settlement order does not have any abnormal items, the order is determined to be a normal order and automatically passes the reconciliation process. This can promptly detect all pending settlement orders with significant abnormalities, avoiding omissions that may occur during manual screening.
[0040] Furthermore, such as Figure 5 As shown in this embodiment of the invention, the step of generating a graph probe based on the preprocessed billing data, and performing causal analysis based on the preprocessed billing data and the graph probe to generate preliminary root cause results of discrepancies in the orders to be settled, includes: 501. Extract the core features of settlement discrepancy events from preprocessed billing data to generate a discrepancy feature vector. The core features include the discrepancy amount, the abnormal expense item, the time of occurrence, the transportation route, and related semantic evidence. In this embodiment, the difference in amount is normalized and mapped to the range of 0 to 1; the abnormal expense item is one-hot encoded and converted into a numerical vector; the occurrence time is converted into a timestamp, and time features such as month, weekday, and whether it is a holiday are extracted; the transportation route is geocoded and converted into a latitude and longitude coordinate vector; the associated semantic evidence is encoded into a high-dimensional vector using the Sentence-BERT model; and the difference feature vector with a unified dimension is obtained by concatenating the above four vectors.
[0041] 502. Input the differential feature vector into the pre-trained classification model and output multiple preliminary root cause categories. The multiple preliminary root cause categories are used as graph probes to locate the corresponding subgraph entry in the pre-constructed settlement causal graph. In this embodiment, the pre-trained classification model is a three-layer multilayer perceptron model. The input layer dimension is the same as the dimension of the differential feature vector, the hidden layer dimension is 256, and the output layer dimension is the number of root cause categories. When training the classification model, historical differential event data confirmed manually over the past year are collected, and the corresponding root cause categories are labeled. The dataset is divided into training, validation, and test sets in a 7:2:1 ratio, and training is performed using the cross-entropy loss function and the Adam optimizer. During training, the hyperparameters are adjusted using the validation set, and training stops when the validation set accuracy no longer improves after 10 consecutive rounds. The trained classification model can output the top three preliminary root cause categories based on the input vector probability. These preliminary root cause categories serve as graph probes to locate the corresponding subgraph regions in the causal graph. That is, before searching, the pre-trained classification model narrows the search range of root causes, avoiding traversal of the entire causal graph and significantly improving the efficiency of root cause analysis.
[0042] 503. Invoke a pre-trained language model with external tool invocation capabilities to retrieve and verify cross-system data related to multiple preliminary root cause categories, and generate first evidence information; In this embodiment, the language model is based on a general large language model and fine-tuned using low-rank adaptation technology. The data used for fine-tuning includes settlement data, contract texts, customer service records, historical attribution cases, and tool call example datasets from the logistics field. Through fine-tuning, the language model is trained to understand logistics business terminology and logic, and learns to generate tool call instructions that meet the format requirements. The language model has the ability to call the contract query interface of the enterprise resource planning system, the order query interface of the transportation management system, the trajectory query interface of the global positioning system, the customer information query interface of the customer relationship management system, and the communication record query interface of the email system. Through language models, cross-system data related to multiple preliminary root cause categories are obtained. The relevant data includes all data related to the preliminary root cause category that can prove or refute the root cause. For example, if the root cause is that the fuel rate has not been updated, the relevant data includes the fuel rate adjustment rules agreed in the contract, the current official fuel price data, the fuel rate data used in the bill, etc. The first piece of evidence includes all real-time cross-system data obtained by the model through calling the aforementioned interface; by obtaining real-time external data, the rationality of the preliminary root cause can be verified, providing objective data support for root cause deduction.
[0043] 504. Parallel invocation of the pre-constructed settlement causal graph, and directional depth-first search based on the graph probe to generate second evidence information; In this embodiment, the pre-constructed settlement causal graph includes two types of elements: nodes and edges. Nodes include difference type nodes, root cause nodes, evidence nodes, entity nodes, etc., and edges include causal relationship edges, evidence relationship edges, association relationship edges, etc. For example, a fuel surcharge difference node may be connected to a contract rate not updated node through an edge, and a contract rate not updated node may be connected to an email communication record node through an evidence edge. Based on the subgraph entry point located by the graph probe, a directional depth-first search is performed to traverse all nodes and edges in the subgraph, collect information such as static business rules, historical cases, and causal relationships related to settlement discrepancy events, and generate secondary evidence information; by executing model reasoning and graph search in parallel, system resources are fully utilized and the total time for root cause analysis is shortened.
[0044] 505. Integrate the first evidence information and the second evidence information to generate preliminary root cause results of differences, wherein the preliminary root cause results of differences include root cause categories, evidence sources and logical deduction processes; In this embodiment, the first and second pieces of evidence are linked together according to time sequence and causal relationship. First, a root cause hypothesis is proposed, then the evidence supporting the hypothesis is listed in sequence, and finally the root cause conclusion is derived based on the evidence. For example, if the root cause is that the fuel rate has not been updated, the first piece of evidence is that the contract stipulates that the fuel rate is adjusted monthly with the official oil price, the second piece of evidence is that the official oil price has increased by 15% month-on-month, and the third piece of evidence is that the fuel rate used in the bill is the rate of the previous quarter. It can be deduced that the difference in fuel surcharge is caused by the carrier's failure to update the fuel rate in a timely manner. The integrated content was organized into preliminary root cause results, achieving an organic combination of dynamic real-time data and static business knowledge. The generated preliminary root cause results include a complete chain of evidence and deduction process, and have high interpretability.
[0045] Furthermore, such as Figure 6 As shown in this embodiment of the invention, the step of calling a pre-trained multi-view agent to perform cross-validation on the preliminary differential root cause results to determine the final attribution information includes: 601. Initialize three pre-trained agents with different perspectives: a financial compliance perspective agent, a field operation perspective agent, and a data system perspective agent. In this embodiment, all three agents are built on the same large language model fine-tuned for the logistics field, eliminating the need for separate training. Each agent is given a specific professional perspective by embedding different system prompts. Specifically, the system prompts for the financial compliance perspective agent include financial auditing standards, invoice management methods, and internal corporate financial regulations; the system prompts for the on-site operations perspective agent include logistics operation procedures, transportation scheduling rules, warehouse operation specifications, and abnormal situation handling procedures; and the system prompts for the data system perspective agent include enterprise system architecture, data flow processes, field mapping rules, common system problems, and solutions. By setting up agents with different perspectives, preliminary root cause results can be comprehensively reviewed from multiple dimensions, uncovering issues that might be overlooked from a single perspective.
[0046] 602. Input the preliminary root cause results of the differences into the three agents respectively to generate multiple inference branches; In this embodiment, the preliminary root cause results, along with the relevant first and second evidence information, are sent to three intelligent agents. Each intelligent agent, based on its own professional perspective and knowledge, performs logical reasoning on the preliminary root cause results, checks for any contradictions, missing evidence, or discrepancies with business logic, raises questions, and calls tools to obtain supplementary evidence, generating its own independent reasoning branch.
[0047] 603. Quantitatively evaluate the explanatory power of each inference branch, dynamically prune inference branches whose explanatory power is lower than the preset power threshold, and further verify the retained inference branches. In this embodiment, quantitative evaluation is implemented using a scoring model based on a large language model. The scoring model is also constructed based on a finely tuned large language model in the logistics field. The inputs are the root cause conclusions of the reasoning branch, the evidence list, and the logical deduction process. The scoring model scores from three dimensions: sufficiency of evidence, logical consistency, and business rationality, with weights of 0.3, 0.4, and 0.3 for each dimension, respectively. The weighted average score of the three dimensions is used as the explanatory power score of the reasoning branch. The preset strength threshold is 0.7. When the explanatory power score of a reasoning branch is lower than 0.7, the reasoning branch is automatically pruned, and multiple rounds of in-depth verification are performed on the retained reasoning branches. Through quantitative evaluation and dynamic pruning, computational resources can be concentrated on verifying the most valuable reasoning branches, improving the efficiency and relevance of the verification process.
[0048] 604. When the preset verification stopping condition is met, obtain the inference branch with the best explanatory power, and determine the root cause conclusion corresponding to the inference branch as the final attribution information; In this embodiment, the preset verification stopping condition is that the number of verification rounds reaches five or the score difference of all retained reasoning branches is less than 0.05. When the stopping condition is met, the verification process is terminated, and the root cause conclusion corresponding to the reasoning branch with the highest score is selected as the final attribution information.
[0049] Furthermore, such as Figure 7 As shown in this embodiment of the invention, after generating the settlement discrepancy alarm information based on the final attribution information and preprocessed billing data, the method further includes: 701. Obtain relevant data for all settlement discrepancy events within a preset historical settlement period to construct a standardized time-series dataset; In this embodiment, the historical settlement period is preset to the past two years. That is, the occurrence time, carrier, transportation route, difference amount, difference type, root cause category, and other relevant data of all settlement difference events in the past two years are obtained. The data is then cleaned, deduplicated, filled with missing values, and standardized. Then, the data is arranged in chronological order to construct a standardized time-series dataset.
[0050] 702. Based on the standardized time series dataset, the model pre-built based on the long short-term memory network is trained in multiple rounds to obtain a time series prediction model; In this embodiment, the structure of the time series prediction model built and trained based on the Long Short-Term Memory (LSTM) network includes an input layer, two LSM network layers, a Dropout layer, a fully connected layer, and an output layer connected sequentially. The input layer has a dimension equal to the historical time step multiplied by the feature dimension. The historical time step is set to 12 months, and the feature dimension includes carrier code, transportation route code, month, weekday, whether it is a holiday, the number of discrepancies in the past 12 months, and the total amount of discrepancies in the past 12 months. The output layer has a dimension of 2, outputting the probability of discrepancy events and the expected amount of discrepancies. When training a time series prediction model, the standardized time series dataset is divided into training, validation, and test sets in a 7:2:1 ratio. The regression part is trained using the mean squared error loss function, the classification part is trained using the binary cross-entropy loss function, and the Adam optimizer is used. Training is stopped early when the validation set loss no longer decreases after 10 consecutive rounds. The trained time series prediction model can capture long-term dependencies in time series to accurately predict the occurrence trend of future differential events.
[0051] 703. Obtain settlement data within the current settlement period, and input the settlement data into the time series prediction model to predict the probability and range of differential events for each carrier and each transportation route in the current settlement period; In this embodiment, the current settlement cycle is determined according to the company's settlement system, usually a calendar month, a calendar week, or a bi-weekly period; all settlement data within the current settlement cycle are acquired in real time, and features such as carriers, transportation routes, and time are extracted and input into a time series prediction model to obtain the probability of occurrence of difference events and the expected range of difference amounts for each carrier and each transportation route within the current settlement cycle.
[0052] 704. Based on the predicted probability and range of settlement discrepancy events, determine whether there is a risk of settlement discrepancy events occurring; In this embodiment, a risk assessment threshold is preset. When the probability of a discrepancy event occurring for a certain carrier or transportation route exceeds 80% and the expected discrepancy amount exceeds 10,000 yuan, it is determined that the carrier or transportation route has a risk of settlement discrepancy event occurring. If the aforementioned conditions are not met, it is determined that there is no significant risk. Through clear risk assessment criteria, high-risk objects that need to be focused on can be identified, avoiding the blindness of manual monitoring.
[0053] 705. If it is determined that there is a risk of a settlement discrepancy event, a settlement discrepancy risk warning message will be generated and pushed to the relevant management personnel; In this embodiment, when a risk of settlement discrepancy event is determined to exist, a risk warning information is generated, including the risk level, the carrier involved, the transportation route involved, the expected amount of the discrepancy, the historical discrepancy situation, and the suggested handling measures. This settlement discrepancy risk warning information is then pushed to relevant management personnel in the finance and operations departments via internal instant messaging tools or email. This achieves proactive early warning of settlement risks, helping enterprises to take measures in advance to prevent risks and reduce potential economic losses.
[0054] The settlement discrepancy event alarm method in the embodiments of the present invention has been described above. The settlement discrepancy event alarm device in the embodiments of the present invention will be described below. Please refer to [link / reference]. Figure 8 One embodiment of the settlement difference event alarm device in this invention includes: The parsing module 801 is used to obtain the multi-source settlement voucher data of the order to be settled, and to parse the file type and structure of each voucher included in the multi-source settlement voucher data; The construction module 802 is used to preprocess each voucher based on the file type and the degree of structure, and integrate the preprocessing results of each voucher to construct preprocessed billing data, wherein the preprocessed billing data includes the actual settlement amount of the order to be settled; The calculation module 803 is used to determine the original order node of the order to be settled based on the preprocessed bill data, so as to match the contract pricing rules, and calculate the theoretical payable amount of the order to be settled according to the preprocessed bill data and the contract pricing rules. The judgment module 804 is used to determine the difference threshold and, based on the actual settlement amount, the theoretical payable amount and the difference threshold, determine whether the order to be settled is a settlement difference event; The analysis module 805 is used to generate a graph probe based on the preprocessed billing data if the order to be settled is determined to be a settlement difference event, and to perform causal analysis based on the preprocessed billing data and the graph probe to generate preliminary root cause results of the difference in the order to be settled. The verification module 806 is used to call a pre-trained multi-view agent to cross-validate the preliminary root cause results of the differences in order to determine the final attribution information, and to generate settlement difference alarm information based on the final attribution information and pre-processed billing data.
[0055] Based on the same ideas as the methods in the above embodiments, the apparatus provided in this application can implement the methods in the above embodiments.
[0056] above Figure 8 The settlement discrepancy event alarm device in this embodiment of the invention is described in detail from the perspective of modular functional entities. The settlement discrepancy event alarm device in this embodiment of the invention is described in detail below from the perspective of hardware processing.
[0057] Figure 9 This is a schematic diagram of the structure of a settlement discrepancy event alarm device 900 provided in an embodiment of the present invention. The settlement discrepancy event alarm device 900 can vary significantly due to different configurations or performance. It may include one or more central processing units (CPUs) 910 and memory 920, and one or more storage media 930 (e.g., one or more mass storage devices) for storing application programs 933 or data 932. The memory 920 and storage media 930 can be temporary or persistent storage. The program stored in the storage media 930 may include one or more modules (not shown in the diagram), each module may include a series of instruction operations performed on the settlement discrepancy event alarm device 900. Furthermore, the processor 910 may be configured to communicate with the storage media 930 and execute a series of instruction operations in the storage media 930 on the settlement discrepancy event alarm device 900 to implement the steps of the settlement discrepancy event alarm method provided in the above-described method embodiments.
[0058] The settlement discrepancy event alarm device 900 may also include one or more power supplies 940, one or more wired or wireless network interfaces 950, one or more input / output interfaces 960, and / or one or more operating systems 931, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD, etc. Those skilled in the art will understand that... Figure 9 The structure of the settlement discrepancy event alarm device shown does not constitute a limitation on the settlement discrepancy event alarm device. It may include more or fewer components than shown, or combine certain components, or have different component arrangements.
[0059] The present invention also provides a computer-readable storage medium, which can be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium, wherein the computer-readable storage medium stores instructions that, when executed on a computer, cause the computer to perform the steps of a settlement difference event alarm method.
[0060] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the system, device or unit described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0061] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0062] Finally, it should be noted that the above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for alarming settlement discrepancy events, characterized in that, include: Obtain multi-source settlement voucher data for orders pending settlement, and parse the file type and structure of each voucher included in the multi-source settlement voucher data; Based on file type and degree of structure, each voucher is preprocessed separately, and the preprocessing results of each voucher are integrated to construct preprocessed billing data, which includes the actual settlement amount of the orders to be settled; Based on the pre-processed billing data, the original order node of the order to be settled is determined to match the contract pricing rules, and the theoretical payable amount of the order to be settled is calculated according to the pre-processed billing data and the contract pricing rules. Determine the difference threshold, and based on the actual settlement amount, the theoretical payable amount, and the difference threshold, determine whether the order to be settled is a settlement difference event; If the order to be settled is determined to be a settlement discrepancy event, a graph probe is generated based on the preprocessed billing data, and causal analysis is performed based on the preprocessed billing data and the graph probe to generate preliminary root cause results of the discrepancy in the order to be settled. The pre-trained multi-view agent is invoked to cross-validate the preliminary root cause results of the discrepancies in order to determine the final attribution information, and a settlement discrepancy alarm information is generated based on the final attribution information and the pre-processed billing data.
2. The settlement discrepancy event alarm method according to claim 1, characterized in that, Based on file type and level of structure, each voucher is preprocessed separately, and the preprocessing results of each voucher are integrated to construct preprocessed billing data, including: Based on the file type and degree of structuring of each voucher, vouchers are divided into structured spreadsheets, semi-structured documents, and unstructured images. If the voucher is a structured spreadsheet, the core billing fields are extracted through fuzzy matching of fields, and the core billing fields are processed by data type conversion, null value filling and outlier marking to obtain the structured billing fields; If the voucher is a semi-structured document or an unstructured image, a large visual model is used to perform multimodal document understanding on the voucher to extract text blocks with layout attributes and reorganize them into a continuous text stream, and then extract structured billing fields based on the continuous text stream. Unstructured remarks information is separated from the text content of all vouchers, and the elements of event type, participating subjects, time, location and impact are extracted and transformed into standardized semantic triples. The structured billing fields are integrated with standardized semantic triples to construct preprocessed billing data.
3. The settlement discrepancy event alarm method according to claim 1, characterized in that, The process of determining the original order node of the order to be settled based on the preprocessed billing data to match the contract pricing rules, and calculating the theoretical payable amount of the order to be settled according to the preprocessed billing data and the contract pricing rules, includes: The billing context features of the orders to be settled are extracted from the pre-processed billing data, and the billing context features are encoded into a billing context vector. Calculate the cosine similarity between the billing context vector and each high-dimensional vector in the pre-built contract rule vector library, and determine the contract pricing rules for the order to be settled based on the cosine similarity calculation results; Based on the contract pricing rules and the billing base in the pre-processed billing data, the theoretical payable amount for each order to be settled is calculated for each expense item.
4. The settlement discrepancy event alarm method according to claim 3, characterized in that, The determination of the difference threshold, based on the actual settlement amount, the theoretical payable amount, and the difference threshold, to determine whether the order to be settled is a settlement difference event includes: Collect statistical data on the amount differences of all settlement orders within a preset historical period, and calculate the difference thresholds corresponding to different expense items using the 3-Sigma principle; The actual settlement amount of the order to be settled is compared with the theoretical payable amount item by item, and the difference value and the difference percentage of each item are calculated to generate a multi-dimensional difference matrix. For each expense item, if the amount difference exceeds the corresponding difference threshold and the difference percentage is greater than the preset percentage threshold, then the expense item is marked as an abnormal item. If an order pending settlement has at least one abnormal item, the order pending settlement is determined to be a settlement discrepancy event.
5. The settlement discrepancy event alarm method according to claim 3, characterized in that, The process of generating a graph probe based on the preprocessed billing data, and performing causal analysis based on the preprocessed billing data and the graph probe to generate preliminary root cause results for discrepancies in orders pending settlement, includes: The core features of settlement discrepancy events are extracted from preprocessed billing data to generate a discrepancy feature vector. The core features include the discrepancy amount, the abnormal expense item, the time of occurrence, the transportation route, and related semantic evidence. The differential feature vector is input into the pre-trained classification model, which outputs multiple preliminary root cause categories. These multiple preliminary root cause categories serve as graph probes to locate the corresponding subgraph entry points in the pre-constructed settlement causal graph. A pre-trained language model with external tool invocation capability is invoked to retrieve and verify cross-system data related to multiple preliminary root cause categories, generating first evidence information; The pre-constructed settlement causal graph is invoked in parallel, and a directional depth-first search is performed based on the graph probe to generate second evidence information; By integrating the first and second evidence information, a preliminary root cause result of the difference is generated. The preliminary root cause result of the difference includes the root cause category, the source of evidence, and the logical deduction process.
6. The settlement discrepancy event alarm method according to claim 1, characterized in that, The step of calling a pre-trained multi-view agent to cross-validate the preliminary differential root cause results to determine the final attribution information includes: Initialize three pre-trained agents with different perspectives: a financial compliance perspective agent, an on-site operations perspective agent, and a data system perspective agent. The preliminary root cause results are input into the three agents respectively to generate multiple inference branches; The explanatory power of each inference branch is quantitatively evaluated, inference branches with explanatory power below a preset threshold are dynamically pruned, and the retained inference branches are further verified. When the preset verification stopping condition is met, the inference branch with the best explanatory power is obtained, and the root cause conclusion corresponding to the inference branch is determined as the final attribution information.
7. The settlement discrepancy event alarm method according to claim 1, characterized in that, After generating the settlement discrepancy alarm information based on the final attribution information and preprocessed billing data, the method further includes: Acquire relevant data for all settlement discrepancy events within a preset historical settlement period to construct a standardized time-series dataset; Based on the standardized time series dataset, the model pre-built based on the long short-term memory network is trained in multiple rounds to obtain a time series prediction model; Obtain settlement data for the current settlement period, and input the settlement data into the time series prediction model to predict the probability and range of differential events for each carrier and each transportation route in the current settlement period; Based on the predicted probability and range of settlement discrepancy events, determine whether there is a risk of settlement discrepancy events occurring. If a risk of a settlement discrepancy event is identified, a settlement discrepancy risk warning message will be generated and sent to the relevant management personnel.
8. A settlement discrepancy event alarm device, characterized in that, include: The parsing module is used to obtain multi-source settlement voucher data for orders to be settled, and to parse the file type and structure of each voucher included in the multi-source settlement voucher data; The construction module is used to preprocess each voucher based on its file type and level of structure, and integrate the preprocessing results of each voucher to construct preprocessed billing data, which includes the actual settlement amount of the order to be settled. The calculation module is used to determine the original order node of the order to be settled based on the preprocessed billing data, so as to match the contract pricing rules, and calculate the theoretical payable amount of the order to be settled according to the preprocessed billing data and the contract pricing rules. The judgment module is used to determine the difference threshold. Based on the actual settlement amount, the theoretical payable amount and the difference threshold, it determines whether the order to be settled is a settlement difference event. The analysis module is used to generate a graph probe based on the preprocessed billing data if the order to be settled is determined to be a settlement difference event, and to perform causal analysis based on the preprocessed billing data and the graph probe to generate preliminary root cause results of the difference in the order to be settled. The verification module is used to call a pre-trained multi-view agent to cross-validate the preliminary root cause results of the differences in order to determine the final attribution information, and generate settlement difference alarm information based on the final attribution information and pre-processed billing data.
9. A settlement discrepancy event alarm device, characterized in that, The settlement discrepancy event alarm device includes: a memory and at least one processor, wherein the memory stores instructions; At least one of the processors invokes the instructions in the memory to cause the settlement discrepancy event alarm device to perform the steps of the settlement discrepancy event alarm method as described in any one of claims 1-7.
10. A computer-readable storage medium storing instructions thereon, characterized in that, When the instructions are executed by the processor, they implement the steps of the settlement difference event alarm method as described in any one of claims 1-7.