A method and system for generating conversational software functions based on a large language model

Through the conversational software function generation method based on large language models, natural language processing and machine learning algorithms are used to optimize software function design, solve the problems of complexity and high cost of traditional software function design, and achieve efficient and accurate software function development. , reducing reliance on developer skills.

CN118276826BActive Publication Date: 2024-10-22天衣(北京)科技有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410286141.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-03-13
Publication Date
2024-10-22
Estimated Expiration
2044-03-13

AI Technical Summary

Technical Problem

The design and implementation of traditional software functions are costly, workload-intensive, and complex. They rely on the experience and skills of developers and are difficult to complete efficiently.

Method used

A conversational software function generation method based on a large language model is adopted. By building a large language model and a software function analysis model, natural language processing and machine learning algorithms are used to optimize software function description and analysis, reduce manual design complexity, and improve development efficiency.

Benefits of technology

It reduces the complexity and cost of software function design, improves development efficiency and the accuracy of demand analysis, reduces dependence on developer experience and skills, and is highly versatile and practical.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118276826B_ABST
    Figure CN118276826B_ABST
Patent Text Reader

Abstract

The present invention belongs to the technical field of software development, and discloses a method and system for generating conversational software functions based on a large language model. The method comprises the following steps: constructing a corresponding large language model and a software function analysis model; inputting a user's software function requirement statement into the large language model, performing a software function description, and obtaining a corresponding initial software function description statement; inputting the initial software function description statement into the software function analysis model, performing software function analysis, and obtaining a corresponding software function analysis result; optimizing the large language model according to the software function analysis result, and obtaining a corresponding optimized large language model; inputting the software function requirement statement into the optimized large language model, performing a secondary software function description, and obtaining a corresponding optimized software function description statement, and returning it to the corresponding user. The present invention solves the problems of high cost investment, large workload, and complex development in the prior art.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of software development, and in particular relates to a method and system for generating conversational software functions based on a large language model. Background Art

[0002] With the rapid development of computer technology, software development has become an indispensable part of modern society. In the software development process, the design and implementation of software functions are key steps. Traditionally, the design and implementation of software functions often rely on the experience and skills of developers, which is not only time-consuming and labor-intensive, but also costly and labor-intensive, and prone to errors. In addition, when designing software functions, software engineers often need to spend a lot of time understanding and analyzing user needs, which further increases the complexity and cost of software function development.

[0003] In recent years, natural language processing technology, especially large language models, has made significant progress in the field of artificial intelligence. Large language models are trained with large amounts of data to understand and generate natural language texts, and have strong language understanding and generation capabilities. These technological advances provide new ideas and methods for software function generation. Summary of the invention

[0004] In order to solve the problems of high cost investment, heavy workload and complex development in the prior art, the present invention aims to provide a method and system for generating conversational software functions based on a large language model.

[0005] The technical solution adopted by the present invention is:

[0006] A method for generating conversational software functions based on a large language model comprises the following steps:

[0007] According to the local software function component library and software function corpus, build the corresponding large language model and software function analysis model;

[0008] Input the user's software function requirement statement into the large language model, perform a software function description, and obtain the corresponding initial software function description statement;

[0009] Inputting the initial software function description statement into the software function analysis model, performing software function analysis, and obtaining corresponding software function analysis results;

[0010] According to the software function analysis results, the large language model is optimized to obtain the corresponding optimized large language model;

[0011] The software function requirement statement is input into the optimized large language model, and a secondary software function description is performed to obtain the corresponding optimized software function description statement, and the optimized software function description statement is returned to the corresponding user.

[0012] Furthermore, according to the local software function component library and software function corpus, a corresponding large language model and software function analysis model are constructed, including the following steps:

[0013] Based on the local software function component library and software function corpus, use the natural language processing algorithm to build the corresponding large language model;

[0014] Based on the local software function component library, use machine learning algorithms to build the corresponding software function analysis model.

[0015] Furthermore, according to the local software function component library and software function corpus, a corresponding large language model is constructed using a natural language processing algorithm, including the following steps:

[0016] Obtaining existing software function vectors corresponding to several existing software function components in a local software function component library;

[0017] Generate corresponding software function dialogue samples according to a number of existing software function vectors and a number of software function corpora in a software function corpus;

[0018] Based on several software function dialogue samples, the Transformer algorithm of the natural language processing algorithm is used to perform optimization training and build a corresponding large language model.

[0019] Furthermore, according to the local software function component library, a corresponding software function analysis model is constructed using a machine learning algorithm, including the following steps:

[0020] Acquire software project data corresponding to each existing software functional component in the local software functional component library;

[0021] Combining the software project data with the corresponding existing software functional components to obtain a number of corresponding software functional description samples;

[0022] According to the preset software function analysis key dimensions, labels are added to each software function description sample to obtain a number of corresponding software function analysis samples with real software function analysis labels;

[0023] According to several software function analysis samples, the FCM clustering algorithm of the machine learning algorithm is used to perform optimization training and build the corresponding software function analysis model.

[0024] Furthermore, the software project data includes software function documentation, software function test cases, user application scope, and software function performance description;

[0025] The key dimensions of preset software function analysis include software function completeness, software function performance indicators and software function safety indicators.

[0026] Furthermore, according to several software function analysis samples, the FCM clustering algorithm of the machine learning algorithm is used to perform optimization training and construct a corresponding software function analysis model, including the following steps:

[0027] Construct the objective function of the FCM clustering algorithm, and take each software function analysis sample as a data point to obtain a number of corresponding data points;

[0028] Obtaining an initial training membership matrix of several data points, clustering the several data points according to the initial training membership matrix, and obtaining corresponding several initial clustering centers;

[0029] According to the initial training membership matrix, the Lagrange multiplier method is used to obtain the corresponding merge function value and change value;

[0030] If the merge function value is greater than the merge function value threshold, or the change value is greater than the change value threshold, the initial cluster center and the initial training membership matrix are iteratively updated to obtain an updated cluster center and an updated training membership matrix, and then proceed to the next step; otherwise, proceed to the next step;

[0031] If the objective function converges or the number of iterations reaches the iteration threshold, the current cluster center and the current training membership matrix are used as the final cluster center and the final training membership matrix;

[0032] According to the Euclidean distance between each data point and several final cluster centers, several data points are divided to obtain the cluster clusters corresponding to each final cluster center;

[0033] The actual software function analysis label of the final cluster center is used as the predicted software function analysis label of all data points in the corresponding cluster cluster;

[0034] The prediction accuracy is obtained based on the predicted software function analysis label and the corresponding real software function analysis label of each data point;

[0035] If the prediction accuracy is greater than the accuracy threshold, the corresponding software function analysis model is output, otherwise, the optimization training continues.

[0036] Furthermore, the user's software function requirement statement is input into the large language model to perform a software function description to obtain a corresponding initial software function description statement, including the following steps:

[0037] Collecting the user's software function requirement statements and inputting the user's software function requirement statements into the software function description model;

[0038] Using the software function description model, extracting several required software function vectors in the software function requirement statement;

[0039] According to a number of required software function vectors, a search is performed in a local software function component library, and matching existing software function components are used as corresponding required software function components;

[0040] If there is no matching existing software function component in the local software function component library, assemble the software function components according to a number of required software function vectors to obtain the corresponding newly added software function component;

[0041] According to a number of required software function vectors and corresponding required / newly added software function components, corresponding initial software function description statements are generated according to a preset software function description template.

[0042] Furthermore, the initial software function description statement is input into the software function analysis model to perform software function analysis to obtain corresponding software function analysis results, including the following steps:

[0043] Inputting the initial software function description statement into the software function analysis model to obtain the real-time membership matrix of the initial software function description statement and a number of cluster centers;

[0044] Classify the initial software function description statements into the real-time membership matrix, and match the cluster center with the highest real-time membership;

[0045] Using the actual software function analysis label of the corresponding matching cluster center as the predicted software function analysis label of the initial software function description statement;

[0046] The predicted software function analysis label is output as the software function analysis result.

[0047] Furthermore, the large language model is optimized using a reinforcement learning algorithm. Specifically, according to the software function analysis result, the large language model is optimized using a reinforcement learning algorithm to obtain a corresponding optimized large language model, including the following steps:

[0048] If the software function analysis results meet the preset output requirements, the reward function of the reinforcement learning algorithm is defined according to the real-time membership matrix corresponding to the software function analysis results;

[0049] Analyze key dimensions according to preset software functions, optimize the reward function of the reinforcement learning algorithm, and obtain the corresponding optimized reward function;

[0050] According to the optimized reward function, adjust the policy gradient of the reinforcement learning algorithm to obtain the corresponding adjusted policy gradient;

[0051] According to the adjusted policy gradient, the policy parameters of the reinforcement learning algorithm are updated to obtain the corresponding updated policy parameters;

[0052] According to the optimized reward function, adjusted policy gradient and updated policy parameters, the reinforcement learning algorithm is used to optimize the generation strategy rules of the large language model to obtain the corresponding optimized large language model.

[0053] A conversational software function generation system based on a large language model, used to implement a software function generation method, the system includes a model building unit, a primary software function description unit, a software function analysis unit, a large language model optimization unit and a secondary software function description unit connected in sequence;

[0054] A model building unit, used to build a corresponding large language model and software function analysis model based on a local software function component library and a software function corpus;

[0055] A primary software function description unit is used to input the user's software function requirement statement into the large language model, perform a software function description, and obtain a corresponding initial software function description statement;

[0056] A software function analysis unit, used to input the initial software function description statement into the software function analysis model, perform software function analysis, and obtain corresponding software function analysis results;

[0057] A large language model optimization unit is used to optimize the large language model according to the software function analysis results to obtain the corresponding optimized large language model;

[0058] The secondary software function description unit is used to input the software function requirement statement into the optimized large language model, perform secondary software function description, obtain the corresponding optimized software function description statement, and return the optimized software function description statement to the corresponding user.

[0059] The beneficial effects of the present invention are:

[0060] The present invention discloses a method and system for generating conversational software functions based on a large language model. The large language model is used to generate software functions, which reduces the complexity of manually designing software functions, improves the efficiency of software function development, and reduces investment costs and workload. Through dialogue with the large language model, users can express software function requirements more intuitively and accurately, thereby improving the accuracy of demand analysis. The proposed conversational software function generation reduces the dependence on the experience and skills of developers, and can be applied to a variety of software fields, with high versatility and practicality. The software function analysis model is used to accurately analyze software function description statements, thereby improving user experience. The large language model is optimized through reinforcement learning, thereby improving the accuracy and efficiency of software function generation.

[0061] Other beneficial effects of the present invention will be further described in the specific embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0062] Figure 1 It is a flowchart of the method for generating conversational software functions based on a large language model in the present invention.

[0063] Figure 2 It is a structural block diagram of the conversational software function generation system based on the large language model in the present invention. DETAILED DESCRIPTION

[0064] The present invention will be further explained below in conjunction with the accompanying drawings and specific embodiments.

[0065] Embodiment 1:

[0066] like Figure 1 As shown, this embodiment provides a method for generating a conversational software function based on a large language model, comprising the following steps:

[0067] S1: Based on the local software function component library and software function corpus, build the corresponding large language model and software function analysis model, including the following steps:

[0068] S1-1: Based on the local software function component library and software function corpus, use the natural language processing algorithm to build the corresponding large language model, including the following steps:

[0069] S1-1-1: Obtain existing software function vectors corresponding to several existing software function components in the local software function component library;

[0070] S1-1-2: Generate corresponding software function dialogue samples according to several existing software function vectors and several software function corpora in the software function corpus;

[0071] S1-1-3: Based on several software function dialogue samples, use the Transformer algorithm of the natural language processing algorithm to perform optimization training and build the corresponding large language model;

[0072] The Transformer model is a large language model based on the Transformer architecture. It is an important progress in the field of natural language processing. The Transformer model is powerful because it introduces the Self-Attention Mechanism, which allows the model to consider any position in the sequence when processing sequence data, thereby capturing long-distance dependencies. This is a major improvement compared to previous models such as recurrent neural networks and convolutional neural networks.

[0073] The Transformer model usually has the following characteristics: Self-attention mechanism: The Transformer model can process all elements in the input sequence at the same time and calculate the correlation between them through the self-attention mechanism, which enables the model to capture long-distance dependencies in the input sequence; Multi-head attention: The multi-head attention mechanism in the Transformer model allows the model to process different parts of the input sequence in parallel, thereby improving the computational efficiency and performance of the model; Position encoding: Since the Transformer model itself does not have the ability to process sequence order, position encoding is required to provide the model with information about the position of elements in the sequence; Feedforward neural network: After the self-attention mechanism of the Transformer model, a feedforward neural network is usually connected, which can further nonlinearly transform the output of the self-attention mechanism; Hierarchical representation: The Transformer model can process input sequences at different levels through hierarchical representation, thereby improving the performance and flexibility of the model;

[0074] S1-2: Based on the local software function component library, use machine learning algorithms to build the corresponding software function analysis model, including the following steps:

[0075] S1-2-1: Obtain software project data corresponding to each existing software functional component in the local software functional component library;

[0076] Software project data includes software function documentation, software function test cases, user application scope, and software function performance description;

[0077] S1-2-2: Combine the software project data and the corresponding existing software functional components to obtain several corresponding software functional description samples;

[0078] S1-2-3: according to the preset software function analysis key dimensions, label each software function description sample to obtain a number of corresponding software function analysis samples with real software function analysis labels;

[0079] The key dimensions of preset software function analysis include software function completeness, software function performance indicators and software function safety indicators;

[0080] S1-2-4: Based on several software function analysis samples, the Fuzzy C-Means (FCM) clustering algorithm of the machine learning algorithm is used to perform optimization training and build a corresponding software function analysis model, including the following steps:

[0081] S1-2-4-1: Construct the objective function of the FCM clustering algorithm, and take each software function analysis sample as a data point to obtain a number of corresponding data points;

[0082] S1-2-4-2: Obtain an initial training membership matrix of several data points, cluster the several data points according to the initial training membership matrix, and obtain corresponding initial clustering centers;

[0083] S1-2-4-3: According to the initial training membership matrix, use the Lagrange multiplier method to obtain the corresponding merge function value and change value;

[0084] The formula is:

[0085]

[0086] ΔJ t =J t -J t-1

[0087] In the formula, J t , J t-1 is the combined function value at time t and t-1; ΔJ t is the change value; i is the eigenvalue of the i-th data point; d ij is the distance from the i-th data point to the j-th current cluster center; u ij is the current membership of the i-th data point to the j-th cluster center, forming the training membership matrix U; α is a hyperparameter; m is the total number of data; c is the total number of cluster centers; j is the cluster center indicator; i is the data point indicator;

[0088] S1-2-4-4: If the merge function value is greater than the merge function value threshold, or the change value is greater than the change value threshold, the initial cluster center and the initial training membership matrix are iteratively updated to obtain updated cluster centers and updated training membership matrix, and proceed to the next step; otherwise, proceed to the next step;

[0089] S1-2-4-5: If the objective function converges or the number of iterations reaches the iteration threshold, the current cluster center and the current training membership matrix are used as the final cluster center and the final training membership matrix; otherwise, the merge function value and the change value are updated, and the previous step is returned;

[0090] The formula is:

[0091]

[0092] In the formula, is the updated membership of the i-th data point to the j-th cluster center; d ij ,d ik is the distance from the i-th data point to the j-th and k-th updated cluster centers; k is the cluster center indicator;

[0093]

[0094] In the formula, z j is the jth updated cluster center; x i is the i-th data point; The updated membership of the i-th data point to the j-th cluster center constitutes the training membership matrix

[0095] S1-2-4-6: Divide the data points according to the Euclidean distance between each data point and the final cluster centers, and obtain the clusters corresponding to each final cluster center;

[0096] S1-2-4-7: The actual software function analysis label of the final cluster center is used as the predicted software function analysis label of all data points in the corresponding cluster cluster;

[0097] S1-2-4-8: Obtain prediction accuracy based on the predicted software function analysis label and the corresponding real software function analysis label of each data point;

[0098] S1-2-4-9: If the prediction accuracy is greater than the accuracy threshold, the corresponding software function analysis model is output, otherwise, optimization training continues;

[0099] S2: Input the user's software function requirement statement into the large language model, perform a software function description, and obtain the corresponding initial software function description statement, including the following steps:

[0100] S2-1: Collect the user's software function requirement statements and input the user's software function requirement statements into the software function description model; for example, the user may input: "I hope to develop a software that can help me manage my schedule.";

[0101] S2-2: Use the software function description model to extract several required software function vectors in the software function requirement statement;

[0102] S2-3: searching the local software function component library according to the required software function vectors, and taking the matching existing software function components as the corresponding required software function components;

[0103] S2-4: If there is no matching existing software function component in the local software function component library, assemble the software function components according to a number of required software function vectors to obtain the corresponding new software function component;

[0104] S2-5: Generate the corresponding initial software function description statement according to the preset software function description template based on the several required software function vectors and the corresponding required / newly added software function components; the large language model can generate the following software function description statement: "Based on the schedule information input by the user, the software can automatically remind the user of upcoming events and provide functions such as editing and deleting schedules. The software function document of the software includes XXX, the software function test cases include XXX, the user application scope includes XXX, and the software function performance description includes XXX.";

[0105] S3: Inputting the initial software function description statement into the software function analysis model, performing software function analysis, and obtaining corresponding software function analysis results, including the following steps:

[0106] S3-1: Inputting the initial software function description statement into the software function analysis model to obtain the real-time membership matrix of the initial software function description statement and a number of cluster centers;

[0107] S3-2: Classify the initial software function description statements into the real-time membership matrix, and match the cluster center with the highest real-time membership;

[0108] S3-3: using the real software function analysis label of the corresponding matching cluster center as the predicted software function analysis label of the initial software function description statement;

[0109] S3-4: outputting the predicted software function analysis label as a software function analysis result;

[0110] S4: According to the software function analysis results, the large language model is optimized using a reinforcement learning algorithm to obtain the corresponding optimized large language model, including the following steps:

[0111] S4-1: If the software function analysis result meets the preset output requirements, the reward function of the reinforcement learning algorithm is defined according to the real-time membership matrix corresponding to the software function analysis result;

[0112] Reinforcement learning is a machine learning method that optimizes behavior through a reward system. In the context of software function generation, a reward function can be defined based on the results of software function analysis. When the quality of the generated software function is high, a positive reward is given, and when the quality is low, a negative reward is given. The large language model can adjust its generation strategy based on these rewards, thereby optimizing its output during the learning process.

[0113] The formula is:

[0114]

[0115] In the formula, is the reward function; is the real-time membership matrix; μ max is the maximum membership value between the software function description statement f and the jth cluster center; f is the software function description statement indicator; j' is the cluster center indicator;

[0116] S4-2: Analyze the key dimensions according to the preset software functions, optimize the reward function of the reinforcement learning algorithm, and obtain the corresponding optimized reward function;

[0117] The key dimensions of preset software function analysis include software function completeness, software function performance indicators and software function safety indicators;

[0118] The formula is:

[0119]

[0120] In the formula, is the optimized reward function; μ max is the maximum membership value between the software function description statement f and the jth cluster center; I completeness ,I performance ,I security They are software function completeness, software function performance index and software function safety index respectively; ω1, ω2, ω3, ω4 and ω5 are all weight coefficients; is the real-time membership matrix The average value of

[0121] S4-3: According to the optimized reward function, adjust the policy gradient of the reinforcement learning algorithm to obtain the corresponding adjusted policy gradient;

[0122] The formula is:

[0123]

[0124] In the formula, is the adjusted policy gradient; For strategy The gradient parameter of are the strategy parameters θ t and strategy action a t Gradient logo of s t is the state; t is the indicator of the number of iterations; T is the total number of iterations; is the optimized reward function;

[0125] S4-4: Update the policy parameters of the reinforcement learning algorithm according to the adjusted policy gradient to obtain the corresponding updated policy parameters;

[0126] The formula is:

[0127]

[0128] In the formula, θ t+1 ,θ t They are the strategy parameters before and after updating respectively; is the adjusted policy gradient;

[0129] S4-5: Based on the optimized reward function, the adjusted policy gradient, and the updated policy parameters, the reinforcement learning algorithm is used to optimize the generation policy rules of the large language model to obtain the corresponding optimized large language model;

[0130] S5: Input the software function requirement statement into the optimized large language model, perform secondary software function description, obtain the corresponding optimized software function description statement, and return the optimized software function description statement to the corresponding user.

[0131] Embodiment 2:

[0132] like Figure 2 As shown, this embodiment provides a conversational software function generation system based on a large language model, which is used to implement a software function generation method. The system includes a model building unit, a primary software function description unit, a software function analysis unit, a large language model optimization unit, and a secondary software function description unit connected in sequence;

[0133] A model building unit, used to build a corresponding large language model and software function analysis model based on a local software function component library and a software function corpus;

[0134] A primary software function description unit is used to input the user's software function requirement statement into the large language model, perform a software function description, and obtain a corresponding initial software function description statement;

[0135] A software function analysis unit, used to input the initial software function description statement into the software function analysis model, perform software function analysis, and obtain corresponding software function analysis results;

[0136] A large language model optimization unit is used to optimize the large language model according to the software function analysis results to obtain the corresponding optimized large language model;

[0137] The secondary software function description unit is used to input the software function requirement statement into the optimized large language model, perform secondary software function description, obtain the corresponding optimized software function description statement, and return the optimized software function description statement to the corresponding user.

[0138] The present invention discloses a method and system for generating conversational software functions based on a large language model. The large language model is used to generate software functions, which reduces the complexity of manually designing software functions, improves the efficiency of software function development, and reduces investment costs and workload. Through dialogue with the large language model, users can express software function requirements more intuitively and accurately, thereby improving the accuracy of demand analysis. The proposed conversational software function generation reduces the dependence on the experience and skills of developers, and can be applied to a variety of software fields, with high versatility and practicality. The software function analysis model is used to accurately analyze software function description statements, thereby improving user experience. The large language model is optimized through reinforcement learning, thereby improving the accuracy and efficiency of software function generation.

[0139] The present invention is not limited to the above optional implementations, and anyone can derive other various forms of products under the enlightenment of the present invention. The above specific implementations should not be understood as limiting the scope of protection of the present invention. The scope of protection of the present invention should be based on the definition in the claims, and the description can be used to interpret the claims.

Claims

1. A method for generating conversational software functions based on a large language model, characterized in that: The steps include: According to the local software function component library and software function corpus, the corresponding large language model and software function analysis model are constructed, including the following steps: Based on the local software function component library and software function corpus, use the natural language processing algorithm to build the corresponding large language model, including the following steps: Obtaining existing software function vectors corresponding to several existing software function components in a local software function component library; Generate corresponding software function dialogue samples according to a number of existing software function vectors and a number of software function corpora in a software function corpus; Based on several software function dialogue samples, the Transformer algorithm of the natural language processing algorithm is used to perform optimization training and build a corresponding large language model; According to the local software function component library, use machine learning algorithms to build the corresponding software function analysis model, including the following steps: Obtaining software project data corresponding to each existing software functional component in the local software functional component library; Combining the software project data with the corresponding existing software functional components to obtain a number of corresponding software functional description samples; According to the preset software function analysis key dimensions, labels are added to each software function description sample to obtain a number of corresponding software function analysis samples with real software function analysis labels; According to several software function analysis samples, the FCM clustering algorithm of the machine learning algorithm is used to perform optimization training and build the corresponding software function analysis model; Input the user's software function requirement statement into the large language model, perform a software function description, and obtain the corresponding initial software function description statement; Inputting the initial software function description statement into the software function analysis model, performing software function analysis, and obtaining corresponding software function analysis results; According to the software function analysis results, the large language model is optimized to obtain the corresponding optimized large language model; The software function requirement statement is input into the optimized large language model, and a secondary software function description is performed to obtain the corresponding optimized software function description statement, and the optimized software function description statement is returned to the corresponding user.

2. The method for generating conversational software functions based on a large language model according to claim 1, characterized in that: The software project data includes software function documentation, software function test cases, user application scope and software function performance description; The preset software function analysis key dimensions include software function completeness, software function performance indicators and software function safety indicators.

3. The method for generating conversational software functions based on a large language model according to claim 1, characterized in that: According to several software function analysis samples, the FCM clustering algorithm of the machine learning algorithm is used for optimization training to build the corresponding software function analysis model, including the following steps: Construct the objective function of the FCM clustering algorithm, and take each software function analysis sample as a data point to obtain a number of corresponding data points; Obtaining an initial training membership matrix of a number of data points, clustering the data points according to the initial training membership matrix, and obtaining a number of corresponding initial cluster centers; According to the initial training membership matrix, the Lagrange multiplier method is used to obtain the corresponding merge function value and change value; If the merge function value is greater than the merge function value threshold, or the change value is greater than the change value threshold, the initial cluster center and the initial training membership matrix are iteratively updated to obtain an updated cluster center and an updated training membership matrix, and then proceed to the next step; otherwise, proceed to the next step; If the objective function converges or the number of iterations reaches the iteration threshold, the current cluster center and the current training membership matrix are used as the final cluster center and the final training membership matrix; According to the Euclidean distance between each data point and several final cluster centers, several data points are divided to obtain the cluster clusters corresponding to each final cluster center; The actual software function analysis label of the final cluster center is used as the predicted software function analysis label of all data points in the corresponding cluster cluster; The prediction accuracy is obtained based on the predicted software function analysis label and the corresponding real software function analysis label of each data point; If the prediction accuracy is greater than the accuracy threshold, the corresponding software function analysis model is output, otherwise, the optimization training continues.

4. The method for generating conversational software functions based on a large language model according to claim 2, characterized in that: Input the user's software function requirement statement into the large language model, perform a software function description, and obtain the corresponding initial software function description statement, including the following steps: Collecting the user's software function requirement statements and inputting the user's software function requirement statements into the software function description model; Using the software function description model, extracting several required software function vectors in the software function requirement statement; According to a number of required software function vectors, a search is performed in a local software function component library, and matching existing software function components are used as corresponding required software function components; If there is no matching existing software function component in the local software function component library, assemble the software function components according to a number of required software function vectors to obtain the corresponding newly added software function component; According to a number of required software function vectors and corresponding required / newly added software function components, corresponding initial software function description statements are generated according to a preset software function description template.

5. The method for generating conversational software functions based on a large language model according to claim 3, characterized in that: Inputting the initial software function description statement into the software function analysis model, performing software function analysis, and obtaining corresponding software function analysis results, includes the following steps: Inputting the initial software function description statement into the software function analysis model to obtain the real-time membership matrix of the initial software function description statement and a number of cluster centers; Classify the initial software function description statements into the real-time membership matrix, and match the cluster center with the highest real-time membership; Using the actual software function analysis label of the corresponding matching cluster center as the predicted software function analysis label of the initial software function description statement; The predicted software function analysis label is output as the software function analysis result.

6. The method for generating conversational software functions based on a large language model according to claim 4, characterized in that: The large language model is optimized using a reinforcement learning algorithm. Specifically, according to the software function analysis results, the large language model is optimized using a reinforcement learning algorithm to obtain a corresponding optimized large language model, including the following steps: If the software function analysis results meet the preset output requirements, the reward function of the reinforcement learning algorithm is defined according to the real-time membership matrix corresponding to the software function analysis results; Analyze key dimensions according to preset software functions, optimize the reward function of the reinforcement learning algorithm, and obtain the corresponding optimized reward function; According to the optimized reward function, adjust the policy gradient of the reinforcement learning algorithm to obtain the corresponding adjusted policy gradient; According to the adjusted policy gradient, the policy parameters of the reinforcement learning algorithm are updated to obtain the corresponding updated policy parameters; According to the optimized reward function, adjusted policy gradient and updated policy parameters, the reinforcement learning algorithm is used to optimize the generation strategy rules of the large language model to obtain the corresponding optimized large language model.

7. A conversational software function generation system based on a large language model, used to implement the software function generation method according to any one of claims 1 to 6, characterized in that: The system comprises a model building unit, a primary software function description unit, a software function analysis unit, a large language model optimization unit and a secondary software function description unit which are connected in sequence; A model building unit, used to build a corresponding large language model and software function analysis model based on a local software function component library and a software function corpus; A primary software function description unit is used to input the user's software function requirement statement into the large language model, perform a software function description, and obtain a corresponding initial software function description statement; A software function analysis unit, used to input the initial software function description statement into the software function analysis model, perform software function analysis, and obtain corresponding software function analysis results; A large language model optimization unit is used to optimize the large language model according to the software function analysis results to obtain the corresponding optimized large language model; The secondary software function description unit is used to input the software function requirement statement into the optimized large language model, perform secondary software function description, obtain the corresponding optimized software function description statement, and return the optimized software function description statement to the corresponding user.