Risk prediction method based on large language model and related product
By extracting key information from the company's original data through a large language model and performing vectorized processing, combined with a multi-factor analysis model, the problem of lengthy information collection and analysis in enterprise risk assessment is solved, and efficient and accurate risk prediction is achieved.
Patent Information
- Application Number
- CN202511026679.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-24
- Publication Date
- 2025-10-17
AI Technical Summary
The information collection and analysis process of existing technologies when assessing corporate risks is lengthy, time-consuming and labor-intensive, and information is not fully mined and utilized, resulting in insufficient accuracy in the final judgment.
A large language model is used to extract and process the company's original data, extract key information, and then vectorize it and input it into the multi-factor analysis model for risk prediction.
Through the semantic understanding and feature extraction capabilities of large language models, combined with quantitative analysis methods, the accuracy and efficiency of risk assessment are significantly improved, manual intervention is reduced, and error accumulation is avoided.
Smart Images

Figure CN120806650A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a risk prediction method based on a large language model and related products. Background Art
[0002] With the rapid development of information technology, a vast amount of information is now available about every company, including a wealth of information on each company's financial reports, stock price fluctuations, and organizational structure adjustments. Whether it's investment-related or loan-related, banks must conduct extensive data collection, analysis, and collation to develop a risk profile for each target company.
[0003] Currently, there are roughly four steps to determine whether a company has risks; Step 1: Information collection, collect as much information as possible related to the company, including but not limited to payments, income, financial reports, etc., as well as some information that the company has not disclosed to the public but is willing to provide to potential investors; Step 2: Classify the collected information, which can be roughly divided into two parts. The first part is numerical information, such as income and expenditure, financial reports, etc. Generally speaking, this part of the data is more important. The second part of the data is non-numerical information, such as the company's legal background, shareholder composition, organizational structure, etc.; Step 3: For the first part of the receipts collected in step 2, use existing technologies, including but not limited to statistical analysis, multi-factor analysis, logistic regression and other methods to perform numerical modeling, calculate the company's finances and development status, and provide a more objective data; Step 4: Relevant business personnel will analyze the objective data provided in step 3 and the second part of the data collected in step 2 to obtain risk prediction results.
[0004] However, in practice, these methods suffer from lengthy, time-consuming, and labor-intensive information collection and analysis processes, and the information obtained is not fully explored and utilized. The entire process involves significant manual effort and relies on multiple models to analyze data, which can easily lead to cumulative errors, affecting the accuracy of the final judgment. Therefore, current technical solutions for assessing enterprise risk still have significant room for improvement in terms of accuracy. Summary of the Invention
[0005] Based on the above problems, this application provides a risk prediction method and related products based on a large language model, aiming to improve the accuracy of risk prediction.
[0006] The embodiments of this application disclose the following technical solutions:
[0007] In a first aspect, the present application provides a risk prediction method based on a large language model, the risk prediction method based on a large language model comprising:
[0008] obtaining raw data of an enterprise;
[0009] performing extraction processing on the raw data by using a large language model to obtain key information;
[0010] performing vectorization processing on the key information to obtain a vector corresponding to the key information;
[0011] inputting the vector corresponding to the key information into a multi-factor analysis model to obtain a risk prediction result of the enterprise.
[0012] Optionally, the method further comprises:
[0013] obtaining a first training data set; the first training data set comprises historical data of an enterprise and key information corresponding to the historical data;
[0014] constructing a large language model;
[0015] taking the historical data of the enterprise in the first training data set as input of the large language model, taking the key information corresponding to the historical data in the first training data set as target output of the large language model, and performing fine-tuning training on parameters of the large language model with the purpose of minimizing a loss value.
[0016] Optionally, the vectorization processing on the key information to obtain a vector corresponding to the key information comprises:
[0017] performing vectorization processing on the key information by using a neural network model to obtain a vector corresponding to the key information; the neural network model comprises a plurality of two-layer fully connected neural networks.
[0018] Optionally, the inputting the vector corresponding to the key information into a multi-factor analysis model to obtain a risk prediction result of the enterprise comprises:
[0019] performing feature aggregation processing on the vector corresponding to the key information by using two-layer fully connected neural networks in the multi-factor analysis model to obtain a vector after feature aggregation processing;
[0020] performing high-order feature interaction and fusion on the vector after feature aggregation processing by using two self-attention layers in the multi-factor analysis model to obtain a vector after fusion processing;
[0021] performing processing on the vector after fusion processing by using two fully connected layers in the multi-factor analysis model to obtain a vector after connection processing;
[0022] performing risk prediction based on the vector after connection processing by using a fully connected layer in the multi-factor analysis model to obtain a risk prediction result corresponding to the enterprise.
[0023] Optionally, the method further comprises:
[0024] obtaining a second training data set; the second training data set comprises a vector corresponding to historical key information and a risk prediction result of the vector corresponding to the historical key information;
[0025] constructing a multi-factor analysis model;
[0026] taking the vector corresponding to the historical key information in the second training data set as the input of the multi-factor analysis model, taking the risk prediction result of the vector corresponding to the historical key information in the second training data set as the target output of the multi-factor analysis model, and fine-tuning the parameters of the multi-factor analysis model for the purpose of minimizing the loss value.
[0027] Optionally, the extracting processing of the original data by using the large language model to obtain the key information specifically comprises:
[0028] inputting the original data into the large language model to obtain the to-be-processed information corresponding to the original data;
[0029] if there is information missing in the to-be-processed information, supplementing data to the to-be-processed information to obtain the key information corresponding to the original data;
[0030] if there is no information missing in the to-be-processed information, taking the to-be-processed information corresponding to the original data as the key information corresponding to the original data and outputting.
[0031] The second aspect of the present application provides a risk prediction device based on a large language model, comprising:
[0032] an acquisition module configured to acquire original data of an enterprise;
[0033] an extraction module configured to extract and process the original data by using a large language model to obtain key information;
[0034] a vectorization processing module configured to perform vectorization processing on the key information to obtain a vector corresponding to the key information;
[0035] a prediction module configured to input the vector corresponding to the key information into a multi-factor analysis model to obtain a risk prediction result of the enterprise.
[0036] The third aspect of the present application provides a computer device, comprising 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 implement the risk prediction method based on a large language model provided in the first aspect.
[0037] The fourth aspect of the present application provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to realize the risk prediction method based on a large language model provided in the first aspect.
[0038] The fifth aspect of the present application provides a computer program product, which comprises a computer program, and the computer program is executed by a processor to realize the risk prediction method based on a large language model provided in the first aspect.
[0039] Compared with the prior art, the present application has the following beneficial effects:
[0040] The present application comprises obtaining original data of an enterprise; using a large language model to extract and process the original data to obtain key information; vectorizing the key information to obtain a vector corresponding to the key information; inputting the vector corresponding to the key information into a multi-factor analysis model to obtain a risk prediction result of the enterprise.
[0041] By obtaining the original data of the enterprise and using a large language model to extract information, the key features are accurately extracted; then the extracted key information is vectorized to have computable and comparable mathematical properties; finally, the vectorization result is input into a multi-factor analysis model to realize intelligent prediction of enterprise risk. This process fully utilizes the advantages of large language models in semantic understanding and feature extraction, and combines quantitative analysis methods to effectively improve the accuracy and efficiency of risk assessment. BRIEF DESCRIPTION OF DRAWINGS
[0042] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings needed in the embodiment or prior art description will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application, and those skilled in the art can also obtain other drawings according to these drawings without creative labor.
[0043] Figure 1 A flowchart of a risk prediction method based on a large language model provided by an embodiment of the present application;
[0044] Figure 2 A structural diagram of a risk prediction device based on a large language model provided by an embodiment of the present application. DETAILED DESCRIPTION
[0045] As described above, the current evaluation of whether a company is at risk can be divided into the following nine core steps: first, target and basic research: determine the risk assessment target (expected return, risk tolerance, liquidity demand), and collect basic information of the target company (business scope, market positioning, equity structure) and basic data of the industry (market size, policy orientation, competition pattern). Second, evaluate the core business model: analyze the income source, profit model and market competitiveness of products or services, judge the business moat and growth ceiling; disassemble the business structure: sort out the income proportion of main products / services, customer concentration, supplier bargaining power, and identify key business risk points. Third, analyze the financial statements of the past 3-5 years: focus on core indicators such as income growth rate, gross profit margin / net profit margin level, asset-liability ratio, and operating cash flow; compare with industry data: use tools such as Dupont analysis to evaluate the company's operational efficiency and profitability in the industry. Fourth, judge the industry life cycle: distinguish the industry from the start-up / growth / mature stage through market size, penetration rate, and technology iteration speed; identify policy and market risks: pay attention to the impact of external variables such as macroeconomic fluctuations, industrial policy adjustments, and international trade environment on the industry.
[0046] Fifth, evaluate the core team's ability: examine the management team's industry experience, strategic execution, and team stability; analyze the effectiveness of governance: check the rationality of equity structure, decision transparency, and standardization of related transactions. Sixth, build a financial forecasting model: use DCF, PE / PB, and other valuation tools to estimate the intrinsic value of the enterprise; stress test: simulate the return rate under different market environments and set a safety margin. Seventh, on-site investigation: visit the production / operation site, interview upstream and downstream customers and suppliers; document verification: verify the authenticity of key materials such as intellectual property rights, major contracts, and legal proceedings. Eighth, negotiate core terms: determine valuation gambling, priority liquidation rights, and board seats; investment decision: make a final investment decision through risk-reward ratio analysis. Ninth, establish a monitoring system: regularly track financial indicators, business progress, and the completion of the gambling clause; design exit path: choose IPO, merger and acquisition, or equity buyback as the exit method according to the growth stage of the enterprise.
[0047] The above technical solution has the problems of long and time-consuming information collection and analysis process in actual application, and the obtained information cannot be fully mined and utilized. A large number of manual participation is involved in the whole process, and multiple models are used to analyze the data, which is easy to cause error accumulation, thereby affecting the accuracy of the final judgment.
[0048] In view of the above problems, the present application provides a risk prediction generation method based on a large language model and related products. The method includes: obtaining original data of an enterprise; using a large language model to perform extraction processing on the original data to obtain key information; performing vectorization processing on the key information to obtain a vector corresponding to the key information; and inputting the vector corresponding to the key information into a multi-factor analysis model to obtain a risk prediction result of the enterprise. By obtaining original data related to the enterprise and using a large language model to deeply analyze the data content, efficient extraction and structured expression of key information are realized. Further, the extracted key information is subjected to vectorization processing to give it mathematical properties that can be operated and measured. Finally, the vectorized information is input into a multi-factor analysis model to intelligently evaluate and predict potential risks of the enterprise. This method fully integrates the powerful capabilities of large language models in semantic modeling and feature recognition, and combines a quantitative analysis framework to significantly improve the accuracy and efficiency of risk assessment.
[0049] Related professional terms are explained as follows:
[0050] DuPont analysis: decomposes return on equity (ROE) into net profit margin, asset turnover, and equity multiplier to comprehensively evaluate a company's profitability, operational efficiency, and financial leverage risk.
[0051] Human annotation: Human annotation refers to the process of labeling or categorizing data by human experts. It is a common method for creating training sets in the field of machine learning, especially in supervised learning. Through human annotation, algorithms can learn to recognize patterns and make predictions. For example, in an image recognition task, workers may manually label pictures to describe their content.
[0052] Neural network model: A neural network model is a type of artificial intelligence algorithm inspired by the biological nervous system. It consists of a large number of simple processing units (nodes or "neurons") connected to form a hierarchical structure. Each connection has a weight parameter that can be adjusted to change the behavior of the model. Neural networks are particularly good at handling nonlinear problems and are widely used in image recognition, speech recognition, natural language processing, and other fields.
[0053] Model training: Model training is a key step in machine learning, which involves providing a set of known input and output data (i.e., training set) to the model so that the model can learn the relationship between input and output. In this process, the model will continuously adjust its internal parameters (such as weights in neural networks) to minimize prediction errors. After sufficient training, the model should theoretically be able to make accurate predictions or classifications on new data it has not seen before.
[0054] Fine-tuning: Fine-tuning refers to the process of further training an already trained model (usually a large pre-trained model) for a specific task. This process typically involves using a smaller learning rate and a smaller dataset, with the goal of enabling the model to better adapt to the specific task or domain while retaining the general features and knowledge learned from the original large-scale data. Fine-tuning is a form of transfer learning and is widely used in natural language processing, computer vision, and other fields. Through fine-tuning, the performance of the model on a specific task can be improved without training the model from scratch.
[0055] In order to enable those skilled in the art to better understand the technical solutions of the present application, the technical solutions in the embodiments of the present application will be described clearly and completely below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, not all. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor fall within the scope of protection of the present application.
[0056] Figure 1 A flowchart of a risk prediction method based on a large language model provided by an embodiment of the present application is shown in FIG. 1. As shown in FIG. 1, a risk prediction method based on a large language model includes: Figure 1
[0057] S101: Obtain the original data of an enterprise.
[0058] Scrape the relevant text information of the enterprise from public channels (such as the business system, Credit China, the Judgment Documents Network, news media, the official website of the enterprise, etc.); including but not limited to the basic information of the enterprise (business scope, market positioning, equity structure), financial reports, administrative penalty records, litigation information, industry dynamics (market size, policy orientation, competition pattern), public opinion information, etc.; the data forms include structured data (such as tables), unstructured text (such as web pages, PDFs), etc.; automatic data collection can be realized by combining API interfaces, web crawlers, database imports, etc. For example, collect the information of a certain enterprise in the past three years, such as annual reports, litigation records, news reports, etc., to form text data containing thousands of words.
[0059] S102: Use a large language model to extract and process the original data to obtain key information.
[0060] Taking an open-source large language model (such as ChatGLM, LLaMA, BERT, etc.) as a base model, then using relevant data, the model is fine-tuned and trained, and through fine-tuning training, the large language model extracts key information such as "asset-liability ratio", "net profit growth rate", "whether there is a major administrative penalty", "whether there is a major contract dispute", etc. For example, after analyzing the annual report of a certain enterprise, the key information "net profit: 120 million yuan", "debt ratio: 58%", "major contract: none" is extracted. The key information extracted in this application can be divided into two parts, one is the regular factor, and the other is the special factor; for example, the number of employees, the number of shareholders, and the registered capital all belong to the regular factor, and every company has these contents, but the founder of the company belongs to the special factor, because every company is basically different.
[0061] With the powerful semantic understanding ability of the large language model, key information is automatically extracted from unstructured and semi-structured enterprise raw data, reducing manual intervention and improving the completeness and accuracy of information extraction.
[0062] S103: Vectorizing the key information to obtain a vector corresponding to the key information.
[0063] Numerical indicators (such as revenue, profit, debt ratio, etc.) are directly used as numerical features; text information (such as penalty description, public opinion keywords, etc.) is vectorized using a word embedding model (such as Word2Vec, BERT); classification information (such as industry type, enterprise nature) is One-Hot encoded or embedded; all feature vectors are concatenated or weighted and fused to form a unified feature vector for subsequent modeling. For example, "asset-liability ratio: 58%" is used as a numerical feature, and "involvement in litigation: no major contract dispute" is encoded into a 768-dimensional vector using a BERT model, and the final input vector is formed after concatenation. By vectorizing the key information, the text semantics are converted into a computable numerical form, facilitating subsequent model quantitative analysis and comparison.
[0064] S104: Inputting the vector corresponding to the key information into a multi-factor analysis model to obtain a risk prediction result of the enterprise.
[0065] A multi-factor analysis model can be constructed using machine learning models (such as XGBoost, LightGBM, and random forest) or deep learning models (such as DNN and Transformer); input features include enterprise financial status, legal risk, public opinion risk, industry fluctuations, and other dimensions; the output is a risk score or risk level (such as high, medium, and low); model training data can be derived from historical enterprise samples and their actual risk event records; and the model supports explainable analysis (such as SHAP values and feature importance ranking) to improve the credibility of the evaluation results. For example, after inputting the feature vector, the model outputs a risk score of 0.72 (out of 1.0) for the enterprise, determining it as a "medium-high risk" and recommending cautious investment.
[0066] The present application greatly saves manpower costs, and after data collection is completed, there is no need to rely on various professional personnel for manual analysis of different types of data; at the same time, information is more fully utilized, even seemingly unstructured information (such as enterprise-related news) without obvious characteristics can be effectively mined and quantitatively utilized; the final output conclusion is more objective and stable, avoiding subjective bias caused by differences in business personnel capabilities, and improving the consistency and reliability of the evaluation results.
[0067] The above is the main technical solution of the present application, and the expansion implementation of the main technical solution of the present application will be introduced. Specifically as follows:
[0068] For the training process of the large language model, the present application provides an optional embodiment:
[0069] Obtain a first training data set; the first training data set includes historical data of an enterprise and key information corresponding to the historical data.
[0070] The first training data set can be obtained from public channels (such as the business system, credit China, judgment documents network, news media, and enterprise official website, etc.), and the data in the first training data set should not be less than 20,000.
[0071] Construct a large language model.
[0072] The large language model is composed of 550 two-layer fully connected neural networks, each neural network has 100 nodes in the first layer and 20 nodes in the second layer, which means that each category of information has 100 possible value taking methods, and each specific value is represented by a 20-dimensional vector.
[0073] The historical data of the enterprise in the first training data set is used as the input of the large language model, and the key information corresponding to the historical data in the first training data set is used as the target output of the large language model, and the parameters of the large language model are fine-tuned for the purpose of minimizing the loss value.
[0074] In a specific application, the large language model can also be fine-tuned with the number of training iterations as the target. For example, the historical data of the enterprise in the first training data set is input into the large language model, the key information corresponding to the historical data in the first training data set is taken as the target output of the large language model, and the parameters of the large language model are fine-tuned for 10 epochs. One epoch means that all simulation data pass through the model once.
[0075] The above detailed discussion of the training process of the large language model enables the large language model to accurately extract key information. After extracting the key information, the risk prediction result needs to be determined based on the key information. However, considering that there can be multiple representations (text form and numerical form) in the key information, the present application proposes to perform vectorization processing on the key information. The present application provides an optional embodiment of performing vectorization processing on the key information in S103 to obtain a vector corresponding to the key information.
[0076] The key information is vectorized using a neural network model to obtain a vector corresponding to the key information. The neural network model includes a plurality of two-layer fully connected neural networks.
[0077] By introducing a neural network model composed of a plurality of two-layer fully connected neural networks, the key information is vectorized, and text, classification, or semi-structured information that is originally difficult to directly use for modeling analysis is converted into a unified dimension and has semantic expression ability. For example, suppose a certain enterprise needs to be evaluated for risk, and its key information includes: "asset-liability ratio: 65%" (numerical type); "company profile: technology company, main business artificial intelligence" (text type); "industry: information technology" (category type); "change in revenue over the past three years: +12%, +8%, +5%" (time series).
[0078] Four two-layer fully connected sub-networks are constructed for the above information, and the respective corresponding vector representations are output, and finally spliced into a unified feature vector: [0.32, -0.15, 0.78,..., 0.44].
[0079] The two-layer fully connected neural network can perform nonlinear transformation and high-order feature combination on the original features, enhance the semantic richness and discrimination of the vector representation, and thus improve the accuracy of subsequent model prediction. For key information of different modalities or sources (such as financial data, text description, classification label, etc.), independent two-layer fully connected networks are constructed for encoding, which can ensure independent modeling of information and unified representation. Through unified dimensional vectorization output, different sources and types of information have comparability and fusibility in subsequent models, improving the generalization performance of the overall system.
[0080] The vector corresponding to the key information is input into the multi-factor analysis model for S104 to obtain the risk prediction result of the enterprise, and the application provides an optional embodiment:
[0081] The two-layer fully connected neural network in the multi-factor analysis model is used for feature aggregation processing on the vector corresponding to the key information to obtain a vector after feature aggregation processing.
[0082] The node number of the first layer of the two-layer fully connected neural network in the multi-factor analysis model is 550, corresponding to 550 networks of the large language model, and the input of each node is a 20-dimensional vector. The node number of the second layer of the two-layer fully connected neural network in the multi-factor analysis model is still 550, which converts the 20-dimensional vector of each node into 128 dimensions.
[0083] The two self-attention layers in the multi-factor analysis model are used for high-order feature interaction and fusion on the vector after feature aggregation processing to obtain a vector after fusion processing.
[0084] The left and right of the two self-attention layers in the multi-factor analysis model are 550 features (the vector after feature aggregation processing) input by the two-layer fully connected neural network for high-order feature interaction and fusion, and finally a 550*128-dimensional vector (the vector after fusion processing) is obtained.
[0085] The two fully connected layers in the multi-factor analysis model are used for processing the vector after fusion processing to obtain a vector after connection processing.
[0086] The node number of the first layer of the two fully connected layers in the multi-factor analysis model is 550*128, and the node number of the second layer of the two fully connected layers in the multi-factor analysis model is 10240.
[0087] The fully connected layer in the multi-factor analysis model is used for risk prediction based on the vector after connection processing to obtain the risk prediction result corresponding to the enterprise.
[0088] The full connection layer in the multi-factor analysis model includes a first branch and a second branch; the first branch and the second branch are each a three-layer full connection neural network; the three-layer node numbers of the first branch are 10240, 2048 and 1 respectively, and the output value of the last node is between 0 and 1, indicating the probability that the current input data label is 1, and the higher the probability is, the better; the three-layer node numbers of the second branch are 10240, 2048 and 10 respectively, and the output value of each node is between 0 and 1, and the node number of the level corresponding to 10% to 100% is 10, and each node indicates how much the individual category information of the current input data label is retained, for example, the output value of the node corresponding to 10% is 0.8, so that the model considers that the individual category information of the input data retains a 10% probability of 0.8, and the maximum one is selected from the 10 probabilities.
[0089] By adopting the two-layer full connection neural network in the multi-factor analysis model to perform feature aggregation processing on the vectors corresponding to the key information, the 550 20-dimensional input feature vectors from the large language model are effectively integrated, and the feature dimension is maintained through the first layer and is increased to 128 dimensions through the second layer, thereby enhancing the feature expression capability; then, two self-attention layers are used to perform high-order feature interaction and fusion on the 550 128-dimensional vectors after feature aggregation, fully mining the complex correlation between different features, and outputting a fusion vector with stronger semantic expression capability; then, two full connection layers are used to perform nonlinear transformation and compression on the 550 128-dimensional vectors after fusion, and finally output 10240-dimensional intermediate representation; finally, risk prediction is performed based on the representation, and an intelligent evaluation result of enterprise risk is generated. The advantages of feature aggregation, high-order interaction and deep modeling are fully combined, which significantly improves the accuracy of risk prediction and the generalization ability of the model, and provides efficient and reliable data support for investment decision-making.
[0090] The present application provides an optional embodiment for the training process of the multi-factor analysis model.
[0091] A second training data set is obtained; the second training data set includes vectors corresponding to historical key information and risk prediction results of the vectors corresponding to the historical key information.
[0092] A large number of enterprise risk assessment cases of the bank or other banks are collected, and the case content includes enterprise related information, risk prediction results (for example, if the risk prediction result is high, it indicates that the enterprise has certain risk, and investment is not recommended; if the risk prediction result is low, it indicates that the risk of the enterprise is low, and investment can be made, and if investment is made, the investment return can be used as a judgment standard for the accuracy of the risk prediction result), and as much information as possible about the subsequent development of the enterprise. On this basis, the common type information of all cases is integrated to determine the common type information category, such as “registered capital”, which is a common type information, but each company is different, and the common information category can be determined to be about 500. Then, the individual information category is determined, such as the founder, which is an individual type information, although each company has it, but the influence of the founder on the development of the company is almost decisive, and the individual information category is determined to be about 50. Then, for each case, the vector of the key information of each enterprise (the content of the common information category and the content of the individual information category) is sorted out, and each enterprise is labeled (risk prediction result) based on the vector of the key information of each enterprise.
[0093] A multi-factor analysis model is constructed.
[0094] The vector corresponding to the historical key information in the second training data set is taken as the input of the multi-factor analysis model, and the risk prediction result of the vector corresponding to the historical key information in the second training data set is taken as the target output of the multi-factor analysis model, and the parameters of the multi-factor analysis model are fine-tuned to minimize the loss value.
[0095] In specific application, the multi-factor analysis model can also be fine-tuned for training, for example, the vector corresponding to the historical key information in the second training data set is taken as the input of the multi-factor analysis model, and the risk prediction result of the vector corresponding to the historical key information in the second training data set is taken as the target output of the multi-factor analysis model, and the parameters of the multi-factor analysis model are fine-tuned for 20 epochs.
[0096] To ensure the accuracy of the output data of the multi-factor analysis model, new case data can also be accumulated continuously, and when the accumulated data reaches a certain degree, such as 5000, the accumulated new data is used to fine-tune the parameters of the multi-factor analysis model.
[0097] A large language model is used to extract and process the original data to obtain key information for S102, and the application provides an optional embodiment:
[0098] The original data is input into the large language model to obtain the to-be-processed information corresponding to the original data.
[0099] If there is information missing in the to-be-processed information, data supplement is performed on the to-be-processed information to obtain the key information corresponding to the original data.
[0100] The output field is subjected to integrity check. If some key fields (such as "registered capital", "asset-liability ratio", "revenue growth rate", "industry classification", etc.) are empty, "unknown" or do not conform to the preset format, it is determined that there is information missing; the missing part can be replaced by a conventional value or an average value. For example, by analyzing the historical data of the enterprise and the industry trend, the "revenue growth rate" is supplemented to be "8%".
[0101] If there is no information missing in the to-be-processed information, the to-be-processed information corresponding to the original data is output as the key information corresponding to the original data.
[0102] By judging whether the to-be-processed information is missing and intelligently supplementing in the case of missing, the evaluation deviation caused by incomplete information is effectively avoided, and the completeness and accuracy of the key information are improved. The entire process can be completed from end to end extraction and processing of original data to key information without manual intervention, significantly improving the information processing efficiency.
[0103] The present application automatically extracts key information from unstructured and semi-structured enterprise raw data with the powerful semantic understanding ability of the large language model, reduces manual intervention, and improves the completeness and accuracy of information extraction. By vectorizing the key information, the text semantics are converted into a computable numerical form, which facilitates subsequent quantitative analysis and comparison by the model. The multi-factor analysis model is used to comprehensively evaluate the vectorized features, considering multiple factors such as enterprise finance, public opinion, law, industry environment, etc., to output risk prediction results, providing a scientific basis for investment decisions. The entire process is highly automated, reducing subjective bias caused by human judgment, and avoiding evaluation errors caused by insufficient information utilization and inaccurate feature expression in traditional methods.
[0104] Figure 2 The structure diagram of a risk prediction device based on a large language model provided by an embodiment of the present application is shown in Figure 2 According to the risk prediction method based on a large language model provided in the foregoing embodiments, the present application also correspondingly provides a risk prediction device based on a large language model, which includes:
[0105] The acquisition module is configured to acquire the raw data of the enterprise.
[0106] The extraction module is configured to extract and process the raw data by using a large language model to obtain key information.
[0107] The vectorization processing module is configured to vectorize the key information to obtain a vector corresponding to the key information.
[0108] a prediction module configured to input the vector corresponding to the key information into a multi-factor analysis model to obtain a risk prediction result of the enterprise.
[0109] As an optional embodiment, the device further comprises:
[0110] a first training data set determination module configured to obtain a first training data set. The first training data set comprises historical data of an enterprise and key information corresponding to the historical data.
[0111] a first construction module configured to construct a large language model.
[0112] a first training module configured to take the historical data of the enterprise in the first training data set as an input of the large language model, take the key information corresponding to the historical data in the first training data set as a target output of the large language model, and perform fine-tuning training on parameters of the large language model with the purpose of minimizing a loss value.
[0113] As an optional embodiment, the vectorization processing module is specifically configured to:
[0114] perform vectorization processing on the key information by using a neural network model to obtain a vector corresponding to the key information. The neural network model comprises a plurality of two-layer fully connected neural networks.
[0115] As an optional embodiment, the prediction module specifically comprises:
[0116] a feature aggregation unit configured to perform feature aggregation processing on the vector corresponding to the key information by using two-layer fully connected neural networks in the multi-factor analysis model to obtain a vector after feature aggregation processing.
[0117] a fusion unit configured to perform high-order feature interaction and fusion on the vector after feature aggregation processing by using two self-attention layers in the multi-factor analysis model to obtain a vector after fusion processing.
[0118] a connection unit configured to perform processing on the vector after fusion processing by using two fully connected layers in the multi-factor analysis model to obtain a vector after connection processing.
[0119] a prediction unit configured to perform risk prediction based on the vector after connection processing by using a fully connected layer in the multi-factor analysis model to obtain a risk prediction result corresponding to the enterprise.
[0120] As an optional embodiment, the device further comprises:
[0121] The second training data set determination module is configured to obtain a second training data set. The second training data set comprises a vector corresponding to historical key information and a risk prediction result of the vector corresponding to the historical key information.
[0122] The second construction module is configured to construct a multi-factor analysis model.
[0123] The second training module is configured to take the vector corresponding to the historical key information in the second training data set as an input of the multi-factor analysis model, take the risk prediction result of the vector corresponding to the historical key information in the second training data set as a target output of the multi-factor analysis model, and fine-tune parameters of the multi-factor analysis model for the purpose of minimizing a loss value.
[0124] As an optional embodiment, the extraction module specifically comprises:
[0125] The extraction unit is configured to input the original data into the large language model to obtain the to-be-processed information corresponding to the original data.
[0126] The first judgment unit is configured to, if there is information missing in the to-be-processed information, perform data supplement on the to-be-processed information to obtain the key information corresponding to the original data.
[0127] The second judgment unit is configured to, if there is no information missing in the to-be-processed information, output the to-be-processed information corresponding to the original data as the key information corresponding to the original data.
[0128] Embodiments of the present application provide a computer device, comprising 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 implement the risk prediction method based on the large language model.
[0129] Embodiments of the present application provide a computer readable storage medium having a computer program stored thereon, wherein the computer program is executed by a processor to implement the risk prediction method based on the large language model.
[0130] Embodiments of the present application provide a computer program product comprising a computer program, wherein the computer program is executed by a processor to implement the risk prediction method based on the large language model.
[0131] It should be noted that each of the embodiments of the present specification is described in a progressive manner, and the same or similar parts between each embodiment can be understood by referring to each other, and each embodiment focuses on the difference from other embodiments. In particular, for the device and equipment embodiments, since they are basically similar to the method embodiments, they are described more simply, and the relevant parts can be understood by referring to the part of the method embodiment. The above-described device and equipment embodiments are only illustrative, and the units described as separate components can or can not be physically separated, and the components indicated as units can or can not be physical units, that is, they can be located in one place, or they can be distributed on multiple network units. Part or all of the modules can be selected to achieve the purpose of the embodiments of the present application according to actual needs. Those skilled in the art can understand and implement it without creative labor.
[0132] The above is only one specific embodiment of the present application, but the protection scope of the present application is not limited to this. Any skilled person in the art can easily think of changes or replacements within the technical scope disclosed in the present application, which should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
Claims
1. A risk prediction method based on a large language model, characterized in that: The risk prediction method based on the large language model includes: Obtaining the original data of the enterprise; Using a large language model to extract and process the raw data to obtain key information; Performing vectorization processing on the key information to obtain a vector corresponding to the key information; The vector corresponding to the key information is input into the multi-factor analysis model to obtain the risk prediction result of the enterprise.
2. The risk prediction method based on a large language model according to claim 1, characterized in that: The method further comprises: Obtain a first training data set; the first training data set includes historical data of the enterprise and key information corresponding to the historical data; Build a large language model; The historical data of the enterprises in the first training data set is used as the input of the large language model, and the key information corresponding to the historical data in the first training data set is used as the target output of the large language model. The parameters of the large language model are fine-tuned with the purpose of minimizing the loss value.
3. The risk prediction method based on a large language model according to claim 1, characterized in that: The vectorization processing of the key information to obtain a vector corresponding to the key information specifically includes: A neural network model is used to vectorize the key information to obtain a vector corresponding to the key information; the neural network model includes multiple two-layer fully connected neural networks.
4. The risk prediction method based on a large language model according to claim 1, characterized in that: Inputting the vector corresponding to the key information into the multi-factor analysis model to obtain the risk prediction result of the enterprise specifically includes: Using a two-layer fully connected neural network in the multi-factor analysis model to perform feature aggregation processing on the vector corresponding to the key information to obtain a vector after feature aggregation processing; Using two self-attention layers in the multi-factor analysis model to perform high-order feature interaction and fusion on the vector after the feature aggregation process to obtain a fused vector; Processing the fused vector using two fully connected layers in the multi-factor analysis model to obtain a connected vector; The fully connected layer in the multi-factor analysis model is used to perform risk prediction based on the connected vector to obtain a risk prediction result corresponding to the enterprise.
5. The risk prediction method based on a large language model according to claim 1, characterized in that: The method further comprises: Acquire a second training data set; the second training data set includes a vector corresponding to the historical key information and a risk prediction result of the vector corresponding to the historical key information; Construct a multi-factor analysis model; The vector corresponding to the historical key information in the second training data set is used as the input of the multi-factor analysis model, and the risk prediction result of the vector corresponding to the historical key information in the second training data set is used as the target output of the multi-factor analysis model. The parameters of the multi-factor analysis model are fine-tuned with the purpose of minimizing the loss value.
6. The risk prediction method based on a large language model according to claim 1, characterized in that: The large language model is used to extract and process the original data to obtain key information, specifically including: Inputting the original data into the large language model to obtain information to be processed corresponding to the original data; If there is any missing information in the information to be processed, the information to be processed is supplemented to obtain key information corresponding to the original data; If there is no missing information in the information to be processed, the information to be processed corresponding to the original data is output as the key information corresponding to the original data.
7. A risk prediction device based on a large language model, characterized in that: The risk prediction device based on the large language model includes: Acquisition module, used to obtain the original data of the enterprise; An extraction module, configured to extract the raw data using a large language model to obtain key information; A vectorization processing module, configured to perform vectorization processing on the key information to obtain a vector corresponding to the key information; The prediction module is used to input the vector corresponding to the key information into the multi-factor analysis model to obtain the risk prediction result of the enterprise.
8. A computer device comprising: 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 implement the risk prediction method based on a large language model according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the risk prediction method based on a large language model according to any one of claims 1 to 6 is implemented.
10. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the risk prediction method based on a large language model according to any one of claims 1 to 6 is implemented.