A business application automatic construction method based on AI semantic analysis

By segmenting and semantically encoding the business requirement text input by the user, and using a multi-level semantic parsing network to identify business intent and functional entities, and combining it with a component knowledge base for matching and topology construction, the problem of insufficient understanding of business requirements in existing technologies is solved, and the automated construction and efficient generation of business applications are realized.

CN122132092APending Publication Date: 2026-06-02JIANGSU BEE GRP TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
JIANGSU BEE GRP TECH CO LTD
Filing Date
2026-01-15
Publication Date
2026-06-02

AI Technical Summary

Technical Problem

Existing low-code or no-code platforms struggle to achieve deep semantic understanding of users' business requirements in natural language during the application building process. This results in incomplete business logic expression, insufficient component matching accuracy, and a lack of automatic organization of business function dependencies, limiting the intelligence and scalability of automatic application building.

Method used

By acquiring the business requirement description text input by the user, performing word segmentation and stop word filtering, extracting semantic feature vectors using a pre-trained semantic encoding model, and combining it with a multi-level semantic parsing network to identify business intent, functional entities and their dependencies, and performing cosine similarity matching with the component knowledge base to construct the component topology structure, and finally generating the business application package.

Benefits of technology

It achieves automated mapping from natural language requirements to executable application structures, improves the accuracy of business intent recognition and component matching precision, ensures the automation, seamless integration and stability of the application building process, shortens the development cycle and reduces manual intervention.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122132092A_ABST
    Figure CN122132092A_ABST
Patent Text Reader

Abstract

This invention discloses an automatic business application construction method based on AI semantic analysis, belonging to the field of artificial intelligence semantic analysis and automatic software application generation technology. The method includes: acquiring user-input business requirement description text, performing word segmentation and stop word filtering to form a requirement word sequence; inputting the requirement word sequence into a pre-trained semantic encoding model to generate semantic feature vectors; extracting business intent tags, functional entity sets, and dependency triples; performing similarity matching between the business intent tags and functional entities and component semantic vectors in a component knowledge base to determine the main control component and functional components; constructing a functional component call relationship graph and generating a component topology structure according to topological sorting; and calling an application building engine to instantiate each component sequentially according to the component topology structure, outputting a business application package. This invention enables automatic mapping of business requirements to application structures, reduces manual configuration, and improves the intelligence and consistency of business application construction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence semantic analysis and automatic software application construction technology, and in particular to an automatic construction method for business applications based on AI semantic analysis. Background Technology

[0002] With the increasing demands for digital transformation and agile delivery of business systems, low-code and no-code development models are gradually becoming an important development direction in the field of business application construction. These technologies aim to reduce the technical barriers between business personnel and developers by abstracting business logic, encapsulating components, and automating orchestration mechanisms, enabling rapid mapping of business requirements to application systems. However, in practical applications, existing low-code or no-code platforms still heavily rely on manual configuration, rule templates, or visual drag-and-drop methods for business modeling. The understanding of business requirements often remains at the level of structured fields or pre-set forms, making it difficult to perform deep semantic modeling and intent recognition of natural language-based business descriptions. This leads to problems such as incomplete business logic expression, insufficient component matching accuracy, and fragmented system construction processes. Especially in complex business scenarios, there are explicit or implicit dependencies between business functions. Existing technologies generally lack the ability to systematically parse and automatically organize business semantics, functional entities, and their calling relationships, limiting the intelligence and scalability of automated business application construction.

[0003] CN120144107B discloses a zero-code, multi-platform application automatic construction method based on AI semantic understanding. This method receives user-uploaded UI design draft images and layer metadata, utilizes a dual-branch feature extractor to extract visual and structural features, and combines a cross-modal attention mechanism to generate UI component masks and interaction dependency graphs. It then maps UI components to target platform controls and generates corresponding code, thereby achieving automated construction of multi-platform applications. While this technology has advantages in UI-level component recognition and cross-platform adaptation, its semantic understanding process mainly revolves around interface structure and interaction relationships, relying on existing design draft input. It does not semantically encode or model the user's natural language business requirements, making it difficult to directly extract business objectives, functional entities, and their dependencies from business description text. Therefore, it still has significant shortcomings in the automated mapping capability "from business semantics to application structure."

[0004] CN118194877B discloses a semantic analysis method based on a large AI model. This method improves the accuracy of semantic understanding by constructing a scene triangular region, a multi-level feature extraction layer, and a semantic fusion model to perform multi-level semantic analysis on target sentences. This technology demonstrates good technical performance in terms of semantic analysis accuracy and semantic matching capability, and is suitable for text understanding and semantic optimization scenarios. However, this solution focuses on the analysis and matching of the semantic content itself, without further applying the semantic analysis results to the business system construction process. It also does not address the issues of component selection, function mapping, and component topology generation based on the semantic analysis results. Therefore, it lacks an engineering implementation path for automatically building scenarios for business applications, making it difficult to support the automatic generation and deployment of business applications.

[0005] In summary, existing technologies based on no-code or semantic analysis generally suffer from problems such as a disconnect between semantic understanding of business requirements and the application construction process, reliance on manual rules for functional component matching, and a lack of automatic organization mechanisms for business function dependencies. This invention provides an automated business application construction method based on AI semantic analysis. Utilizing a pre-trained semantic encoding model and a multi-level semantic parsing network, it automatically extracts business intent tags, functional entity sets, and dependency triples from business requirement description text. Combined with a component knowledge base, it completes semantic matching and topological assembly of components, achieving automated construction and output of business applications. This method effectively solves the problem that natural language business requirements are difficult to directly translate into executable application structures. Summary of the Invention

[0006] The purpose of this section is to outline some aspects of the embodiments of the present invention and to briefly introduce some preferred embodiments. Some simplifications or omissions may be made in this section, as well as in the abstract and title of the present application, to avoid obscuring the purpose of this section, the abstract and the title of the invention. Such simplifications or omissions shall not be used to limit the scope of the present invention.

[0007] Given that existing low-code or no-code application building technologies generally rely on manual rule configuration, template mapping, or interface-driven methods to complete business modeling, it is difficult to perform deep semantic understanding and structured parsing of business requirements described by users in natural language. This leads to inaccurate business intent recognition, reliance on manual intervention for functional component matching, and difficulty in automatically organizing the dependencies between business functions, which in turn restricts the degree of automation and system consistency in the business application building process. Therefore, this invention is proposed.

[0008] Therefore, the problem to be solved by this invention is how to perform contextual semantic modeling on business requirement description text through AI semantic analysis technology, automatically identify business intent, functional entities and their dependencies, and on this basis realize intelligent matching, topological assembly and application instantiation of business functional components, thereby realizing the automatic, efficient and low-human-involvement construction of business applications.

[0009] To solve the above-mentioned technical problems, the present invention provides the following technical solution: In a first aspect, embodiments of the present invention provide a method for automatically constructing business applications based on AI semantic analysis, comprising, Obtain the business requirement description text input by the user, and perform word segmentation and stop word filtering on the business requirement description text to obtain a requirement word sequence; The sequence of demand words is input into a pre-trained semantic encoding model to encode the contextual associations of each word in the sequence of demand words and output the corresponding semantic feature vector. Based on the semantic feature vector, a multi-level semantic parsing network is used to extract business intent tags, functional entity sets, and dependency triplet sets, respectively. The business intent tag and each functional entity in the functional entity set are respectively compared with the component semantic vector stored in the pre-built component knowledge base. Components with similarity scores higher than the preset matching threshold are filtered out to obtain the main control component and functional components. Based on the set of dependency triples, a call relationship graph between the functional components is constructed. With the main control component as the root node, the functional components are connected according to the topological sorting order of the call relationship graph to generate the component topology structure of the business application. Based on the component topology, the application building engine is invoked to instantiate the main control component and functional components in the order of topology sorting, and the business application package is output.

[0010] Secondly, embodiments of the present invention provide a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement any step of the above-described automatic construction method for business applications based on AI semantic analysis.

[0011] Thirdly, embodiments of the present invention provide a computer-readable storage medium having a computer program stored thereon, wherein: when the computer program is executed by a processor, it implements any step of the above-described automatic construction method for business applications based on AI semantic analysis.

[0012] Compared with the prior art, the beneficial effects of the present invention are as follows: 1. By acquiring the business requirement description text input by the user and performing word segmentation and stop word filtering, the original requirement text is preprocessed in a structured manner. Its function is to remove irrelevant words and extract key requirement word sequences, which not only provides a clean input for subsequent semantic encoding, but also improves the overall processing efficiency by reducing noisy data, thereby reducing computational complexity and improving the accuracy of requirement parsing. 2. By inputting the sequence of demand words into a pre-trained semantic encoding model and encoding the contextual association of each word, a deep understanding and vectorized representation of the demand semantics are achieved. Its role is to capture the contextual information and logical relationships implied in the demand description, so that unstructured text demand is transformed into semantic feature vectors that can be processed by machines, thereby enhancing semantic understanding capabilities and supporting the extraction of complex relationships. 3. By using a multi-level semantic parsing network based on semantic feature vectors to extract business intent tags, functional entity sets, and dependency triplet sets in parallel, a multi-dimensional structured parsing of requirements is achieved. Its function is to simultaneously identify the user's core intent, functional module entities, and their dependencies. The parallel architecture with shared feature input ensures the consistency and real-time performance of the parsing, thereby transforming vague requirement descriptions into clear structured elements, improving parsing efficiency and ensuring the integrity of business logic. 4. By performing cosine similarity matching between business intent tags and functional entity sets and a pre-built component knowledge base, and filtering high-similarity components, a precise mapping from semantic elements to specific software components is achieved. Its function is to automatically match the optimal component based on semantic vector similarity, reduce manual intervention, and ensure the accuracy and reliability of component selection through preset matching thresholds, thereby improving component matching accuracy and accelerating the application building process. 5. By constructing a call relationship graph based on the set of dependency triples and generating a component topology structure by sorting the topology with the master component as the root node, a visual modeling and orderly organization of the call relationship between components is achieved. Its function is to transform the dependency relationship into an executable structured layout. Through loop detection and topology sorting, the acyclicity of the structure and the executable order are ensured, thereby providing a clear component connection blueprint for the automatic build engine, achieving the optimization of component scheduling order and ensuring the stability of application operation. 6. By calling the application build engine based on the component topology to instantiate components in topological order and output application packages, the automated generation from topology to deployable application is realized. Its role is to directly transform logical design into runnable code. Sequential instantiation ensures the correctness of component initialization dependencies, thereby completing the fully automated construction process from requirement description to final application. This achieves the beneficial effects of significantly shortening the development cycle and reducing human coding errors. Attached Figure Description

[0013] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. Wherein: Figure 1 A flowchart for an automated construction method for business applications based on AI semantic analysis. Detailed Implementation

[0014] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments.

[0015] Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without inventive effort should fall within the scope of protection of this invention.

[0016] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.

[0017] As mentioned in the background section, existing technologies based on no-code or semantic analysis generally suffer from problems such as a disconnect between semantic understanding of business requirements and the application building process, reliance on manual rules for matching functional components, and a lack of automatic organization mechanisms for business function dependencies. To address these issues, this invention provides a method for automatically building business applications based on AI semantic analysis.

[0018] Reference Figure 1 , Figure 1 This is a flowchart illustrating an automatic construction method for business applications based on AI semantic analysis according to an embodiment of the present invention. Figure 1 As shown, an automated business application construction method based on AI semantic analysis includes: S1: Obtain the business requirement description text input by the user, and perform word segmentation and stop word filtering on the business requirement description text to obtain the requirement word sequence; S2: Input the demand word sequence into the pre-trained semantic encoding model, encode the contextual association of each word in the demand word sequence, and output the corresponding semantic feature vector; S3: Based on semantic feature vectors, a multi-level semantic parsing network is used to extract business intent tags, functional entity sets, and dependency triplet sets respectively; S4: Perform cosine similarity calculations between the business intent tags and each functional entity in the functional entity set and the component semantic vectors stored in the pre-built component knowledge base, and filter out components with similarity scores higher than the preset matching threshold to obtain the main control component and functional components. S5: Construct a call relationship graph between functional components based on the set of dependency triples, with the main control component as the root node, and connect each functional component according to the topological sorting order of the call relationship graph to generate the component topology structure of the business application; S6: Based on the component topology, the application build engine is called to instantiate the main control component and functional components in the order of topology sorting, and output the business application package.

[0019] In this embodiment of the application, step S1 includes: S1.1: Receive the original requirement text input by the user through the human-computer interaction interface, store it in the text buffer, and perform encoding format detection on the original requirement text. Convert the original requirement text that is not in UTF-8 encoding format to UTF-8 encoding format to obtain the standard encoded requirement text. S1.2: Perform character-level cleaning on the standard encoding requirement text, removing HTML tags, URL links, emoticons, and consecutive repeated whitespace characters from the standard encoding requirement text, while retaining Chinese characters, English characters, numeric characters, and punctuation marks from the standard encoding requirement text, to obtain the cleaned requirement text; S1.3: Perform sentence boundary recognition on the cleaned requirement text, using periods, question marks and exclamation marks as sentence separators, divide the cleaned requirement text into several requirement sentences, and obtain a set of requirement sentences, wherein the set of requirement sentences contains at least one requirement sentence. S1.4: A word segmentation model based on conditional random fields is used to segment each demand sentence in the demand sentence set into words; It should be noted that this word segmentation model is trained on a large-scale business corpus and incorporates a pre-built business domain dictionary to achieve priority identification and overall segmentation of professional terms and business vocabulary, and outputs an initial word sequence set corresponding to the set of required sentences, where each initial word sequence in the initial word sequence set contains several word elements.

[0020] S1.5: Load the pre-built multi-level stop word list; Preferably, the multi-level stop word list includes a general stop word sub-list and a business-irrelevant word sub-list; the general stop word sub-list stores modal particles, auxiliary words, and conjunctions; the business-irrelevant word sub-list stores high-frequency generalized words that are unrelated to business semantics; S1.6: Traverse each word element of each initial word sequence in the initial word sequence set, and match each word element with the word entries in the multi-level stop word list one by one. Delete word elements that successfully match any word entry in the multi-level stop word list, and keep word elements that do not successfully match, to obtain the filtered word sequence set; S1.7: Based on each filtered word sequence in the filtered word sequence set, concatenate them according to the original order of the corresponding requirement sentences in the requirement sentence set, insert sentence separators between adjacent filtered word sequences, and generate requirement word sequences, wherein the requirement word sequences maintain the same word order structure as the original requirement text.

[0021] In this embodiment of the application, step S2 includes: The semantic encoding model is trained on a business domain corpus (including documents such as business requirements, system design, and functional specifications). Its architecture includes a word embedding layer, a positional encoding layer, a multi-layer Transformer encoding layer, and a feature aggregation layer. The pre-training task is a masked language model. After training, when the prediction accuracy of the semantic encoding model on the reserved validation set is higher than a preset performance threshold, its parameters are saved for use in the online phase.

[0022] S2.1: Construct a pre-trained semantic coding model, which includes a word embedding layer, a positional coding layer, a multi-layer self-attention coding layer, and a feature aggregation layer; Furthermore, a business domain corpus is collected, and text preprocessing is performed on each document in the business domain corpus, including encoding format unification, character cleaning, and word segmentation, to obtain a pre-training corpus set; a business domain vocabulary is constructed, the frequency of each word in the pre-training corpus set is counted, words with a frequency higher than a preset frequency threshold are retained, and special markers are added, including sentence separator [SEP], mask marker [MASK], unknown word marker [UNK], and padding marker [PAD], to generate a vocabulary mapping table; the vocabulary mapping table establishes a bidirectional mapping relationship between words and vocabulary indexes.

[0023] Furthermore, the network structure of the semantic encoding model is initialized, specifically including: initializing the word embedding layer, constructing a word vector matrix, and randomly initializing the word vector matrix using a Xavier uniform distribution, where the number of rows in the word vector matrix equals the total number of words in the vocabulary mapping table, and the number of columns equals the preset embedding dimension d; initializing the positional encoding layer, using sine and cosine positional encoding functions to pre-calculate the positional encoding vectors for each position within the maximum sequence length range, generating a positional encoding matrix; initializing a multi-layer self-attention encoding layer, setting the number of layers in the self-attention encoding layer to L, with each layer containing a multi-head self-attention module and a feedforward neural network module; the number of attention heads in the multi-head self-attention module is H, initializing the query weight matrix, key weight matrix, and value weight matrix, the feedforward neural network module containing two fully connected layers, the hidden layer dimension being four times the preset embedding dimension d, and the activation function using the GELU function; and initializing the feature aggregation layer, constructing an attention weight calculation network to calculate the aggregation weights of each word encoding vector.

[0024] Specifically, the pre-training task of the masked language model is constructed. For each training sample in the pre-training corpus, a word position with a preset mask ratio is randomly selected, and the word corresponding to the word position is replaced with a mask marker [MASK] to generate a masked training sample and a corresponding mask position label. The pre-training process of the semantic coding model is then executed, which includes: inputting the masked training sample into the semantic coding model and outputting the predicted word probability distribution for each mask position; calculating the cross-entropy loss between the predicted word probability distribution and the real words corresponding to the mask position labels; using the Adam optimizer to calculate the gradient of each network parameter based on the cross-entropy loss and updating the network parameters of the semantic coding model; and iteratively executing the above training process according to a preset batch size and preset training rounds until the cross-entropy loss converges to below a preset loss threshold.

[0025] Furthermore, the pre-trained semantic coding model is validated. The prediction accuracy of the semantic coding model on the masked language model task is calculated using a reserved validation corpus. When the prediction accuracy is higher than the preset accuracy threshold, the network parameters of the semantic coding model are saved to the model storage path, thus completing the pre-training construction of the semantic coding model. The preset performance accuracy threshold needs to be determined comprehensively by analyzing the performance distribution on the validation set based on the requirements of the business scenario for the model's semantic understanding ability.

[0026] S2.2: Match each word element of the required word sequence with the vocabulary mapping table of the semantic coding model to obtain the vocabulary index corresponding to each word element, and obtain the vocabulary index sequence; It should be noted that the length of the vocabulary index sequence is equal to the number of lexical units in the required word sequence.

[0027] S2.3: Input the vocabulary index sequence into the word embedding layer and output the word embedding vector sequence; Specifically, the word embedding layer queries the pre-trained word vector matrix for each word index in the word index sequence, obtains the word embedding vector corresponding to each word index, and outputs a word embedding vector sequence, where the dimension of each word embedding vector in the word embedding vector sequence is the preset embedding dimension d.

[0028] S2.4: Generate a position encoding vector sequence through a position encoding layer based on the position information of each word index in the word index sequence; Furthermore, the positional encoding layer uses sine and cosine positional encoding functions to generate a positional encoding vector for the i-th position in the word index sequence; the even-numbered dimensions of the positional encoding vector are calculated using a sine function, and the odd-numbered dimensions are calculated using a cosine function; the dimension of each positional encoding vector in the positional encoding vector sequence is the same as the preset embedding dimension d.

[0029] S2.5: Add the word embedding vector sequence and the position encoding vector sequence at corresponding positions to obtain the input embedding vector sequence; S2.6: Input the input embedding vector sequence into a multi-layer self-attention encoding layer, perform multi-head self-attention calculation, and output the final encoded vector sequence; Furthermore, in each layer of the multi-layer self-attention encoding layer, the multi-head self-attention computation specifically includes: multiplying the input embedding vector sequence with the query weight matrix, key weight matrix, and value weight matrix respectively to obtain the query vector sequence, key vector sequence, and value vector sequence; calculating the dot product of each query vector in the query vector sequence with all key vectors in the key vector sequence, dividing the dot product by a scaling factor, and then performing softmax normalization to obtain the attention weight matrix; multiplying the attention weight matrix with the value vector sequence to obtain the context encoding vector sequence of the current attention head; and concatenating the context encoding vector sequences output by multiple attention heads and passing them through a linear projection layer to output the multi-head attention output vector sequence.

[0030] Preferably, the multi-head attention output vector sequence and the input embedding vector sequence are subjected to residual connection and layer normalization. The processed vector sequence is then input into a feedforward neural network layer, which contains two fully connected layers and an activation function, and outputs an encoded feature vector sequence. The encoded feature vector sequence is then subjected to residual connection and layer normalization again and used as the input to the next self-attention encoding layer. This process is passed layer by layer until the last layer of the multi-layer self-attention encoding layer outputs the final encoded vector sequence.

[0031] S2.7: Input the final encoded vector sequence into the feature aggregation layer and output the semantic feature vector corresponding to the required word sequence.

[0032] Specifically, the feature aggregation layer performs a weighted average pooling operation on each encoding vector in the final encoding vector sequence, and performs a weighted sum based on the attention weights of the corresponding words in each encoding vector, outputting the semantic feature vector corresponding to the required word sequence, where the dimension of the semantic feature vector is the preset embedding dimension d.

[0033] In this embodiment of the application, step S3 includes: S3.1: Load the pre-built multi-level semantic parsing network; Furthermore, the multi-level semantic parsing network includes a business intent classification sub-network, a functional entity recognition sub-network, and a dependency extraction sub-network. The business intent classification sub-network, the functional entity recognition sub-network, and the dependency extraction sub-network share semantic feature vectors as input and adopt a parallel processing architecture to parse the semantic feature vectors simultaneously to obtain business intent labels, functional entity sets, and dependency triplet sets.

[0034] S3.1.1: Input the semantic feature vector into the business intent classification sub-network, which includes an intent feature mapping layer and an intent classification layer; Furthermore, the intent feature mapping layer maps the semantic feature vector to the intent feature space through a fully connected network to obtain the intent feature vector; the intent classification layer performs multi-classification calculation on the intent feature vector, multiplies the intent feature vector with the preset business intent category weight matrix, performs softmax normalization, outputs the intent probability distribution vector, and selects the preset business intent category corresponding to the element with the largest probability value in the intent probability distribution vector as the business intent label, where each element in the intent probability distribution vector corresponds to the probability value of a preset business intent category; the business intent label represents the overall functional target type of the business application described by the demand word sequence.

[0035] S3.1.2: Input the semantic feature vector into the functional entity recognition sub-network, which includes an entity feature decoding layer and an entity boundary annotation layer; Specifically, the entity feature decoding layer uses a bidirectional long short-term memory network to perform sequence decoding on the semantic feature vector, capturing the forward and backward context information at each position in the semantic feature vector, and outputting an entity candidate feature sequence. The entity boundary labeling layer performs BIO label prediction on each position in the entity candidate feature sequence, and outputs an entity label sequence, where the BIO labels include the entity start label B, the entity internal label I, and the non-entity label O. Based on the positional distribution of the entity start label B and the entity internal label I in the entity label sequence, the position labeled as the entity start label B is taken as the starting boundary of the functional entity, and the positions continuously labeled as the entity internal label I after the starting boundary are taken as the continuation part of the functional entity, until the non-entity label O or the next entity start label B is encountered. The boundary range of each functional entity is determined based on the starting boundary and the continuation part. The word combination within the boundary range is extracted from the demand word sequence to obtain the functional entity set, which contains at least one functional entity.

[0036] S3.1.3: Input the semantic feature vector and the set of functional entities into the dependency extraction sub-network, which includes an entity pair encoding layer and a relation classification layer; Furthermore, the entity pair encoding layer pairs functional entities in the functional entity set to generate a functional entity pair set. For each functional entity pair in the functional entity pair set, the feature vectors of the corresponding positions of the two functional entities in the semantic feature vector are concatenated to obtain the entity pair feature vector. The functional entity pair set corresponds to the generated entity pair feature vector set. The relation classification layer performs relation type discrimination on each entity pair feature vector in the entity pair feature vector set. After multiplying the entity pair feature vector with a preset relation type weight matrix, it performs softmax normalization and outputs a relation probability distribution vector. Relationship types with probability values ​​exceeding a preset relation threshold are selected from the relation probability distribution vector, and functional entity pairs with no relation type are filtered out. Functional entity pairs with valid relation types and their corresponding relation types are retained. The relation types include data flow relation, call relation, trigger relation, and no relation.

[0037] Furthermore, based on the functional entity pairs with valid relation types and their corresponding relation types, dependency triples are constructed. All dependency triples are then aggregated to obtain a dependency triple set. The format of the dependency triple is <source functional entity, relation type, target functional entity>. The source functional entity is the first functional entity in the functional entity pair, the target functional entity is the second functional entity in the functional entity pair, and the relation type is the valid relation type determined by the relation classification layer.

[0038] In this embodiment of the application, step S4 includes: S4.1: Load the pre-built component knowledge base, which includes a main component library and a functional component library; Specifically, the master control component library stores several master control component records, each containing a master control component identifier, master control component name, master control component function description, and master control component semantic vector; the function component library stores several function component records, each containing a function component identifier, function component name, function component function description, function component input interface definition, function component output interface definition, and function component semantic vector; both the master control component semantic vector and the function component semantic vector are obtained by pre-encoding the corresponding function description text through a semantic coding model.

[0039] S4.2: Input the business intent label into the semantic encoding model, perform semantic encoding on the business intent label, and output the business intent semantic vector, wherein the dimension of the business intent semantic vector is the same as the dimension of the main control component semantic vector; S4.3: Traverse each master control component record in the master control component library and calculate the cosine similarity between the business intent semantic vector and the master control component semantic vector in each master control component record; Furthermore, the formula for calculating cosine similarity is as follows: divide the dot product of the business intent semantic vector and the main control component semantic vector by the product of the magnitude of the business intent semantic vector and the magnitude of the main control component semantic vector to obtain the main control component similarity score; associate and store the main control component similarity score with the corresponding main control component identifier to generate a main control component similarity list.

[0040] S4.4: Filter the main control component records from the main control component similarity list whose main control component similarity scores are higher than the preset main control matching threshold; Furthermore, when the number of master control component records that meet the filtering conditions is greater than one, the master control component record with the highest similarity score is selected; when the number of master control component records that meet the filtering conditions is equal to one, the master control component record that meets the filtering conditions is directly selected; based on the master control component identifier in the selected master control component record, the corresponding master control component is obtained from the master control component library as the master control component output corresponding to the business intent tag.

[0041] S4.5: Traverse each functional entity in the functional entity set and input each functional entity into the semantic encoding model; Specifically, the semantic encoding model performs semantic encoding on functional entities, outputs functional entity semantic vectors, associates and stores functional entities with their corresponding semantic vectors, and generates a functional entity semantic vector mapping table. The functional entity semantic vector mapping table contains each functional entity in the functional entity set and its corresponding semantic vector.

[0042] S4.6: For each functional entity semantic vector in the functional entity semantic vector mapping table, traverse each functional component record in the functional component library to calculate the cosine similarity and generate a functional component similarity matrix. Furthermore, cosine similarity is calculated between the semantic vector of the functional entity and the semantic vector of the functional component in each functional component record to obtain the functional component similarity score. The functional component similarity score is associated with and stored with the corresponding functional component identifier and functional entity to generate a functional component similarity matrix. The rows of the functional component similarity matrix correspond to each functional entity in the functional entity set, and the columns correspond to each functional component record in the functional component library.

[0043] S4.7: For each row in the functional component similarity matrix, filter the functional component records with the highest similarity scores that are higher than the preset functional matching threshold. When the number of functional component records that meet the filtering conditions is zero, mark the corresponding functional entity as unmatched, remove the functional entities marked as unmatched, generate a functional entity component mapping table, and obtain the functional components corresponding to each functional entity.

[0044] Furthermore, the system filters functional component records whose similarity scores are higher than a preset functional matching threshold. When the number of functional component records meeting the filtering criteria is greater than one, the functional component record with the highest similarity score is selected. When the number of functional component records meeting the filtering criteria is equal to one, the functional component record that meets the filtering criteria is directly selected. When the number of functional component records meeting the filtering criteria is zero, the corresponding functional entity is marked as unmatched. Based on the functional component identifier in the selected functional component record, the corresponding functional component is retrieved from the functional component library to establish a mapping relationship between functional entities and functional components. The mapping relationship between each functional entity and its corresponding functional component in the functional entity set is summarized, functional entities marked as unmatched are removed, a functional entity component mapping table is generated, and the functional component corresponding to each record is output as the functional component corresponding to each functional entity in the functional entity set. Each record in the functional entity component mapping table contains a functional entity, a functional component identifier, and a functional component similarity score.

[0045] In this embodiment of the application, step S5 includes: S5.1: Perform loop detection on the call relationship graph, use a depth-first search algorithm to traverse each node in the call relationship graph, and mark the access status; Specifically, the construction of the relationship graph includes: S5.1.1: Based on the functional entity component mapping table, replace the source functional entity of each dependency triplet in the dependency triplet set with the corresponding source functional component and the target functional entity with the corresponding target functional component to generate a component dependency triplet set; S5.1.2: Initialize the data structure of the call relationship graph to obtain the initial node set, wherein the call relationship graph is represented by a directed graph structure; the directed graph structure includes a node set and a directed edge set; The main control component is added as the first node in the node set, and each functional component in the functional entity component mapping table is added as the remaining node in the node set in sequence to obtain the initial node set of the call relationship graph.

[0046] S5.1.3: Traverse the component dependency triples in the component dependency triples set, determine the direction and edge type attributes of the directed edges according to the relation type, create directed edges from the source functional component to the target functional component, and obtain the set of directed edges between components; In an optional embodiment, if the relationship type is a data flow relationship, a directed edge is created from the source functional component to the target functional component, and the edge type attribute of the directed edge is set to data transmission; if the relationship type is a call relationship, a directed edge is created from the source functional component to the target functional component, and the edge type attribute of the directed edge is set to method call; if the relationship type is a trigger relationship, a directed edge is created from the source functional component to the target functional component, and the edge type attribute of the directed edge is set to event trigger; the created directed edges are added to the directed edge set to obtain the inter-component directed edge set.

[0047] S5.1.4: Analyze the in-degree of each functional component in the initial node set, and filter functional components with an in-degree of zero and no directed edges connected to the main control component, where the in-degree is the number of directed edges pointing to the functional component; S5.1.5: Starting from the main control component, create initial call directed edges for each of the selected functional components, set the edge type attribute of the initial call directed edge to initial call, and add it to the set of directed edges between components to obtain a complete set of directed edges.

[0048] S5.1.6: Construct a call relationship graph based on the initial node set and the complete directed edge set. S5.2: When a path is detected that starts from the current node, passes through several directed edges, and returns to the current node, it is determined that there is a cycle in the call relationship graph. The directed edge with the lowest edge weight in the cycle is located and deleted. The cycle detection and deletion operation is repeated until there are no cycles in the call relationship graph, and a cycle-free call relationship graph is obtained. S5.3: Perform topological sorting on the acyclic call graph to obtain the component topological sorting sequence, specifically including: Furthermore, the topology sorting queue and the topology sorting result list are initialized, and the main control component is enqueued as the first element of the topology sorting queue. The head node is taken out of the topology sorting queue and added to the topology sorting result list. All successor nodes pointed to by the outgoing edges of the head node are traversed, and the in-degree of each successor node is decremented by one. When the in-degree of a successor node is reduced to zero, the successor node is added to the topology sorting queue. The take-out and enqueue operations are repeated until the topology sorting queue is empty, resulting in the component topology sorting sequence. The order of the nodes in the component topology sorting sequence represents the execution order of the functional components.

[0049] S5.4: Construct the component topology structure based on the component topology sorting sequence and the complete set of directed edges, where the component topology structure includes node hierarchy information and edge connection information; Furthermore, the node hierarchy information records the hierarchy number of each functional component in the component topology sorting sequence. The hierarchy number of the master component is zero, and the hierarchy number of each other functional component is its position index in the component topology sorting sequence. The edge connection information records the source node identifier, target node identifier, and edge type attribute of each directed edge in the complete directed edge set.

[0050] S5.5: Verify the connectivity of the component topology. Starting from the master component, perform a breadth-first traversal along each directed edge in the edge connection information and mark the reachable functional components. S5.6: Compare the reachable functional components with each functional component in the initial node set, update the edge connection information, and output the component topology; In an optional embodiment, if there is an unreachable functional component, a supplementary directed edge is created from the main control component to the unreachable functional component. The edge type attribute of the supplementary directed edge is set to the default call. The supplementary directed edge is added to the edge connection information, the component topology is updated, and the component topology of the business application is output.

[0051] In this embodiment of the application, step S6 includes: S6.1: Load the application building engine, parse the node hierarchy information and edge connection information in the component topology, extract the component topology sorting sequence from the node hierarchy information, extract the source node identifier, target node identifier and edge type attribute of each directed edge from the edge connection information, and establish a component call relationship index table. Specifically, the application building engine includes a component instantiation module, an interface configuration module, a parameter binding module, and an application packaging module. The component instantiation module is used to create component runtime instances based on component identifiers. The interface configuration module is used to establish data transmission channels between components. The parameter binding module is used to set the input and output parameter mappings of components. The application packaging module is used to encapsulate component instances and configuration information into deployable business application packages.

[0052] It should be noted that the component call relationship index table records the list of predecessor components, the list of successor components, and the corresponding edge type attributes for each functional component.

[0053] S6.1.1: The component instantiation module reads the component code templates corresponding to the main control component and each functional component from the component knowledge base according to the component topology sorting sequence, creates the main control component instance and functional component instance set in sequence, allocates instance identifier and running memory space to each component instance, and registers each component instance to the application runtime container; Furthermore, according to the arrangement order of each functional component in the component topology sorting sequence, the component instantiation module instantiates each functional component in turn. For each functional component in the component topology sorting sequence, it reads the corresponding functional component record from the functional component library of the component knowledge base, obtains the component code template, functional component input interface definition and functional component output interface definition from the functional component record, creates a functional component instance according to the component code template, allocates a unique instance identifier and running memory space to the functional component instance, registers the functional component instance to the application runtime container, and obtains a set of functional component instances.

[0054] S6.1.2: The interface configuration module configures the data transmission interface between the main control component instance and each functional component instance based on the component call relationship index table. It matches and verifies the output parameter type of the source component instance with the input parameter type of the target component instance. When the output parameter type matches the input parameter type, a data transmission channel is created from the output port of the source component instance to the input port of the target component instance. The channel identifier, source port identifier, and target port identifier of the data transmission channel are recorded in the interface configuration table. S6.1.3: For each directed edge whose edge type attribute is method call or event trigger, the parameter binding module generates default parameter values ​​based on the semantic information of the corresponding functional entity in the business intent tag and functional entity set, binds the required parameters of each component instance to the corresponding default parameter values ​​and records them in the parameter binding table; S6.1.4: The application packaging module summarizes the main control component instances, functional component instances, interface configuration table and parameter binding table, generates application description file, and outputs business application package; Furthermore, the application description file uses a structured format to record the node hierarchy information of the component topology, the configuration information of each data transmission channel in the interface configuration table, and the parameter configuration information of each component in the parameter binding table; the component code files of the main control component instance, the component code files of each functional component instance in the functional component instance set, and the application description file are packaged into a unified application directory structure.

[0055] Preferably, the application directory structure is checked for integrity, verifying whether the component code files of the main control component instance and each functional component instance are complete, whether the source port identifier and target port identifier of each data transmission channel in the interface configuration table are valid, and whether all required parameters in the parameter binding table have been bound to parameter values. When the integrity check passes, the application packaging module compresses and signs the application directory structure to generate a business application package, which contains application metadata, component code set, interface configuration data and parameter binding data, and outputs the business application package to the specified application storage path.

[0056] In summary, this invention extracts core requirement words through word segmentation and filtering, providing purified input for semantic encoding and improving processing efficiency; the semantic encoding model transforms text into vectors, capturing deep contextual relationships and providing a foundation for structured parsing; a multi-level parsing network is used to extract intent, entities, and dependencies in parallel, achieving a complete structured representation of requirement elements; corresponding components are selected from the component library through semantic matching, achieving a precise mapping from requirements to reusable components; an acyclic topology is constructed based on dependencies, forming an executable component connection blueprint; finally, components are instantiated in topological order to generate applications, completing an automated construction loop from requirements to finished product.

[0057] This embodiment also provides a computer device applicable to the automatic construction method of business applications based on AI semantic analysis, including a memory and a processor; the memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions to realize the automatic construction method of business applications based on AI semantic analysis as proposed in the above embodiment.

[0058] The computer device can be a terminal, comprising a processor, memory, communication interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, carrier networks, NFC (Near Field Communication), or other technologies. The display screen can be an LCD screen or an e-ink screen. The input devices can be a touch layer covering the display screen, buttons, a trackball, or a touchpad on the computer device's casing, or an external keyboard, touchpad, or mouse.

[0059] This embodiment also provides a storage medium on which a computer program is stored. When the program is executed by a processor, it implements the method for automatically building business applications based on AI semantic analysis as proposed in the above embodiments.

[0060] The storage medium proposed in this embodiment and the data storage method proposed in the above embodiments belong to the same inventive concept. Technical details not described in detail in this embodiment can be found in the above embodiments, and this embodiment has the same beneficial effects as the above embodiments.

[0061] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.

Claims

1. A method for automatically constructing business applications based on AI semantic analysis, characterized in that: include, Obtain the business requirement description text input by the user, and perform word segmentation and stop word filtering on the business requirement description text to obtain a requirement word sequence; The sequence of demand words is input into a pre-trained semantic encoding model to encode the contextual associations of each word in the sequence of demand words and output the corresponding semantic feature vector. Based on the semantic feature vector, a multi-level semantic parsing network is used to extract business intent tags, functional entity sets, and dependency triplet sets, respectively. The business intent tag and each functional entity in the functional entity set are respectively compared with the component semantic vector stored in the pre-built component knowledge base. Components with similarity scores higher than the preset matching threshold are filtered out to obtain the main control component and functional components. Based on the set of dependency triples, a call relationship graph between the functional components is constructed. With the main control component as the root node, the functional components are connected according to the topological sorting order of the call relationship graph to generate the component topology structure of the business application. Based on the component topology, the application building engine is invoked to instantiate the main control component and functional components in the order of topology sorting, and the business application package is output.

2. The method for automatically constructing business applications based on AI semantic analysis as described in claim 1, characterized in that: The method for generating the component topology is as follows: Loop detection is performed on the call relationship graph by using a depth-first search algorithm to traverse each node in the call relationship graph and marking the access status; When a path is detected that starts from the current node, passes through several directed edges, and returns to the current node, it is determined that there is a cycle in the call relationship graph. The directed edge with the lowest edge weight in the cycle is located and deleted. The cycle detection and deletion operation is repeated until there are no cycles in the call relationship graph, and a cycle-free call relationship graph is obtained. Perform topological sorting on the acyclic call relationship graph to obtain the component topological sorting sequence; The component topology structure is constructed based on the component topology sorting sequence and the complete set of directed edges, wherein the component topology structure includes node hierarchy information and edge connection information; The connectivity of the component topology is verified by starting from the main control component and performing a breadth-first traversal along each directed edge in the edge connection information to mark reachable functional components. Compare the reachable functional components with each functional component in the initial node set, update the edge connection information, and output the component topology.

3. The method for automatically constructing business applications based on AI semantic analysis as described in claim 2, characterized in that: The method for obtaining the component topology sorting sequence is as follows: Initialize the topology sorting queue and the topology sorting result list, and enqueue the main control component as the first element of the topology sorting queue; Take the head node from the topological sorting queue, add the head node to the topological sorting result list, traverse all the successor nodes pointed to by the outgoing edges of the head node, and decrement the in-degree of each successor node by one. When the in-degree of a successor node decreases to zero, the successor node is added to the topological sorting queue. Repeat the retrieval and enqueue operations until the topology sorting queue is empty to obtain the component topology sorting sequence.

4. The method for automatically constructing business applications based on AI semantic analysis as described in claim 2, characterized in that: The method for constructing the call relationship graph is as follows: Based on the functional entity component mapping table, the source functional entity of each dependency triplet in the dependency triplet set is replaced with the corresponding source functional component, and the target functional entity is replaced with the corresponding target functional component to generate a component dependency triplet set. The data structure of the call relationship graph is initialized to obtain an initial set of nodes, wherein the call relationship graph is represented by a directed graph structure; the directed graph structure includes a set of nodes and a set of directed edges; Traverse each component dependency triple in the set of component dependency triples, determine the direction and type attributes of the directed edges according to the relation type, create directed edges from the source functional component to the target functional component, and obtain the set of directed edges between components. Analyze the in-degree of each functional component in the initial node set, and filter out functional components with an in-degree of zero and no directed edge connection to the main control component; Starting from the main control component, initial call directed edges are created for each of the selected functional components. The edge type attribute of the initial call directed edge is set to initial call, and it is added to the set of directed edges between components to obtain a complete set of directed edges. Based on the initial set of nodes and the complete set of directed edges, a call relationship graph is constructed.

5. The method for automatically constructing business applications based on AI semantic analysis as described in claim 4, characterized in that: The direction and type attributes of directed edges are determined based on the relation type, including: If the relationship type is a data flow relationship, then create a directed edge from the source functional component to the target functional component, and set the edge type attribute of the directed edge to data transmission. If the relationship type is a call relationship, then create a directed edge from the source functional component to the target functional component, and set the edge type property of the directed edge to method call; If the relationship type is triggering relationship, then create a directed edge from the source functional component to the target functional component, and set the edge type property of the directed edge to event triggering.

6. The method for automatically constructing business applications based on AI semantic analysis as described in claim 1, characterized in that: The multi-level semantic parsing network includes a business intent classification sub-network, a functional entity recognition sub-network, and a dependency extraction sub-network. The business intent classification sub-network, the functional entity recognition sub-network, and the dependency extraction sub-network share a semantic feature vector as input and adopt a parallel processing architecture to parse the semantic feature vector simultaneously to obtain the business intent label, the functional entity set, and the dependency triplet set.

7. The method for automatically constructing business applications based on AI semantic analysis as described in claim 6, characterized in that: The method for obtaining the semantic feature vector is as follows: Construct a pre-trained semantic encoding model, wherein the semantic encoding model includes a word embedding layer, a positional encoding layer, a multi-layer self-attention encoding layer, and a feature aggregation layer; The word elements of the required word sequence are matched with the vocabulary mapping table of the semantic encoding model to obtain the vocabulary index corresponding to each word element, thus obtaining the vocabulary index sequence. The vocabulary index sequence is input into the word embedding layer, and the word embedding vector sequence is output. Based on the position information of each word index in the word index sequence, a position encoding vector sequence is generated through the position encoding layer; The word embedding vector sequence and the position encoding vector sequence are added together at corresponding positions to obtain the input embedding vector sequence; The input embedding vector sequence is input into the multi-layer self-attention coding layer to perform multi-head self-attention calculation and output the final encoded vector sequence. The final encoded vector sequence is input into the feature aggregation layer, and the semantic feature vector corresponding to the required word sequence is output.

8. The method for automatically constructing business applications based on AI semantic analysis as described in claim 7, characterized in that: The semantic encoding model is pre-trained based on a business domain corpus; the business domain corpus includes business requirement documents, system design documents, and functional specification documents.

9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, it implements the steps of the automatic construction method for business applications based on AI semantic analysis as described in any one of claims 1 to 8.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by the processor, it implements the steps of the automatic construction method for business applications based on AI semantic analysis as described in any one of claims 1 to 8.